mirror of
https://github.com/ParadiseSS13/Paradise.git
synced 2026-08-22 19:47:22 +01:00
Fixes several potential pipe runtimes
Pipes would naively assume they had a turf, even when they didn't (probably after getting qdel'd); they'll now abort turf-sensitive operations if turfless. This should cut down on pipe-deletion-related runtimes.
This commit is contained in:
@@ -470,7 +470,8 @@
|
||||
update_icon()
|
||||
|
||||
/obj/machinery/atmospherics/proc/universal_underlays(var/obj/machinery/atmospherics/node, var/direction)
|
||||
var/turf/T = loc
|
||||
var/turf/T = get_turf(src)
|
||||
if(!istype(T)) return
|
||||
if(node)
|
||||
var/node_dir = get_dir(src,node)
|
||||
if(node.icon_connect_type == "-supply")
|
||||
@@ -632,6 +633,7 @@
|
||||
underlays.Cut()
|
||||
|
||||
var/turf/T = get_turf(src)
|
||||
if(!istype(T)) return
|
||||
var/list/directions = list(NORTH, SOUTH, EAST, WEST)
|
||||
var/node1_direction = get_dir(src, node1)
|
||||
var/node2_direction = get_dir(src, node2)
|
||||
@@ -890,6 +892,7 @@
|
||||
*/
|
||||
|
||||
var/turf/T = get_turf(src)
|
||||
if(!istype(T)) return
|
||||
var/list/directions = list(NORTH, SOUTH, EAST, WEST)
|
||||
var/node1_direction = get_dir(src, node1)
|
||||
var/node2_direction = get_dir(src, node2)
|
||||
@@ -1104,7 +1107,8 @@
|
||||
node = target
|
||||
break
|
||||
|
||||
var/turf/T = src.loc // hide if turf is not intact
|
||||
var/turf/T = get_turf(src) // hide if turf is not intact
|
||||
if(!istype(T)) return
|
||||
hide(T.intact)
|
||||
update_icon()
|
||||
|
||||
|
||||
Reference in New Issue
Block a user