
User
7 posts
Last seen: 5 years ago
GM Version: Studio
5 years ago
Is this something that can be done?
At the moment I have a loading script where it loads like this:
"GMech_Profile_Read_Real("level",global.level);
GMech_Profile_Read_Real("hp", global.hp);
GMech_Profile_Read_Real("maxhp", global.maxhp); ........"
and a saving script that does this:
"GMech_Profile_Write_Real("level",global.level);
GMech_Profile_Write_Real("hp", global.hp);
GMech_Profile_Write_Real("maxhp", global.maxhp);...."
When I have them loading and saving I also used in a step:
if(!GMech_Profile_Uploading())
{
instance_deactivate_all(true);
draw_text(x,y,"Saving..."); //or loading
}else
{
instance_deactivate_all(false);
}
When I call for a load the defaults kick in. My defaults are set in the log in screen, while the title screen has a new game and a continue button. I want the new game button to save all the defaults, and the continue button to load all the new data (after the player saves, exits, then comes back.)
Game Dev

Administrator
64 posts
Last seen: 2 years ago
GM Version: Studio
5 years ago
The GMech_Profile_read functions return a value, so you need to set them like you set a variable:
variable1=GMech_Profile_Read_String("section","variable","DefaultValue")
GMechanism Creator

Administrator
64 posts
Last seen: 2 years ago
GM Version: Studio
5 years ago
Actually booleans ARE reals. True=1 and false=0. So you should be able to use the real functions with booleans.
GMechanism Creator

User
7 posts
Last seen: 5 years ago
GM Version: Studio
5 years ago
Good to know then it was my loading that was off thanks!!
Game Dev