From 5affad5d239f5fed725f5992ebab08c6da59c090 Mon Sep 17 00:00:00 2001
From: xdh <xiefantasy@qq.com>
Date: 星期二, 12 二月 2019 11:58:17 +0800
Subject: [PATCH] 5819 【后端】【1.6】运营活动支持对应不同的职业和世界等级
---
ServerPython/ZoneServerGroup/map1_8G/MapServer/MapServerData/Script/GameWorldLogic/FBProcess/GameLogic_SealDemon.py | 31 +++++++++++++++++++++++--------
1 files changed, 23 insertions(+), 8 deletions(-)
diff --git a/ServerPython/ZoneServerGroup/map1_8G/MapServer/MapServerData/Script/GameWorldLogic/FBProcess/GameLogic_SealDemon.py b/ServerPython/ZoneServerGroup/map1_8G/MapServer/MapServerData/Script/GameWorldLogic/FBProcess/GameLogic_SealDemon.py
index 8cb7cbb..eb36a09 100644
--- a/ServerPython/ZoneServerGroup/map1_8G/MapServer/MapServerData/Script/GameWorldLogic/FBProcess/GameLogic_SealDemon.py
+++ b/ServerPython/ZoneServerGroup/map1_8G/MapServer/MapServerData/Script/GameWorldLogic/FBProcess/GameLogic_SealDemon.py
@@ -36,6 +36,8 @@
import PlayerMagicWeapon
import PlayerBossReborn
import PlayerFairyCeremony
+import PlayerNewFairyCeremony
+import PlayerWeekParty
import EventReport
FBDict_StartTick = 'FBDict_StartTick%s' #开始时间
@@ -47,6 +49,18 @@
FBPlayerDict_Rank = "FBPlayerDict_Rank" # 玩家排名
g_npcHurtDict = {}
+
+
+def OnFBPlayerOnLogin(curPlayer):
+ if not GameWorld.GetDictValueByBit(curPlayer, ChConfig.Def_Player_Dict_VersionFix, ChConfig.Def_VerFix_FMTDouble):
+ GameWorld.SetDictValueByBit(curPlayer, ChConfig.Def_Player_Dict_VersionFix, ChConfig.Def_VerFix_FMTDouble, 1)
+ needViplv = IpyGameDataPY.GetFuncCfg('DemonJarSpecial')
+ if curPlayer.GetVIPLv() >= needViplv:
+ PlayerControl.NomalDictSetProperty(curPlayer, ChConfig.Def_Player_Dict_FMTOldDouble, 1)
+ GameWorld.DebugLog('1.3版本前可以双倍挑战')
+ NotifyFMTDouble(curPlayer)
+ return
+
## 是否能够通过活动查询进入
# @param curPlayer 玩家实例
@@ -265,7 +279,7 @@
remainHP = GetBossRemainHP(lineID, tick)
totalHP = __GetBossTotalHP()
hpReduceSpeed = curSpeed * 10000 / totalHP if totalHP else 0
- remainHPPer = min(100, remainHP * 100 / totalHP) if totalHP else 0
+ remainHPPer = min(1000000, remainHP * 1000000 / totalHP) if totalHP else 0
fbHelpDict = {FBCommon.Help_lineID:lineID, "hurtInfo":hurtInfo, 'hpReduceSpeed':hpReduceSpeed, 'remainHPPer':remainHPPer}
GameWorld.DebugLog("DoFBHelp: %s" % fbHelpDict, curPlayer.GetPlayerID())
FBCommon.Notify_FBHelp(curPlayer, fbHelpDict)
@@ -408,12 +422,8 @@
if playerHurtList:
killerName, hurtValue = playerHurtList[0][1]
NPCCommon.GameServer_KillGameWorldBoss(bossID, killerName, hurtValue)
-
- msgList = [bossID, 0]
- GameWorld.GetPlayerManager().GameServer_QueryPlayerResult(0, 0, 0, 'GameWorldBossState',
- '%s' % (msgList), len(str(msgList)))
- bosskey = ShareDefine.Def_Notify_WorldKey_GameWorldBossReborn % bossID
- GameWorld.GetGameWorld().SetGameWorldDict(bosskey, 0)
+
+ NPCCommon.GameServe_GameWorldBossState(bossID, 0)
__DoLogicSealDemonOver(1, tick, dropPosX, dropPosY)
gameFB.SetGameFBDict(FBDict_IsOver, tick)
@@ -451,6 +461,8 @@
curPlayer.Sync_TimeTick(ChConfig.tttPickupItem, 0, ChConfig.Def_FBPickupItemTime, True)
else:
leaveTick = PlayerControl.GetPlayerLeaveServerTick(playerID)
+ if not leaveTick:
+ continue
if tick - leaveTick > ChConfig.Def_PlayerOfflineProtectTime:
#离线超过3分钟的不给奖励
continue
@@ -536,6 +548,8 @@
PlayerMagicWeapon.SetMWPrivilegeData(curPlayer, ChConfig.MWPrivilege_SealDemonAddAttr, addCnt, True)
PlayerBossReborn.AddBossRebornActionCnt(curPlayer, ChConfig.Def_BRAct_FMT, addCnt)
PlayerFairyCeremony.AddFCPartyActionCnt(curPlayer, ChConfig.Def_PPAct_FMT, addCnt)
+ PlayerNewFairyCeremony.AddFCPartyActionCnt(curPlayer, ChConfig.Def_PPAct_FMT, addCnt)
+ PlayerWeekParty.AddWeekPartyActionCnt(curPlayer, ChConfig.Def_WPAct_FMT, addCnt)
return prizeItemList
def OnPickUpItem(curPlayer, curItem, tick):
@@ -700,7 +714,7 @@
curPlayer = GameWorld.GetPlayerManager().GetPlayerByIndex(playerIndex)
if GameWorld.GetMap().GetMapID() == ChConfig.Def_FBMapID_SealDemon:
return
- if not PlayerVip.GetPrivilegeValue(curPlayer, ChConfig.VIPPrivilege_FMTDouble):
+ if not curPlayer.NomalDictGetProperty(ChConfig.Def_Player_Dict_FMTOldDouble) and not PlayerVip.GetPrivilegeValue(curPlayer, ChConfig.VIPPrivilege_FMTDouble):
return
PlayerControl.NomalDictSetProperty(curPlayer, ChConfig.Def_Player_Dict_FMTDouble, clientData.IsDouble)
NotifyFMTDouble(curPlayer)
@@ -709,6 +723,7 @@
def NotifyFMTDouble(curPlayer):
packData = ChPyNetSendPack.tagMCFMTDoubleState()
packData.IsDouble = curPlayer.NomalDictGetProperty(ChConfig.Def_Player_Dict_FMTDouble)
+ packData.OldDouble = curPlayer.NomalDictGetProperty(ChConfig.Def_Player_Dict_FMTOldDouble)
NetPackCommon.SendFakePack(curPlayer, packData)
return
--
Gitblit v1.8.0