From 0da168207a8361e1738ea6ea9ac4be9830fa01e7 Mon Sep 17 00:00:00 2001
From: hxp <ale99527@vip.qq.com>
Date: 星期五, 07 十一月 2025 14:57:41 +0800
Subject: [PATCH] 237 【福利内容】每日任务/每周任务/章节奖励-服务端(增加物品效果281-给活跃度;每日任务奖励改为配置物品;)

---
 ServerPython/ZoneServerGroup/map1_8G/MapServer/MapServerData/Script/Player/ChPlayer.py |  704 +++++++++++++++++-----------------------------------------
 1 files changed, 204 insertions(+), 500 deletions(-)

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 a88b907..76605b3 100644
--- a/ServerPython/ZoneServerGroup/map1_8G/MapServer/MapServerData/Script/Player/ChPlayer.py
+++ b/ServerPython/ZoneServerGroup/map1_8G/MapServer/MapServerData/Script/Player/ChPlayer.py
@@ -19,7 +19,6 @@
 import ChConfig
 import BuffSkill
 import PlayerEventCounter
-import PlayerTeam
 import PlayerHorse
 import NPCCommon
 import SkillCommon
@@ -27,21 +26,16 @@
 import ChItem
 import ItemCommon
 import ItemControler
-import ChEquip
 import FunctionNPCCommon
 import PlayerGMOper
 import ReadChConfig
 import PetControl
 import OperControlManager
 import ShareDefine
-import PlayerAutoCheckOnline
-import PlayerGameWallow
 import NetPackCommon
 import ChPyNetSendPack
 import DataRecordPack
 import PlayerBillboard
-import UpdatePlayerName
-import PlayerOnlinePrize
 import PlayerLVAward
 import PlayerGoldGift
 import PlayerSignDay
@@ -49,29 +43,16 @@
 import PlayerPrestigeSys
 import PlayerFamily
 import PlayerLoginDayAward
-import PlayerGodWeapon
 import PlayerGoldInvest
 import PlayerActivity
 import FBCommon
-import BossHurtMng
 import PlayerWishingWell
 import PlayerSuccess
-import PlayerDienstgrad
 import PlayerFreeGoods
-import PlayerRecover
-import GameLogic_SkyTower
-import PlayerEquipDecompose
-import PlayerGatherSoul
-import PlayerGatherTheSoul
-import PlayerFairyDomain
 import PlayerCrossRealmPK
 import PlayerCrossChampionship
-import PlayerCrossBattlefield
 import GameFuncComm
-import PlayerMagicWeapon
-import GameLogic_FamilyBoss
-import GameLogic_TrialTower
-import GameLogic_FamilyWar
+import PlayerFamilyTaofa
 import PlayerBossReborn
 import PlayerWeekParty
 import PlayerFeastWeekParty
@@ -80,16 +61,10 @@
 import PlayerFeastWish
 import PlayerActLogin
 import PlayerTreasure
-import GameLogic_GodArea
 import PlayerRune
-import PlayerFamilyRedPacket
 import IpyGameDataPY
 import EventReport
-import OpenServerCampaign
-import PlayerVip
-import PlayerRefineStove
 import PassiveBuffEffMng
-import GameLogic_XMZZ
 import PlayerFlashSale
 import PlayerFlashGiftbag
 import PlayerDailyGiftbag
@@ -99,27 +74,17 @@
 import PlayerActCollectWords
 import PlayerActTotalRecharge
 import PlayerActRechargePrize
-import PlayerActGarbageSorting
-import PlayerActXianXiaMJ
-import PlayerActGubao
-import PlayerActHorsePetTrain
 import PlayerActLianqi
 import PlayerActGodGift
 import PlayerActFamilyCTGAssist
 import PlayerActRechargeRebateGold
 import PlayerActManyDayRecharge
 import PlayerActSingleRecharge
-import PlayerActHorsePetFeast
-import PlayerActBossTrial
 import PlayerSpringSale
-import PlayerFairyCeremony
-import PlayerNewFairyCeremony
 import GY_Query_BossFirstKill
 import PlayerCrossYaomoBoss
-import PlayerFeastRedPacket
 import PlayerLuckyCloudBuy
 import PlayerLuckyTreasure
-import Item_ResetAttrPoint
 import CrossActCTGBillboard
 import CrossActAllRecharge
 import PlayerFuncSysPrivilege
@@ -127,9 +92,6 @@
 import PlayerTongTianLing
 import CrossRealmPlayer
 import ChNetSendPack
-import FamilyRobBoss
-import FBHelpBattle
-import PlayerAssist
 import PlayerArena
 import PyGameData
 import PlayerCoin
@@ -144,17 +106,15 @@
 import PlayerCustomAward
 import PlayerZhanling
 import PlayerTree
+import PlayerLLMJ
 import PlayerLianTi
 import PlayerTask
 import PlayerYinji
 import PlayerLove
 import GameObj
 import PlayerChangeJob
-import PlayerGuaji
-import PlayerFace
-import PlayerChatBox
 import PlayerXiangong
-import PlayerMineArea
+import PlayerGoldRush
 import PlayerActLoginNew
 import PlayerActBuyCountGift
 import PlayerActLunhuidian
@@ -163,6 +123,7 @@
 import PlayerActTask
 import PlayerMail
 import DBDataMgr
+import UpdatePlayerName
 import GameServerRefresh
 import IPY_ServerDefine
 import CommFunc
@@ -172,6 +133,8 @@
 import PlayerHero
 import PlayerOnline
 import TurnAttack
+import PlayerHJG
+import ObjPool
 
 import datetime
 import time
@@ -289,9 +252,6 @@
     
     if PlayerControl.GetCrossMapID(curPlayer):
         CrossRealmPlayer.DoExitCrossRealm(curPlayer)
-        
-    if curPlayer.GetDictByKey(ChConfig.Def_PlayerKey_ClientCustomScene):
-        PlayerFB.DoExitCustomScene(curPlayer)
         
     PetControl.DoLogic_PetLoadMapOK(curPlayer)
     
@@ -481,7 +441,7 @@
     InitPlayerPack(curPlayer)
     
     if GameWorld.IsCrossServer():
-        SkillCommon.PlayerLoginMergeServerSkillLogic(curPlayer, tick)
+        #SkillCommon.PlayerLoginMergeServerSkillLogic(curPlayer, tick)
         # 重置所有技能CD
         
         DoPlayerLoginInMap(curPlayer, tick)
@@ -489,9 +449,7 @@
         DataRecordPack.DR_PlayerLogin(curPlayer)
         EventReport.WriteEvent_login(curPlayer)
         #---玩家上线, 宠物逻辑处理---
-        PetControl.DoLogic_PetInfo_OnLogin(curPlayer, tick)
-        
-        PlayerTeam.OnPlayerLoginCrossServer(curPlayer)
+        #PetControl.DoLogic_PetInfo_OnLogin(curPlayer, tick)
         return
     
     leaveServerSecond = PlayerControl.GetPlayerLeaveServerSecond(curPlayer)
@@ -516,18 +474,18 @@
     PlayerControl.UpdPlayerServerGroupID(curPlayer)
     
     #上线学习技能
-    SkillCommon.PlayerLoginCheckLearnSkill(curPlayer)
+    #SkillCommon.PlayerLoginCheckLearnSkill(curPlayer)
     
     #刷新技能CD
-    SkillCommon.PlayerLoginUpdateSkillCD(curPlayer, tick)
+    #SkillCommon.PlayerLoginUpdateSkillCD(curPlayer, tick)
     
     #通知玩家技能信息
