Find out how much power is still needed to start current production and research orders...
Syntax
var power = queuedPower(player);
Parameters
Parameter
Type
Mandatory
Description
Game version
player
Number
The player to inspect.
3.2
Return value
Value
Type
Description
Game version
<power>
Number
A number representing the amount of power the player needs before all current production and research tasks can start.
3.2
<error>
Error
The player specified does not exist. There is no spoon.
3.2
Example
Do I have power in my power reserves?
var powerRequired = queuedPower(me);
if (!powerRequired) {
// I have power in my power reserves
} else {
// My power reserves are empty and tasks are stalling waiting for power
}