]> git.smokeofanarchy.ru Git - space-station-14.git/commitdiff
Cockroach Gib when Stepped on (#40103)
authorFungiFellow <151778459+FungiFellow@users.noreply.github.com>
Sat, 13 Sep 2025 07:01:13 +0000 (03:01 -0400)
committerGitHub <noreply@github.com>
Sat, 13 Sep 2025 07:01:13 +0000 (00:01 -0700)
* Cockroach Gib

* Prevent Cockroaches From Gibbing Eachother

* Added - type: RandomChanceTriggerCondition

* Update animals.yml

* Named SuccessChance Datafield

* successChance

* Revert Change

* Uncapitalize C

* RECAPITALIZE THE C

Resources/Prototypes/Entities/Mobs/NPCs/animals.yml

index c8bf6f23c3bf3d3631e62c8746a143ac436d3847..7fa2583b52ac7201e7a4643cf24e8d8cf0de0846 100644 (file)
   - type: TimedDespawn #delete the egg after the chicken spawns
     lifetime: 21
 
-- type: entity # TODO: figure out how to make these guys gib when stepped on
+- type: entity
   name: cockroach
   parent: SimpleMobBase
   id: MobCockroach
       - !type:GibBehavior
         recursive: false
   - type: NonSpreaderZombie
+  - type: StepTrigger
+    requiredTriggeredSpeed: 1
+  - type: TriggerOnStepTrigger
+  - type: RandomChanceTriggerCondition
+    successChance: 0.2
+  - type: GibOnTrigger
+  - type: ProtectedFromStepTriggers
   - type: MeleeWeapon
     soundHit:
       path: /Audio/Effects/bite.ogg