By replacing the Autorun with a parallel event.
The Autorun is very restrictive in its function, as it runs from start to finish, but the parallel event works in the background, running simultaneously, making it easier to bypass.
An example of this is shown in the 2 video (Unskipped_scene and Skip_Scene). The first part (Unskipped_scene) plays my scene, which includes: image movement, movement route on the player, and a text message.
In the second part(Skip_Scene), I press the "Z" key to skip my scene.
Back to my question. A scene created this way can be skipped with just a few commands, whereas a scene that uses a video ("play movie") becomes more difficult. In fact, we would have to deal with stopping the video and removing the black background that RPG Maker creates for it. Let's say the difference I wanted to highlight is precisely this.
Skip part of the event?
● ARCHIVED · READ-ONLY
-
-
Then you're losing the whole purpose of autorun, to block input so the player can't walk around and open menus during the cutscene.By replacing the Autorun with a parallel event.
I'm not sure why you're making and zipping videos instead of just posting screenshots of events people can look at, but I'll bow out of this. You clearly have some notion of how you think it can work - I just don't think it'll pan out :wink:
But I'm not always right - good luck! -
The truth is that I have the engine set to my native language. But you're right, to provide better help, event screenshots are necessary. I'll try to change the language of RPG Maker MZ (it seems there's no direct option for it, I'll investigate).
As for the mechanic, I did it this way:
Autorun event with:
- Disable menu
- Switch "Skip Button" = On
- Switch "Scene Start" = On
- Erase Event
- Set movement route -> Player (Wait)
- Move down
- Move down
- Move down
- Move right
- Move right
- Move right
- Show image(1) ...
- Move image(1) ...(wait)
- Text Box
- If the "ok" button is pressed
Switch "Scene Start" = Off
Erase image(1)
Transfer Player ...
Switch "Skip Button" = Off - End
If this is what the requester is asking for, I'll share the code after switching the language. -
So if the actual issue is that you can't interrupt an autorun event with a button press, and an autorun is what you'd typically use for cutscenes because it blocks player input and disables menu access:
I'd suggest make it a parallel event instead, disable menu access and use this script to disable player movement
JavaScript:if($gamePlayer.moveByInputCached === undefined) //This checks if the value is undefined $gamePlayer.moveByInputCached = $gamePlayer.moveByInput; //If it is undefined, it sets to the current value of $gamePlayer.moveByInput which is 'true' $gamePlayer.moveByInput = function(){ return false; }
To enable movement again
Code:$gamePlayer.moveByInput = $gamePlayer.moveByInputCached; //This resets the value of moveByInput to the cached value
Then have another parallel event listening for button press, which would trigger a self switch of the first event, or transfer to new scene (whatever each section of the cutscene is. If on the same map, do the self switch, if different maps, transfer). -
So i searched for plugins, but found only two paid ones, and it seems like both of them are outdated.
The only free one i found were for MZ.
So if the actual issue is that you can't interrupt an autorun event with a button press, and an autorun is what you'd typically use for cutscenes because it blocks player input and disables menu access:
I'd suggest make it a parallel event instead, disable menu access and use this script to disable player movement
JavaScript:if($gamePlayer.moveByInputCached === undefined) //This checks if the value is undefined $gamePlayer.moveByInputCached = $gamePlayer.moveByInput; //If it is undefined, it sets to the current value of $gamePlayer.moveByInput which is 'true' $gamePlayer.moveByInput = function(){ return false; }
To enable movement again
Code:$gamePlayer.moveByInput = $gamePlayer.moveByInputCached; //This resets the value of moveByInput to the cached value
Then have another parallel event listening for button press, which would trigger a self switch of the first event, or transfer to new scene (whatever each section of the cutscene is. If on the same map, do the self switch, if different maps, transfer).
Still not working. Pressing down cancel does nothing, seems like second parallel is ignored for some reason. -
You can't remotely jump to label on a different event. You can remotely toggle a self switch on another eventStill not working. Pressing down cancel does nothing, seems like second parallel is ignored for some reason.
-
Do you know how? I tried as said here - https://forums.rpgmakerweb.com/inde...s-self-switch-through-a-script-command.63218/You can't remotely jump to label on a different event. You can remotely toggle a self switch on another event
But i am getting the error "key is not defined" when event reaching script.
-
Do you know how? I tried as said here - https://forums.rpgmakerweb.com/inde...s-self-switch-through-a-script-command.63218/
View attachment 318079But i am getting the error "key is not defined" when event reaching script.
$gameSelfSwitches.setValue([3,1,'A'], true);
It should be formatted like that. Where 3 is the map Id, 1 is the event number and A is the self switch -
Still not working
-
You're still putting the jump to label command in the button press. I told you you can't do that. You have to put the change self switch script in the button press.Still not workingView attachment 318081View attachment 318080
Also don't put leading zeros. I did not put leading zeros in my example. That makes javascript parse the number as octal. At low numbers there's no difference but above 8 or so it becomes a different number -
So i need 3 events on parallel run. First is my main event that has the only different is label added to specific spot where skip should end.You're still putting the jump to label command in the button press. I told you you can't do that. You have to put the change self switch script in the button press.
Also don't put leading zeros. I did not put leading zeros in my example. That makes javascript parse the number as octal. At low numbers there's no difference but above 8 or so it becomes a different number
Second event that self switches third event when button is presssed
And third event that makes jump to label?
It still does not work tho. Also just noticed that i forgot to remove self switch from event 2, removed it, still not working.
-
If you're interested, the update to version 1.8.1 includes text skipping.
-
No, you only need two events. One event with the code for the cutscene and another to listen for button press. Your third event does nothing. You can only jump to label within the same event. You cannot make another event force the first event to jump to label.
You would have each section of the cutscene in a new event page in the first event. The button press would just force the first event to toggle its self switch and start the next page of the cutscene. -
Sadly i do not own MZ. And message waits is not what i want to skip.
Ah, i think i got the logic of it, will try to do that.No, you only need two events. One event with the code for the cutscene and another to listen for button press. Your third event does nothing. You can only jump to label within the same event. You cannot make another event force the first event to jump to label.
You would have each section of the cutscene in a new event page in the first event. The button press would just force the first event to toggle its self switch and start the next page of the cutscene.
But will it work with show movie command? If i remember correctly, even in parallel process it ignores user input. -
I dont know if it will interrupt a video or not. You might have to put additional code in the button prese script to check if a video is playing and force it to stop.
-
So it worked as you said. But:I dont know if it will interrupt a video or not. You might have to put additional code in the button prese script to check if a video is playing and force it to stop.
- Does not skip the scrolling text (event changes, but text remains until it's fully scrolled)
- Does not skip movies
- Instantly works on button press. That's the most problematic part, is it possible to make it work on button hold to avoid random pressing? -
You can either use the script: Input.isLongPressed('cancel') or have the button press increment a another variable by 1 then trigger the effect once that variable reaches a certain number, e.g. 10
-
Thank you, this worked! Would be great if holding were a bit longer (it's like one second now), but it's way better than just pressing, so it will do. Probably the second method should be longer, but i am not exactly sure how to do that, i only recently first tried to work with variables.You can either use the script: Input.isLongPressed('cancel') or have the button press increment a another variable by 1 then trigger the effect once that variable reaches a certain number, e.g. 10
Do you know what code might do that? I don't even think that check is necessary because i would use it only during video plays.You might have to put additional code in the button prese script to check if a video is playing and force it to stop. -
You can either put a wait 1 frame in the current event or do the variable increment in a conditional within the conditional, e.g.Thank you, this worked! Would be great if holding were a bit longer (it's like one second now), but it's way better than just pressing, so it will do. Probably the second method should be longer, but i am not exactly sure how to do that, i only recently first tried to work with variables.
>if Cancel is pressed, ButtonPressCount +1
>If ButtonPressCount = 10
>Script to toggle self switch
>ButtonPressCount=0
I don't use videos or scrolling text so I don't know any more than you. You can ask in the Javascript questions threadDo you know what code might do that? I don't even think that check is necessary because i would use it only during video plays. -
Syntax error - unexpected token.>if Cancel is pressed, ButtonPressCount +1
>If ButtonPressCount = 10
>Script to toggle self switch
>ButtonPressCount=0