-    __Sync_ClientSkill(curPlayer)
+    #__Sync_ClientSkill(curPlayer)
     #清除VIPbuff
     #BuffSkill.DelBuffBySkillID(curPlayer, ChConfig.Def_VIPExp_SkillTypeID, tick)
     
     #通知玩家的buff
-    __Sync_ClientBuff(curPlayer)
+    #__Sync_ClientBuff(curPlayer)
     
     #---刷新了玩家属性, 登陆只刷新一次,其他地方不用刷
     DoPlayerLoginInMap(curPlayer, tick)
@@ -535,7 +493,6 @@
     PlayerControl.SyncOnLineTimeTotal(curPlayer)
     #PlayerControl.SyncOnLineTimeLastOpenPack(curPlayer, IPY_GameWorld.rptItem)
     PlayerControl.SyncTrainRealmLV(curPlayer)
-    PlayerGodWeapon.OnLogin(curPlayer)
     PlayerPrestigeSys.OnLogin(curPlayer)
     #DataRecordPack.DR_PlayerLogin(curPlayer)
     EventReport.WriteEvent_login(curPlayer)
@@ -544,32 +501,15 @@
     __DoMixServerFirstLogin(curPlayer)
     PlayerBillboard.BillboardOnLogin(curPlayer)
     
-    #上线时通知脱机挂时被击杀的离线时间
-    __Sync_PlayerOffline(curPlayer, tick)
-    
     #玩家扩展信息
     __SyncPlayerInfoEx(curPlayer)
     
-    #补丁包下载奖励
-    GiveDownloadPatchAward(curPlayer)
-    
     #PK模式
-    SyncPKModel(curPlayer)
-    
-    #通知VIP
-    PlayerVip.DoOnLogin(curPlayer, tick)
-    
-    #通知法宝精炼等级
-    PlayerRefineStove.DoOnLogin(curPlayer, tick)
+    #SyncPKModel(curPlayer)
     
     #---玩家上线, 宠物逻辑处理---
-    PetControl.DoLogic_PetInfo_OnLogin(curPlayer, tick)
-    PlayerPet.OnPlayerPetLogin(curPlayer)
-    
-    #PlayerLoginNotify(curPlayer, tick)
-    
-    #防沉迷计算下线累积时间
-    PlayerGameWallow.Calc_Wallow_OfflineTime(curPlayer, tick)
+    #PetControl.DoLogic_PetInfo_OnLogin(curPlayer, tick)
+    #PlayerPet.OnPlayerPetLogin(curPlayer)
     
     # 通知等级奖励领取记录
     PlayerLVAward.Sync_LVAwardGetRecordInfo(curPlayer)
@@ -578,24 +518,14 @@
     # 首充/天天首充/充值豪礼
     PlayerGoldGift.OnLogin(curPlayer)
     
-#    #通知功能首次触发情况
+    #通知功能首次触发情况
     GameFuncComm.Sync_FuncOpenState(curPlayer)
-#    
-#    #通知客户端签到信息
+    
+    #通知客户端签到信息
     PlayerSignDay.SignDayOnLogin(curPlayer)
     
     #通知玩家死亡时间
-    PlayerControl.PlayerControl(curPlayer).NotifyPlayerDeadTime(curPlayer)
-    #ClearPlayerDeadInfo(curPlayer)
-    
-    #充值活动玩家登入处理
-    #PlayerGoldAction.DoLogic_PlayerOnLogin(curPlayer)
-    
-    # 提示贵宾俱乐部信息
-    #PlayerVip.NoteVIPClubInfo(curPlayer)
-    
-    #角色改名次数
-    UpdatePlayerName.Sync_UpdatePlayerNameCount(curPlayer)
+    #PlayerControl.PlayerControl(curPlayer).NotifyPlayerDeadTime(curPlayer)
     
     # 坐骑相关通知
     PlayerHorse.PlayerHorseLogin(curPlayer)
@@ -610,19 +540,6 @@
     
     # 通知累计登陆礼
     PlayerLoginDayAward.OnLoginNotifyLoginDayAward(curPlayer)
-    
-    # 开服活动奖励信息
-    OpenServerCampaign.OnOpenServerCampaignLogin(curPlayer)
-
-    # 试炼之塔
-    GameLogic_TrialTower.OnFBPlayerLogin(curPlayer)
-    # 古神禁地
-    GameLogic_GodArea.GodAreaOnLogin(curPlayer)
-    # 采集NPC次数通知
-    NPCCommon.SyncCollNPCTime(curPlayer)
-    
-    # 每日活跃度
-    PlayerActivity.OnLogin(curPlayer)
     
     # 副本进入时间
     FBCommon.FBOnLogin(curPlayer)
@@ -643,12 +560,6 @@
 #    Sync_AutoFightSetting(curPlayer)
     
     PlayerFamily.OnPlayerLogin(curPlayer, tick)
-    #改到 GameServerRefresh GameSever_PlayerInitOK后处理才能保证玩家已经在Gameserver注册
-    #PlayerDienstgrad.RefreshBillBoardDienstgrad(curPlayer)
-    # 称号
-    PlayerDienstgrad.Sync_AllDienstgradOnLogin(curPlayer)
-    # 资源找回OnLogin
-    PlayerRecover.RecoverOnLogin(curPlayer)
     
     # 时装
     PlayerCoat.OnLogin_Coat(curPlayer)
@@ -656,7 +567,6 @@
     # 跨服PK
     PlayerCrossRealmPK.DoPlayerLogin(curPlayer)
     PlayerCrossChampionship.DoPlayerLogin(curPlayer)
-    PlayerCrossBattlefield.DoPlayerLogin(curPlayer)
     
     # 幸运云购
     PlayerLuckyCloudBuy.OnPlayerLogin(curPlayer)
@@ -668,7 +578,7 @@
     PlayerControl.NotifyPlayerAllCurrency(curPlayer)
     PlayerControl.NotifyUseMoneyTotal(curPlayer)
     #通知基础属性
-    NotifyPlayerBasePoint(curPlayer)
+    #NotifyPlayerBasePoint(curPlayer)
     
     #跨服充值排行
     CrossActCTGBillboard.OnPlayerLogin(curPlayer)
@@ -698,37 +608,17 @@
     PlayerActFamilyCTGAssist.OnPlayerLogin(curPlayer)
     #集字活动
     PlayerActCollectWords.OnPlayerLogin(curPlayer)
-    # 世界boss
-    BossHurtMng.OnLogin(curPlayer)
     ChItem.Sync_ItemDayUseCnt(curPlayer)
     # 符印登录通知
     PlayerRune.PlayerRuneLogin(curPlayer)
-    # 仙盟红包登录通知
-    PlayerFamilyRedPacket.OnPlayerLogin(curPlayer)
-    PlayerFeastRedPacket.DoPlayerOnLogin(curPlayer)
-    # 法宝登录通知
-    PlayerMagicWeapon.PlayerMagicWeaponLogin(curPlayer)
     # 商店物品购买次数登录通知
     FunctionNPCCommon.ShopItemOnLogin(curPlayer)
     # 通知设置的被动功法
     #PassiveBuffEffMng.OnLoginGFPassive(curPlayer)
-    #仙魔之争
-    GameLogic_XMZZ.OnXMZZLogin(curPlayer)
-    PlayerOnlinePrize.OnPlayerLogin(curPlayer)
-    #装备分解
-    PlayerEquipDecompose.PlayerLogin(curPlayer)
-    #防沉迷
-    PlayerGameWallow.DoLogic_CheckWallow(curPlayer, tick)
-    # 协助
-    PlayerAssist.OnPlayerLogin(curPlayer)
     # 极品白拿
     PlayerFreeGoods.OnLogin(curPlayer)
     # BOSS复活活动
     PlayerBossReborn.OnLogin(curPlayer)
