Purzelkater

cat as cat can
Veteran
Joined
Feb 20, 2016
Messages
86
Reaction score
69
First Language
German
Primarily Uses
Hi,


how can I execute an event after a savegame is loaded?


On new game is easy to write an autorun event on the starting map. But I want to execute an event after a savegame was loaded (so this should be map-independent).


Kind regards,


Purzelkater
 

izyees

My Secret Santa
Veteran
Joined
Oct 24, 2015
Messages
248
Reaction score
67
First Language
english
you mean common event?
 

Purzelkater

cat as cat can
Veteran
Joined
Feb 20, 2016
Messages
86
Reaction score
69
First Language
German
Primarily Uses
Basically yes.


I can place an event on the starting map as autorun (using self-switch to ensure it only runs once at game start). Now I want to execute this event (or rather the script calls I have used on this events) runs after a savegame was loaded too.
 

mrcopra

Veteran
Veteran
Joined
Jul 21, 2015
Messages
453
Reaction score
164
First Language
Not English
Primarily Uses
N/A
Do you want execute the event with any load files?
 

Purzelkater

cat as cat can
Veteran
Joined
Feb 20, 2016
Messages
86
Reaction score
69
First Language
German
Primarily Uses
@mrcopra: Yes, that's right. I'd like to show a "Welcome back" message (and some other stuff) after every load.


@izyees: Well, this looks like the right way but can't get it to work properly. On my start map I have added a new event but I don't understand your "switch on x" setting to fire this event after the savegame was loaded. Sorry... //rmwforums.s3.amazonaws.com/emoticons/default_sad.gif
 

Purzelkater

cat as cat can
Veteran
Joined
Feb 20, 2016
Messages
86
Reaction score
69
First Language
German
Primarily Uses
OMG! *facepalm* For hours I have tried to get it to work, because I unrealized there are common events. I had tried to get this working with map events that couldn't work. On German tanslation it's called "Gew. Ereignisse" - don't know what "Gew" stands for, but with the english help file I have missed that.
Anyway, it's so easy now. Just made a common event and call reserveCommonEvent after load. Thank you so much you both! :)
 

Eff-n-Geoff

Veteran
Veteran
Joined
Oct 26, 2015
Messages
182
Reaction score
7
First Language
English
Hi there, sorry to resurrect a thread. 


@mrcopra, your plugin is great. Is it possible to only have the event run for the first time you load a save ... not every time. So if you quit the game and load a save, the common event would run. But if you are already mid-game and load a save - nothing happens.


Also, to further clarify ... if you loaded a save for the first time, it would run the common event. Then if you loaded a save again nothing would happen.


However, if you quit the game and loaded the save, the event would run again. 


So it resets after every quit.


Thank you.
 
Last edited by a moderator:

mrcopra

Veteran
Veteran
Joined
Jul 21, 2015
Messages
453
Reaction score
164
First Language
Not English
Primarily Uses
N/A
Hi there, sorry to resurrect a thread. 


@mrcopra, your plugin is great. Is it possible to only have the event run for the first time you load a save ... not every time. So if you quit the game and load a save, the common event would run. But if you are already mid-game and load a save - nothing happens.


Also, to further clarify ... if you loaded a save for the first time, it would run the common event. Then if you loaded a save again nothing would happen.


However, if you quit the game and loaded the save, the event would run again. 


So it resets after every quit.


Thank you.



hmmm, to be sure i understood


you want event run once and when you saved it will not run again


but if you quit the game without save override the old one it will trigger again?
 

Eff-n-Geoff

Veteran
Veteran
Joined
Oct 26, 2015
Messages
182
Reaction score
7
First Language
English
Thank you for responding, 


So basically it the common event would only run once per play session. 


If the player quits the game and loads a saved game, the common event would run.


If the player has already loaded a save, and loads another one it wouldn't run


Basically, the event is only allowed to be run once per play session. If the player quits, it's reset.
 

mrcopra

Veteran
Veteran
Joined
Jul 21, 2015
Messages
453
Reaction score
164
First Language
Not English
Primarily Uses
N/A
Thank you for responding, 


So basically it the common event would only run once per play session. 


If the player quits the game and loads a saved game, the common event would run.


If the player has already loaded a save, and loads another one it wouldn't run


Basically, the event is only allowed to be run once per play session. If the player quits, it's reset.



Try this 

View attachment Event After Load.js
 

Eff-n-Geoff

Veteran
Veteran
Joined
Oct 26, 2015
Messages
182
Reaction score
7
First Language
English
Thank you for this @mrcopra, unfortunately that didn't work for me.


Each time I load a saved game, the common event runs. Not only the first time in the play session.


I have set the switch ID in the plugin to 300 (a switch that isn't being used anywhere), but unfortunately it doesn't work for me ... unless I'm doing it wrong.
 

mrcopra

Veteran
Veteran
Joined
Jul 21, 2015
Messages
453
Reaction score
164
First Language
Not English
Primarily Uses
N/A
it will disabled common event if you saved the game after it triggered
 

KillerGin

Freddie
Veteran
Joined
Dec 18, 2015
Messages
558
Reaction score
510
First Language
English
Primarily Uses
N/A
Hello @mrcopra!


I would love for the run common event on successful load to work for me but for some reason it only works sometimes.


Sometimes it seems to only work the first time I load the save but then If I try to load the same save again, it doesn't work.


Other times it doesn't seem to work at all.


I use a lot of Yanfly's scripts and I am hoping the save core isn't interfering with this plugin. I placed the plugin in all different locations but it doesn't seem to help at all. Any suggestions? 
 
Last edited by a moderator:

KillerGin

Freddie
Veteran
Joined
Dec 18, 2015
Messages
558
Reaction score
510
First Language
English
Primarily Uses
N/A
@izyees I tried yours after and it works! Sweet! Thanks!


P.S. Sorry for double post, I would add to above but I can't delete this, sorry.
 
Last edited by a moderator:

Latest Threads

Latest Profile Posts

This catgirl name is Elyune.
Her hobby is cooking and eating sweets. She's also an alchemist.

Cat_girl.jpg
catgirl-1.jpg
Raptor Revolt Demo 4_10_2021 3_12_09 PM.png

Latest custom tileset work for RAPTOR REVOLT in this beach scene set in the acheroraptor capital in Ridge City, Hell Creek.
unknown.png


I figured it was about time to update the battle sprite for one of my characters. The old one was the first time I ever drew a battle sprite, and filled with lines that shouldn't be there. So far, the new one is cleaner.
EQAQeW8.png

This was supposed to become her neutral talking stance, but now i just feel like she looks a little puzzled :D
I'm also open for any name suggestions, as i seriously suck at those. In my notes everything is just THE CITY or THAT GUY and THIS PRIESTESS or whatever :D
Nearing completion of the first major city of Albert, a vacation getaway city built a long time ago by a king who really didn't want to be invaded.

Forum statistics

Threads
110,281
Messages
1,051,945
Members
143,301
Latest member
KurvyKirby
Top