ActiveAnim
The animation the structure runs in its first active slot.
- Applies to
- BuildingType
- File
art.ini- Section
[<Image ID>]Image ID: Image= value; ObjectType ID when omitted- Value
- string
- When omitted
(empty)
The value names an animation registered in [Animations], which the structure runs as an attached animation: a separate object pinned to a point on the structure’s artwork, cycling on its own timing, and created and destroyed as the structure changes state. A name no [Animations] entry registers creates nothing.
[MYPOWR] ; example power plant, drawn from its own Image IDActiveAnim=MYSMOKE ; an AnimType registered in [Animations]ActiveAnimDamaged=MYFIRE ; used at ConditionYellow and belowActiveAnimX=-12 ; twelve pixels left of the drawing centerActiveAnimY=-30 ; thirty pixels up, onto the chimneyActiveAnimZAdjust=-5 ; drawn over the structure rather than behind itActiveAnimPowered=no ; keeps cycling through a power shortfallA BuildingType carries four active slots, and slots two, three and four repeat the same eight settings under the ActiveAnimTwo, ActiveAnimThree and ActiveAnimFour prefixes. Building animations owns what the eight do — the damaged name, the offset, the two draw-order biases, the two power flags, the fifteen-character limit on a name, and which art entry each setting is read from.
When the slot runs
Section titled “When the slot runs”The animation is created as the structure comes online, either as construction finishes or as the scenario places it, and all four slots are destroyed when the structure is sold or otherwise taken off the map. In between, an animation that plays to its end empties its slot and a looping one holds it.
Four things refill this slot once it is empty. A repair step the house can pay for starts every active slot that is not running, and installing an upgrade on a damaged structure repairs it to full strength and does the same. Power returning to the house recreates a slot left at ActiveAnimPowered=no with ActiveAnimPoweredLight=yes. And this slot alone is started again whenever a UnitRepair=yes bay finishes with the vehicle it was servicing.
What belongs to this slot alone
Section titled “What belongs to this slot alone”Two behaviors are peculiar to the first slot.
- On a
SensorArray=yesstructure it starts two seconds — 30 frames — after construction finishes. Every other path that starts it, and every path that starts the other three slots, applies no delay. - A
UnitRepair=yesbay stops it as it begins repairing the vehicle standing over it, and starts it again as the visit ends. A bay that drops the repair mission with its other animations still running is caught on its next update, which leaves this slot dark.
A type declaring four or more Upgrades= loses this slot to its fourth plug, both in the art file and again as a plug is installed; the upgrade slots and the active slots share one array covers what that costs.