-    # boss历练
-    PlayerActBossTrial.OnPlayerLogin(curPlayer)
-    # 骑宠盛宴活动
-    PlayerActHorsePetFeast.OnLogin(curPlayer)
     # 周狂欢活动
     PlayerWeekParty.OnLogin(curPlayer)
     # 购买次数礼包活动
@@ -751,14 +641,6 @@
     PlayerFeastTravel.OnPlayerLogin(curPlayer)
     # 登录奖励活动
     PlayerActLogin.OnLogin(curPlayer)
-    # 垃圾分类活动
-    PlayerActGarbageSorting.OnPlayerLogin(curPlayer)
-    # 仙匣秘境活动
-    PlayerActXianXiaMJ.OnPlayerLogin(curPlayer)
-    # 古宝养成活动
-    PlayerActGubao.OnPlayerLogin(curPlayer)
-    # 骑宠养成活动
-    PlayerActHorsePetTrain.OnPlayerLogin(curPlayer)
     # 炼器活动
     PlayerActLianqi.OnPlayerLogin(curPlayer)
     # 天帝礼包活动
@@ -769,34 +651,19 @@
     PlayerActSingleRecharge.OnPlayerLogin(curPlayer)
     # 转盘活动
     PlayerActTurntable.OnPlayerLogin(curPlayer)
-    # 仙界盛典活动
-    PlayerFairyCeremony.OnLogin(curPlayer)
-    # 新仙界盛典活动
-    PlayerNewFairyCeremony.OnLogin(curPlayer)
-    # 分支下载奖励记录通知
-    SyncPackDownloadAward(curPlayer)
     # 登录触发功能开启(老号处理)
     GameFuncComm.DoFuncOpenLogic(curPlayer)
     # 神兽
     PlayerDogz.OnPlayerLogin(curPlayer)
-    # 骑宠
-    FamilyRobBoss.OnPlayerLogin(curPlayer)
     # 许愿池
     PlayerWishingWell.OnLogin(curPlayer)
     #幸运鉴宝
     PlayerLuckyTreasure.OnLogin(curPlayer)
     # 小助手
     SyncLittleHelper(curPlayer)
-    # 副本助战
-    FBHelpBattle.DoPlayerLogin(curPlayer)
-    # 聚魂
-    PlayerGatherSoul.PlayerLogin(curPlayer)
-    PlayerGatherTheSoul.OnPlayerLogin(curPlayer)
-    #缥缈仙域
-    PlayerFairyDomain.OnLogin(curPlayer)
     PlayerFB.OnLogin(curPlayer)
     #技能专精信息
-    SkillShell.NotifyElementSkillInfo(curPlayer)
+    #SkillShell.NotifyElementSkillInfo(curPlayer)
     #Boss首杀
     GY_Query_BossFirstKill.OnPlayerLogin(curPlayer)
     #通天令
@@ -853,18 +720,20 @@
         PyMongoMain.GetUserCtrlDB().OnPlayerLogin(curPlayer)
         PlayerHero.OnPlayerLogin(curPlayer)
         PlayerMail.OnPlayerLogin(curPlayer)
-        PlayerChatBox.OnPlayerLogin(curPlayer)
-        PlayerFace.OnPlayerLogin(curPlayer)
+        PlayerHJG.OnPlayerLogin(curPlayer)
         PlayerXiangong.OnPlayerLogin(curPlayer)
         PlayerGubao.OnPlayerLogin(curPlayer)
         PlayerShentong.OnPlayerLogin(curPlayer)
         PlayerZhanling.OnPlayerLogin(curPlayer)
         PlayerTask.OnPlayerLogin(curPlayer)
         PlayerTree.OnPlayerLogin(curPlayer)
-        PlayerMineArea.OnPlayerLogin(curPlayer)
-        PlayerGuaji.OnPlayerLogin(curPlayer)
+        PlayerGoldRush.OnPlayerLogin(curPlayer)
         PlayerActFamilyGCZ.OnPlayerLogin(curPlayer)
         PlayerTalk.OnPlayerLogin(curPlayer)
+        SyncADCntInfo(curPlayer)
+        UpdatePlayerName.OnPlayerLogin(curPlayer)
+        PlayerActivity.OnPlayerLogin(curPlayer)
+        PlayerLLMJ.OnPlayerLogin(curPlayer)
         
         # 上线查询一次充值订单
         curPlayer.SendDBQueryRecharge()
@@ -899,6 +768,8 @@
     # 那么在DoPlayerLogin 中设置的数据将不会被保存, 如会导致第一个任务重复触发问题,记录多次发送
     EventReport.WriteEvent_Entry(curPlayer, 4)
     #EventReport.EventReport(ShareDefine.Def_UserAction_FirstLogin, "", curPlayer)
+     
+    curPlayer.SetFightPoint(1) # 初始化为1倍消耗
     
     #---补满血满魔---
     GameObj.SetHP(curPlayer, GameObj.GetMaxHP(curPlayer))
@@ -927,6 +798,9 @@
         
     PlayerHero.OnPlayerFirstLogin(curPlayer)
     
+    #淘金初始化
+    PlayerGoldRush.InitGoldEnergy(curPlayer)
+    
     PlayerControl.NomalDictSetProperty(curPlayer, ChConfig.Def_Player_Dict_FirstLogin, 1)
     return
 
@@ -954,11 +828,10 @@
     
     curPlayer.SetDict(ChConfig.Def_PlayerKey_MixServerFirstLogin, 1)
     
+    PlayerSignDay.ResetDaySign(curPlayer) # 重置签到
+    
     # 重置首充双倍
     PlayerCoin.DoResetCTGCount(curPlayer, "MixServer")
-    
-    # 重置商店购买次数,暂定只重置类型 7 的
-    FunctionNPCCommon.ResetShopItemBuyCount(curPlayer, [7])
     
     # 合服邮件,盟主专属邮件在GameServer处理
     mailItemList = IpyGameDataPY.GetFuncEvalCfg("MixServerMail", 1)
@@ -990,20 +863,6 @@
     
     # 同步排行榜
     PlayerBillboard.UpdatePlayerBillboardOnLeaveServer(curPlayer, isAll=True)
-    
-    # 天星塔全服过关记录
-    GameLogic_SkyTower.OnMixFirstLogin(curPlayer)
-    
-    # boss凭证
-    PlayerActBossTrial.OnMixFirstLogin(curPlayer)
-    # 仙匣秘境
-    PlayerActXianXiaMJ.OnMixFirstLogin(curPlayer)
-    # 古宝养成
-    PlayerActGubao.OnMixFirstLogin(curPlayer)
-    # 骑宠养成
-    PlayerActHorsePetTrain.OnMixFirstLogin(curPlayer)
-    # 重置玩家改名次数
-    #UpdatePlayerName.ResetChangeNameCnt(curPlayer)
     return
 #---------------------------------------------------------------------
         
@@ -1015,51 +874,6 @@
     PlayerControl.NomalDictSetProperty(curPlayer, ChConfig.Def_Player_Dict_PlayerDeadCnt, 0)
     PlayerControl.NomalDictSetProperty(curPlayer, ChConfig.Def_Player_Dict_DeadTime, 0)
     return
