

| | ||

I have the following issues that were not issues but now are...
- Can't Dash
- Can't Change Leader
I have made a few recent changes such as setting CT to a Variable and Normal Speed to a Variable. *Had everything working before the normal speed change.
Also I as wondering how to set Dash_Speed to a variable as well?
Around the same time of changing Normal Speed to a variable the Change Leader script. (Which was working very well) has suddenly stopped... :S
I'm no pro scripter, I'm just trying to learn, so if you can explain what I did wrong then I'll avoid the same mistake again.
Thanks so much everyone.
Change Leader Script
(PART 1)
- Can't Dash
- Can't Change Leader
I have made a few recent changes such as setting CT to a Variable and Normal Speed to a Variable. *Had everything working before the normal speed change.
Also I as wondering how to set Dash_Speed to a variable as well?
Around the same time of changing Normal Speed to a variable the Change Leader script. (Which was working very well) has suddenly stopped... :S
I'm no pro scripter, I'm just trying to learn, so if you can explain what I did wrong then I'll avoid the same mistake again.
Thanks so much everyone.
Change Leader Script
- Spoiler:
- #------------------#
#Dod Change Leader #
#by:Dodoop #
#version:1.0 #
#------------------#
#
# Edited by: Night_Runner
# Date: 15/Sept/09
#
# Designed to: Turn on the switch corresponding with the leading player's ID
# (and turn off the switch from the last leading player). And update the
# leading player before battle (designed to be compatable with MOG XAS Hud
# V2.6.
#
#-----------------#
#Muda o líder quando uma certa tecla for pressionada no mapa.
module Dodoop
#Tecla que devera ser pressiona para mudar o líder.
CHANGE_LEADER_INPUT = Input::L
end
class Scene_Map
alias change_leader update
def update
change_leader
if Input.trigger?(Dodoop::CHANGE_LEADER_INPUT)
leader_read
end
$game_variables[$game_party.actors[0].id] = $game_system.xas_skill_id
$game_switches[$game_party.actors[0].id] = true # Turns on the switch of
# the leading hero
end
def leader_read
$game_switches[$game_party.actors[0].id] = false # Turns off the switch of
# the last hero
@actors = []
for i in 0...$game_party.actors.size
@actors[i] = $game_party.actors[i]
end
for i in 1...@actors.size
$game_party.actors[i - 1] = @actors[i]
end
$game_party.actors[@actors.size - 1] = @actors[0]
$game_player.refresh
$game_party.refresh # Needed to update the party order.
@sthero.refresh # Only to be used with MOG's XAS, refreshes the HUD.
@sthero.update if @sthero != nil
@sthero.refresh if @sthero != nil
@sthero.update if @sthero != nil
if @sthero != nil
@sthero.dispose
last_act = $game_party.actors.shift
$game_party.add_actor (last_act.id)
$game_player.refresh
$game_system.xas_item_id = 0
$scene = Scene_Map.new
$game_system.xas_skill_id = $game_variables[$game_party.actors[0].id]
@sthero = Window_HUD.new
@sthero.x = XAS_HUD::XASHUD_X
@sthero.y = XAS_HUD::XASHUD_Y
if $game_switches[XAS_HUD::DISABLE_STATUS_HUD_SWITCH] == false
@sthero.visible = true
else
@sthero.visible = false
end
@sthero.update
$game_switches[25] = true
end
end
end
#================================================#
# Game_Party
#================================================#
class Game_Party
def remove_actor(actor_id)
# Delete actor
@actors.delete($game_actors[actor_id])
# Refresh player
$game_player.refresh
$game_switches[actor_id] = false # If the actor is removed, they cannot
# be the leading hero.
end
end
(PART 1)




















































































