Difference between revisions of "Mapcycle.cfg"
Splittingred (Talk | contribs) |
Splittingred (Talk | contribs) |
||
Line 9: | Line 9: | ||
It is noteworthy that maps here can be either PNG's (.png), KAG (.kag) files, or gamemonkey scripts (.gm) files. Using a .gm file will allow you to run specific scripts prior to loading the map and during gameplay; however, you will need to call LoadMap in the .gm file. KAG map files will allow you to save entities such as rooms, lanterns, and other items not saveable by the png format. | It is noteworthy that maps here can be either PNG's (.png), KAG (.kag) files, or gamemonkey scripts (.gm) files. Using a .gm file will allow you to run specific scripts prior to loading the map and during gameplay; however, you will need to call LoadMap in the .gm file. KAG map files will allow you to save entities such as rooms, lanterns, and other items not saveable by the png format. | ||
− | For example, a Map cycle with two maps would look like this: | + | For example, a Map cycle with two maps that are initialized in .gm files would look like this: |
<syntaxhighlight lang="actionscript" enclose="div"> | <syntaxhighlight lang="actionscript" enclose="div"> | ||
− | mapcycle = Rules/CTF/Maps/mapname. | + | mapcycle = Rules/CTF/Maps/mapname.gm; Rules/CTF/Maps/anothermap.gm; |
</syntaxhighlight> | </syntaxhighlight> | ||
Revision as of 20:01, 15 January 2013
Often loaded by the dedicated_autostart.gm file, this script creates the array "mapcycle" with the cycle of maps, separated by semicolons (;).
NOTE: When editing .cfg and .gm files, make sure to copy them to a separate Rules/ subfolder with your own gamemode. Otherwise, they will get automatically overwritten during KAG updates.
It is noteworthy that maps here can be either PNG's (.png), KAG (.kag) files, or gamemonkey scripts (.gm) files. Using a .gm file will allow you to run specific scripts prior to loading the map and during gameplay; however, you will need to call LoadMap in the .gm file. KAG map files will allow you to save entities such as rooms, lanterns, and other items not saveable by the png format.
For example, a Map cycle with two maps that are initialized in .gm files would look like this: