Adventure Game Studio

AGS Support => Advanced Technical Forum => Topic started by: Peegee on Tue 07/12/2021 11:26:47

Title: Backup
Post by: Peegee on Tue 07/12/2021 11:26:47
Hello. I have a problem with backups. I cannot use "SaveGameSlot" which saves the progress of the game. I have to make an independent save of each room. I have to use "ResetRoom" which only saves the objects, and include my other backup elements (characters, variables, inventory) in the room load. It works, until I quit the exe and relaunch it, my "save" is no longer there, unless I make it accessible at the start of the game. Question: Could the program save a variable that would say if the backup is accessible or not?
Title: Re: Backup
Post by: Khris on Tue 07/12/2021 12:56:08
Anything besides savegames that is supposed to survive exiting and restarting the game must be stored in custom files.

Simply check the File (https://www.adventuregamestudio.co.uk/manual/ags52.htm#topic519) section of the manual. You can write and read Strings or raw bytes at any point.
Title: Re: Backup
Post by: Peegee on Wed 08/12/2021 14:13:34
OK, thanks. I'm afraid it's a bit complex for me. I am moving towards a simpler solution.
Title: Re: Backup
Post by: Khris on Wed 08/12/2021 15:17:50
1. Which one? There is none that I know of.

2. Since this is still about storing level progress or whatever, I can't help thinking this might be an [utl=https://xyproblem.info/]xy problem[/url]. Please try to describe, without any AGS-related technical terms, what your actual goal is here.
How is your game supposed to work from a player's perspective? Why do you need to store room progress independently? Can the player just leave a room and try another? When is a room going to reset?