#!/usr/bin/python # -*- coding: GBK -*- #------------------------------------------------------------------------------- # ##@package Skill.PassiveBuff.PassiveSkill_5000 # # @todo:»ØºÏ´¥·¢ # @author hxp # @date 2024-01-17 # @version 1.0 # # ÏêϸÃèÊö: »ØºÏ´¥·¢ # #------------------------------------------------------------------------------- #"""Version = 2024-01-17 16:00""" #------------------------------------------------------------------------------- import ChConfig # ½øÈëXX buff״̬´¥·¢¼¼ÄÜ def CheckCanHappen(attacker, defender, effect, curSkill): #A-»ØºÏ±àºÅ£¨0-ÿ»ØºÏ£¬>=1-x»ØºÏ£©£»B-ÅжϷ½Ê½£¨0-µÈÓÚ£¬1-´óÓÚµÈÓÚ£¬2-СÓÚµÈÓÚ£¬3-ÿx»ØºÏ£©£»C- timeLine = attacker.GetDictByKey(ChConfig.Def_Obj_Dict_TurnFightTimeline) if not timeLine: return False checkTurnNum = effect.GetEffectValue(0) checkType = effect.GetEffectValue(1) if checkTurnNum: turnNum = timeLine / 100 if checkType == 0: # µÚx»ØºÏ if turnNum != checkTurnNum: return False elif checkType == 1: # ´óÓÚµÈÓÚx»ØºÏ if turnNum < checkTurnNum: return False elif checkType == 2: # СÓÚµÈÓÚx»ØºÏ if turnNum > checkTurnNum: return False elif checkType == 3: # ÿx»ØºÏ if turnNum % checkTurnNum != 0: return False else: return False # ÆäËûÂß¼­... return True