#!/usr/bin/python
|
# -*- coding: GBK -*-
|
#-------------------------------------------------------------------------------
|
#
|
##@package Skill.PassiveTrigger.PassiveEff_5508
|
#
|
# @todo:´¥·¢Êͷż¼ÄÜ£¨¶Ô´¥·¢ÓѾü£©
|
# @author hxp
|
# @date 2025-12-20
|
# @version 1.0
|
#
|
# ÏêϸÃèÊö: ´¥·¢Êͷż¼ÄÜ£¨¶Ô´¥·¢ÓѾü£©
|
#
|
#-------------------------------------------------------------------------------
|
#"""Version = 2025-12-20 22:00"""
|
#-------------------------------------------------------------------------------
|
|
import TurnSkill
|
import GameWorld
|
|
def DoSkillEffectLogic(turnFight, batObj, tagObj, effSkill, curEffect, connSkill, connBuff, **kwargs):
|
if "byFriendObj" not in kwargs:
|
return
|
byFriendObj = kwargs.pop("byFriendObj") # Ö±½ÓÈ¡³ö£¬·ÀÖ¹´«µÝ
|
|
passiveSkillID = curEffect.GetEffectValue(0) # ¼¼ÄÜID£¬Îª0ʱÊͷű¾¼¼ÄÜ
|
rate = curEffect.GetEffectValue(1) # ¸ÅÂÊÍò·ÖÂÊ
|
sameCountryRate = curEffect.GetEffectValue(2) # ÓѾüͬ¹úʱµÄ¸ÅÂÊ
|
if sameCountryRate:
|
if byFriendObj.GetCountry() == batObj.GetCountry():
|
rate = sameCountryRate
|
|
if not GameWorld.CanHappen(rate):
|
GameWorld.DebugLogEx("5508¸ÅÂʲ»´¥·¢¼¼ÄÜ! rate=%s,friendID=%s", rate, byFriendObj.GetID())
|
return
|
GameWorld.DebugLogEx("5508¸ÅÂÊ´¥·¢¼¼ÄÜ! rate=%s,friendID=%s", rate, byFriendObj.GetID())
|
|
if not passiveSkillID:
|
passiveSkillID = effSkill.GetSkillID()
|
if not passiveSkillID:
|
return
|
|
effectID = curEffect.GetEffectID()
|
effSkillID = effSkill.GetSkillID()
|
return TurnSkill.OnUsePassiveSkill(turnFight, batObj, byFriendObj, passiveSkillID, connSkill, effSkillID, effectID, connBuff, **kwargs)
|