I'm try to event a "Skip Cutscene" Event and I need to know if there is a way to forcibly close a Message Box that is open and running using a Script Call.
I'm using YEP_MessageCore if that helps.
I'm using YEP_MessageCore if that helps.
Not 100% sure what you are looking to do here, but adding \^ to the end of the message forces it to close. But make sure to add a bunch of \.\.\.\.\.\. to make sure it doesn't close up instantly. You can time the whole thing out and then it will just close on it's own.
\^ just show the text in 1x and not animated.\. is more silence for some time◆If:Script:Input.isTriggered("escape")
◆Fadeout Screen
◆Plugin Command:ResetAllEventLocations
◆Script:$gameMessage.clear();
◆Script:$gameMap.eraseEvent($gameVariables.value(639));
◆Erase Picture:#1
◆Erase Picture:#2
◆Erase Picture:#3
◆Transfer Player:Volume Teleport (7,5) (Direction: Down, Fade: None)
◆
:End
let win = Scene_Manager._scene._windowLayer.children.find(win => win instanceof Window_Message);
if(win) win.pause = false;
SceneManager._scene._messageWindow.terminateMessage();

I didn't see that when I was looking through Script Call List... But it doesn't work - or at least not the way I want. The Message box continues to remain unclosed when i hit the key needed. It even opens the next box after the first one closes and continues the entire conversation before skipping the CS.
◆If:Script:Input.isTriggered("escape")
◆Fadeout Screen
◆Plugin Command:ResetAllEventLocations
◆Script:SceneManager._scene._messageWindow.terminateMessage();
◆Script:$gameMap.eraseEvent($gameVariables.value(639));
◆Erase Picture:#1
◆Erase Picture:#2
◆Erase Picture:#3
◆Transfer Player:Volume Teleport (7,5) (Direction: Down, Fade: None)
◆
:End
Unfortunately, this doesn't work either...
$gameMap._interpreter.command115(); // Exit Event Processing on main interpreter
SceneManager._scene._messageWindow.terminateMessage();
What if you made your own dialog box, like mimic 100% the dialog box RPG Maker uses, then then use that as an image only for this that can be removed in this same fashion you have setup already?
if ($gameMessage.isBusy()) {
$gameMessage.clear();
if (SceneManager._scene._messageWindow) {
SceneManager._scene._messageWindow.close();
}
if ($gameMessage.isBusy()) {
$gameMessage.clear();
SceneManager._scene?._messageWindow.close()
Unfortunately, neither one of those worked for me. Thank you for trying... I might have to just be content with what I have right now.
I have updated my NWJS to the most recent stable version for MV, but the shortened version still doesn't work... Maybe it'll only work on MZ.
it works for me though, only I use the first version for the plugin.
can you try the altMesasgeWindow and see if walk away works?
Saga Game
The Variable should be the first line of the Controlling Event, and it should be set to the EventID [Controlling Event = 1; Variable 1 = 1]. You will have to add this Variable to all the controlling events in the Cutscene on each map. Make sure you set up the variable with the right number.
This thread is being closed, due to being solved. If for some reason you would like this thread re-opened, please report this post and leave a message why. Thank you.
Original thread: https://forums.rpgmakerweb.com/threads/forcing-a-message-box-to-close-using-a-script-call.181972/