User Tools

Site Tools


tutorials:save_games

Saving Game information to the Config

As well as loading information from a config file, you can also save your own sections back to a seperate config file.

This can be used to persist score or player information to a file that can be loaded when the player returns to your game.

There is currently no specific guide on this page to take you through the process. In lieu of that, the following link takes you to the API where you can get familiar with what config functions are available for working with config files:

http://orx-project.org/orx/doc/html/group__orx_config.html

You might be able to glean some usage examples from this project file:

https://bitbucket.org/sausage/xerop/src/5fbf06b1aea0ddfbb1c1403481b4713ebea1721a/pinball/src/pinball/pinballbase.cpp?at=master&fileviewer=file-view-default

Look for the LoadSavedHighScores and SaveHighScoresToConfig functions.

Also, make sure you don't miss the detail outlined on the Config page

Hopefully a proper tutorial can be put together soon. If you'd like to write one, please feel free to replace this page.

tutorials/save_games.txt · Last modified: 2017/05/30 05:50 (8 weeks ago) (external edit)