8835 【BT2】【主干】【后端】Part3-2 5)新增多日连充(主干补冲突;钱单位修改为分)
9个文件已修改
47 ■■■■ 已修改文件
PySysDB/PySysDBPY.h 2 ●●● 补丁 | 查看 | 原始文档 | blame | 历史
ServerPython/CoreServerGroup/GameServer/Script/ChPyNetSendPack.py 补丁 | 查看 | 原始文档 | blame | 历史
ServerPython/CoreServerGroup/GameServer/Script/ShareDefine.py 7 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
ServerPython/ZoneServerGroup/map1_8G/MapServer/MapServerData/Script/ChConfig.py 12 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
ServerPython/ZoneServerGroup/map1_8G/MapServer/MapServerData/Script/ChPyNetSendPack.py 补丁 | 查看 | 原始文档 | blame | 历史
ServerPython/ZoneServerGroup/map1_8G/MapServer/MapServerData/Script/IpyGameDataPY.py 6 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
ServerPython/ZoneServerGroup/map1_8G/MapServer/MapServerData/Script/Player/PlayerActManyDayRecharge.py 11 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
ServerPython/ZoneServerGroup/map1_8G/MapServer/MapServerData/Script/Player/PlayerCoin.py 2 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
ServerPython/ZoneServerGroup/map1_8G/MapServer/MapServerData/Script/ShareDefine.py 7 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
PySysDB/PySysDBPY.h
@@ -1672,7 +1672,7 @@
struct tagActManyDayRechargeAward
{
    DWORD        _TemplateID;    //模板ID
    DWORD        NeedRecharge;    //所需充值额度
    float        NeedRMB;    //所需充值额度
    BYTE        NeedDays;    //所需充值天数
    BYTE        AwardIndex;    //奖励索引
    dict        AwardItemInfo;    //奖励物品信息  {世界等级范围:[[物品ID,个数,是否拍品], ...]}
ServerPython/CoreServerGroup/GameServer/Script/ChPyNetSendPack.py
ServerPython/CoreServerGroup/GameServer/Script/ShareDefine.py
@@ -232,6 +232,7 @@
OperationActionName_FeastLogin = "ActFeastLogin" # 节日登录活动
OperationActionName_FeastWish = "ActFeastWish" # 节日祝福活动
OperationActionName_FeastTravel = "ActFeastTravel" # 节日游历活动
OperationActionName_ManyDayRecharge = "ActManyDayRecharge" # 多日连充活动
#节日活动类型列表 - 该类型无视开服天,日期到了就开启
FeastOperationActionNameList = [OperationActionName_FeastWeekParty, OperationActionName_FeastRedPacket,
                                OperationActionName_RechargeRebateGold, OperationActionName_GrowupBuy,
@@ -248,8 +249,8 @@
                           OperationActionName_WeekParty, OperationActionName_LoginAward, 
                           OperationActionName_NewFairyCeremony, OperationActionName_LuckyTreasure,
                           OperationActionName_DailyGiftbag, 
                           OperationActionName_CollectWords] \
                           + FeastOperationActionNameList
                           OperationActionName_CollectWords, OperationActionName_ManyDayRecharge,
                           ] + FeastOperationActionNameList
#需要记录开启活动时的世界等级的运营活动
NeedWorldLVOperationActNameList = [OperationActionName_FairyCeremony, OperationActionName_WishingWell, 
                                   OperationActionName_NewFairyCeremony, OperationActionName_FlashSale,
@@ -261,12 +262,14 @@
                                   OperationActionName_CollectWords,
                                   OperationActionName_FeastLogin,
                                   OperationActionName_FeastWish, OperationActionName_FeastTravel,
                                   OperationActionName_ManyDayRecharge,
                                   ]
#支持多活动分组编号的活动名
MultiActNumOperationActNameList = [OperationActionName_TotalRecharge, OperationActionName_CollectWords,
                                   OperationActionName_FlashGiftbag, OperationActionName_CostRebate,
                                   OperationActionName_SpringSale, OperationActionName_FlashSale,
                                   OperationActionName_ManyDayRecharge,
                                   ]
