RPG Maker Forums

Hello! I'm new here and
(I don't speak english very well, so I'll try my best to be understable)
I wonder how to know what savefile is loaded with a script call.

I'm trying to make if the player die somewhere, when he'll load the game again and go back where he was died, he'll be alble to see blood where he died before.
I already tried Jackkel's Persistent Switches , but it affect all savesfiles. (and i would like that switches and variables are saved only one the actual savefile used by the player)
Then I found Olivia's Meta Controls, but the problem is the same, because even <Local Meta> affect all the save in the same in playthrough.


So I almost found a solution by combine Meta Controls and Autosave:

I already know "$gameSystem.onBeforeSave();DataManager.saveGame(x);". But in fact, I would like to make a save on the last loaded file (the file used by the player)
I tried "$gameSystem.onBeforeSave();DataManager.saveGame(DataManager.latestSavefileId());", but it works only with the last saved file so if I save my game in 3 slots (so there are 3 savefiles), then if I quit the game and I load the 2nd file, and I make an autosave by event with this script call, it will be saved on the 3rd, because it is the last saved file.)
So to solve this problem, I should force a 2nd save when the player loaded his file (So it will be the last saved file). But how i could guess what file was loaded by the player?

So is it posible to make a sort of conditional call script like this?

If slot 2 is loaded
script call: $gameSystem.onBeforeSave();DataManager.saveGame(2)


If slot 1 is loaded
script call: $gameSystem.onBeforeSave();DataManager.saveGame(1)


If slot 3 is loaded
script call: $gameSystem.onBeforeSave();DataManager.saveGame(3)


Or is there another solution to save only switches and variables values by script call or something?

I think I should make only one save slot in the game but i think it would be annoying to make a new game to have another end...


Thanks for your answer.

Latest Threads

Latest Profile Posts

Our latest feature is an interview with... me?!

People4_2 (Capelet off and on) added!

Just beat the last of us 2 last night and starting jedi: fallen order right now, both use unreal engine & when I say i knew 80% of jedi's buttons right away because they were the same buttons as TLOU2 its ridiculous, even the same narrow hallway crawl and barely-made-it jump they do. Unreal Engine is just big budget RPG Maker the way they make games nearly identical at its core lol.
Can someone recommend some fun story-heavy RPGs to me? Coming up with good gameplay is a nightmare! I was thinking of making some gameplay platforming-based, but that doesn't work well in RPG form*. I also was thinking of removing battles, but that would be too much like OneShot. I don't even know how to make good puzzles!
one bad plugin combo later and one of my followers is moonwalking off the screen on his own... I didn't even more yet on the new map lol.

Forum statistics

Threads
106,034
Messages
1,018,446
Members
137,820
Latest member
georg09byron
Top