From 9aa469a20cb48867d414d024c19db770bec79d75 Mon Sep 17 00:00:00 2001
From: hxp <ale99527@vip.qq.com>
Date: 星期四, 28 三月 2019 15:31:28 +0800
Subject: [PATCH] 6373 【后端】【2.0】删除无用功能代码、封包、配置(新手指导员)

---
 /dev/null                                                                              |   61 --------------------
 ServerPython/CoreServerGroup/GameServer/Script/Player/PlayerControl.py                 |   14 ----
 ServerPython/CoreServerGroup/GameServer/Script/Player/PlayerQuery.py                   |   10 ---
 ServerPython/CoreServerGroup/GameServer/Script/ChConfig.py                             |    2 
 ServerPython/ZoneServerGroup/map1_8G/MapServer/MapServerData/Script/Player/ChPlayer.py |   47 +++++++--------
 ServerPython/ZoneServerGroup/map1_8G/MapServer/MapServerData/Script/ChConfig.py        |    3 -
 6 files changed, 22 insertions(+), 115 deletions(-)

diff --git a/ServerPython/CoreServerGroup/GameServer/Script/ChConfig.py b/ServerPython/CoreServerGroup/GameServer/Script/ChConfig.py
index 6aac95c..da10f58 100644
--- a/ServerPython/CoreServerGroup/GameServer/Script/ChConfig.py
+++ b/ServerPython/CoreServerGroup/GameServer/Script/ChConfig.py
@@ -633,8 +633,6 @@
 Def_PlayerKey_IsLoginToMergeServer = "IsLoginToMergeServer"  #是否要登陆跨服服务器
 Def_PlayerKey_IsCrossPKMatching = "IsCrossPKMatching"  #是否跨服匹配中
 
-Def_PlayerKey_FreshmanGuiderDay = "FreshmanGuiderDay"  #新手指导员天数
-
 Def_PlayerKey_PlayerFromPID = "PlayerFromPID"  #pid
 
 Def_PDict_LoginMapID = "LoginMapID"  #登录处理时的地图ID
diff --git a/ServerPython/CoreServerGroup/GameServer/Script/GM/Commands/GMT_FreshmanGuide.py b/ServerPython/CoreServerGroup/GameServer/Script/GM/Commands/GMT_FreshmanGuide.py
deleted file mode 100644
index e594254..0000000
--- a/ServerPython/CoreServerGroup/GameServer/Script/GM/Commands/GMT_FreshmanGuide.py
+++ /dev/null
@@ -1,53 +0,0 @@
-#!/usr/bin/python
-# -*- coding: GBK -*-
-#-------------------------------------------------------------------------------
-#
-#-------------------------------------------------------------------------------
-#
-##@package GM.Commands.GMT_FreshmanGuide
-#
-# @todo:新手指导员
-# @author hxp
-# @date 2014-02-28
-# @version 1.0
-#
-# 详细描述: 新手指导员
-#
-#---------------------------------------------------------------------
-"""Version = 2014-02-28 21:10"""
-#---------------------------------------------------------------------
-#导入
-import GMCommon
-import GameWorld
-import ChConfig
-#---------------------------------------------------------------------
-#全局变量
-#---------------------------------------------------------------------
-"""Version = 2012-08-27 13:59"""
-#---------------------------------------------------------------------
-
-
-## 执行逻辑
-#  @param curPlayer 当前玩家
-#  @param gmCmdDict: 命令字典
-#  @return None
-#  @remarks 函数详细说明.
-def OnExec(orderId, gmCmdDict):
-    queryType = gmCmdDict.get(GMCommon.Def_GMKey_QueryType, '')
-    playerFind = gmCmdDict.get(GMCommon.Def_GMKey_PlayerFind, '')
-    value = GameWorld.ToIntDef(gmCmdDict.get('value', ''))
-    
-    if queryType == GMCommon.Def_GMKey_PlayerAccID:
-        queryType = ChConfig.queryType_sqtPlayerByAccID
-    
-    elif queryType == GMCommon.Def_GMKey_PlayerName:
-        queryType = ChConfig.queryType_sqtPlayerByName
-    
-    else:
-        GMCommon.GMCommandResult(orderId, gmCmdDict, GMCommon.Def_ParamErr)
-        return
-    
-    GMCommon.GMTool_MapServer_Query(queryType, orderId, playerFind,
-                                         gmCmdDict, 'GMTFreshmanGuide', value)
-    return
-
diff --git a/ServerPython/CoreServerGroup/GameServer/Script/Player/PlayerControl.py b/ServerPython/CoreServerGroup/GameServer/Script/Player/PlayerControl.py
index 4470370..e900609 100644
--- a/ServerPython/CoreServerGroup/GameServer/Script/Player/PlayerControl.py
+++ b/ServerPython/CoreServerGroup/GameServer/Script/Player/PlayerControl.py
@@ -248,20 +248,6 @@
 #------------------------------------------------------------------------------ 
 
 
