Other great resources: Official JS API docs, Scripting Forum
You are viewing an old version of this page. View the current version.
Compare with Current View Page History
« Previous Version 4 Current »
Game set-up is currently beyond the realms of the JS API – the game settings are defined in the following ways:
However, once the game starts all of the the settings are available to your scripts...
The map defines maxPlayers, startPositions[] and derrickPositions[].
Scripts also have access to mapName, mapWidth and mapHeight.
Sets values of scavengers.
When scavengers are enabled, scavfact.js will be loaded to control the scavengerPlayer.
Sets alliancesType and has an effect on Victory Conditions.
Obviously, this affects Players & Alliances.
Sets baseType and has a profound effect on Player Initialisation.
AIs should adapt their build orders and early game strategy accordingly.
Structure limits can be determined using getStructureLimit().
Scripts should adapt, in particular to disabled factory types: Working with Factories.
Limits set during game-setup will override those set during Player Initialisation when applyLimitSet() is called.
<to follow>