Set.game.id

From AGI Wiki
Jump to navigationJump to search
The printable version is no longer supported and may have rendering errors. Please update your browser bookmarks and please use the default browser print function instead.

The set.game.id command sets the game ID.

Syntax

set.game.id(msg mGAMEID);
set.game.id("gameid");

Remarks

The game ID is a short name, up to 6 characters, that identifies the game, such as 'KQ1', 'SQ2', 'GR', 'MUMG' etc.

When the game ID is set with this command, AGI checks it against an internal game ID value that is embedded within the main interpreter file. If the values do not match, AGI quits without any warning. This was done presumably to make sure the games were not run on an incorrect version of the interpreter, as well as to discourage pirating by requiring the use of the original interpreter files.

If a game ID is set, AGI prepends it to save game file names (e.g. 'KQ1SG.1').

See the GameIDs and Interpreter Executable topic for additional information on how game IDs were used in Sierra games and how to manage them in fan made games.

Possible Errors

None.

Example

Code:
[ assume the interpreter file has been modified to use 
[ this game ID for that great fan made game 'Dungeon!'
set.game.id("DGN1");  [ DUNGEON!

Technical Information

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

See Also

System Commands
Game IDs and the Interpreter Executable