From d629712afdd7ff097902578febbc93bf1bec490e Mon Sep 17 00:00:00 2001
From: hxp <ale99527@vip.qq.com>
Date: 星期三, 17 十二月 2025 10:53:38 +0800
Subject: [PATCH] 129 【战斗】战斗系统-服务端(大乔全部技能; 增加效果5025;)

---
 ServerPython/ZoneServerGroup/map1_8G/MapServer/MapServerData/Script/Skill/PassiveTrigger/PassiveEff_5025.py |   41 +++++++++++++++++++++++++++++++++++++++++
 ServerPython/ZoneServerGroup/map1_8G/MapServer/MapServerData/Script/Skill/PassiveTrigger/PassiveEff_Attr.py |   12 ++++++++++--
 2 files changed, 51 insertions(+), 2 deletions(-)

diff --git a/ServerPython/ZoneServerGroup/map1_8G/MapServer/MapServerData/Script/Skill/PassiveTrigger/PassiveEff_5025.py b/ServerPython/ZoneServerGroup/map1_8G/MapServer/MapServerData/Script/Skill/PassiveTrigger/PassiveEff_5025.py
new file mode 100644
index 0000000..0389f73
--- /dev/null
+++ b/ServerPython/ZoneServerGroup/map1_8G/MapServer/MapServerData/Script/Skill/PassiveTrigger/PassiveEff_5025.py
@@ -0,0 +1,41 @@
+#!/usr/bin/python
+# -*- coding: GBK -*-
+#-------------------------------------------------------------------------------
+#
+##@package Skill.PassiveTrigger.PassiveEff_5025
+#
+# @todo:增减目标身上某种状态buff回合数
+# @author hxp
+# @date 2025-12-17
+# @version 1.0
+#
+# 详细描述: 增减目标身上某种状态buff回合数
+#
+#-------------------------------------------------------------------------------
+#"""Version = 2025-12-17 11:00"""
+#-------------------------------------------------------------------------------
+
+import TurnBuff
+import GameWorld
+
+def DoSkillEffectLogic(turnFight, batObj, tagObj, effSkill, curEffect, connSkill, connBuff, **kwargs):
+    buffStateList = curEffect.GetEffectValue(0) # buff [状态1, 状态2, ...]
+    addRemainTime = curEffect.GetEffectValue(1) # 变化回合数
+    addType = curEffect.GetEffectValue(2) # 变化是增还是减: 1-增;2-减
+    
+    buffMgr = tagObj.GetBuffManager()
+    for buffState in buffStateList:
+        buffList = buffMgr.FindBuffListByState(buffState)
+        if not buffList:
+            continue
+        for buff in buffList:
+            remainTime = buff.GetRemainTime()
+            if not remainTime:
+                continue
+            if addType == 2:
+                addRemainTime = -addRemainTime
+            remainTime += addRemainTime
+            GameWorld.DebugLogEx("增减目标身上某种状态buff回合数: tagID=%s,buffID=%s,addRemainTime=%s,reaminTime=%s", tagObj.GetID(), buff.GetBuffID(), addRemainTime, remainTime)
+            TurnBuff.SetBuffRemainTime(turnFight, tagObj, buff, remainTime)
+            
+    return True
diff --git a/ServerPython/ZoneServerGroup/map1_8G/MapServer/MapServerData/Script/Skill/PassiveTrigger/PassiveEff_Attr.py b/ServerPython/ZoneServerGroup/map1_8G/MapServer/MapServerData/Script/Skill/PassiveTrigger/PassiveEff_Attr.py
index ceaae8d..4fee62e 100644
--- a/ServerPython/ZoneServerGroup/map1_8G/MapServer/MapServerData/Script/Skill/PassiveTrigger/PassiveEff_Attr.py
+++ b/ServerPython/ZoneServerGroup/map1_8G/MapServer/MapServerData/Script/Skill/PassiveTrigger/PassiveEff_Attr.py
@@ -26,6 +26,14 @@
     if calcType == 10:
         buffStateList = curEffect.GetEffectValue(2)
         maxValue = curEffect.GetEffectValue(3) # 累计最高增加值
+        checkBatType = curEffect.GetEffectValue(4) # 验证攻击类型 0-不验证;1-连击;2-追击;3-反击
+        if checkBatType:
+            if not connSkill:
+                return
+            if connSkill.GetBatType() != checkBatType:
+                #GameWorld.DebugLog("额外属性效果非该战斗类型不触发: checkBatType=%s,skillBatType=%s" % (checkBatType, connSkill.GetBatType()))
+                return
+            
         layerTotal = 0
         buffMgr = defender.GetBuffManager()
         for buffState in buffStateList:
@@ -34,8 +42,8 @@
         attrValue *= layerTotal
         if maxValue and attrValue > maxValue:
             attrValue = maxValue
-        GameWorld.DebugLog("按对方buff层级增加属性: attrID=%s,attrValue=%s,buffStateList=%s,layerTotal=%s,maxValue=%s" 
-                           % (attrID, attrValue, buffStateList, layerTotal, maxValue))
+        GameWorld.DebugLogEx("按对方buff层级增加属性: attrID=%s,attrValue=%s,buffStateList=%s,layerTotal=%s,maxValue=%s,checkBatType=%s", 
+                             attrID, attrValue, buffStateList, layerTotal, maxValue, checkBatType)
     # 11-根据自己已损失血量百分比
     elif calcType == 11:
         curHP = attacker.GetHP()

--
Gitblit v1.8.0