From 027dccfa5c57091f7d1787af3e6c7b26c8c0f9a3 Mon Sep 17 00:00:00 2001
From: hxp <ale99527@vip.qq.com>
Date: 星期一, 23 十二月 2019 15:46:52 +0800
Subject: [PATCH] 8346 【恺英】【后端】协助系统(玩家看到boss才同步伤血封包;修复玩家PK时buff掉血添加npc伤血列表报错)
---
ServerPython/ZoneServerGroup/map1_8G/MapServer/MapServerData/Script/NPC/NPCHurtManager.py | 4 +++-
ServerPython/ZoneServerGroup/map1_8G/MapServer/MapServerData/Script/Skill/GameSkills/SkillCommon.py | 5 +++--
2 files changed, 6 insertions(+), 3 deletions(-)
diff --git a/ServerPython/ZoneServerGroup/map1_8G/MapServer/MapServerData/Script/NPC/NPCHurtManager.py b/ServerPython/ZoneServerGroup/map1_8G/MapServer/MapServerData/Script/NPC/NPCHurtManager.py
index 4028134..29fc7c9 100644
--- a/ServerPython/ZoneServerGroup/map1_8G/MapServer/MapServerData/Script/NPC/NPCHurtManager.py
+++ b/ServerPython/ZoneServerGroup/map1_8G/MapServer/MapServerData/Script/NPC/NPCHurtManager.py
@@ -831,13 +831,15 @@
bossHurtInfoPack.HurtValueList = hurtValueList
bossHurtInfoPack.HurtCount = len(hurtValueList)
+ curNPC = self.curNPC
assistHurtValueListDict = {}
copyPlayerManager = GameWorld.GetMapCopyPlayerManager()
for playerID in syncPlayerIDList:
player = copyPlayerManager.FindPlayerByID(playerID)
if not player:
continue
-
+ if not player.CanSeeOther(curNPC):
+ continue
if playerID in self.__noAssitPlayerIDDict:
assTagPlayerID = playerID
elif playerID in self.__assistPlayerIDDict:
diff --git a/ServerPython/ZoneServerGroup/map1_8G/MapServer/MapServerData/Script/Skill/GameSkills/SkillCommon.py b/ServerPython/ZoneServerGroup/map1_8G/MapServer/MapServerData/Script/Skill/GameSkills/SkillCommon.py
index 046c782..0e36460 100644
--- a/ServerPython/ZoneServerGroup/map1_8G/MapServer/MapServerData/Script/Skill/GameSkills/SkillCommon.py
+++ b/ServerPython/ZoneServerGroup/map1_8G/MapServer/MapServerData/Script/Skill/GameSkills/SkillCommon.py
@@ -1339,12 +1339,13 @@
# 2013-1-3,去除npc攻击造成的伤血记录
if attackerOwner != None and attackerOwner.GetGameObjType() == IPY_GameWorld.gotPlayer:
- AttackCommon.NPCAddObjInHurtList(attackerOwner, curObj, curObjHP_BeforeAttack, lostValue)
#CheckAddPoisonAtkBuff(skillTypeID, attackerOwner, curObj, tick)
if curObjType == IPY_GameWorld.gotPlayer:
AttackCommon.OnPVPDamage(attackerOwner, lostValue, curObj, "SkillLostHP")
-
+ elif curObjType == IPY_GameWorld.gotNPC:
+ AttackCommon.NPCAddObjInHurtList(attackerOwner, curObj, curObjHP_BeforeAttack, lostValue)
+
#统一调用攻击结束动作
if isDoAttackResult:
BaseAttack.DoLogic_AttackResult(buffOwner, curObj, None, tick)
--
Gitblit v1.8.0