mirror of
https://github.com/CHOMPStation2/CHOMPStation2.git
synced 2025-12-16 21:23:20 +00:00
Fixes pipes duplication issues
This commit is contained in:
@@ -35,6 +35,10 @@ obj/machinery/atmospherics/pipe/simple/heat_exchanging
|
|||||||
if(target.initialize_directions_he & get_dir(target,src))
|
if(target.initialize_directions_he & get_dir(target,src))
|
||||||
node2 = target
|
node2 = target
|
||||||
break
|
break
|
||||||
|
if(!node1 && !node2)
|
||||||
|
del(src)
|
||||||
|
return
|
||||||
|
|
||||||
update_icon()
|
update_icon()
|
||||||
return
|
return
|
||||||
|
|
||||||
@@ -102,5 +106,9 @@ obj/machinery/atmospherics/pipe/simple/heat_exchanging/junction
|
|||||||
node2 = target
|
node2 = target
|
||||||
break
|
break
|
||||||
|
|
||||||
|
if(!node1&&!node2)
|
||||||
|
del(src)
|
||||||
|
return
|
||||||
|
|
||||||
update_icon()
|
update_icon()
|
||||||
return
|
return
|
||||||
|
|||||||
@@ -523,6 +523,10 @@
|
|||||||
if (node3)
|
if (node3)
|
||||||
break
|
break
|
||||||
|
|
||||||
|
if(!node1 && !node2 && !node3)
|
||||||
|
del(src)
|
||||||
|
return
|
||||||
|
|
||||||
var/turf/T = get_turf(src)
|
var/turf/T = get_turf(src)
|
||||||
if(istype(T))
|
if(istype(T))
|
||||||
hide(T.intact)
|
hide(T.intact)
|
||||||
@@ -720,6 +724,10 @@
|
|||||||
node4 = target
|
node4 = target
|
||||||
break
|
break
|
||||||
|
|
||||||
|
if(!node1 && !node2 && !node3 && !node4)
|
||||||
|
del(src)
|
||||||
|
return
|
||||||
|
|
||||||
var/turf/T = get_turf(src)
|
var/turf/T = get_turf(src)
|
||||||
if(istype(T))
|
if(istype(T))
|
||||||
hide(T.intact)
|
hide(T.intact)
|
||||||
|
|||||||
@@ -390,7 +390,7 @@ Buildable meters
|
|||||||
M.level = T.intact ? 2 : 1
|
M.level = T.intact ? 2 : 1
|
||||||
M.initialize()
|
M.initialize()
|
||||||
if (!M)
|
if (!M)
|
||||||
usr << "There's nothing to connect this manifold to!" //(with how the pipe code works, at least one end needs to be connected to something, otherwise the game deletes the segment)"
|
usr << pipefailtext
|
||||||
return 1
|
return 1
|
||||||
M.build_network()
|
M.build_network()
|
||||||
if (M.node1)
|
if (M.node1)
|
||||||
@@ -413,7 +413,7 @@ Buildable meters
|
|||||||
M.level = T.intact ? 2 : 1
|
M.level = T.intact ? 2 : 1
|
||||||
M.initialize()
|
M.initialize()
|
||||||
if (!M)
|
if (!M)
|
||||||
usr << "There's nothing to connect this manifold to!" //(with how the pipe code works, at least one end needs to be connected to something, otherwise the game deletes the segment)"
|
usr << pipefailtext
|
||||||
return 1
|
return 1
|
||||||
M.build_network()
|
M.build_network()
|
||||||
if (M.node1)
|
if (M.node1)
|
||||||
|
|||||||
Reference in New Issue
Block a user