Skip to content

Explodes

Blasts the surroundings when an object of this type is destroyed, or detonates an overlay when any explosion reaches its cell.

Violent death

Specification — Violent death
Applies to
AircraftTypeBuildingTypeInfantryTypeUnitType
File
rules.ini
Section
[<ObjectType ID>]
Value
boolean
When omitted
noA section named `E2` is set to `yes` immediately after the read, so that one type always explodes whatever its value says.
rules.ini
[MYAMMOTRUCK] ; a UnitType registered in [VehicleTypes]
Explodes=yes

A destroyed object of this type damages everything around it. The blast carries the warhead of the weapon the object would fire from its first slot — Primary ordinarily, Elite once the object is elite, and an upgrade’s weapon on a structure carrying one — with no warhead at all when that slot is empty — and its strength is the object’s collateral damage figure. A combat explosion animation and a lighting flash sized for that figure, that warhead and the land type under the object appear at its center, and the damage is then applied as area damage sourced to whatever killed it. The same branch is reached without the key by a veteran or elite object carrying the explodes ability.

The radius is that figure divided by 100, divided again by [CombatDamage] ExpSpread, and read as cells; it is clamped to between one lepton and three cells, and the damage applied over it is the figure multiplied by the whole number of cells the radius covers. The first division discards its remainder, so any collateral figure below 100 collapses the blast to a one-lepton radius and a single helping of damage.

Two object kinds do more with the flag on top of that blast:

An object that lost its footing and fell, and then died within ten leptons of water, splashes instead: it leaves the death path before the wreckage and before this blast.

Explosive overlay

Specification — Explosive overlay
Applies to
OverlayType
File
rules.ini
Section
[<ObjectType ID>]
Value
boolean
When omitted
no
rules.ini
[MYBARREL] ; an OverlayType registered in [OverlayTypes]
Explodes=yes

An explosion whose center lands in the cell sets the overlay off. There is no strength test, no armor test and no chance roll: the segment is removed, the cell recalculates its passability and zones, anything aiming at it drops the target, and the detonation follows at once — the [AudioVisual] BarrelExplode animation, area damage of [CombatDamage] AmmoCrateDamage with C4Warhead and no owner, one entry from BarrelDebris on a 15% roll, and a BarrelParticle system on a 25% roll.

That debris roll walks the list in order and stops at the first piece it creates, so at most one piece is ever thrown and later entries are only reached when every earlier one failed its roll.

Each of the four neighboring cells that also holds an explosive overlay receives a FIRE3 animation four to six frames later. The neighbor is not detonated directly; whether the fire goes on to set it off depends on that animation’s own Damage. The same fire is laid on explosive neighbors when an Explodes=yes structure is destroyed.

This is a separate mechanism from ChainReaction=yes, which is what spreads a Tiberium field’s own destruction.