I just need a really simple example of a script that allows you to pick any party member you want during battle. This menu would take place of the Fight escape menu. The script does not need to be complete I just would like an example with some correct syntax so i can learn.
Example:
Instead of
============
Fight
Escape
I would like to have
============
Party member 1
Party member 2
Party member 3
party member 4
Its essentially the same as the "Fight" option but it specifically takes you to that character.
Ability to pick what party member you want during battle.
● ARCHIVED · READ-ONLY
-
-
Code:You will need to change the BattleManager and many methods related to how the command input order works.
class Window_PartyCommand # should also be checking for states, like whether actor can actually move? def enabled?(actor) actor.alive? end def make_command_list #~ add_command(Vocab::fight, :fight) #~ add_command(Vocab::escape, :escape, BattleManager.can_escape?) $game_party.members.each {|actor| add_command(actor.name, :actor_fight, enabled?(actor), actor.index) } end end class Scene_Battle def create_party_command_window @party_command_window = Window_PartyCommand.new @party_command_window.viewport = @info_viewport #~ @party_command_window.set_handler(:fight, method(:command_fight)) #~ @party_command_window.set_handler(:escape, method(:command_escape)) @party_command_window.set_handler(:actor_fight, method(:command_actor_fight)) @party_command_window.unselect end def command_actor_fight index = @party_command_window.current_ext @status_window.select(index) @party_command_window.close @actor_command_window.setup($game_party.members[index]) end end
The point is to use extended data when you're adding your commands and how to retrieve them. -
Woah!
You have been an amazing source of information on this forum Tsukihime. *bow*
Thank you :)