So, I've got a question regarding how the Erase Event command actually works. I'm trying to set up a brief scare in my game, where if certain conditions are met, an image will appear on screen during room transitions, and then quickly fade out once the new room has loaded. I have it working now via self switches, but I'm confused about why the Erase Event command was causing errors.
The way I have it set up, the player will leave a room, and during the screen transition, a common event will be called which sets up the image.
The common event (no trigger method, random number is 1...1 for testing purposes and will be changed later) :
Once the screen transition finishes and the new room is visible, the image quickly fades out via the Move Picture command, followed by the Erase Picture command, both of which are set up via a parallel process.
Now, to avoid the parallel process constantly running once the picture has been erased, I tried to call the Erase Event command once the Erase Picture command had finished executing. For some reason, the Move Picture and Erase Picture commands don't get run, so the event is erased before they can execute, leaving the image on the screen.
However, replacing the Erase Event command with a Self Switch command allows the picture to fade and erase properly. The one downside to this is that I'll need to figure out a way to set the self switch off again so that it isn't just a one-time random event, without causing the parallel process to run.
I guess what I'm mostly wondering is, why does the Self Switch method work here, but the Erase Event method doesn't?
The way I have it set up, the player will leave a room, and during the screen transition, a common event will be called which sets up the image.
The common event (no trigger method, random number is 1...1 for testing purposes and will be changed later) :
Once the screen transition finishes and the new room is visible, the image quickly fades out via the Move Picture command, followed by the Erase Picture command, both of which are set up via a parallel process.
Now, to avoid the parallel process constantly running once the picture has been erased, I tried to call the Erase Event command once the Erase Picture command had finished executing. For some reason, the Move Picture and Erase Picture commands don't get run, so the event is erased before they can execute, leaving the image on the screen.
However, replacing the Erase Event command with a Self Switch command allows the picture to fade and erase properly. The one downside to this is that I'll need to figure out a way to set the self switch off again so that it isn't just a one-time random event, without causing the parallel process to run.
I guess what I'm mostly wondering is, why does the Self Switch method work here, but the Erase Event method doesn't?