er_sprmap_crechara create_characters
alias wora_cater_sprmap_updchara update_characters
#--------------------------------------------------------------------------
# * Create Character Sprite
#--------------------------------------------------------------------------
def create_characters(*args)
wora_cater_sprmap_crechara(*args)
# Remove Game_Player sprite, this will be add later
((@character_sprites.size-1)..0).each do |i|
next if @character_sprites[i].nil?
if @character_sprites[i].character.is_a?(Game_Player)
@character_sprites[i].dispose
@character_sprites.delete_at(i)
break
end
end
# Create party members sprite
(1..(Wora::CATERPILLAR_MAX_ACTORS-1)).each do |n|
@character_sprites.push(Sprite_Character.new(@viewport1, $game_cateracter[n-1]))
end
@character_sprites.push(Sprite_Character.new(@viewport1, $game_player))
end
#--------------------------------------------------------------------------
# * Update Character Sprite
#--------------------------------------------------------------------------
def update_characters(*args)
$game_cateracter.each {|cater| cater.update }
wora_cater_sprmap_updchara(*args)
end
end
class Game_Player < Game_Character
attr_reader :move_speed
unless method_defined?('wora_cater_gampla_movdown')
alias wora_cater_gampla_movdown move_down
alias wora_cater_gampla_movleft move_left
alias wora_cater_gampla_movright move_right
alias wora_cater_gampla_movup move_up
alias wora_cater_gampla_movll move_lower_left
alias wora_cater_gampla_movlr move_lower_right
alias wora_cater_gampla_movul move_upper_left
alias wora_cater_gampla_movur move_upper_right
alias wora_cater_gampla_jump jump
alias wora_cater_gampla_getoffveh get_off_vehicle
alias wora_cater_gampla_moveto moveto
#--------------------------------------------------------------------------
# * Move Down
#--------------------------------------------------------------------------
def move_down(turn_ok = true)
wora_cater_gampla_movdown(turn_ok)
Wora.add_upd_cater("act.move_down(#{turn_ok})") unless @move_failed
end
#--------------------------------------------------------------------------
# * Move Left
#--------------------------------------------------------------------------
def move_left(turn_ok = true)
wora_cater_gampla_movleft(turn_ok)
Wora.add_upd_cater("act.move_left(#{turn_ok})") unless @move_failed
end
#--------------------------------------------------------------------------
# * Move Right
#--------------------------------------------------------------------------
def move_right(turn_ok = true)
wora_cater_gampla_movright(turn_ok)
Wora.add_upd_cater("act.move_right(#{turn_ok})") unless @move_failed
end
#--------------------------------------------------------------------------
# * Move up
#--------------------------------------------------------------------------
def move_up(turn_ok = true)
wora_cater_gampla_movup(turn_ok)
Wora.add_upd_cater("act.move_up(#{turn_ok})") unless @move_failed
end
#--------------------------------------------------------------------------
# * Move Lower Left
#--------------------------------------------------------------------------
def move_lower_left
wora_cater_gampla_movll
Wora.add_upd_cater('act.move_lower_left') unless @move_failed
end
#--------------------------------------------------------------------------
# * Move Lower Right
#--------------------------------------------------------------------------
def move_lower_right
wora_cater_gampla_movlr
Wora.add_upd_cater('act.move_lower_right') unless @move_failed
end
#--------------------------------------------------------------------------
# * Move Upper Left
#--------------------------------------------------------------------------
def move_upper_left
wora_cater_gampla_movul
Wora.add_upd_cater('act.move_upper_left') unless @move_failed
end
#--------------------------------------------------------------------------
# * Move Upper Right
#--------------------------------------------------------------------------
def move_upper_right
wora_cater_gampla_movur
Wora.add_upd_cater('act.move_upper_right') unless @move_failed
end
#--------------------------------------------------------------------------
# * Jump
#--------------------------------------------------------------------------
def jump(x, y)
wora_cater_gampla_jump(x, y)
Wora.add_upd_cater("act.jump(#{x},#{y})")
end
#--------------------------------------------------------------------------
# * Get Off Vehicle
#--------------------------------------------------------------------------
def get_off_vehicle(*args)
wora_cater_gampla_getoffveh(*args)
Wora.reset_cater_pos
end
#--------------------------------------------------------------------------
# * Move to Designated Position
#--------------------------------------------------------------------------
def moveto(*args)
wora_cater_gampla_moveto(*args)
Wora.reset_cater_pos
end
end
end
class Game_Map
attr_accessor :events
alias wora_cater_gammap_setup setup
def setup(*args)
wora_cater_gammap_setup(*args)
# Create caterpillar actors
$game_cateracter = []
(1..(Wora::CATERPILLAR_MAX_ACTORS-1)).each do |n|
$game_cateracter.push(Game_WCateracter.new(n))
end
$cater_movelist = Array.new(Wora::CATERPILLAR_MAX_ACTORS - 1) {''}
end
end[/code]
Cara penyesuainnya seperti tadi sih
[/quote]
trus aktifin switch yang mana ni?