From cc1dc60daab5a6a9c2f1aa23c10736af2227d521 Mon Sep 17 00:00:00 2001
From: hxp <ale99527@vip.qq.com>
Date: 星期四, 04 三月 2021 14:05:52 +0800
Subject: [PATCH] 8650 【主干】【BT2】活动规则优化(多活动支持的改为单表模式,增加活动分组编号字段区分不同的活动编号;常规活动改为不受合服影响,合服活动独立出来;累计充值活动、集字活动适配为新模式);

---
 ServerPython/ZoneServerGroup/map1_8G/MapServer/MapServerData/Script/Skill/PassiveBuff/PassiveSkill_4065.py |   12 ++++++++++--
 1 files changed, 10 insertions(+), 2 deletions(-)

diff --git a/ServerPython/ZoneServerGroup/map1_8G/MapServer/MapServerData/Script/Skill/PassiveBuff/PassiveSkill_4065.py b/ServerPython/ZoneServerGroup/map1_8G/MapServer/MapServerData/Script/Skill/PassiveBuff/PassiveSkill_4065.py
index 922beb8..6d8394b 100644
--- a/ServerPython/ZoneServerGroup/map1_8G/MapServer/MapServerData/Script/Skill/PassiveBuff/PassiveSkill_4065.py
+++ b/ServerPython/ZoneServerGroup/map1_8G/MapServer/MapServerData/Script/Skill/PassiveBuff/PassiveSkill_4065.py
@@ -14,15 +14,23 @@
 import ChConfig
 import GameWorld
 import GameObj
-
+import IPY_GameWorld
 
 def CheckCanHappen(attacker, defender, effect, curSkill):
+    if not defender:
+        return False
+    if defender.GetGameObjType() != IPY_GameWorld.gotPlayer:
+        return False
+    
+    if attacker.GetGameObjType() != IPY_GameWorld.gotPlayer:
+        return False
+    
     attrLV = attacker.NomalDictGetProperty(ChConfig.Def_PDict_GodWeaponLV % effect.GetEffectValue(0))
     tagAttrLV = defender.NomalDictGetProperty(ChConfig.Def_PDict_GodWeaponLV % effect.GetEffectValue(0))
     
     if tagAttrLV >= attrLV:
         return False
-    
+
     return True
     
 

--
Gitblit v1.8.0