-
-##玩家登陆, 相关活动通知
-#@param curPlayer 玩家实例
-#@param tick 时间戳
-#@return 返回值无意义
-#@remarks 玩家登陆, 相关活动通知
-def PlayerLoginNotify(curPlayer, tick):
-    curTime = GameWorld.GetCurrentTime()
-    
-    #读取上线提示表
-    notifyByTimeSect = ReadChConfig.GetEvalChConfig('PlayerLoginNotify_TimeSect')     #某时间段内上线提示
-    notifyByDict = ReadChConfig.GetEvalChConfig('PlayerLoginNotify_Dict')             #根据字典值给提示
-    
-    #在规定时间段内上线给提示
-    DoNotifyByTimeSect(curPlayer, curTime, notifyByTimeSect)
-    #指定字典值内提示
-    DoNotifyByDict(curPlayer, notifyByDict)
-    return
-#---------------------------------------------------------------------
-##在活动规定时间段内上线给提示
-#@param curPlayer 玩家索引
-#@param curTime 传入时间
-#@param notifyInfo 提示信息
-#@return 返回值无意义
-#@remarks 在活动规定时间段内上线给提示
-def DoNotifyByTimeSect(curPlayer, curTime, notifyInfo):
-    for curNotify in notifyInfo:
-        #有时间段限制,验证时间段
-        if not GameWorld.IsAtActTime(curTime, curNotify[0]):
-            continue
-        
-        PlayerControl.NotifyCode(curPlayer, curNotify[1], curNotify[2])
-
-#---------------------------------------------------------------------
-##指定字典值内提示
-#@param curPlayer 玩家实例
-#@param notifyInfo 提示信息
-#@return 返回值无意义
-#@remarks 指定字典值内提示
-def DoNotifyByDict(curPlayer, notifyInfo):
-    gameWorld = GameWorld.GetGameWorld()
-    for curNotify in notifyInfo:
-        if gameWorld.GetGameWorldDictByKey(curNotify[0]) in curNotify[1]:
-            PlayerControl.NotifyCode(curPlayer, curNotify[2], curNotify[3])
-
 
 #---------------------------------------------------------------------
 ##通知背包详细信息
@@ -1154,54 +968,6 @@
     return
 
 #---------------------------------------------------------------------
-##上线时通知离线时间(离线挂机功能)
-# @param curPlayer 玩家实例
-# @param tick 时间戳
-# @return 返回值无意义
-# @remarks 上线时通知离线时间(离线挂机功能)
-def __Sync_PlayerOffline(curPlayer, tick):
-    #---等级限制---
-    if GameWorld.IsCrossServer():
-        return
-    
-#===============================================================================
-#    #---等级限制---
-#    lvLimit = ReadChConfig.GetEvalChConfig('OfflineSys_LVLimit')
-#    if curPlayer.GetLV() < lvLimit:
-#        return
-#    
-#    if GameWorld.IsCrossServer():
-#        return
-#    
-#    #当前离线时间(分)
-#    curOfflineMinutes = min(PlayerControl.GetPlayerLeaveServerMinute(curPlayer),
-#                            ChConfig.Def_UpperLimit_DWord)
-#    
-#    #防止服务器时间修改到过去得到负值
-#    if curOfflineMinutes < 0:
-#        GameWorld.ErrLog("Login Time Error, outTime: %s - loginTime :%s" % 
-#                         (curPlayer.GetLogoffTime(), GameWorld.GetCurrentDataTimeStr()),
-#                         curPlayer.GetPlayerID())
-#        curOfflineMinutes = 0
-#    
-#    #时间为分钟
-#    minTimeLimit, maxTimeLimit = ReadChConfig.GetEvalChConfig("OfflineSys_AllTimeUpperLimit")
-#    if curOfflineMinutes >= minTimeLimit:
-#        #总离线时间(分)
-#        allOfflineMinutes = min(curPlayer.GetOfflineMinutes() + curOfflineMinutes, maxTimeLimit)
-#        #记录离线总时间
-#        curPlayer.SetOfflineMinutes(int(allOfflineMinutes))
-#        GameWorld.DebugLog("设置离线奖励时间 %s,curOfflineMinutes=%s" % (allOfflineMinutes, curOfflineMinutes), curPlayer.GetPlayerID())
-#    else:
-#        GameWorld.DebugLog("离线时间过短,不计入离线奖励!curOfflineMinutes=%s" % curOfflineMinutes, curPlayer.GetPlayerID())
-#    
-#    #通知客户端离线时间
-# #    curPlayer.Syn_OfflineTimeRefresh(int(curOfflineMinutes))
-#    curPlayer.Syn_OfflineTimeQueryResult()
-#===============================================================================
-    return
-
-#---------------------------------------------------------------------
 ##玩家在地图服务器中登录ok,初始化自己
 #@param curPlayer 玩家实例
 #@param tick 时间戳
@@ -1230,16 +996,7 @@
         PlayerControl.SetPlayerSightLevel(curPlayer, curPlayer.GetID())
     if curPlayer.GetSight() != 0:
         PlayerControl.SetSight(curPlayer, 0)
-    #刷新玩家的视野
-    #if not GameWorld.IsCrossServer() and (PlayerControl.GetCrossMapID(curPlayer) or PlayerControl.GetCustomMapID(curPlayer)):
-    #    GameWorld.DebugLog("===登录本服地图时,处于跨服或自定义场景状态,不刷新视野!", curPlayer.GetPlayerID())
-    #    PlayerControl.SetPlayerSightLevel(curPlayer, curPlayer.GetID())
-    #elif not GameWorld.IsCrossServer():
-    #    realmDifficulty = PlayerControl.GetMapRealmDifficulty(curPlayer)
-    #    if realmDifficulty:
-    #        GameWorld.DebugLog("===登录本服地图时,处于境界难度地图,自动设置难度! realmDifficulty=%s" % realmDifficulty, curPlayer.GetPlayerID())
-    #        PlayerControl.SetRealmDifficulty(curPlayer, realmDifficulty)
-    
+        
     PlayerState.ChangePlayerSigh(curPlayer, tick)
     
     if GameWorld.IsCrossServer():
@@ -1582,16 +1339,7 @@
         PlayerControl.SetPlayerSightLevel(curPlayer, curPlayer.GetID())
     if curPlayer.GetSight() != 0:
         PlayerControl.SetSight(curPlayer, 0)
-    #刷新自己的视野
-    #if not GameWorld.IsCrossServer() and (PlayerControl.GetCrossMapID(curPlayer) or curPlayer.GetDictByKey(ChConfig.Def_PlayerKey_ClientCustomScene)):
-    #    GameWorld.DebugLog("===本服LoadMapOK时玩家处于跨服或自定义场景状态,不设置可见!", curPlayer.GetPlayerID())
-    #    PlayerControl.SetPlayerSightLevel(curPlayer, curPlayer.GetID())
-    #elif not GameWorld.IsCrossServer():
-    #    realmDifficulty = PlayerControl.GetMapRealmDifficulty(curPlayer)
-    #    if realmDifficulty:
-    #        GameWorld.DebugLog("===本服LoadMapOK时玩家处于境界难度地图,自动设置难度!realmDifficulty=%s" % realmDifficulty, curPlayer.GetPlayerID())
-    #        PlayerControl.SetRealmDifficulty(curPlayer, realmDifficulty)
-    
+        
     curPlayer.RefreshView()
     curPlayer.SetVisible(True)
         
@@ -1617,32 +1365,6 @@
     #如果在事件状态 , 就不解除锁定 任务1锁死了
     #if curPlayer.GetPlayerAction() != IPY_GameWorld.paEvent:
     curPlayer.SetCanMove(True)
