#bug说明:将召唤生物设置为初始队友会在游戏一开始就离队,原因不明
module CLD99_SUMMON_CREATURE
SUMMON_CREATURE_CLASS_ID = [51..72]
# 在此设置召唤生物的职业ID范围
# 不要删除方括号
# 例: [2] [2,3,5,6] [2..6,8] [2..5,10..20]
end
class Game_Actor
#--------------------------------------------------------------------------
# ● 刷新
#--------------------------------------------------------------------------
alias refresh_for_remove refresh
def refresh
refresh_for_remove
if self.state?(death_state_id) && actor.summon_creature?
$game_party.remove_actor(@actor_id)
end
end
end
class RPG::Actor
#--------------------------------------------------------------------------
# ● 是否为召唤生物
#--------------------------------------------------------------------------
def summon_creature?
CLD99_SUMMON_CREATURE::SUMMON_CREATURE_CLASS_ID.each do |x|
if x.is_a?(Fixnum) then return true if x == self.class_id end
if x.is_a?(Range) then return true if x.include?(self.class_id) end
end
return false
end
end