| | |
| | |
|
| | | # 进入XX buff状态触发技能
|
| | | def CheckCanHappen(attacker, defender, effect, curSkill):
|
| | | #A-回合编号(0-每回合,>=1-第x回合);B-判断方式(0-等于,1-大于等于,2-小于等于);C-
|
| | | #A-回合编号(0-每回合,>=1-x回合);B-判断方式(0-等于,1-大于等于,2-小于等于,3-每x回合);C-
|
| | | timeLine = attacker.GetDictByKey(ChConfig.Def_Obj_Dict_TurnFightTimeline)
|
| | | if not timeLine:
|
| | | return False
|
| | |
| | | checkType = effect.GetEffectValue(1)
|
| | | if checkTurnNum:
|
| | | turnNum = timeLine / 100
|
| | | if checkType == 0:
|
| | | if checkType == 0: # 第x回合
|
| | | if turnNum != checkTurnNum:
|
| | | return False
|
| | | elif checkType == 1:
|
| | | elif checkType == 1: # 大于等于x回合
|
| | | if turnNum < checkTurnNum:
|
| | | return False
|
| | | elif checkType == 2:
|
| | | elif checkType == 2: # 小于等于x回合
|
| | | if turnNum > checkTurnNum:
|
| | | return False
|
| | | elif checkType == 3: # 每x回合
|
| | | if turnNum % checkTurnNum != 0:
|
| | | return False
|
| | | else:
|
| | | return False
|
| | |
|