-    
-    #同步客户端tick
-    #这个封包要在EndLoadMap, 上马之前发, 否则客户端处理时机不对(客户端封包缓存机制)
-    #curPlayer.Sync_ClientTick()
-    
-    #做上一个地图的上马/骠车逻辑
-    #恢复自己的状态
-    playerVehicle = curPlayer.GetLastMapPlayerVehicle()
-    if playerVehicle == IPY_GameWorld.pvHorse:
-        #玩家在骑马中
-        if not PlayerHorse.PlayerRideHorseUp(curPlayer, False, False):
-        #=======================================================================
-        #    playerHorseState = curPlayer.GetLastMapPlayerRidehorseState()
-        #    if playerHorseState != IPY_GameWorld.prsNormal:
-        #        #切换地图, 恢复急行状态
-        #        curPlayer.SetPlayerRidehorseState(playerHorseState)
-        #        
-        #    #刷新人物属性 所有状态
-        #    playerControl = PlayerControl.PlayerControl(curPlayer)
-        #    playerControl.RefreshAllState()
-        # else:
-        #=======================================================================
-            #此时已经是下马状态不需要刷状态 但是需要通知客户端下马
-            PlayerHorse.PlayerRideHorseDown(curPlayer, False)
-        
-    PlayerTeam.PlayerLoginSetTeam(curPlayer, tick)
     
     #激活玩家(保证持续性Buff处理间隔)
     PlayerControl.SetIsNeedProcess(curPlayer, True)
@@ -1702,13 +1424,7 @@
         curPlayer.SetFaction(ChConfig.CampType_Neutral)
         BuffSkill.DelBuffBySkillID(curPlayer, ChConfig.Def_SkillID_Justice, tick)
         BuffSkill.DelBuffBySkillID(curPlayer, ChConfig.Def_SkillID_Evil, tick)
-    
-    
-    #再次请求双倍经验是否领取
-    #PlayerDoubleExpSys.ChangeMapAfter_CalcDoubleExpTime(curPlayer, tick)
-    
-    #PlayerVip.SetStartCalcVIPTick(curPlayer, tick)
-    
+        
     #强制切换PK模式
     initAttackModel = curMap.GetInitAttackModel()
     if curPlayer.GetAttackMode() != initAttackModel:
@@ -1864,7 +1580,7 @@
             return
         ItemCommon.ReduceItem(curPlayer, itemPack, [delIndex], 1, False, ChConfig.ItemDel_ResetAttrPoint)
     
-    Item_ResetAttrPoint.DoResetAttrPoint(curPlayer, 0, 0, 0)
+    #Item_ResetAttrPoint.DoResetAttrPoint(curPlayer, 0, 0, 0)
     return
 
 def NotifyPlayerBasePoint(curPlayer, syncAttrIDList=[]):
@@ -1998,9 +1714,9 @@
     curPlayer = GameWorld.GetPlayerManager().GetPlayerByIndex(index)
     
     #防外挂 不可移动
-    if curPlayer.NomalDictGetProperty(ChConfig.Def_Player_Dict_AutoCheckHack_State) \
-                                      == ChConfig.Def_AutoCheck_State_Danger:
-        return
+    #if curPlayer.NomalDictGetProperty(ChConfig.Def_Player_Dict_AutoCheckHack_State) \
+    #                                  == ChConfig.Def_AutoCheck_State_Danger:
+    #    return
     
     
     #不可移动行为状态, 判断客户端限制
@@ -2366,24 +2082,6 @@
     
     #流向记录玩家下线
     DataRecordPack.DR_PlayerDisconnect(curPlayer)
-    
-    #VIP时间
-    #PlayerVip.CalcVIPTimeByTick(curPlayer, tick, False)
-    #在线时间
-    PlayerOnlinePrize.CalcOnlineTime(curPlayer)
-    #首充提示时间
-    PlayerGoldGift.UpdateFirstGoldTime(curPlayer)
-    #玩家未回图形验证码下线将会记录错误次数
-    #===========================================================================
-    # if curPlayer.NomalDictGetProperty(ChConfig.Def_Player_Dict_Captcha_WaitSign) \
-    # == PlayerAutoCheckOnline.Def_Captcha_WaitAnswer:
-    #    PlayerAutoCheckOnline.CaptchaAnswerErr(curPlayer, tick, False)
-    # 
-    #    PlayerControl.NomalDictSetProperty(curPlayer, ChConfig.Def_Player_Dict_Captcha_WaitSign, PlayerAutoCheckOnline.Def_Captcha_Safe)
-    # 
-    #===========================================================================
-    #@warning: 等字段统一修改,删除双倍经验BUFF
-    #PlayerDoubleExpSys.DeleteDoubleExpBuff(curPlayer, ChConfig.Def_DoubleExpNote_StopOff)
     
     #设置RouteServerInitOK字典
     PlayerControl.NomalDictSetProperty(curPlayer, ChConfig.Def_Player_Dict_RouteServerInitOK, 0)
@@ -2974,11 +2672,7 @@
                     return
                 
     elif rebornType == ChConfig.rebornType_UseItem:
-        if crossMapID == ChConfig.Def_FBMapID_CrossBattlefield:
-            rebornItemID = IpyGameDataPY.GetFuncCfg("CrossBattlefieldReborn", 1)
-            rebornItem = ItemCommon.FindItemInPackByItemID(curPlayer, rebornItemID, IPY_GameWorld.rptItem)
-        else:
-            rebornItem = ItemCommon.FindItemInPackByEffectEx(curPlayer, ChConfig.Def_Effect_Reborn)
+        rebornItem = ItemCommon.FindItemInPackByEffectEx(curPlayer, ChConfig.Def_Effect_Reborn)
         if not rebornItem:
             GameWorld.ErrLog("复活道具不足,无法原地复活! ", playerID)                
             return
@@ -3313,7 +3007,7 @@
 #  @param transportType 传送类型
 #  @return 是否vip等级限制
 def TransportVipLvRestrict(curPlayer, transportType):
-    return PlayerVip.GetPrivilegeValue(curPlayer, ChConfig.VIPPrivilege_FreeTransport)
+    return 0
 
 
 
@@ -3469,24 +3163,28 @@
     NetPackCommon.SendFakePack(curPlayer, awardReceiveState)
     return
 
-## 领取奖励表奖励
-#  @param None None
-#  @return None
-def ClientPlayerGetReward(index, clientData, tick):
-    playerManager = GameWorld.GetPlayerManager()
-    curPlayer = playerManager.GetPlayerByIndex(index)
-    
-    # 背包空间不足
-    if not ItemCommon.CheckPackHasSpace(curPlayer, IPY_GameWorld.rptItem):
-        PlayerControl.NotifyCode(curPlayer, "GeRen_chenxin_676165", [IPY_GameWorld.rptItem])
-        return
-    
-    rewardType = clientData.RewardType
-    
-    #通知GameServer领取奖励
-    resultName = str(rewardType)
-    GameWorld.GetPlayerManager().GameServer_QueryPlayerResult(curPlayer.GetID(), 0, 0, 'PlayerGetReward',
-                                                                  resultName, len(resultName))
+def PlayerOnDay(curPlayer):
+    #玩法前瞻奖励
+    gameNoticeAwardState = curPlayer.NomalDictGetProperty(ChConfig.Def_PDict_GameNoticeAwardState)
+    if gameNoticeAwardState:
+        PlayerControl.NomalDictSetProperty(curPlayer, ChConfig.Def_PDict_GameNoticeAwardState, 0)
+        Sync_RewardGetRecordInfo(curPlayer, ChConfig.Def_RewardType_GameNotice, 0)
+    #每日分享奖励重置
+    shareGameAwardState = curPlayer.NomalDictGetProperty(ChConfig.Def_PDict_ShareGameAwardState)
+    if shareGameAwardState:
+        PlayerControl.NomalDictSetProperty(curPlayer, ChConfig.Def_PDict_ShareGameAwardState, 0)
+        Sync_RewardGetRecordInfo(curPlayer, ChConfig.Def_RewardType_ShareGame, 0)
+    #开服每日奖励
+    awardState = curPlayer.NomalDictGetProperty(ChConfig.Def_PDict_OpenSererDailyAward)
+    if awardState:
+        PlayerControl.NomalDictSetProperty(curPlayer, ChConfig.Def_PDict_OpenSererDailyAward, 0)
+        Sync_RewardGetRecordInfo(curPlayer, ChConfig.Def_RewardType_OpenServerDailyAward, 0)
+    #开服每日奖励
+    awardState = curPlayer.NomalDictGetProperty(ChConfig.Def_PDict_RechargeDayAward)
+    if awardState:
+        PlayerControl.NomalDictSetProperty(curPlayer, ChConfig.Def_PDict_RechargeDayAward, 0)
+        Sync_RewardGetRecordInfo(curPlayer, ChConfig.Def_RewardType_RechargeDayAward, 0)
+    ADCntOnDay(curPlayer)
     return
 
 #//A5 04 玩家领取奖励 #tagCMPlayerGetReward
