[SCRIPTING] [RMVX ACE] DELAY BUTTON INPUT ON CHOICES?
Posts
Pages:
1
Hey all, so one of the biggest complaints about my previous game was that it was way too easy to accidentally select choices without being able to read them first. I've tried adding a delay between the dialogue and the choice menu popping up, but that doesn't seem to help too much. Is there a way one can disable button inputs for about 1 second when the choices pop up? This would give the player a window to actually be able to read the choices before selecting one and hopefully save people a lot of frustration. :) Thanks!
The thought in my head is that you might be able to do something like...
...this? The wait-time is 30 frames in this example, which, from the testing I've done, might be the maximum I'd be willing to do. Feel free to play around with this number, though!
*Edit: As a sub-thought, could your players have been mashing Action Button to get past message boxes? Not sure if that's indicative of impatience, or what.
class Window_ChoiceList < Window_Command #-------------------------------------------------------------------------- # * Start Input Processing #-------------------------------------------------------------------------- def start update_placement wait(30) refresh select(0) open activate end def wait(duration) duration.times {Fiber.yield} end end
...this? The wait-time is 30 frames in this example, which, from the testing I've done, might be the maximum I'd be willing to do. Feel free to play around with this number, though!
*Edit: As a sub-thought, could your players have been mashing Action Button to get past message boxes? Not sure if that's indicative of impatience, or what.
author=Marrend
The thought in my head is that you might be able to do something like...
class Window_ChoiceList < Window_Command #-------------------------------------------------------------------------- # * Start Input Processing #-------------------------------------------------------------------------- def start update_placement wait(30) refresh select(0) open activate end def wait(duration) duration.times {Fiber.yield} end end
...this? The wait-time is 30 frames in this example, which, from the testing I've done, might be the maximum I'd be willing to do. Feel free to play around with this number, though!
*Edit: As a sub-thought, could your players have been mashing Action Button to get past message boxes? Not sure if that's indicative of impatience, or what.
Thanks! I'll test this out. And yeah, I do think it happens mostly to the fast readers (like me!) who are done with the text as soon as it loads, but it's still annoying for them (and me when I watch them play LOL)
author=Marrend
The thought in my head is that you might be able to do something like...
class Window_ChoiceList < Window_Command #-------------------------------------------------------------------------- # * Start Input Processing #-------------------------------------------------------------------------- def start update_placement wait(30) refresh select(0) open activate end def wait(duration) duration.times {Fiber.yield} end end
...this? The wait-time is 30 frames in this example, which, from the testing I've done, might be the maximum I'd be willing to do. Feel free to play around with this number, though!
*Edit: As a sub-thought, could your players have been mashing Action Button to get past message boxes? Not sure if that's indicative of impatience, or what.
I tried that out and it only adds a delay between the two text boxes, which is what I've been doing with a \| at the end of the pre-choice dialogue; what I'm trying to accomplish is this:
1. Text box appears with test (e.g. "Are you sure you want to put the baby in the oven?")
2. Choice box ("Hell yeah" or "Hell no") appears
3. Input is disabled for a brief period (no more than 1 second) while the choices are on screen so button mashers won't automatically select the first choice
4. Input is re-enabled, making it possible to make a choice
Does that make more sense?
Did a bit more fiddling around. If you move the wait function so it would look more like...
...this, the choice-window would appear as normal, but the cursor (or other input) would not respond for a period of <duration>. Which, in this example, is 30 frames.
*Edit: I tried it again with a 300 wait-period (5 seconds). Oh, yeah, that choice-window was staring at me doing nothing as I pressed the up and down arrow for quite some time!
class Window_ChoiceList < Window_Command #-------------------------------------------------------------------------- # * Start Input Processing #-------------------------------------------------------------------------- def start update_placement refresh select(0) open wait(30) activate end def wait(duration) duration.times {Fiber.yield} end end
*Edit: I tried it again with a 300 wait-period (5 seconds). Oh, yeah, that choice-window was staring at me doing nothing as I pressed the up and down arrow for quite some time!
author=Marrend
Did a bit more fiddling around. If you move the wait function so it would look more like...
class Window_ChoiceList < Window_Command #-------------------------------------------------------------------------- # * Start Input Processing #-------------------------------------------------------------------------- def start update_placement refresh select(0) open wait(30) activate end def wait(duration) duration.times {Fiber.yield} end end
...this, the choice-window would appear as normal, but the cursor (or other input) would not respond for a period of <duration>. Which, in this example, is 30 frames.
*Edit: I tried it again with a 300 wait-period (5 seconds). Oh, yeah, that choice-window was staring at me doing nothing as I pressed the up and down arrow for quite some time!
You are a gentleman and a scholar and I thank you kindly, that's exactly what I needed <3
I'll be happy to give you a scripting credit, just let me know what you want to be called :D
Pages:
1














