ModEnc is currently in Maintenance Mode: Changes could occur at any given moment, without advance warning.
TurretCount
Flag: | TurretCount |
File(s): | Rules(md).ini |
Values: | unsigned integers |
Default: | 0 |
Applicable to: | VehicleTypes, BuildingTypes |
Specifies the amount of turrets this object has. Used for special weapon systems, for example, turret-changers (Gunner=yes), charge turrets (IsChargeTurret=yes), or gattling logic (IsGattling=yes).
In those cases, the game loads files objectnametur%d.vxl/hva, where %d represents the number between 1 and TurretCount, as opposed to plain objectnametur.vxl/hva it loads normally.
Bugs/Side-Effects/Unexpected Limitations
When setting TurretCount to a value greater than 0, see that WeaponCount is also set correctly. This has to be done because the latter is not initialized to a constant value, and garbage in memory could lead to unexpected results, like corrupting memory. In the best case it crashes when starting a game.