Files
Aurora.3/code/ZAS/Diagnostic.dm
LordFowl 8d436c4a03 Converts all necessary << outputs into the to_chat() macro. (#6076)
This PR will lead us towards the Promised Day, for in its wake there shall be much celebration and ecstasy as this world becomes a world suitable for developer hegemony. The first strike is thusly;

All << is converted into to_chat().
2019-03-10 23:39:03 +02:00

86 lines
2.0 KiB
Plaintext

client/proc/Zone_Info(turf/T as null|turf)
set category = "Debug"
if(T)
if(istype(T,/turf/simulated) && T:zone)
T:zone:dbg_data(src)
else
to_chat(mob, "No zone here.")
var/datum/gas_mixture/mix = T.return_air()
to_chat(mob, "[mix.return_pressure()] kPa [mix.temperature]C")
for(var/g in mix.gas)
to_chat(mob, "[g]: [mix.gas[g]]\n")
else
if(zone_debug_images)
for(var/zone in zone_debug_images)
images -= zone_debug_images[zone]
zone_debug_images = null
client/var/list/zone_debug_images
client/proc/Test_ZAS_Connection(var/turf/simulated/T as turf)
set category = "Debug"
if(!istype(T))
return
var/direction_list = list(
"North" = NORTH,
"South" = SOUTH,
"East" = EAST,
"West" = WEST,
"Up" = UP,
"Down" = DOWN,
"N/A" = null
)
var/direction = input("What direction do you wish to test?","Set direction") as null|anything in direction_list
if(!direction)
return
if(direction == "N/A")
var/res
ATMOS_CANPASS_TURF(res, T, T)
if(!(res & AIR_BLOCKED))
to_chat(mob, "The turf can pass air! :D")
else
to_chat(mob, "No air passage :x")
return
var/turf/simulated/other_turf = get_step(T, direction_list[direction])
if(!istype(other_turf))
return
var/t_block
ATMOS_CANPASS_TURF(t_block, T, other_turf)
var/o_block
ATMOS_CANPASS_TURF(o_block, other_turf, T)
if(o_block & AIR_BLOCKED)
if(t_block & AIR_BLOCKED)
to_chat(mob, "Neither turf can connect. :(")
else
to_chat(mob, "The initial turf only can connect. :\\")
else
if(t_block & AIR_BLOCKED)
to_chat(mob, "The other turf can connect, but not the initial turf. :/")
else
to_chat(mob, "Both turfs can connect! :)")
to_chat(mob, "Additionally, \...")
if(o_block & ZONE_BLOCKED)
if(t_block & ZONE_BLOCKED)
to_chat(mob, "neither turf can merge.")
else
to_chat(mob, "the other turf cannot merge.")
else
if(t_block & ZONE_BLOCKED)
to_chat(mob, "the initial turf cannot merge.")
else
to_chat(mob, "both turfs can merge.")
client/proc/ZASSettings()
set category = "Debug"
vsc.SetDefault(mob)