@@ -3513,33 +3211,38 @@
     # 活跃度奖励
     if rewardType == ChConfig.Def_RewardType_Activity:
         PlayerActivity.GetActivityAward(curPlayer, dataEx)
-    # 活跃放置奖励
-    elif rewardType == ChConfig.Def_RewardType_ActivityPlace:
-        PlayerActivity.GetActivityPlaceReward(curPlayer)
-    # 挂机奖励
-    elif rewardType == ChConfig.Def_RewardType_Guaji:
-        PlayerGuaji.OnGetGuajiAward(curPlayer, dataEx)
+    # 每日任务奖励
+    elif rewardType == ChConfig.Def_RewardType_DailyTask:
+        PlayerActivity.GetDailyTaskAward(curPlayer, dataEx)
+    # 成就奖励
+    elif rewardType == ChConfig.Def_RewardType_Success:
+        PlayerSuccess.GetSuccessAward(curPlayer, dataEx)
+    # 仙树免费减时
+    elif rewardType == ChConfig.Def_RewardType_TreeFreeTime:
+        PlayerTree.FreeReduceTreeLVTime(curPlayer)
+    # 广告奖励
+    elif rewardType == ChConfig.Def_RewardType_ADAward:
+        OnGetADAward(curPlayer, dataEx)
+    # 历练秘笈升级
+    elif rewardType == ChConfig.Def_RewardType_LLMJLVUp:
+        PlayerLLMJ.OnLLMJLVUp(curPlayer)
+    # 公会讨伐领取宝箱奖励
+    elif rewardType == ChConfig.Def_RewardType_FamilyTaofaBox:
+        PlayerFamilyTaofa.GetTaofaBoxAward(curPlayer)
+    # 阵容推荐奖励
+    elif rewardType == ChConfig.Def_RewardType_LineupRecommend:
+        PlayerHero.GetLineupRecommendAward(curPlayer, dataEx, dataExStr)
+        
+        
     # 每日免费直购礼包
     elif rewardType == ChConfig.Def_RewardType_DayFreeGoldGift:
         PlayerDailyGiftbag.OnGetDailyFreeGiftbag(curPlayer)
-    # 仙盟联赛冠军仙盟每日俸禄奖励
-    elif rewardType == ChConfig.Def_RewardType_ChampionFamilyDailyReward:
-        GameLogic_FamilyWar.GetChampionFamilyDailyReward(curPlayer)
-    # 仙魔之争胜利场数奖励
-    elif rewardType == ChConfig.Def_RewardType_XMZZWinCnt:
-        GameLogic_XMZZ.GetXMZZWinPrize(curPlayer, dataEx)
-    # 仙盟每日福利奖励
-    elif rewardType == ChConfig.Def_RewardType_FamilyDayAward:
-        PlayerFamily.GetFamilyDayAward(curPlayer)
     # 玩家等级奖励
     elif rewardType == ChConfig.Def_RewardType_LVAward:
         PlayerLVAward.GetPlayerLVAward(curPlayer, dataEx)
-    # 仙宝寻主奖励
-    elif rewardType == ChConfig.Def_RewardType_XBXZ:
-        PlayerMagicWeapon.OnGetXBXZAward(curPlayer, dataEx)
     # 首充礼包奖励
-    elif rewardType == ChConfig.Def_RewardType_GoldGiftFirst:
-        PlayerGoldGift.GetPlayerGoldGiftFirst(curPlayer, dataEx)
+    elif rewardType == ChConfig.Def_RewardType_FirstCharge:
+        PlayerGoldGift.GetPlayerFirstCharge(curPlayer, dataEx, dataExStr)
     # 领取极品白拿
     elif rewardType == ChConfig.Def_RewardType_FreeGoods:
         PlayerFreeGoods.OnGetFreeGoods(curPlayer, dataEx)
@@ -3558,15 +3261,6 @@
     # 领取boss复活活动奖励
     elif rewardType == ChConfig.Def_RewardType_BossReborn:
         PlayerBossReborn.GetBossRebornActionAward(curPlayer, dataEx)
-    # 领取仙界盛典充值大礼
-    elif rewardType == ChConfig.Def_RewardType_FCRecharge:
-        PlayerFairyCeremony.GetFCRechargeAward(curPlayer)
-    # 领取仙界盛典全民来嗨
-    elif rewardType == ChConfig.Def_RewardType_FCParty:
-        PlayerFairyCeremony.GetFCPartyAward(curPlayer, dataEx)
-    # 领取分包下载奖励
-    elif rewardType == ChConfig.Def_RewardType_DownLoad:
-        GetDownloadAward(curPlayer, dataEx)
     # 领取许愿池奖励
     elif rewardType == ChConfig.Def_RewardType_WishingWell:
         PlayerWishingWell.DoGetWishingAward(curPlayer)
@@ -3582,12 +3276,6 @@
     # 领取登录奖励活动奖励
     elif rewardType == ChConfig.Def_RewardType_ActLoginAwardAct:
         PlayerActLogin.GetLoginAwardActionAward(curPlayer, dataEx, dataExStr)
-    # 领取新仙界盛典充值大礼
-    elif rewardType == ChConfig.Def_RewardType_NewFairyCRecharge:
-        PlayerNewFairyCeremony.GetFCRechargeAward(curPlayer)
-    # 领取新仙界盛典全民来嗨
-    elif rewardType == ChConfig.Def_RewardType_NewFairyCParty:
-        PlayerNewFairyCeremony.GetFCPartyAward(curPlayer, dataEx)
     # 领取节日巡礼活动奖励
     elif rewardType == ChConfig.Def_RewardType_FeastWeekPartyAct:
         PlayerFeastWeekParty.GetFeastWeekPartyActionAward(curPlayer, dataEx, dataExStr)
@@ -3618,12 +3306,6 @@
     # 跨服妖魔boss伤害奖励
     elif rewardType == ChConfig.Def_RewardType_CrossYaomoBossHurt:
         PlayerCrossYaomoBoss.GetCrossYaomoBossHurtAward(curPlayer, dataEx, tick)
-    # 古宝特殊效果物品奖励
-    elif rewardType == ChConfig.Def_RewardType_GubaoItemEff:
-        PlayerGubao.GetGubaoItemEffAward(curPlayer, dataEx, dataExStr)
-    # 成就积分奖励
-    elif rewardType == ChConfig.Def_RewardType_SuccessScore:
-        PlayerSuccess.GetSuccessScoreAward(curPlayer, dataEx)
     # 买一送多活动免费奖励
     elif rewardType == ChConfig.Def_RewardType_BuyOne:
         PlayerActBuyOne.GetBuyOneFreeAward(curPlayer, dataEx, dataExStr)
