Files
VOREStation/code/ZAS/Diagnostic.dm
T
Kashargul 89fb9871e0 next set of admin verbs (#19260)
* next set of admin verbs

* invoke

* .

* a few more

* few more

* .

* few more

* some more

* move thos

* next

* some debug verbs

* axe the old mod loading

* del

* is local for some verbs

* few more

* .

* .

* .

* Add local narrate.

* Fixes this

Needed to be user.mob, since user is  the client and usr was the old user.mob

* fixes

* .

* .

* .

* .

---------

Co-authored-by: Cameron Lennox <killer65311@gmail.com>
2026-03-21 17:16:41 -04:00

82 lines
2.8 KiB
Plaintext

ADMIN_VERB_VISIBILITY(Zone_Info, ADMIN_VERB_VISIBLITY_FLAG_LOCALHOST)
ADMIN_VERB(Zone_Info, R_DEBUG, "ZAS Zone Info", "Prints the ZAS information of the zone (Only use on a test server).", ADMIN_CATEGORY_MAPPING_ZAS, turf/T)
if(T)
if(istype(T,/turf/simulated) && T:zone)
T:zone:dbg_data(user)
else
to_chat(user, span_debug_warning("No zone here."))
var/datum/gas_mixture/mix = T.return_air()
to_chat(user, span_debug_info("[mix.return_pressure()] kPa [mix.temperature]C"))
for(var/g in mix.gas)
to_chat(user, span_debug_info("[g]: [mix.gas[g]]\n"))
else
if(user.zone_debug_images)
for(var/zone in user.zone_debug_images)
user.images -= user.zone_debug_images[zone]
user.zone_debug_images = null
/client/var/list/zone_debug_images
ADMIN_VERB_VISIBILITY(Test_ZAS_Connection, ADMIN_VERB_VISIBLITY_FLAG_MAPPING_DEBUG)
ADMIN_VERB(Test_ZAS_Connection, R_DEBUG, "Test ZAS Connection", "Tests the ZAS zone connection (Only use on a test server).", ADMIN_CATEGORY_MAPPING_ZAS, turf/simulated/T)
if(!istype(T))
return
var/direction_list = list(\
"North" = NORTH,\
"South" = SOUTH,\
"East" = EAST,\
"West" = WEST,\
#ifdef MULTIZAS
"Up" = UP,\
"Down" = DOWN,\
#endif
"N/A" = null)
var/direction = tgui_input_list(user, "What direction do you wish to test?","Set direction", direction_list)
if(!direction)
return
if(direction == "N/A")
if(!(T.self_airblock() & AIR_BLOCKED))
to_chat(user, span_debug_info("The turf can pass air! :D"))
else
to_chat(user, span_debug_warning("No air passage :x"))
return
var/turf/simulated/other_turf = get_step(T, direction_list[direction])
if(!istype(other_turf))
return
var/t_block = T.c_airblock(other_turf)
var/o_block = other_turf.c_airblock(T)
if(o_block & AIR_BLOCKED)
if(t_block & AIR_BLOCKED)
to_chat(user, span_debug_warning("Neither turf can connect. :("))
else
to_chat(user, span_debug_warning("The initial turf only can connect. :\\"))
else
if(t_block & AIR_BLOCKED)
to_chat(user, span_debug_warning("The other turf can connect, but not the initial turf. :/"))
else
to_chat(user, span_debug_info("Both turfs can connect! :)"))
to_chat(user, span_debug_info("Additionally, \..."))
if(o_block & ZONE_BLOCKED)
if(t_block & ZONE_BLOCKED)
to_chat(user, span_debug_warning("neither turf can merge."))
else
to_chat(user, span_debug_warning("the other turf cannot merge."))
else
if(t_block & ZONE_BLOCKED)
to_chat(user, span_debug_warning("the initial turf cannot merge."))
else
to_chat(user, span_debug_warning("both turfs can merge."))
ADMIN_VERB_VISIBILITY(Test_ZAS_Connection, ADMIN_VERB_VISIBLITY_FLAG_MAPPING_DEBUG)
ADMIN_VERB(ZASSettings, R_ADMIN, "ZAS Settings", "Access the ZAS settings.", ADMIN_CATEGORY_DEBUG_DANGEROUS, turf/simulated/T)
GLOB.vsc.SetDefault(user.mob)