#跨服运营活动表名定义
ServerPython/ZoneServerGroup/map1_8G/MapServer/MapServerData/Script/ChConfig.py
@@ -3848,6 +3848,13 @@
Def_PDict_FeastTravelValue = "FeastTravelValue_%s" # 游历任务总进度值,参数(任务ID)
Def_PDict_FeastTravelCount = "FeastTravelCount_%s" # 游历任务已完成次数,参数(任务ID)
Def_PDict_FeastTravelAwardCount = "FeastTravelAwardCount_%s" # 游历已领奖次数,参数(奖励索引)
#多日连充活动
Def_PDict_ManyDayRechargeID = "ManyDayRechargeID_%s"  # 玩家身上的活动ID,唯一标识,取活动开始日期time值,参数:(活动编号)
Def_PDict_ManyDayRechargeTempID = "ManyDayRechargeTempID_%s"  # 玩家身上的模板ID,参数:(活动编号)
Def_PDict_ManyDayRechargeWorldLV = "ManyDayRechargeWorldLV_%s" #玩家身上的活动世界等级,参数:(活动编号)
Def_PDict_ManyDayRechargeValue = "ManyDayRechargeValue_%s_%s"  # 每日累充总额,参数:(活动编号, 天索引)
Def_PDict_ManyDayRechargeAward = "ManyDayRechargeAward_%s"  # 领奖记录,参数:(活动编号)
#-------------------------------------------------------------------------------
#开服活动,Def_PDictType_OpenServerCampaign
@@ -5383,7 +5390,10 @@
Def_RewardType_CACTGBillboardDabiao, #跨服充值排行活动达标奖励36
Def_RewardType_FeastLogin, #节日登录奖励37
Def_RewardType_FeastTravel, #节日游历奖励38
)= range(39)
Def_RewardType_DailyRecharge, #永久每日累充奖励39
Def_RewardType_RechargeGold30, #1元送30倍充值券每日奖励40
Def_RewardType_ManyDayRecharge, #多日连充41
)= range(42)
#boss复活相关活动定义
ServerPython/ZoneServerGroup/map1_8G/MapServer/MapServerData/Script/ChPyNetSendPack.py
ServerPython/ZoneServerGroup/map1_8G/MapServer/MapServerData/Script/IpyGameDataPY.py
@@ -1317,7 +1317,7 @@
                "ActManyDayRechargeAward":(
                        ("DWORD", "TemplateID", 1),
                        ("DWORD", "NeedRecharge", 0),
                        ("float", "NeedRMB", 0),
                        ("BYTE", "NeedDays", 0),
                        ("BYTE", "AwardIndex", 0),
                        ("dict", "AwardItemInfo", 0),
@@ -4463,7 +4463,7 @@
    
    def __init__(self):
        self.TemplateID = 0
        self.NeedRecharge = 0
        self.NeedRMB = 0.0
        self.NeedDays = 0
        self.AwardIndex = 0
        self.AwardItemInfo = {}
@@ -4471,7 +4471,7 @@
        return
        
    def GetTemplateID(self): return self.TemplateID # 模板ID
    def GetNeedRecharge(self): return self.NeedRecharge # 所需充值额度
    def GetNeedRMB(self): return self.NeedRMB # 所需充值额度
    def GetNeedDays(self): return self.NeedDays # 所需充值天数
    def GetAwardIndex(self): return self.AwardIndex # 奖励索引
    def GetAwardItemInfo(self): return self.AwardItemInfo # 奖励物品信息  {世界等级范围:[[物品ID,个数,是否拍品], ...]}
ServerPython/ZoneServerGroup/map1_8G/MapServer/MapServerData/Script/Player/PlayerActManyDayRecharge.py
@@ -26,6 +26,7 @@
import NetPackCommon
import GameWorld
import ChConfig
import CommFunc
Max_ActDays = 7 # 支持最大活动持续天
@@ -121,7 +122,7 @@
        if awardRecord & pow(2, awardIndex):
            continue
        
        needRechargeValue = ipyData.GetNeedRecharge()
        needRechargeValue = CommFunc.RMBToCoin(ipyData.GetNeedRMB())
        needDays = ipyData.GetNeedDays()
        finishDays = 0
        for dayIndex in xrange(Max_ActDays):
@@ -137,7 +138,7 @@
        
        batchPlayerIDList.append([playerID])
        batchAddItemList.append(awardItemList)
        batchParamList.append([needDays, needRechargeValue])
        batchParamList.append([needDays, str(ipyData.GetNeedRMB())])
        GameWorld.Log("多日连充活动补发奖励! actNum=%s,playerTemplateID=%s,awardIndex=%s" % (actNum, playerTemplateID, awardIndex))
        
    if batchPlayerIDList:
@@ -205,7 +206,7 @@
        GameWorld.DebugLog("找不到该多日连充活动档位索引奖励!actNum=%s,templateID=%s,awardIndex=%s" % (actNum, templateID, awardIndex), playerID)
        return
    
    needRechargeValue = awardIpyData.GetNeedRecharge()
    needRechargeValue = CommFunc.RMBToCoin(awardIpyData.GetNeedRMB())
    needDays = awardIpyData.GetNeedDays()
    
    dayRechargeValueDict = {}
@@ -237,7 +238,7 @@
    GameWorld.DebugLog("    领取成功! actNum=%s,templateID=%s,awardIndex=%s,needRechargeValue=%s,needDays=%s %s" 
                       % (actNum, templateID, awardIndex, needRechargeValue, needDays, dayRechargeValueDict))
    if notifyKey:
        PlayerControl.WorldNotify(0, notifyKey, [curPlayer.GetPlayerName(), needDays, needRechargeValue])
        PlayerControl.WorldNotify(0, notifyKey, [curPlayer.GetPlayerName(), needDays, str(awardIpyData.GetNeedRMB())])
        
    for itemID, itemCount, isAuctionItem in awardItemList:
        ItemControler.GivePlayerItem(curPlayer, itemID, itemCount, isAuctionItem, [IPY_GameWorld.rptItem])
@@ -290,7 +291,7 @@
        for awardIpyData in ipyDataList:
            awardInfo = ChPyNetSendPack.tagMCActManyDayRechargeAward()
            awardInfo.AwardIndex = awardIpyData.GetAwardIndex()
            awardInfo.NeedRecharge = awardIpyData.GetNeedRecharge()
            awardInfo.NeedRecharge = CommFunc.RMBToCoin(awardIpyData.GetNeedRMB())
            awardInfo.NeedDays = awardIpyData.GetNeedDays()
            awardInfo.AwardItemList = []
            awardItemList = GameWorld.GetDictValueByRangeKey(awardIpyData.GetAwardItemInfo(), actWorldLV, [])
ServerPython/ZoneServerGroup/map1_8G/MapServer/MapServerData/Script/Player/PlayerCoin.py
@@ -49,6 +49,7 @@
import PlayerGoldGift
import PlayerActTotalRecharge
import PlayerActRechargeRebateGold
import PlayerActManyDayRecharge
import PlayerActRechargePrize
import CrossActCTGBillboard
import PlayerActGrowupBuy
@@ -437,6 +438,7 @@
    if coinType in [CoinType_Gold, CoinType_Buy]:
        #跨服充值排行活动
        CrossActCTGBillboard.AddCTGRMB(curPlayer, orderCoin)
        PlayerActManyDayRecharge.AddManyDayRechargeValue(curPlayer, orderCoin) # 多日连充
        
    # 只算充仙玉的
    if coinType == CoinType_Gold:
ServerPython/ZoneServerGroup/map1_8G/MapServer/MapServerData/Script/ShareDefine.py
@@ -232,6 +232,7 @@
OperationActionName_FeastLogin = "ActFeastLogin" # 节日登录活动
OperationActionName_FeastWish = "ActFeastWish" # 节日祝福活动
OperationActionName_FeastTravel = "ActFeastTravel" # 节日游历活动
OperationActionName_ManyDayRecharge = "ActManyDayRecharge" # 多日连充活动
#节日活动类型列表 - 该类型无视开服天,日期到了就开启
FeastOperationActionNameList = [OperationActionName_FeastWeekParty, OperationActionName_FeastRedPacket,
                                OperationActionName_RechargeRebateGold, OperationActionName_GrowupBuy,
@@ -248,8 +249,8 @@
                           OperationActionName_WeekParty, OperationActionName_LoginAward, 
                           OperationActionName_NewFairyCeremony, OperationActionName_LuckyTreasure,
                           OperationActionName_DailyGiftbag, 
                           OperationActionName_CollectWords] \
                           + FeastOperationActionNameList
                           OperationActionName_CollectWords, OperationActionName_ManyDayRecharge,
                           ] + FeastOperationActionNameList
#需要记录开启活动时的世界等级的运营活动
NeedWorldLVOperationActNameList = [OperationActionName_FairyCeremony, OperationActionName_WishingWell, 
                                   OperationActionName_NewFairyCeremony, OperationActionName_FlashSale,
@@ -261,12 +262,14 @@
                                   OperationActionName_CollectWords,
                                   OperationActionName_FeastLogin,
                                   OperationActionName_FeastWish, OperationActionName_FeastTravel,
                                   OperationActionName_ManyDayRecharge,
                                   ]
#支持多活动分组编号的活动名
MultiActNumOperationActNameList = [OperationActionName_TotalRecharge, OperationActionName_CollectWords,
                                   OperationActionName_FlashGiftbag, OperationActionName_CostRebate,
                                   OperationActionName_SpringSale, OperationActionName_FlashSale,
                                   OperationActionName_ManyDayRecharge,
                                   ]
#跨服运营活动表名定义