Makes being thrown into airlocks/doors/machines hurt, mobs can now be thrown over railings. (#15054)

* Makes being thrown into airlocks/doors/machines hurt, mobs can now be thrown over railings.

* Apply suggestions from code review

Co-authored-by: SleepyGemmy <99297919+SleepyGemmy@users.noreply.github.com>

* Update code/game/machinery/machinery.dm

Co-authored-by: SleepyGemmy <99297919+SleepyGemmy@users.noreply.github.com>

Co-authored-by: Matt Atlas <liermattia@gmail.com>
Co-authored-by: SleepyGemmy <99297919+SleepyGemmy@users.noreply.github.com>
This commit is contained in:
Matt Atlas
2022-11-11 01:51:40 +01:00
committed by GitHub
co-authored by SleepyGemmy Matt Atlas
parent 49f340a999
commit 4db452cfa8
10 changed files with 74 additions and 11 deletions
@@ -265,8 +265,13 @@
/obj/structure/ship_weapon_dummy/attackby(obj/item/W, mob/user)
connected.attackby(W, user)
/obj/structure/ship_weapon_dummy/hitby(atom/movable/AM)
/obj/structure/ship_weapon_dummy/hitby(atom/movable/AM, var/speed = THROWFORCE_SPEED_DIVISOR)
connected.hitby(AM)
if(ismob(AM))
if(isliving(AM))
var/mob/living/M = AM
M.turf_collision(src, speed)
return
/obj/structure/ship_weapon_dummy/bullet_act(obj/item/projectile/P, def_zone)
connected.bullet_act(P)