招式扫墓怎么做

lige

宝可梦训练家
2023/09/23
3
0
70
22
很奇怪,不知道为什么会改变初始值
 
最后编辑:

lige

宝可梦训练家
2023/09/23
3
0
70
22
[Pokémon Essentials version 20.1]
[EBDX v1.0]
Exception:NoMethodError
Message: undefined method []' for nil:NilClass Backtrace: Legends Arceus:98:in pbFaintedAllyCount'
Legends Arceus:56:in num_fainted_allies' Move_Effects_19A:348:in pbBaseDamage'
Move_Usage_Calculations:243:in pbCalcDamage' Battler_UseMove:733:in pbProcessMoveHit_ebdx'
Battler_UseMove:725:ineach' Battler_UseMove:725:in pbProcessMoveHit_ebdx'
[EBDX] Battle r Info:66:in pbProcessMoveHit' Battler_UseMove:509:in pbUseMove_ebdx'
Battler_UseMove:507:in `each'
This exception was logged in C:\Users\USERNAME\Saved Games\Pokemon Spaimer\errorlog. txt. Press Ctrl+C to copy this message to the clipboard.

class PokeBattle_Move_20C < PokeBattle_Move
def pbBaseDamage(baseDmg, user, target)
numFainted = user.num_fainted_allies
return baseDmg if numFainted <= 0
baseDmg += 50 * numFainted
return baseDmg
end
end

def num_fainted_allies
return @battle.pbFaintedAllyCount(self)
end

class PokeBattle_Battle
attr_accessor :fainted_count # Used to track the number of fainted battlers for Last Respects/Supreme Overlord.

alias __pla__initialize initialize
def initialize(scene, p1, p2, player, opponent)
__pla__initialize(scene, p1, p2, player, opponent)
@fainted_count = [0,0]
end

def pbFaintedAllyCount(idxBattler)
idxBattler = idxBattler.index if idxBattler.respond_to?("index")
return @fainted_count[idxBattler & 1]
end
end
 

在线成员

现在没有成员在线。

最新帖子

论坛统计

主题
517
消息
2,352
成员
3,007
最新成员
ZQLdw