Mappers, this one's for you. New debug verb added for Coders and Hosts, when pressed, it goes through every obj/machinery/atmospherics in the map, and lists all of the ones that have the nodealert var set to 1, which should only be the case if not all the nodes are connected to something.

git-svn-id: http://tgstation13.googlecode.com/svn/trunk@970 316c924e-a436-60f5-8080-3fe189b3f50e
This commit is contained in:
n3ophyt3@gmail.com
2011-02-06 03:33:01 +00:00
parent 5617d09a3c
commit 9d8e8573b4
6 changed files with 55 additions and 7 deletions

View File

@@ -14,7 +14,7 @@ obj/machinery/atmospherics
anchored = 1
power_usage = 10
power_channel = ENVIRON
var/nodealert = 0
var/initialize_directions = 0
var/color

View File

@@ -106,7 +106,7 @@ obj/machinery/atmospherics/valve
build_network()
return 1
proc/normalize_dir()
if(dir==3)
dir = 1
@@ -131,6 +131,17 @@ obj/machinery/atmospherics/valve
..()
if(open && (!node1 || !node2))
close()
if(!node1)
if(!nodealert)
//world << "Missing node from [src] at [src.x],[src.y],[src.z]"
nodealert = 1
else if (!node2)
if(!nodealert)
//world << "Missing node from [src] at [src.x],[src.y],[src.z]"
nodealert = 1
else if (nodealert)
nodealert = 0
return
@@ -139,14 +150,14 @@ obj/machinery/atmospherics/valve
var/node1_dir
var/node2_dir
for(var/direction in cardinal)
if(direction&initialize_directions)
if (!node1_dir)
node1_dir = direction
else if (!node2_dir)
node2_dir = direction
for(var/obj/machinery/atmospherics/target in get_step(src,node1_dir))
if(target.initialize_directions & get_dir(target,src))
node1 = target

View File

@@ -5,7 +5,7 @@ obj/machinery/atmospherics/pipe
var/datum/pipeline/parent
var/volume = 0
var/nodealert = 0
layer = 2.4 //under wires with their 2.5
@@ -118,6 +118,8 @@ obj/machinery/atmospherics/pipe
if(!nodealert)
//world << "Missing node from [src] at [src.x],[src.y],[src.z]"
nodealert = 1
else if (nodealert)
nodealert = 0
else if(parent)
@@ -342,6 +344,11 @@ obj/machinery/atmospherics/pipe
..()
if(!node1)
parent.mingle_with_turf(loc, 200)
if(!nodealert)
//world << "Missing node from [src] at [src.x],[src.y],[src.z]"
nodealert = 1
else if (nodealert)
nodealert = 0
carbon_dioxide
name = "Pressure Tank (Carbon Dioxide)"
@@ -515,6 +522,13 @@ obj/machinery/atmospherics/pipe
if(parent)
parent.mingle_with_turf(loc, 250)
if(!node1)
if(!nodealert)
//world << "Missing node from [src] at [src.x],[src.y],[src.z]"
nodealert = 1
else if (nodealert)
nodealert = 0
Del()
if(node1)
node1.disconnect(src)
@@ -606,12 +620,21 @@ obj/machinery/atmospherics/pipe
if(!node1)
parent.mingle_with_turf(loc, 70)
if(!nodealert)
//world << "Missing node from [src] at [src.x],[src.y],[src.z]"
nodealert = 1
else if(!node2)
parent.mingle_with_turf(loc, 70)
if(!nodealert)
//world << "Missing node from [src] at [src.x],[src.y],[src.z]"
nodealert = 1
else if(!node3)
parent.mingle_with_turf(loc, 70)
if(!nodealert)
//world << "Missing node from [src] at [src.x],[src.y],[src.z]"
nodealert = 1
else if (nodealert)
nodealert = 0
Del()
if(node1)