MaxDebris
The number of pieces of wreckage a destroyed object may throw.
Specification
- Applies to
- AircraftTypeBuildingTypeInfantryTypeUnitType
- File
rules.ini- Section
[<ObjectType ID>]- Value
- integer
- When omitted
0
[MYTANK] ; a UnitType registered in [VehicleTypes]MaxDebris=6DebrisTypes=MYSCRAP,MYTIRE ; VoxelAnimTypes registered in [VoxelAnims]DebrisMaximums=4,2At 0, a destroyed object throws no wreckage, whatever its debris lists say. Above 0, the value caps the total number of pieces. Which pieces are thrown depends on whether the type sets DebrisTypes:
- With
DebrisTypes, the entries are taken in order. Each throws a random number of pieces, from zero up to its matchingDebrisMaximumsfigure, untilMaxDebrispieces have been thrown. Give every entry a figure of0or more, or the game can crash when the object is destroyed. Any budget left after the last entry goes unused. The pieces start at the object’s center and belong to the object’s owner. - Without
DebrisTypes, a random number of pieces from zero up toMaxDebrisis thrown, each aMetallicDebrisanimation picked at random, 20 leptons above the object’s center.
In the example, MYSCRAP throws zero to four pieces and MYTIRE zero to two. Their maximums add up to six, so the budget never cuts a draw short.
Wreckage is thrown after the death voice and before any Explodes=yes blast. An object that has fallen from a height, for example off a bridge, and dies over water within 10 leptons of the ground throws no wreckage and does not explode.