-
Notifications
You must be signed in to change notification settings - Fork 0
CompRemoteExplosive
flango edited this page Nov 29, 2022
·
1 revision
Makes a thing (building, item, etc) explode with a press of a button or when destroyed.
Very customizable. See the list of available options below.

'string' commandLabel = "Detonate";
'string' commandDescription = "Make this thing go kaboom.";
'string' commandIcon;
'int' timerTicks; // Default: 0 (Explode instantly). 1 second = 60 ticks.
'float' range = 0.9f;
'DamageDef' damageDef; // Default: Bomb
'int' damage = -1; // Usually defaults to DamageDef base damage
'float' armorPenetration = -1; // Usually scales with damage
'ExplosionShape' explosionShape; // Normal, Star, CrossPlus, CrossX, Ring, RandomAdjacent
'SoundDef' soundDef; // Optional
'ThingDef' preExplosionSpawnThing;
'ThingDef' postExplosionSpawnThing;
'float' preExplosionSpawnChance;
'float' postExplosionSpawnChance;
'int' preExplosionSpawnCount;
'int' postExplosionSpawnCount;
'float' chanceToStartFire;
'bool' applyDamageToCellNeighbors;
'bool' damageFalloff;
'bool' destroyOnDetonation = true;
'bool' explodeOnDestroyed = true;
'bool' canBeCancelled;
'bool' showAlert = false; // "This thing will explode in X seconds."
'bool' drawWick = false; // A mote indicating that this thing is about to explode
'string' cancelLabel = "Cancel";
'string' cancelDescription = "Cancel kaboom.";
'string' cancelIcon;
'SoundDef' soundActivated;
'SoundDef' soundCancelled;
'SoundDef' sustainerSound; // Hissing sound
'EffecterDef' explosionEffecter; // Trigger an effecter after exploding
'FleckProps' fleck; // Spawn a fleck every X ticks after starting the timer
'FleckProps' explosionFleck; // Spawn X flecks after exploding
'int' explosionFleckCount;<comps>
<li Class="flangoCore.CompProperties_RemoteExplosive">
<commandLabel>Detonate</commandLabel>
<commandIcon>UI/Kaboom</commandIcon>
<timerTicks>300</timerTicks>
<range>3.9</range>
<damageDef>Bomb</damageDef>
<canBeCancelled>true</canBeCancelled>
<cancelLabel>Cancel</cancelLabel>
<cancelIcon>UI/Designators/Cancel</cancelIcon>
<soundActivated>TurretAcquireTarget</soundActivated>
<chanceToStartFire>0.25</chanceToStartFire>
<explosionShape>Star</explosionShape>
<sustainerSound>HissSmall</sustainerSound>
<fleck>
<fleckDef>Smoke</fleckDef>
<intervalTicks>24</intervalTicks>
<scaleRange>0.8~1</scaleRange>
<offset>(0.5, 0, 0.9)</offset>
<randomRotation>true</randomRotation>
<rotationRate>10</rotationRate>
<velocityAngle>0~10</velocityAngle>
<velocitySpeed>2~4</velocitySpeed>
<solidTimeOverride>1</solidTimeOverride>
</fleck>
<explosionFleck>
<fleckDef>Smoke</fleckDef>
<scaleRange>0.8~1</scaleRange>
<offset>(0.5, 0, 0.5)</offset>
<randomRotation>true</randomRotation>
<rotationRate>10</rotationRate>
<velocityAngle>0~360</velocityAngle>
<velocitySpeed>8~12</velocitySpeed>
<colorMin>(0,0,0)</colorMin>
<colorMax>(255,255,255)</colorMax>
<solidTimeOverride>2</solidTimeOverride>
</explosionFleck>
<explosionFleckCount>1000</explosionFleckCount>
</li>
</comps>🦩 Home
🚧 - 404 Page not found.
🖼 - Preview needed.
🟡 - Works but has some TODOs.
🟠 - Basic functionality implemented.
🔴 - Not working properly.
❓ - Not tested.
🟡 Should recode some stuff 🟡
🟠 WIP, work/kill XP gain not implemented 🟠
-
🚧Give Hediff Severity Extended (aka Autobong)
-
Weapon Animations 🟡 (Not included)