-## 设置新手指导员天数
-#  @param curPlayer: 玩家实例
-#  @param day: 天数
-#  @return: 
-def SetFreshmanGuiderDay(curPlayer, day):
-    curPlayer.SetDict(ChConfig.Def_PlayerKey_FreshmanGuiderDay, day) 
-    return
-
-## 获取新手指导员天数
-#  @param curPlayer: 玩家实例
-#  @return: 天数
-def GetFreshmanGuiderDay(curPlayer):
-    return curPlayer.GetDictByKey(ChConfig.Def_PlayerKey_FreshmanGuiderDay)
-
 ## 增加成就完成进度
 #  @param curPlayer
 #  @param successType: 成就类型
diff --git a/ServerPython/CoreServerGroup/GameServer/Script/Player/PlayerQuery.py b/ServerPython/CoreServerGroup/GameServer/Script/Player/PlayerQuery.py
index c7ab944..cd02fab 100644
--- a/ServerPython/CoreServerGroup/GameServer/Script/Player/PlayerQuery.py
+++ b/ServerPython/CoreServerGroup/GameServer/Script/Player/PlayerQuery.py
@@ -701,16 +701,6 @@
         GameWorldProcess.UpdGlobalKillCount(eval(resultName))
         return
     
-    # 新手指导员天数
-    if callName =="FreshmanGuiderDay":
-        curPlayer = GameWorld.GetPlayerManager().FindPlayerByID(srcPlayerID)
-        if not curPlayer:
-            return
-        
-        guiderDay = eval(resultName)[0]
-        PlayerControl.SetFreshmanGuiderDay(curPlayer, guiderDay)
-        return
-    
     #生成仙盟红包
     if callName == "MapServer_CreatRedPacket":
         PlayerFamilyRedPacket.MapServer_CreatRedPacket(eval(resultName))
diff --git a/ServerPython/ZoneServerGroup/map1_8G/MapServer/MapServerData/Script/ChConfig.py b/ServerPython/ZoneServerGroup/map1_8G/MapServer/MapServerData/Script/ChConfig.py
index b0da649..ec1cd76 100644
--- a/ServerPython/ZoneServerGroup/map1_8G/MapServer/MapServerData/Script/ChConfig.py
+++ b/ServerPython/ZoneServerGroup/map1_8G/MapServer/MapServerData/Script/ChConfig.py
@@ -709,7 +709,6 @@
 Def_SkillID_VipBuff = 11500     # VIPbuff
 Def_SkillID_TeamVIPBuff = 22000     # VIP队伍buff, 攻守同盟
 Def_SkillID_FBEncourageBuff = 20051     # 副本鼓舞buff
-Def_SkillID_FreshmanGuideBuff = 21219   # 新手指导员buff
 Def_SkillID_PoisonAtkBuff = 25180   # 毒攻buff
 Def_SkillID_DropOwnerBuff = 20040   # 掉落归属buff
 Def_SkillID_PetSignDay = 47111   # 灵宠签到属性技能, 单次签到的加成
@@ -3462,8 +3461,6 @@
 Def_PDict_GiveFlowerCntByDay = "GiveFlowerCntByDay"  #当日已赠送鲜次数
 Def_PDict_PackCount_FineSoul = "PackCount_FineSoul"    # 已购买精魄/符文背包格子数
 Def_PDict_KillPlayerAddActive = "KillPlayerAddActiveByDay"  # 杀人每日获得活跃度
-Def_PDict_FreshmanGuideDay = "FreshmanGuideDay"  # 玩家新手指导员剩余天数,0为不是
-Def_PDict_FreshmanGuideSpeakerCntToday = "FreshmanGuideSpeakerCntDay"  # 新手指导员今日已免费传音次数
 Def_PDict_LoginDayCnt = "PLoginDayCnt"  # 累计登陆天数
 Def_PDict_LoginDayAward = "PLoginDayAward"  # 累计登陆领取情况
 Def_PDict_CollNpcIDCollTime = "CollNpcIDCollTime_%s"   # 采集NPCID对应每日对应采集次数,%sNPCID
