Difference between revisions of "Config Commands"
From King Arthur's Gold Wiki
Splittingred (Talk | contribs) (Created page with "Various commands are available to .gm files when they are loaded. They can be run in any .gm file during server load, or run using RCON. All commands must end with a semicolon (;...") |
Splittingred (Talk | contribs) |
||
Line 27: | Line 27: | ||
</syntaxhighlight> | </syntaxhighlight> | ||
+ | ; addBotX(Team,Class, `Name of the Bot`); | ||
+ | : Adds an AI-run bot to the map. First parameter is the team (0 = blue, 1 = red, 3 = neutral). Second is the class (0 = knight, 2 = archer, 1 = builder). Final parameter is the name to give the bot. Example to load a knight named "George" for the blue team: | ||
+ | <syntaxhighlight lang="gml"> | ||
+ | addBotX(0,0,`George`); | ||
+ | </syntaxhighlight> | ||
= See Also = | = See Also = |
Revision as of 16:51, 8 January 2013
Various commands are available to .gm files when they are loaded. They can be run in any .gm file during server load, or run using RCON. All commands must end with a semicolon (;).
Commands
- LoadRules("path/to/rules.cfg");
- Loads a gamemode rules file, such as a gamemode.cfg file. This file must be a "cfg" file, and will adjust the rules for the server. It requires a map restart to take effect.
LoadMap("Rules/MODE/gamemode.cfg");
- LoadMap("path/to/map.cfg/or/map.gm");
- Loads a map .png or .gm file. Will automatically restart the round and load the map if run. Example:
LoadMap("Rules/MODE/Maps/mymap.gm");
- addBlob(`item-name`, `Path/To/Entity/File.cfg`,Xposition,Yposition,Team);
- Loads a named entity at the given X and Y position, for the given team (0 = blue, 1 = red, 3 = neutral). For example, this loads a lantern for Red at 64x64 on the map:
addBlob(`mylantern`, `Entities/Items/Lantern.cfg`,64 ,64,0);
- waterLevel(123);
- Sets the water level at the specified number of tiles from the bottom of the map. The game mode config variable "water_suddendeath" must be set to true for this to work. Example to load the water at 20 tiles from the bottom of the map:
waterLevel(20);
- addBotX(Team,Class, `Name of the Bot`);
- Adds an AI-run bot to the map. First parameter is the team (0 = blue, 1 = red, 3 = neutral). Second is the class (0 = knight, 2 = archer, 1 = builder). Final parameter is the name to give the bot. Example to load a knight named "George" for the blue team:
addBotX(0,0,`George`);