Restore.game

From AGI Wiki
Revision as of 21:06, 19 April 2019 by Andrew Korson (talk | contribs) (Created page with "The '''restore.game''' command restores a game from a previously saved game file. == Syntax == restore.game(); == Remarks == This command displays a window that allows a p...")
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to navigationJump to search

The restore.game command restores a game from a previously saved game file.

Syntax

restore.game();

Remarks

This command displays a window that allows a player to choose a previously saved game (using the save.game command) and restore it. Restoring a game reads all the game state information from the save file.

See the Restoring Games topic for detailed information on how AGI restores games.

Possible Errors

Save game files are not compatible among different games. Do not attempt to restore a save file from one game from within a different game. It will fail, and probably crash AGI.

Example

Code:

<syntaxhighlight lang="agi"> if (said("restore"))

 {
 restore.game();
 }

</syntaxhighlight>

Technical Information

Required Interpreter Version: Available in all AGI versions.
Byte-Code Value: 126 (0x7E hex)

See Also

System Commands
save.game
Restoring Games