Running a game¶
The yatage
executable is automatically made available when YATAGE is installed. This is the
executable that must be used in order to run games.
Basic usage¶
The most basic use of yatage
is:
$ yatage <world>
Where <world>
is the path to a YATAGE world file.
A bunch of validation steps will be performed on the given file before being actually used to make sure it is a well-formed world file.
Exiting the game¶
You can exit the game anytime using either Control-D, Control-C, or the exit action.
Note
You will lose your progress as YATAGE does not allow to save game state (yet).
Advanced usage¶
More advanced stuff is needed in some specific use cases.
Debug mode¶
Sometimes, you will need debug information about what’s happening, or perform actions that would never be possible while
playing normally, for example while creating a game. Use the --debug
flag:
$ yatage <world> --debug
This will add the following debug statements in-game:
Current YATAGE version
World file version, number of rooms and number of items will be displayed before world’s description
Rooms identifier will be displayed next to all rooms names
Details will be displayed next to the exits’ name (exit type, conditions, rooms identifiers / names, etc)
In addition, debug mode will alter some of the game engine’s behavior:
Used items will not be hidden in inventory. A
[used]
suffix will instead be appended to the items’ name
Finally, new actions are made available.
Automating actions¶
Sometimes, you will be tired of typing every single action that needs to be made in order to get to a given progress
in-game, for example while creating a game. Fortunately, there is the --actions
option:
$ yatage <world> --actions <actions>
Where <actions>
is the path to a plain text file (usually *.txt
) which contains the actions to be automatically
executed, in order, starting from the top.
The file should contain one action per line:
# This is an automated actions file. This line is a comment, which will be
# ignored, as well as empty lines.
take security card # First action. Inline comments are allowed.
catch up
back # Third action.
entrance
lifts
Note
If debug mode is enabled, debug actions are made available too (see Debug mode).
You can now continue to Playing a game.