参照 Game_Unit#smooth_target 和 Game_Action#targets_for_opponents、Game_Action#targets_for_friends 方法
简单改了下,未测试。如果有什么问题,可以自己看着改改。
class Game_Action def targets_for_opponents if item.for_random? Array.new(item.number_of_targets) { opponents_unit.random_target } elsif item.for_one? num = 1 + (attack? ? subject.atk_times_add.to_i : 0) if @target_index < 0 [opponents_unit.random_target] * num else # [opponents_unit.smooth_target(@target_index)] * num target = opponents_unit.members[@target_index] target && target.alive? ? Array.new(num, target) : [] end else opponents_unit.alive_members end end end
class Game_Action
def targets_for_opponents
if item.for_random?
Array.new(item.number_of_targets) { opponents_unit.random_target }
elsif item.for_one?
num = 1 + (attack? ? subject.atk_times_add.to_i : 0)
if @target_index < 0
[opponents_unit.random_target] * num
else
# [opponents_unit.smooth_target(@target_index)] * num
target = opponents_unit.members[@target_index]
target && target.alive? ? Array.new(num, target) : []
end
else
opponents_unit.alive_members
end
end
end
|