Other great resources: Official JS API docs, Scripting Forum
setPower()
- Aubergine
Owned by Aubergine
Set the power reserves for a player...
Syntax
setPower(power[, player]);
Parameters
Parameter | Type | Mandatory | Description |
---|---|---|---|
power | Number | The amount of power to give to the player. | |
player | Number | Optionally define which player will get the power. Default: me |
Return value
Value | Type | Description |
---|---|---|
undefined | Undefined | The player's power was set. |
<error> | Error | The player specified does not exist. |
Example
Give yourself some free power
setPower(1000000); // give yourself 1000000 power instantly
This function should only be using during Player Initialisation or single player games.
Availability 3.1 B1+
Requires:
- Warzone 3.1 Beta 1 or above
Contents
Jump to:
See also
Relates articles:
- playerPower() – find out how much power a specific player has
- powerType – what is the power setting for the current game?
- setPowerModifier() – a multiplier applied to powerType
- Cheats - Warzone 2100 Cheat Codes – there's a cheat code for that