本帖最后由 正太君 于 2015-5-21 21:32 编辑
Project1.rar
(238.38 KB, 下载次数: 70)
class Game_Battler #-------------------------------------------------------------------------- # ● 可以使用技能的判定 # skill : 技能 #-------------------------------------------------------------------------- def skill_can_use?(skill) return false unless skill.is_a?(RPG::Skill) return false unless movable? return false if silent? and skill.spi_f > 0 return false if calc_mp_cost(skill) > mp return false if skill.id == 1 and $game_troop.end_turn > 0 # 聪聪 if $game_temp.in_battle return skill.battle_ok? else return skill.menu_ok? end end end class Game_Troop < Game_Unit attr_accessor :end_turn # 聪聪 #-------------------------------------------------------------------------- # ● 清除 #-------------------------------------------------------------------------- def clear @screen.clear @interpreter.clear @event_flags.clear @enemies = [] @turn_count = 0 @names_count = {} @can_escape = false @can_lose = false @preemptive = false @surprise = false @turn_ending = false @forcing_battler = nil @end_turn = 0 # 聪聪 end end class Scene_Battle < Scene_Base #-------------------------------------------------------------------------- # ● 回合结束 #-------------------------------------------------------------------------- def turn_end $game_troop.turn_ending = true $game_party.slip_damage_effect $game_troop.slip_damage_effect $game_party.do_auto_recovery $game_troop.preemptive = false $game_troop.surprise = false process_battle_event $game_troop.end_turn += 1 # 聪聪 $game_troop.turn_ending = false start_party_command_selection end end
class Game_Battler
#--------------------------------------------------------------------------
# ● 可以使用技能的判定
# skill : 技能
#--------------------------------------------------------------------------
def skill_can_use?(skill)
return false unless skill.is_a?(RPG::Skill)
return false unless movable?
return false if silent? and skill.spi_f > 0
return false if calc_mp_cost(skill) > mp
return false if skill.id == 1 and $game_troop.end_turn > 0 # 聪聪
if $game_temp.in_battle
return skill.battle_ok?
else
return skill.menu_ok?
end
end
end
class Game_Troop < Game_Unit
attr_accessor :end_turn # 聪聪
#--------------------------------------------------------------------------
# ● 清除
#--------------------------------------------------------------------------
def clear
@screen.clear
@interpreter.clear
@event_flags.clear
@enemies = []
@turn_count = 0
@names_count = {}
@can_escape = false
@can_lose = false
@preemptive = false
@surprise = false
@turn_ending = false
@forcing_battler = nil
@end_turn = 0 # 聪聪
end
end
class Scene_Battle < Scene_Base
#--------------------------------------------------------------------------
# ● 回合结束
#--------------------------------------------------------------------------
def turn_end
$game_troop.turn_ending = true
$game_party.slip_damage_effect
$game_troop.slip_damage_effect
$game_party.do_auto_recovery
$game_troop.preemptive = false
$game_troop.surprise = false
process_battle_event
$game_troop.end_turn += 1 # 聪聪
$game_troop.turn_ending = false
start_party_command_selection
end
end
|