Merge pull request #8892 from Citadel-Station-13/kevinz000-patch-61

Fixes RPD infinite transit tube stacking
This commit is contained in:
deathride58
2019-07-17 17:47:09 -04:00
committed by GitHub
+4
View File
@@ -435,6 +435,10 @@ GLOBAL_LIST_INIT(transit_tube_recipes, list(
to_chat(user, "<span class='notice'>You start building a transit tube...</span>")
playsound(get_turf(src), 'sound/machines/click.ogg', 50, 1)
if(do_after(user, transit_build_speed, target = A))
for(var/obj/structure/c_transit_tube/tube in A)
if(tube.dir == queued_p_dir || (queued_p_flipped && (tube.dir == turn(queued_p_dir, 45))))
to_chat(user, "<span class='warning'>[src]'s error light flickers; there's already a pipe in the way!</span>")
return
activate()
if(queued_p_type == /obj/structure/c_transit_tube_pod)
var/obj/structure/c_transit_tube_pod/pod = new /obj/structure/c_transit_tube_pod(A)