Difference between revisions of "Scenarios"
Jump to navigation
Jump to search
Line 1: | Line 1: | ||
− | Scenarios are special files that tell [[ | + | Scenarios are special files that tell [[MegaGlest]] how to play a game. They have set values, so you cannot choose your faction, nor your map, tileset, and opponents. However, scenarios can use scripts to allow them to do things not otherwise possible, such as campaigns. Due to this, they are able to tell a story, and can be considered a more linear story mode compared to the "free play" of a custom game. |
− | |||
− | |||
− | |||
− | |||
==Installing== | ==Installing== | ||
Line 19: | Line 15: | ||
*[[XML/Scenario| Scenario XML format]] | *[[XML/Scenario| Scenario XML format]] | ||
*[[MG/Scripted Scenarios|MegaGlest Lua Commands]] | *[[MG/Scripted Scenarios|MegaGlest Lua Commands]] | ||
− | |||
[[Category:Scenarios]] | [[Category:Scenarios]] | ||
[[Category:Lua]] | [[Category:Lua]] | ||
[[Category:XMLs]] | [[Category:XMLs]] |
Latest revision as of 02:34, 10 October 2019
Scenarios are special files that tell MegaGlest how to play a game. They have set values, so you cannot choose your faction, nor your map, tileset, and opponents. However, scenarios can use scripts to allow them to do things not otherwise possible, such as campaigns. Due to this, they are able to tell a story, and can be considered a more linear story mode compared to the "free play" of a custom game.
Installing[edit]
List of Scenarios[edit]
- See Scenarios/List
Scripting[edit]
Scripting in scenarios is done with Lua. This is a simple and fast scripting language which has many pre-defined functions for Glest scenarios. For example, you can use createUnit('unit_name', 0, startLocation(0)) to create a unit named "unit name" for player 0 at the start location of player 0. See Lua for how to write scripted scenarios.