@@ -3642,18 +3324,12 @@
     # 轮回殿奖励
     elif rewardType == ChConfig.Def_RewardType_LunhuidianAward:
         PlayerActLunhuidian.GetLunhuidianAward(curPlayer, dataEx, dataExStr)
-    #缥缈奇遇领取
-    elif rewardType == ChConfig.Def_RewardType_FairyAdventuresAward:
-        PlayerFairyDomain.GetFairyAdventuresAward(curPlayer, dataEx, dataExStr)
     #历史累计充值领取
     elif rewardType == ChConfig.Def_RewardType_HistoryChargeAward:
         PlayerGoldGift.OnGetHistoryRechargeAward(curPlayer, dataEx)
     #在线特惠充值额外奖励
     elif rewardType == ChConfig.Def_RewardType_OnlineRechargeTH:
         PlayerCoin.OnGetOnlineRechargeTH(curPlayer)
-    #天星塔全服挑战层领奖
-    elif rewardType == ChConfig.Def_RewardType_SkyTowerServerChallengeReward:
-        GameLogic_SkyTower.OnGetSkyTowerServerChallengeReward(curPlayer, dataEx, dataExStr)
     #创角奖励
     elif rewardType == ChConfig.Def_RewardType_CreateRole:
         OnGetCreateRoleAward(curPlayer)
@@ -3663,9 +3339,6 @@
     #境界渡劫任务条件奖励
     elif rewardType == ChConfig.Def_RewardType_RealmLVUpTask:
         PlayerPrestigeSys.GetRealmLVUpTaskAward(curPlayer, dataEx)
-    #仙盟boss伤害奖励
-    elif rewardType == ChConfig.Def_RewardType_FamilyBossHurt:
-        GameLogic_FamilyBoss.GetFamilyBossHurtAward(curPlayer, dataEx, dataExStr)
     #打包直购礼包奖励
     elif rewardType == ChConfig.Def_RewardType_DailyPackBuyGift:
         PlayerGoldGift.GetDailyPackBuyGift(curPlayer, dataEx)
@@ -3675,9 +3348,6 @@
     #战令奖励
     elif rewardType == ChConfig.Def_RewardType_Zhanling:
         PlayerZhanling.GetZhanlingReward(curPlayer, dataEx, dataExStr)
-    #福地聚宝盆奖励
-    elif rewardType == ChConfig.Def_RewardType_MineTreasure:
-        PlayerMineArea.GetMineTreasureAward(curPlayer, dataEx)
     #玩法前瞻奖励
     elif rewardType == ChConfig.Def_RewardType_GameNotice:
         OnGiveAwardByClient(curPlayer, rewardType, ChConfig.Def_PDict_GameNoticeAwardState, IpyGameDataPY.GetFuncEvalCfg("GameNoticeReward", 1))
@@ -3700,7 +3370,71 @@
     elif rewardType == ChConfig.Def_RewardType_RechargeDayAward:
         OnGetRechargeDayAward(curPlayer, rewardType)
     return
+
+def OnGetADAward(curPlayer, adID):
+    ipyData = IpyGameDataPY.GetIpyGameData("ADAward", adID)
+    if not ipyData:
+        return
+    adCntMax = ipyData.GetADCntMax()
+    adCnt = curPlayer.NomalDictGetProperty(ChConfig.Def_PDict_ADCnt % adID)
+    if adCnt >= adCntMax:
+        GameWorld.DebugLog("今日该广告奖励已达上限! adID=%s,adCnt=%s > %s" % (adID, adCnt, adCntMax))
+        return
+    adCnt += 1
+    PlayerControl.NomalDictSetProperty(curPlayer, ChConfig.Def_PDict_ADCnt % adID, adCnt)
+    awardItemList = ipyData.GetADAwardItemList()
+    adMapID = ipyData.GetADMapID()
+    GameWorld.DebugLog("领取广告奖励! adID=%s,adCnt=%s,adMapID=%s,awardItemList=%s" % (adID, adCnt, adMapID, awardItemList))
+    SyncADCntInfo(curPlayer, [adID])
     
+    if adMapID:
+        FBCommon.AddFBADCnt(curPlayer, adMapID)
+        
+    if awardItemList:
+        ItemControler.GivePlayerItemOrMail(curPlayer, awardItemList, event=["ADAward", False, {}])
+        
+    return
+
+def ADCntOnDay(curPlayer):
+    syncADIDList = []
+    ipyDataMgr = IpyGameDataPY.IPY_Data()
+    for index in xrange(ipyDataMgr.GetADAwardCount()):
+        ipyData = ipyDataMgr.GetADAwardByIndex(index)
+        adID = ipyData.GetADID()
+        if not curPlayer.NomalDictGetProperty(ChConfig.Def_PDict_ADCnt % adID):
+            continue
+        PlayerControl.NomalDictSetProperty(curPlayer, ChConfig.Def_PDict_ADCnt % adID, 0)
+        syncADIDList.append(adID)
+    if syncADIDList:
+        SyncADCntInfo(curPlayer, syncADIDList)
+    return
+
+def SyncADCntInfo(curPlayer, syncADIDList=None):
+    if not syncADIDList:
+        ipyDataMgr = IpyGameDataPY.IPY_Data()
+        adIDList = [ipyDataMgr.GetADAwardByIndex(i).GetADID() for i in xrange(ipyDataMgr.GetADAwardCount())]
+    else:
+        adIDList = syncADIDList
+        
+    adInfoList = []
+    for adID in adIDList:
+        adCnt = curPlayer.NomalDictGetProperty(ChConfig.Def_PDict_ADCnt % adID)
+        if not adCnt and syncADIDList == None:
+            continue
+        adInfo = ObjPool.GetPoolMgr().acquire(ChPyNetSendPack.tagSCADInfo)
+        adInfo.ADID = adID
+        adInfo.ADCnt = adCnt
+        adInfoList.append(adInfo)
+        
+    if not adInfoList:
+        return
+    
+    clientPack = ObjPool.GetPoolMgr().acquire(ChPyNetSendPack.tagSCADInfoList)
+    clientPack.ADInfoList = adInfoList[:255]
+    clientPack.Count = len(clientPack.ADInfoList)
+    NetPackCommon.SendFakePack(curPlayer, clientPack)
+    return
+
 def OnGetRechargeDayAward(curPlayer, rewardType):
     ## 领取累充每日奖励,取最高档
     realTotal = curPlayer.NomalDictGetProperty(ChConfig.Def_PDict_CTGRealTotal)
@@ -3843,7 +3577,6 @@
     curPlayer = GameWorld.GetPlayerManager().GetPlayerByIndex(index)
     if not curPlayer:
         return
-    BossHurtMng.OnQueryBossHurtList(curPlayer, clientData)
     return
 
 
@@ -4014,24 +3747,6 @@
     clientPack.NowMicSecond = serverTime.microsecond
     clientPack.WeekOfYear = GameWorld.GetWeekOfYear()
     NetPackCommon.SendFakePack(curPlayer, clientPack)
