Common Event + Save = WRYYYYY

I will be very very swift.

After having spent quite a bit of time bringing my project up to completion-I have noticed that there is one nifty addition I could implement. Thanks to Vlue's Advanced Game Time script, and Yanfly's Save Engine, I thought that I could PERHAPS display, on the Save Screen, the Date in which the Save File was made.

Now then, why am I not posting in Script Support? Simple.
I pretty much know how to do it, it's as simple and as explanatory-but, the real problem is this.

I would like to run a Common Event which writes down the Date in a Variable, which I already know how to do, but I haven't the slightest of clues as to how I would go about forcing such a thing Right before the Save File is written. I.E. Do I add a line or two in which script? Where exactly? Which process do I have to "Ninja" to store the data in the Variables I require?


So... Any Clues?

~Daena Grey

Quick Edit: On Second thought, I am under the impression this still pertains to Script Support... Oops. My Apologies.
This is actually very easy. You add a line of code to whatever function is responsible for the actual saving. Don't know which one it is exactly, since I don't use VXAce.
That is... Exactly my problem. Adding a Line, that is understandably easy. I have no clue where, though. That is what gets me...
on_action_save method in Yanfly save engine sounds like the culprit to me.

There you can force the save of the date before the file itself gets saved.
I will investigate right away, be riiiiight back.


Edit: It does not appear to be working. Hrmmmmm... I have tried multiple times and even on fresh starts, but noperinos, it will not work as intended. Not getting any errors though.
Hrmmmm...
And where do you put the code?
Right before the script calls the Save Process. Third line of the method definition. I might've oopsed with calling the Common Event, But I can find a Workaround. Still on it!

Thank you very much for pointing out where I should concentrate my efforts. Weeee!

Edit: I did oops with calling the Common Event. OOPS!
All good now. ( ^ o ^ ) /
Ok, good to know 🙂 You're welcome!

Original thread: https://forums.rpgmakerweb.com/threads/common-event-save-wryyyyy.84218/