Expand description
Additional constants representing internal game mechanics that aren’t included in the game’s constants
Constants§
- Percentage of energy spent on construction that is left in a
Resource
if the construction site is destroyed byConstructionSite::remove
, or from being stepped on by a hostile creep - Percentage of progress toward next level controllers retain when downgraded
- Maximum length (in UTF-16 units) of input to
Creep::sign_controller
- Maximum amount of CPU that can be accumulated in
game::cpu::bucket
per shard - Time (in milliseconds) that the
cpu::set_shard_limits
function needs to cool down between calls - Maximum value of
cpu::tick_limit
, the amount of CPU time (in milliseconds) available this tick, including available time from the bucket (game::cpu::bucket
) - Maximum length (in UTF-16 units) of the string input to
StuctureSpawn::spawn_creep
for the name of aCreep
- The range of all ranged actions of
Creep
objects - Maximum length (in UTF-16 units) of string input to
Creep::say
andPowerCreep::say
- Maximum length (in UTF-16 units) of names of
Flag
objects - The cost of a single ‘intent’ (in milliseconds), a CPU penalty charged for most successful API calls which change the game state (
Creep::pull
,Creep::say
, andPowerCreep::say
are excepted) - Maximum size (in UTF-16 units) of data input to
inter_shard_memory::set_local
- The
Owner::username
of hostile non-player structures and creeps which create strongholds and spawn to attack rooms due to energy harvesting activity - Maximum range between interacting
StructureLab
strucures forStructureLab::run_reaction
orStructureLab::reverse_reaction
- The maximum size (in UTF-16 units) of the serialized
MapVisual
data - The maximum number of times that you can use
game::market::deal
in a tick - Maximum active memory segments to be readable next tick allowed in
raw_memory::set_active_segments
- Maximum size (in UTF-16 units) of the string contents allowed in
raw_memory::segments
- Maximum size (in UTF-16 units) of the string contents allowed in serialized memory or
raw_memory::set
- Fatigue points added for each body part that generates fatigue when stepping onto a tile with
Terrain::Plain
- Fatigue points added for each body part that generates fatigue when stepping onto a tile with a
StructureRoad
- Fatigue points added for each body part that generates fatigue when stepping onto a tile with
Terrain::Swamp
- Fatigue points removed per effective
Part::Move
per tick - Maximum length (in UTF-16 units) of message content sent to
game::notify
. - Maximum carry capacity of a
PowerCreep
per level - Maximum hits of a
PowerCreep
per level - Maximum length (in UTF-16 units) of names input to
PowerCreep::create
orAccountPowerCreep::rename
- Hits of damage per effective ranged attack part per
Creep::ranged_mass_attack
action at range 1 - Hits of damage per effective ranged attack part per
Creep::ranged_mass_attack
action at range 2 - Hits of damage per effective ranged attack part per
Creep::ranged_mass_attack
action at range 3 - The maximum height/width of a
Room
in the game - The maximum size (500 KiB) of the serialized
RoomVisual
data for each room - Owner username of hostile non-player structures and creeps which occupy sector center rooms.
- Maximum length (in UTF-16 units) of the name of a
StructureSpawn
, set via the optional name parameter when creating aConstructionSite
- Exponential scaling rate for
StructureTerminal
energy costs