Merge pull request #7570 from VOREStation/aro-baycats

One more tweak to Bay catwalks
This commit is contained in:
Aronai Sieyes
2020-05-01 14:56:40 -04:00
committed by GitHub
2 changed files with 45 additions and 10 deletions
+8
View File
@@ -28,8 +28,15 @@
/obj/structure/catwalk/Destroy()
redraw_nearby_catwalks()
update_falling()
return ..()
/obj/structure/catwalk/proc/update_falling()
spawn(1) //We get called in Destroy() and things. We might not be gone yet, so let's just put this off.
if(istype(loc, /turf/simulated/open))
var/turf/simulated/open/O = loc
O.update() //Will cause anything on the open turf to fall if it should
/obj/structure/catwalk/proc/redraw_nearby_catwalks()
for(var/direction in alldirs)
var/obj/structure/catwalk/L = locate() in get_step(src, direction)
@@ -83,6 +90,7 @@
if(hatch_open)
playsound(src, 'sound/items/Crowbar.ogg', 100, 2)
to_chat(user, "<span class='notice'>You pry open \the [src]'s maintenance hatch.</span>")
update_falling()
else
playsound(src, 'sound/items/Deconstruct.ogg', 100, 2)
to_chat(user, "<span class='notice'>You shut \the [src]'s maintenance hatch.</span>")