[RMVX ACE] TEXT INPUT DURING BATTLE
Posts
Pages:
1
Has anyone played around with using Name Input screen events in combat?
I was trying to make an event that would let you type something in during combat, and realized you can't actually call that screen during battle (at least every time I tried it would just skip over the event.)
Anyone have an idea/or have a snippet that would help me accomplish such a thing?
I'm guessing it has to do with the fact that the scene it's being called in can't be called during battle? I'm playing around with a few things but figured I would ask ;^^
I was trying to make an event that would let you type something in during combat, and realized you can't actually call that screen during battle (at least every time I tried it would just skip over the event.)
Anyone have an idea/or have a snippet that would help me accomplish such a thing?
I'm guessing it has to do with the fact that the scene it's being called in can't be called during battle? I'm playing around with a few things but figured I would ask ;^^
I took a brief look at how Ace handles Name Input...
...and, of course, it's not as simple as just commenting out the first line. Scene_Name ends it's processing...
...with a "return_scene" function, which has the effect of making it look like the battle was reset. At least with the minimal testing I've done.
Getting around this isn't going to be easy, because the only way I can figure it is to take the windows that Scene_Name uses in it's "start" function...
...and throw them into Scene_Battle? I'm becoming less and less certain of this as I type, to be honest.
class Game_Interpreter #-------------------------------------------------------------------------- # * Name Input Processing #-------------------------------------------------------------------------- def command_303 return if $game_party.in_battle if $data_actors[@params[0]] SceneManager.call(Scene_Name) SceneManager.scene.prepare(@params[0], @params[1]) Fiber.yield end end end
...and, of course, it's not as simple as just commenting out the first line. Scene_Name ends it's processing...
class Scene_Name < Scene_MenuBase #-------------------------------------------------------------------------- # * Input [OK] #-------------------------------------------------------------------------- def on_input_ok @actor.name = @edit_window.name return_scene end end
...with a "return_scene" function, which has the effect of making it look like the battle was reset. At least with the minimal testing I've done.
Getting around this isn't going to be easy, because the only way I can figure it is to take the windows that Scene_Name uses in it's "start" function...
class Scene_Name < Scene_MenuBase #-------------------------------------------------------------------------- # * Start Processing #-------------------------------------------------------------------------- def start super @actor = $game_actors[@actor_id] @edit_window = Window_NameEdit.new(@actor, @max_char) @input_window = Window_NameInput.new(@edit_window) @input_window.set_handler(:ok, method(:on_input_ok)) end end
...and throw them into Scene_Battle? I'm becoming less and less certain of this as I type, to be honest.
Pages:
1