From 85a55d93ea4c99337ad1b81d2c471208effaebd1 Mon Sep 17 00:00:00 2001
From: hxp <ale99527@vip.qq.com>
Date: 星期二, 23 十二月 2025 18:59:22 +0800
Subject: [PATCH] 121 【武将】武将系统-服务端(修复个别情况下上阵中的生效卡被视为未生效的bug;)
---
ServerPython/ZoneServerGroup/map1_8G/MapServer/MapServerData/Script/Skill/PassiveTrigger/PassiveEff_5022.py | 13 ++++++++++---
1 files changed, 10 insertions(+), 3 deletions(-)
diff --git a/ServerPython/ZoneServerGroup/map1_8G/MapServer/MapServerData/Script/Skill/PassiveTrigger/PassiveEff_5022.py b/ServerPython/ZoneServerGroup/map1_8G/MapServer/MapServerData/Script/Skill/PassiveTrigger/PassiveEff_5022.py
index bf3848c..e196c5b 100644
--- a/ServerPython/ZoneServerGroup/map1_8G/MapServer/MapServerData/Script/Skill/PassiveTrigger/PassiveEff_5022.py
+++ b/ServerPython/ZoneServerGroup/map1_8G/MapServer/MapServerData/Script/Skill/PassiveTrigger/PassiveEff_5022.py
@@ -29,6 +29,7 @@
# 100 - 按友方某个国家武将数 参数1:国家
if ruleType == 100:
country = calcRule[1] if len(calcRule) > 1 else 0
+ onlyAlive = calcRule[2] if len(calcRule) > 2 else 0
batLineup = batObj.GetBatLineup()
countryCnt = 0
batObjMgr = BattleObj.GetBatObjMgr()
@@ -38,11 +39,17 @@
continue
if batObj.GetCountry() != country:
continue
- #if batObj.IsAlive(): # 死亡也算
- # continue
+ if onlyAlive and not batObj.IsAlive():
+ continue
countryCnt += 1
calcLayer = countryCnt
- GameWorld.DebugLogEx("按友方某个国家武将数计算额外buff属性: ruleType=%s,country=%s,countryCnt=%s", ruleType, country, countryCnt)
+ GameWorld.DebugLogEx("按友方某个国家武将数计算额外buff属性: ruleType=%s,country=%s,countryCnt=%s,onlyAlive=%s", ruleType, country, countryCnt, onlyAlive)
+ # 101 - 仅对指定性别有效 参数1:性别
+ elif ruleType == 101:
+ onlySex = calcRule[1] if len(calcRule) > 1 else 0
+ if tagObj.GetSex() != onlySex:
+ GameWorld.DebugLogEx("5022额外buff对该性别无效: ruleType=%s,onlySex=%s,tagSex=%s,tagID=%s", ruleType, onlySex, tagObj.GetSex(), tagObj.GetID())
+ return
if calcLayer <= 0:
return
--
Gitblit v1.8.0