Update car.dm

This commit is contained in:
zeroisthebiggay
2021-06-08 15:43:32 -04:00
committed by GitHub
parent 614c3192e5
commit 082ffa16f3

View File

@@ -76,11 +76,15 @@
return FALSE
if(occupant_amount() >= max_occupants)
return FALSE
if(do_mob(forcer, get_enter_delay(M), target = src))
var/atom/old_loc = loc
if(do_mob(forcer, M, get_enter_delay(M), extra_checks=CALLBACK(src, /obj/vehicle/sealed/car/proc/is_car_stationary, old_loc)))
mob_forced_enter(M, silent)
return TRUE
return FALSE
/obj/vehicle/sealed/car/proc/is_car_stationary(atom/old_loc)
return (old_loc == loc)
/obj/vehicle/sealed/car/proc/mob_forced_enter(mob/M, silent = FALSE)
if(!silent)
M.visible_message("<span class='warning'>[M] is forced into \the [src]!</span>")