mirror of
https://github.com/Bubberstation/Bubberstation.git
synced 2026-08-27 23:27:34 +01:00
Convert mouse and rat to basic mobs (#70728)
* Converts mice and rats to basic mobs * Update paths * Fixes * Tweaks * . * Use helpers * Unit test * Correct the targeting * Fixes the unit test? * Fixes the unit test * Docs * update the path script with pr id * Faction check tweak * Review * AHH
This commit is contained in:
@@ -136,16 +136,17 @@
|
||||
if(affecting.receive_damage(1, 0))
|
||||
victim.update_damage_overlays()
|
||||
else if(ismouse(target))
|
||||
var/mob/living/simple_animal/mouse/M = target
|
||||
var/mob/living/basic/mouse/splatted = target
|
||||
visible_message(span_boldannounce("SPLAT!"))
|
||||
M.splat()
|
||||
else if(israt(target))
|
||||
var/mob/living/simple_animal/hostile/rat/ratt = target
|
||||
visible_message(span_boldannounce("Clink!"))
|
||||
ratt.apply_damage(5) //Not lethal, but just enought to make a mark.
|
||||
ratt.Stun(1 SECONDS)
|
||||
if(splatted.health <= 5)
|
||||
splatted.splat()
|
||||
else
|
||||
splatted.adjust_health(5)
|
||||
splatted.Stun(1 SECONDS)
|
||||
|
||||
else if(isregalrat(target))
|
||||
visible_message(span_boldannounce("Skreeeee!")) //He's simply too large to be affected by a tiny mouse trap.
|
||||
|
||||
playsound(src, 'sound/effects/snap.ogg', 50, TRUE)
|
||||
pulse(FALSE)
|
||||
|
||||
@@ -199,7 +200,7 @@
|
||||
INVOKE_ASYNC(src, .proc/triggered, H)
|
||||
H.visible_message(span_warning("[H] accidentally steps on [src]."), \
|
||||
span_warning("You accidentally step on [src]"))
|
||||
else if(ismouse(MM) || israt(MM) || isregalrat(MM))
|
||||
else if(ismouse(MM) || isregalrat(MM))
|
||||
INVOKE_ASYNC(src, .proc/triggered, MM)
|
||||
else if(AM.density) // For mousetrap grenades, set off by anything heavy
|
||||
INVOKE_ASYNC(src, .proc/triggered, AM)
|
||||
|
||||
Reference in New Issue
Block a user