-    
-    #旧包先保留,之后删除
-    gw = GameWorld.GetGameWorld()
-    packData = ChPyNetSendPack.tagOpenServerDay()
-    packData.Clear()
-    packData.Day = gw.GetGameWorldDictByKey(ShareDefine.Def_Notify_WorldKey_ServerDay)
-    packData.IsMixServer = gw.GetGameWorldDictByKey(ShareDefine.Def_Notify_WorldKey_IsMixServer)
-    packData.MixDay = gw.GetGameWorldDictByKey(ShareDefine.Def_Notify_WorldKey_MixServerDay)
-    packData.OpenWeekday = gw.GetGameWorldDictByKey(ShareDefine.Def_Notify_WorldKey_OpenServerWeekday)
-    packData.NowYear = serverTime.year
-    packData.NowMonth = serverTime.month
-    packData.NowDay = serverTime.day
-    packData.NowHour = serverTime.hour
-    packData.NowMinute = serverTime.minute
-    packData.NowSecond = serverTime.second
-    packData.NowMicSecond = serverTime.microsecond
-    packData.WeekOfYear = GameWorld.GetWeekOfYear()
-    NetPackCommon.SendFakePack(curPlayer, packData)
     return
 
 #===============================================================================
@@ -4055,9 +3770,9 @@
     curPlayer = GameWorld.GetPlayerManager().GetPlayerByIndex(index)
     
     #防外挂 不可移动
-    if curPlayer.NomalDictGetProperty(ChConfig.Def_Player_Dict_AutoCheckHack_State) \
-                                      == ChConfig.Def_AutoCheck_State_Danger:
-        return
+    #if curPlayer.NomalDictGetProperty(ChConfig.Def_Player_Dict_AutoCheckHack_State) \
+    #                                  == ChConfig.Def_AutoCheck_State_Danger:
+    #    return
 
     if not PYPlayerNormalMove(curPlayer, clientPack, tick):
         posX, posY = curPlayer.GetPosX(), curPlayer.GetPosY()
@@ -4212,64 +3927,6 @@
     PlayerControl.PyNotifyAll(curPlayer, sendPack, False, 0)
     return
 
-def GiveDownloadPatchAward(curPlayer):
-    ## 发放下载补丁包奖励
-    playerID = curPlayer.GetPlayerID()
-    patchAwardNum = IpyGameDataPY.GetFuncCfg('DownReward', 4)
-    curAwardNum = curPlayer.NomalDictGetProperty(ChConfig.Def_PDict_DownloadPatchAward)
-    if curAwardNum == patchAwardNum:
-        GameWorld.DebugLog("已发放下载补丁包奖励! curAwardNum(%s) == patchAwardNum(%s)" % (curAwardNum, patchAwardNum), playerID)
-        return
-    
-    awardItemList = IpyGameDataPY.GetFuncEvalCfg('DownReward', 3)
-    if not awardItemList:
-        return
-    
-    PlayerControl.NomalDictSetProperty(curPlayer, ChConfig.Def_PDict_DownloadPatchAward, patchAwardNum)
-    GameWorld.DebugLog("发放补丁包下载奖励: curAwardNum=%s,patchAwardNum=%s" % (curAwardNum, patchAwardNum), playerID)
-    PlayerControl.SendMailByKey("DownloadPatchAward", [playerID], awardItemList)
-    return
-
-def GetDownloadAward(curPlayer, dataEx):
-    ##分包下载奖励 dataEx 0直接领取 1发邮件
-    playerID = curPlayer.GetPlayerID()
-    downloadAwardNum = IpyGameDataPY.GetFuncCfg('DownReward', 5)
-    curAwardNum = curPlayer.NomalDictGetProperty(ChConfig.Def_PDict_DownloadAwardState)
-    if curAwardNum == downloadAwardNum:
-        GameWorld.DebugLog("已领取分包奖励! curAwardNum(%s) == downloadAwardNum(%s)" % (curAwardNum, downloadAwardNum), playerID)
-        return
-    
-    awardItemList = IpyGameDataPY.GetFuncEvalCfg('DownReward', 1)
-    if not awardItemList:
-        return
-    
-    # 检查背包
-    if dataEx == 0:
-        needSpace = len(awardItemList)
-        packSpace = ItemCommon.GetItemPackSpace(curPlayer, IPY_GameWorld.rptItem, needSpace)
-        if needSpace > packSpace:
-            PlayerControl.NotifyCode(curPlayer, "GeRen_chenxin_998371")
-            return
-        
-    PlayerControl.NomalDictSetProperty(curPlayer, ChConfig.Def_PDict_DownloadAwardState, downloadAwardNum)
-    GameWorld.DebugLog("领取分包下载奖励: curAwardNum=%s,downloadAwardNum=%s" % (curAwardNum, downloadAwardNum), playerID)
-    if dataEx == 1:
-        PlayerControl.SendMailByKey('SubpackageDownload', [curPlayer.GetID()], awardItemList)
-    else:
-        for itemID, itemCnt, isBind in awardItemList:
-            ItemControler.GivePlayerItem(curPlayer, itemID, itemCnt, 0, [IPY_GameWorld.rptItem])
-    SyncPackDownloadAward(curPlayer)
-    return
-
-def SyncPackDownloadAward(curPlayer):
-    #分包下载奖励记录通知
-    downloadAwardNum = IpyGameDataPY.GetFuncCfg('DownReward', 5)
-    sendPack = ChPyNetSendPack.tagMCPackDownloadRecord()
-    sendPack.Clear()
-    sendPack.Record = curPlayer.NomalDictGetProperty(ChConfig.Def_PDict_DownloadAwardState) == downloadAwardNum
-    NetPackCommon.SendFakePack(curPlayer, sendPack)
-    return
-
 def NotifyPlayerMove(curPlayer, posX, posY, npcID=0):
     '''通知前端向某个点移动
                 这里前端可能需要针对某次移动做额外处理,比如移动到某个点后需要自动战斗等
@@ -4317,3 +3974,50 @@
     #PlayerControl.SetRealmDifficulty(curPlayer, clientData.RealmDifficulty)
     return
 
+#// A0 08 查看通用记录 #tagCSViewGameRec
+#
+#struct    tagCSViewGameRec
+#{
+#    tagHead        Head;
+#    WORD         RecType;        //记录类型
+#    DWORD         RecID;        //自定义记录ID
+#};
+def OnViewGameRec(index, clientData, tick):
+    curPlayer = GameWorld.GetPlayerManager().GetPlayerByIndex(index)
+    recType = clientData.RecType
+    recID = clientData.RecID
+    if recType not in ShareDefine.Def_GameRecTypeList:
+        return
+    if recType in ShareDefine.Def_ViewGameRecSelfList:
+        recID = curPlayer.GetPlayerID()
+    recTypeIDMgr = DBDataMgr.GetGameRecMgr().GetRecTypeIDMgr(recType, recID)
+    SyncGameRecInfo(curPlayer, recType, recID, recTypeIDMgr.GetDataList())
+    return
+
+def SyncGameRecInfo(curPlayer, recType, recID, recDataList):
+    recList = []
+    for recData in recDataList:
+        if not recData:
+            continue
+        rec = ChPyNetSendPack.tagSCGameRec()
+        rec.Time = recData.GetTime()
+        rec.Value1 = recData.GetValue1()
+        rec.Value2 = recData.GetValue2()
+        rec.Value3 = recData.GetValue3()
+        rec.Value4 = recData.GetValue4()
+        rec.Value5 = recData.GetValue5()
+        rec.Value6 = recData.GetValue6()
+        rec.Value7 = recData.GetValue7()
+        rec.Value8 = recData.GetValue8()
+        rec.UserData = recData.GetUserData()
+        rec.UserDataLen = len(rec.UserData)
+        recList.append(rec)
+        
+    clientPack = ChPyNetSendPack.tagSCGameRecInfo()
+    clientPack.Clear()
+    clientPack.RecType = recType
+    clientPack.RecID = recID
+    clientPack.RecList = recList
+    clientPack.Count = len(clientPack.RecList)
+    NetPackCommon.SendFakePack(curPlayer, clientPack)
+    return

--
Gitblit v1.8.0