Exit processing "Input Number" command

There is a monster that is chasing you. In order, to beat the level you'll have to Input a certain number.
What I want to do is to force a Game Over when the monster touches you, even though you're in the middle of inputting the number or reading a message.

What I'll probably need is some kind of script call that imitates\forces "key pressed" command without you actually pressing it.
I tried to use these:

(Input.isTriggered('ok'))
(Input.isRepeated(ok'))
(Input.isPressed('ok'))
(Input.isLongPressed('ok'))

but as I understand those are only for checking if certain keys are pressed.
Don't all events pause when you have a message window or an input window open? How will the monster touch you if they're not moving?
Don't all events pause when you have a message window or an input window open? How will the monster touch you if they're not moving?
Nope. All my parallel events work perfectly fine.
I still can change some things (erase pictures, fade-out, display messages) in the middle of it, but I'll still have press Ok to get rid of this Input Number window.
So there is no way to do that? 😀
This seems to work for me in a Script command:
Code:
SceneManager._scene._messageWindow._numberWindow.processOk();
This seems to work for me in a Script command:
Code:
SceneManager._scene._messageWindow._numberWindow.processOk();

What command should I use for pressing X/Cancel?

There is an Exit Event Processing Script Call $gameInterpreter._index = $gameInterpreter._list.length;
Could I somehow use it on some particular event?
How command should I use for pressing X/Cancel?

There is an Exit Event Processing Script Call $gameInterpreter._index = $gameInterpreter._list.length;
Could I somehow use it on some particular event?
I don't believe there is a "cancel" command for number input? What you could do instead is set the number to zero and "click" OK:
Code:
SceneManager._scene._messageWindow._numberWindow._number = 0;
SceneManager._scene._messageWindow._numberWindow.processOk();

There is no such object as $gameInterpreter in the default code: interpreters are bound to the map/battle scenes and individual parallel events. Generally speaking I would not recommend remotely interrupting an interpreter like that. 😅

If you're still stuck, it would help to have more details of your situation and what you're trying to achieve. 🙂
There is no such object as $gameInterpreter in the default code: interpreters are bound to the map/battle scenes and individual parallel events. Generally speaking, I would not recommend remotely interrupting an interpreter like that. 😅

If you're still stuck, it would help to have more details of your situation and what you're trying to achieve. 🙂

That's alright. There are more ways to stop an event 🙂 Thank you anyway.
Thread closed IgnoreMe

Original thread: https://forums.rpgmakerweb.com/threads/exit-processing-input-number-command.111667/