diff --git a/ServerPython/ZoneServerGroup/map1_8G/MapServer/MapServerData/Script/Player/ChPlayer.py b/ServerPython/ZoneServerGroup/map1_8G/MapServer/MapServerData/Script/Player/ChPlayer.py
index 40ac9b2..9796fcd 100644
--- a/ServerPython/ZoneServerGroup/map1_8G/MapServer/MapServerData/Script/Player/ChPlayer.py
+++ b/ServerPython/ZoneServerGroup/map1_8G/MapServer/MapServerData/Script/Player/ChPlayer.py
@@ -613,17 +613,14 @@
     #通知运行成功
     curPlayer.BalanceServer_PlayerLoginInitOK()
     
-    # 新手指导员上线处理
-#    #PlayerFreshmanGuide.FreshmanGuiderOnLogin(curPlayer)
-#    
     # 坐骑相关通知
     PlayerHorse.PlayerHorseLogin(curPlayer)
     
     PlayerTreasure.OnTreasureLogin(curPlayer)
     
-#    # 通知累计登陆礼
+    # 通知累计登陆礼
     PlayerLoginDayAward.OnLoginNotifyLoginDayAward(curPlayer)
-#    
+    
     # 开服活动奖励信息
     OpenServerCampaign.OnOpenServerCampaignLogin(curPlayer)
 
@@ -631,39 +628,39 @@
     GameLogic_TrialTower.OnFBPlayerLogin(curPlayer)
     # 古神禁地
     GameLogic_GodArea.GodAreaOnLogin(curPlayer)
-#    # 采集NPC次数通知
+    # 采集NPC次数通知
     NPCCommon.SyncCollNPCTime(curPlayer)
-#    
-#    # 每日活跃度
+    
+    # 每日活跃度
     PlayerActivity.OnLogin(curPlayer)
-#    
-#    # 副本进入时间
+    
+    # 副本进入时间
     FBCommon.FBOnLogin(curPlayer)
-#    
-#    #世界等级
+    
+    #世界等级
     PlayerWorldAverageLv.OnLogin(curPlayer)
-#    
+    
     # 投资理财
     PlayerGoldInvest.OnLogin(curPlayer)
-#    
-#    #属性果实使用情况
+    
+    #属性果实使用情况
     PlayerAttrFruit.AttrFruitOnLogin(curPlayer)
-#    
-#    #成就
+    
+    #成就
     PlayerSuccess.SuccOnLogin(curPlayer)
-#    
-#    #同步自动战斗配置记录
+    
+    #同步自动战斗配置记录
 #    Sync_AutoFightSetting(curPlayer)
-#    
+    
     PlayerFamily.FamilyPlayerOnLogin(curPlayer, tick)
     #改到 GameServerRefresh GameSever_PlayerInitOK后处理才能保证玩家已经在Gameserver注册
     #PlayerDienstgrad.RefreshBillBoardDienstgrad(curPlayer)
     # 称号
     PlayerDienstgrad.Sync_AllDienstgradOnLogin(curPlayer)
-#    # 资源找回OnLogin
+    # 资源找回OnLogin
     PlayerRecover.RecoverOnLogin(curPlayer)
-#
-#    # 时装
+    
+    # 时装
     PlayerCoat.OnLogin_Coat(curPlayer)
     
     # 跨服PK
@@ -687,8 +684,8 @@
     # 世界boss
     BossHurtMng.OnLogin(curPlayer)
     ChItem.Sync_ItemDayUseCnt(curPlayer)
-#    # 悬赏登录通知
-#    PlayerArrestTask.OnLogin(curPlayer)
+    # 悬赏登录通知
+    #PlayerArrestTask.OnLogin(curPlayer)
     # 符印登录通知
     PlayerRune.PlayerRuneLogin(curPlayer)
     # 仙盟红包登录通知
