Skip to content

emissions

Source: base/tealdef/game_mechanics/emission/emissions.d.tl

Notes

State of the emissions game script (eco levels of industries).

EmissionSimState

record global base/tealdef/game_mechanics/emission/emissions.d.tl:3

global record EmissionSimState

Notes

State of the emissions game script.

Fields

Name Type Description
ecoLevels {Engine.Entity : {EntityUtil.EntityAndRevision, integer}} Industry construction -> { entity and revision, eco level }; set to level 1 by the industry-greenify perk.
version integer Layout version of the state.

EmissionLegacyUtil

record global base/tealdef/game_mechanics/emission/emissions.d.tl:8

global record EmissionLegacyUtil

Notes

Upgrades an emissions state saved by an older game version.

Fields

Name Type Description
currentVersion integer Current layout version.

Functions

updateLegacyState(townsState : EmissionSimState) base/tealdef/game_mechanics/emission/emissions.d.tl:10

Notes

Upgrades the state in place (e.g. converts old eco levels to {entity and revision, level}).

Parameter Type Description
townsState EmissionSimState State to upgrade.