saving and loading game progress

Post your questions, suggestions and experiences regarding game design, integration of external libraries here. For irrEdit, irrXML and irrKlang, see the
ambiera forums
Post Reply
drr00t
Posts: 14
Joined: Wed Aug 05, 2009 2:11 pm
Location: Brasilia/DF - Brasil

saving and loading game progress

Post by drr00t »

Hi,

I coding my game engine on top of Irrlicht, and now i thinking how can build my save and load game file format.

i using irr scene files and Irrlicht standard scene loader.

here follow format that i thinking

Code: Select all


[game file]
     [game level missions]
           [ mission name="First"]
                    [Completed="true"]
                    [missionFile="scene.irr"]
           [/mission]
           [ mission  name="Last"]
                    [Completed="false"]
                    [missionFile="scene.irr"]
           [/mission]
     [/game level missions]
[/game file]

Somebody has another solution to make this, more robust.

thanks for help.
vitek
Bug Slayer
Posts: 3919
Joined: Mon Jan 16, 2006 10:52 am
Location: Corvallis, OR

Post by vitek »

Are you worried that users might just open this file and skip through all of your levels? If you are going to leave it plain text, is there some reason you aren't using xml?
Insomniacp
Posts: 288
Joined: Wed Apr 16, 2008 1:45 am
Contact:

Post by Insomniacp »

I would also suggest xml, you can also find a compression to use to compress the file and make it unreadable unless the person really wants to find out what it is they will find out how to decompress it. In general most users don't care to take the time and those that care enough will try to decrypt it either way if you use encryption. If it is single player I would just compress, saves space and makes it harder to cheat through a level.

An interesting note though quite a few games have ways of skipping things in plain text. I know all the total war series has a very easy way to unlock all playable factions instead of playing till you destroy one to unlock it. I have also found many config files in plain text that allow you to skip intro movies and change some other features around which isn't cheating but just something to make loading a game quicker (no nvidia into movies and things like that).

As for structure it could be a bit more complex, if there are multiple objectives you will need to save each of those and which are done. I think that is the plan you have but saying it just in case. Also you may need a section for player data, name, level, and things like that depending on the game. You may also need to have a current mission hint and save where in the mission they are. This will help with quickly loading back to where they left off or the last checkpoint they reached (all pends game type and structure).

I think I have blabbered enough :)
drr00t
Posts: 14
Joined: Wed Aug 05, 2009 2:11 pm
Location: Brasilia/DF - Brasil

Post by drr00t »

hi,

Thank you for answer, the structure has just a example to start a discuss with you about ways to make a robust save and loading games with Irrlicht, lot of people here are making games, so i thinking this topic would be interesting.

There is a lot information about architecture, ai, etc... but very fill talk about this topic, i know that is not so hard, but is helpfull for a lot of games.

So, about my post, is just a simple sample of structure to save my game, i will include: some dynamic entities, experience of player(s) and properties, etc...

I thinking in save using encrypted BerkleyDB database.

again, thanks for answers.

you have a lot of experience, i follow a lot in my engine, that use same model from irrlicht, when it here i will release under MIT to get some feedback and help others.
Post Reply