# ▼▲▼ XRXS25. ダッシュ機能 ver.2 ▼▲▼
# by 桜雅 在土 (根本、再改訂)
# Tetra-Z (改訂原案)
#==============================================================================
# □ カスタマイズポイント
#==============================================================================
module XRXS_Dash
#
# 按下加速键之后的速度増加量
#
PLUSPEED = 1
#
# 行走加速的按键
#
BUTTON = Input::C
end
#==============================================================================
# ■ Game_Player
#==============================================================================
class Game_Player < Game_Character
#--------------------------------------------------------------------------
# ● フレーム更新
#--------------------------------------------------------------------------
alias xrxs25_update update
def update
# 例外補正
if @move_speed_arcadia == nil
@move_speed_arcadia = @move_speed
end
# 移動中、イベント実行中、移動ルート強制中、
# メッセージウィンドウ表示中、
# ダッシュボタン挿下中、のいずれでもない場合
unless moving? or $game_system.map_interpreter.running? or
@move_route_forcing or $game_temp.message_window_showing
# 速度の変更
if Input.press?(XRXS_Dash::BUTTON)
@move_speed = @move_speed_arcadia + XRXS_Dash::PLUSPEED
else
@move_speed = @move_speed_arcadia
end
end
# 呼び戻す
xrxs25_update
end
#--------------------------------------------------------------------------
# ○ 移動タイプ : カスタム [オーバーライド]
#--------------------------------------------------------------------------
def move_type_custom
# 例外補正
if @move_speed_arcadia == nil
@move_speed_arcadia = @move_speed
end
# 標準速度に戻す
@move_speed = @move_speed_arcadia
# 呼び戻す
super
# 速度の保管
@move_speed_arcadia = @move_speed
end
end
#==============================================================================
以下是人物跳跃脚本:
在Game_Player中找到:
if Input.trigger?(Input::C)
# 同位置および正面のイベント起動断定
check_event_trigger_here([0])
check_event_trigger_there([0,1,2])
end
在这段下面,添加脚本段落1即可(这段下面还有3个end,段落插在3个end之前)。如果使用了行走加速
脚本,则在添加段落1后继续添加脚本段落2(还是在3个end之前),否以实现跑步的时候跳跃得更远。
#==============================================================================
# 本脚本来自www.66RPG.com,使用和转载请保去此信息
#==============================================================================
脚本段落1:
#========================================================================================
====
# Advanced Jump Edit By: Title Loan Man
#==============================================================================
unless $game_system.map_interpreter.running?
if Input.press?(Input::RIGHT) and Input.press?(Input::A)
if passable?(@x, @y, 4) and $game_map.terrain_tag($game_player.x+1, $game_player.y)
!= 6
Audio.se_play ("Audio/SE/016-Jump02", 90, 100)
jump(2,0)
end
end
if Input.press?(Input::LEFT) and Input.press?(Input::A)
if passable?(@x, @y, 6) and $game_map.terrain_tag($game_player.x-1, $game_player.y)
!= 6
Audio.se_play ("Audio/SE/016-Jump02", 90, 100)
jump(-2,0)
end
end
if Input.press?(Input::DOWN) and Input.press?(Input::A)
if passable?(@x, @y, 8) and $game_map.terrain_tag($game_player.x, $game_player.y+1)
!= 6
Audio.se_play ("Audio/SE/016-Jump02", 90, 100)
jump(0,2)
end
end
if Input.press?(Input::UP) and Input.press?(Input::A)
if passable?(@x, @y, 2) and $game_map.terrain_tag($game_player.x, $game_player.y-1)
!= 6
Audio.se_play ("Audio/SE/016-Jump02", 90, 100)
jump(0,-2)
end
end
if Input.trigger?(Input::A)
Audio.se_play ("Audio/SE/016-Jump02", 90, 100)
jump(0,0)
end
end
脚本段落2:
#========================================================================================
====
# Advanced Jump Edit By: Title Loan Man
#==============================================================================
unless $game_system.map_interpreter.running?
if Input.press?(Input::RIGHT) and Input.press?(Input::A) and Input.press?(Input::C)
if passable?(@x, @y, 4)
if $game_map.terrain_tag($game_player.x+1, $game_player.y) != 6
if $game_map.terrain_tag($game_player.x+2, $game_player.y) != 6
if $game_map.terrain_tag($game_player.x+3, $game_player.y) != 6
if $game_map.terrain_tag($game_player.x+4, $game_player.y) != 6
Audio.se_play ("Audio/SE/016-Jump02", 90, 100)
jump(5,0)
end
end
end
end
end
end
if Input.press?(Input::LEFT) and Input.press?(Input::A) and Input.press?(Input::C)
if passable?(@x, @y, 6)
if $game_map.terrain_tag($game_player.x-1, $game_player.y) != 6
if $game_map.terrain_tag($game_player.x-2, $game_player.y) != 6
if $game_map.terrain_tag($game_player.x-3, $game_player.y) != 6
if $game_map.terrain_tag($game_player.x-4, $game_player.y) != 6
Audio.se_play ("Audio/SE/016-Jump02", 90, 100)
jump(-5,0)
end
end
end
end
end
end
if Input.press?(Input::DOWN) and Input.press?(Input::A) and Input.press?(Input::C)
if passable?(@x, @y, 8)
if $game_map.terrain_tag($game_player.x, $game_player.y+1) != 6
if $game_map.terrain_tag($game_player.x, $game_player.y+2) != 6
if $game_map.terrain_tag($game_player.x, $game_player.y+3) != 6
if $game_map.terrain_tag($game_player.x, $game_player.y+4) != 6
Audio.se_play ("Audio/SE/016-Jump02", 90, 100)
jump(0,5)
end
end
end
end
end
end
if Input.press?(Input::UP) and Input.press?(Input::A) and Input.press?(Input::C)
if passable?(@x, @y, 2)
if $game_map.terrain_tag($game_player.x, $game_player.y-1) != 6
if $game_map.terrain_tag($game_player.x, $game_player.y-2) != 6
if $game_map.terrain_tag($game_player.x, $game_player.y-3) != 6
if $game_map.terrain_tag($game_player.x, $game_player.y-4) != 6
Audio.se_play ("Audio/SE/016-Jump02", 90, 100)
jump(0,-5)
end
end
end
end
end
end
end