Ladder unfuckery. (#9047)

This commit is contained in:
Alberyk
2020-06-09 17:20:40 +02:00
committed by GitHub
parent 97037700cd
commit 21c547d88a
2 changed files with 11 additions and 4 deletions
+5 -4
View File
@@ -142,9 +142,10 @@
to_chat(M, "<span class='notice'>\The [T] is blocking \the [src].</span>")
return FALSE
for(var/atom/A in T)
if(!A.CanPass(M, M.loc, 1.5, 0))
to_chat(M, "<span class='notice'>\The [A] is blocking \the [src].</span>")
return FALSE
if(!isliving(A))
if(!A.CanPass(M, M.loc, 1.5, 0))
to_chat(M, "<span class='notice'>\The [A] is blocking \the [src].</span>")
return FALSE
playsound(src, pick(climbsounds), 50)
playsound(target_ladder, pick(climbsounds), 50)
var/obj/item/grab/G = M.l_hand
@@ -152,7 +153,7 @@
G = M.r_hand
if (istype(G))
G.affecting.forceMove(T)
return M.Move(T)
return M.forceMove(T)
/obj/structure/ladder/CanPass(obj/mover, turf/source, height, airflow)
return airflow || !density