Save-Point
Script Request - Variables Specific Save File - Printable Version

+- Save-Point (https://www.save-point.org)
+-- Forum: Games Development (https://www.save-point.org/forum-4.html)
+--- Forum: Code Support (https://www.save-point.org/forum-20.html)
+--- Thread: Script Request - Variables Specific Save File (/thread-5124.html)



Script Request - Variables Specific Save File - JayRay - 04-27-2014

Here's what I'm humbly and most modestly asking for.

I'd like a version of the save/load scenes (and the subsequent windows) that only saves ten of the variables of a game... This would then, when brought up, only adjust the variables of a current game while it's being played.

I'd like to do this for an overall game completion... non-dependant on different save files. Basically, say I have something where a percentage of game completion or a specific quest unlocks a character that I want to be able to access. This save file (after everything else is loaded) would be loaded and changes the variables, letting the game know whether or not the specific character is unlockable.

If it can't be done I understand. If so, I'd like it under a different name like completion.rxdata


RE: Script Request - Variables Specific Save File - MechanicalPen - 04-27-2014

You want to save some data, and then load that same data into ALL saved games overwriting the ten or so variables with the data. Sort of like a new game plus sort of thing, correct?

This isn't so hard to do. in Scene_Save you'd define another file, in addition to the selected save file. Then you'd copy your ten variables into an object (probably an array) and then Marshal.dump(characters_unlocked, another_file)

in Scene_Load, you'd load everything as normal but then read the array from your completion.rxdata using Marshal.load(another_file) and overwrite the variables with the saved data (ex: $game_variables[1] = characters_unlocked[1] )


RE: Script Request - Variables Specific Save File - JayRay - 04-28-2014

"Hey, Mech. I'm a spriter, not a scripter. I don't have a clue how to write something like that."

Please, if someone can create this script, it'd be very helpful in getting something to work for my game.