diff --git a/ServerPython/ZoneServerGroup/map1_8G/MapServer/MapServerData/Script/Player/PlayerFreshmanGuide.py b/ServerPython/ZoneServerGroup/map1_8G/MapServer/MapServerData/Script/Player/PlayerFreshmanGuide.py
deleted file mode 100644
index 26ccceb..0000000
--- a/ServerPython/ZoneServerGroup/map1_8G/MapServer/MapServerData/Script/Player/PlayerFreshmanGuide.py
+++ /dev/null
@@ -1,123 +0,0 @@
-#!/usr/bin/python
-# -*- coding: GBK -*-
-#-------------------------------------------------------------------------------
-#
-#-------------------------------------------------------------------------------
-#
-##@package Player.PlayerFreshmanGuide
-#
-# @todo:新手指导员
-# @author hxp
-# @date 2014-02-28
-# @version 1.0
-#
-# 详细描述: 新手指导员
-#
-#---------------------------------------------------------------------
-#"""Version = 2014-02-28 21:10"""
-
-import ChConfig
-import BuffSkill
-import GameWorld
-import SkillCommon
-import ReadChConfig
-import PlayerControl
-
-
-## 设置新手指导员有效天数
-#  @param curPlayer 玩家实例
-#  @param day 天数,为0时取消新手指导员功能
-#  @param tick 当前时间
-#  @return
-def SetFreshmanGuideDay(curPlayer, day):
-    GameWorld.DebugLog("SetFreshmanGuideDay day=%s" % day, curPlayer.GetPlayerID())
-    day = max(0, day)
-    PlayerControl.NomalDictSetProperty(curPlayer, ChConfig.Def_PDict_FreshmanGuideDay, day)
-    
-    tick = GameWorld.GetGameWorld().GetTick()
-    
-    # buff处理
-    if day > 0:
-        SkillCommon.AddBuffBySkillType(curPlayer, ChConfig.Def_SkillID_FreshmanGuideBuff, tick)
-    else:
-        BuffSkill.DelBuffBySkillID(curPlayer, ChConfig.Def_SkillID_FreshmanGuideBuff, tick)
-    
-    PlayerControl.NomalDictSetProperty(curPlayer, ChConfig.Def_PDict_FreshmanGuideSpeakerCntToday, 0)
-    # 通知GameServer
-    __NotifyGameServer(curPlayer)
-    return
-
-
-## 获取新手指导员剩余天数
-#  @param curPlayer 玩家实例
-#  @return 剩余天数,为0表示非指导员
-def GetFreshmanGuiderDay(curPlayer):
-    return curPlayer.NomalDictGetProperty(ChConfig.Def_PDict_FreshmanGuideDay)
-
-
-## 通知GameServer
-#  @param curPlayer 玩家实例
-#  @return None
-def __NotifyGameServer(curPlayer):
-    msgList = [GetFreshmanGuiderDay(curPlayer)]
-    GameWorld.GetPlayerManager().GameServer_QueryPlayerResult(curPlayer.GetID(), 0, 0, 'FreshmanGuiderDay', \
-                                                               '%s' % (msgList), len(str(msgList)))
-    return
-
-
-## 新手指导员登录处理
-#  @param curPlayer 发出请求的玩家
-#  @return None
-def FreshmanGuiderOnLogin(curPlayer):
-    # 非新手指导员
-    if GetFreshmanGuiderDay(curPlayer) <= 0:
-        return
-    
-    # 登录时向GameServer同步剩余天数
-    __NotifyGameServer(curPlayer)
-    return
-
-
-## 新手指导员过天处理
-#  @param curPlayer 发出请求的玩家
-#  @param tick 当前时间
-#  @return None
-def FreshmanGuiderOnDay(curPlayer):
-    # 非新手指导员
-    if GetFreshmanGuiderDay(curPlayer) <= 0:
-        GameWorld.DebugLog("FreshmanGuiderOnDay...非新手指导员!", curPlayer.GetPlayerID())
-        return
-    
-    PlayerControl.NomalDictSetProperty(curPlayer, ChConfig.Def_PDict_FreshmanGuideSpeakerCntToday, 0)
-    nowDay = curPlayer.NomalDictGetProperty(ChConfig.Def_PDict_FreshmanGuideDay)
-    nowDay = max(0, nowDay - 1)
-    GameWorld.DebugLog("FreshmanGuiderOnDay...更新新手指导员天数:%s,清空传音次数!" % nowDay, curPlayer.GetPlayerID())
-    SetFreshmanGuideDay(curPlayer, nowDay)
-    return
-
-
-## 新手指导员可否免费使用传音
-#  @param curPlayer 发出请求的玩家
-#  @return True or False
-def CanFreeSpeak(curPlayer):
-    # 非新手指导员
-    if GetFreshmanGuiderDay(curPlayer) <= 0:
-        return False
-    
-    maxFreeCnt = ReadChConfig.GetEvalChConfig("FreshmanGuiderFreeSpeakCnt")  
-    todayCnt = curPlayer.NomalDictGetProperty(ChConfig.Def_PDict_FreshmanGuideSpeakerCntToday)
-    GameWorld.DebugLog("CanFreeSpeak maxFreeCnt=%s,todayCnt=%s" % (maxFreeCnt, todayCnt), curPlayer.GetPlayerID())
-    return todayCnt < maxFreeCnt
-
-
-## 增加新手指导员免费使用传音次数
-#  @param curPlayer 发出请求的玩家
-#  @return
-#  @remarks 默认加1
-def AddFreeSpeakCnt(curPlayer):
-    speakerCnt = curPlayer.NomalDictGetProperty(ChConfig.Def_PDict_FreshmanGuideSpeakerCntToday)
-    PlayerControl.NomalDictSetProperty(curPlayer, ChConfig.Def_PDict_FreshmanGuideSpeakerCntToday, speakerCnt + 1)
-    GameWorld.DebugLog("AddFreeSpeakCnt 新手指导员增加免费发传音次数!当前已免费次数=%s" 
-                       % (speakerCnt + 1), curPlayer.GetPlayerID())
-    return
-
diff --git a/ServerPython/ZoneServerGroup/map1_8G/MapServer/MapServerData/Script/Player/RemoteQuery/GY_Query_GMTFreshmanGuide.py b/ServerPython/ZoneServerGroup/map1_8G/MapServer/MapServerData/Script/Player/RemoteQuery/GY_Query_GMTFreshmanGuide.py
deleted file mode 100644
index 6355094..0000000
--- a/ServerPython/ZoneServerGroup/map1_8G/MapServer/MapServerData/Script/Player/RemoteQuery/GY_Query_GMTFreshmanGuide.py
+++ /dev/null
@@ -1,61 +0,0 @@
-#!/usr/bin/python
-# -*- coding: GBK -*-
-#-------------------------------------------------------------------------------
-#
-#-------------------------------------------------------------------------------
-#
-##@package Player.RemoteQuery.GY_Query_GMTFreshmanGuide
-#
-# @todo:GM工具 - 新手指导员
-# @author hxp
-# @date 2014-02-28
-# @version 1.0
-#
-# 详细描述: 新手指导员
-#
-#---------------------------------------------------------------------
-"""Version = 2014-02-28 21:10"""
-
-import GameWorld
-import DataRecordPack
-#---------------------------------------------------------------------
-#全局变量
-#---------------------------------------------------------------------
-
-#---------------------------------------------------------------------
-#逻辑实现 
-## 请求逻辑  
-#  @param query_Type 请求类型
-#  @param query_ID 玩家ID
-#  @param packCMDList 发包命令 
-#  @param tick 当前时间
-#  @return "True" or "False" or ""
-#  @remarks 函数详细说明.
-def DoLogic(query_Type, query_ID, packCMDList, tick):
-    #===========================================================================
-    # curPlayer = GameWorld.GetPlayerManager().FindPlayerByID(query_ID)
-    # 
-    # if not curPlayer or curPlayer.IsEmpty():
-    #    return 
-    # 
-    # value = int(packCMDList)
-    # PlayerFreshmanGuide.SetFreshmanGuideDay(curPlayer, value)
-    # GameWorld.Log("GY_Query_GMTFreshmanGuide, value=%s" % value, curPlayer.GetPlayerID())
-    # #流向
-    # DataRecordPack.DR_ToolGMOperate(query_ID, curPlayer.GetPlayerName(), curPlayer.GetAccID(), 'GMTFreshmanGuide')
-    #===========================================================================
-    return
-
-#---------------------------------------------------------------------
-#执行结果
-## 执行结果
-#  @param curPlayer 发出请求的玩家
-#  @param callFunName 功能名称
-#  @param funResult 查询的结果
-#  @param tick 当前时间
-#  @return None
-#  @remarks 函数详细说明.
-def DoResult(curPlayer, callFunName, funResult, tick):
-    return
-
-

--
Gitblit v1.8.0