class Scene_Map
#--------------------------------------------------------------------------
# ● 戦闘前トランジション実行 @速度変更
#--------------------------------------------------------------------------
alias SSS001_perform_battle_transition perform_battle_transition
def perform_battle_transition
if $game_variables[SSS_BTLSPD::BATTLE_SPEED_VID] == 0
$game_variables[SSS_BTLSPD::BATTLE_SPEED_VID] = SSS_BTLSPD::BATTLE_SPEED_DEFAULT_VALUE
end
if $game_variables[SSS_BTLSPD::BATTLE_SPEED_VID] >= 11
$game_variables[SSS_BTLSPD::BATTLE_SPEED_VID] = 10
end
Graphics.transition(60, "Graphics/System/BattleStart", 100)
Graphics.freeze
end
end
class Scene_Battle
#--------------------------------------------------------------------------
# ● 終了前処理
#--------------------------------------------------------------------------
alias SSS001_pre_terminate pre_terminate
def pre_terminate
super
Graphics.fadeout(30) if SceneManager.scene_is?(Scene_Map)
Graphics.fadeout(30) if SceneManager.scene_is?(Scene_Title)
end
#--------------------------------------------------------------------------
# ● ウェイト
#--------------------------------------------------------------------------
alias SSS001_wait wait
def wait(duration)
duration.times {|i| update_for_wait if i < duration / (2 * $game_variables[SSS_BTLSPD::BATTLE_SPEED_VID]) || !show_fast? }
end
#--------------------------------------------------------------------------
# ● アニメーションの表示
# targets : 対象者の配列
# animation_id : アニメーション ID(-1: 通常攻撃と同じ)
#--------------------------------------------------------------------------
alias SSS001_show_animation show_animation
def show_animation(targets, animation_id)
#もしアニメカット用のスイッチがtrueで、
#fast状態にしているなら、エフェクトを飛ばす
#両方満たしていないなら、エフェクトを飛ばさない
if $game_switches[SSS_BTLSPD::BATTLE_SPEED_SID] == true
if !show_fast?
if animation_id < 0
show_attack_animation(targets)
else
show_normal_animation(targets, animation_id)
end
@log_window.wait
wait_for_animation
end
else
if animation_id < 0
show_attack_animation(targets)
else
show_normal_animation(targets, animation_id)
end
@log_window.wait
wait_for_animation
end
end
end
class Window_Selectable
#--------------------------------------------------------------------------
# ● 決定やキャンセルなどのハンドリング処理
#--------------------------------------------------------------------------
alias SSS001_process_handling process_handling
def process_handling
#戦闘中はInput.trigger?をrepeat?に書き換えて、テンポを上げてます
if $game_party.in_battle
return unless open? && active
return process_ok if ok_enabled? && Input.trigger?(:C)#Input.repeat?(:C)
return process_cancel if cancel_enabled? && Input.trigger?(:B)#Input.repeat?(:B)
return process_pagedown if handle?(:pagedown) && Input.trigger?(:R)
return process_pageup if handle?(:pageup) && Input.trigger?(:L)
else
return unless open? && active
return process_ok if ok_enabled? && Input.trigger?(:C)
return process_cancel if cancel_enabled? && Input.trigger?(:B)
return process_pagedown if handle?(:pagedown) && Input.trigger?(:R)
return process_pageup if handle?(:pageup) && Input.trigger?(:L)
end
end
end
class Sprite_Battler
#--------------------------------------------------------------------------
# ● エフェクトの開始
#--------------------------------------------------------------------------
alias SSS001_start_effect start_effect
def start_effect(effect_type)
@effect_type = effect_type
case @effect_type
when :appear
@effect_duration = 16
@battler_visible = true
when :disappear
@effect_duration = 32
@battler_visible = false
when :whiten
@effect_duration = 16
@battler_visible = true
when :blink
@effect_duration = 20
@battler_visible = true
#敵撃破時エフェクト(default=48)
#Sprite_Battler 150行以降を変数を織りまぜて書き換えた方が良いかも
when :collapse
@effect_duration = 48
@battler_visible = false
when :boss_collapse
@effect_duration = bitmap.height
@battler_visible = false
when :instant_collapse
@effect_duration = 16
@battler_visible = false
end
revert_to_normal
end
end[/pre]