Prevents crash from movement (#19287)

Prevents crashing when moving while restrained
This commit is contained in:
Cameron Lennox
2026-03-16 21:50:58 +01:00
committed by GitHub
parent 35abead3d4
commit 0c6db8dd6e
+1
View File
@@ -236,6 +236,7 @@
if(M.pulling == my_mob)
if(!M.restrained() && M.stat == 0 && M.canmove && my_mob.Adjacent(M))
to_chat(src, span_blue("You're restrained! You can't move!"))
my_mob.setMoveCooldown(my_mob.movement_delay()) //Prevent no-cooldown attempts at moving while restrained.
return 0
else
M.stop_pulling()