Shoving nerds into lockers (#20160)

* Adds locker shove impacts

* Feedback

* we do a little testing

* fuck
This commit is contained in:
Luc
2023-01-19 14:48:14 -05:00
committed by GitHub
parent eae1af4c15
commit a45f33c313
3 changed files with 22 additions and 0 deletions
@@ -383,6 +383,21 @@
// Its okay to silently teleport mobs out of lockers, since the only thing affected is their contents list.
return
/obj/structure/closet/shove_impact(mob/living/target, mob/living/attacker)
if(opened)
target.forceMove(src)
visible_message("<span class='danger'>[attacker] shoves [target] inside [src]!</span>", "<span class='warning'>You hear a thud, and something clangs shut.</span>")
close()
add_attack_logs(attacker, target, "shoved into [src]")
return TRUE
if(can_open())
open()
visible_message("<span class='danger'>[attacker] shoves [target] against [src], knocking it open!</span>")
target.KnockDown(3 SECONDS)
return TRUE
return ..()
/obj/structure/closet/bluespace
name = "bluespace closet"
@@ -149,6 +149,9 @@
add_fingerprint(user)
toggle(user, by_hand = TRUE)
/obj/structure/closet/crate/shove_impact(mob/living/target, mob/living/attacker)
return FALSE
// Called when a crate is delivered by MULE at a location, for notifying purposes
/obj/structure/closet/crate/proc/notifyRecipient(destination)
var/list/msg = list("[capitalize(name)] has arrived at [destination].")