From 717d63f1297d23c43784bd448d783f090d048d28 Mon Sep 17 00:00:00 2001 From: CitadelStationBot Date: Fri, 28 Apr 2017 10:59:14 -0500 Subject: [PATCH 1/2] Adds new debug verb for highlighting roundstart ATs --- code/_globalvars/lists/mapping.dm | 1 + code/controllers/subsystem/air.dm | 2 +- code/game/objects/effects/misc.dm | 21 ++++++++++++++++++++- code/modules/admin/verbs/mapping.dm | 2 +- code/modules/admin/verbs/mapping.dm.rej | 19 +++++++++++++++++++ 5 files changed, 42 insertions(+), 3 deletions(-) create mode 100644 code/modules/admin/verbs/mapping.dm.rej diff --git a/code/_globalvars/lists/mapping.dm b/code/_globalvars/lists/mapping.dm index 090000fded..eece2b4ca8 100644 --- a/code/_globalvars/lists/mapping.dm +++ b/code/_globalvars/lists/mapping.dm @@ -54,3 +54,4 @@ GLOBAL_LIST_EMPTY(awaydestinations) //a list of landmarks that the warpgate can GLOBAL_LIST_EMPTY(sortedAreas) GLOBAL_LIST_EMPTY(transit_markers) +GLOBAL_LIST_EMPTY(all_abstract_markers) \ No newline at end of file diff --git a/code/controllers/subsystem/air.dm b/code/controllers/subsystem/air.dm index 919b4cfce9..38245c5bcc 100644 --- a/code/controllers/subsystem/air.dm +++ b/code/controllers/subsystem/air.dm @@ -299,7 +299,7 @@ SUBSYSTEM_DEF(air) var/timer = world.timeofday warning("There are [starting_ats] active turfs at roundstart, this is a mapping error caused by a difference of the air between the adjacent turfs. You can see its coordinates using \"Mapping -> Show roundstart AT list\" verb (debug verbs required)") for(var/turf/T in active_turfs) - GLOB.active_turfs_startlist += text("[T.x], [T.y], [T.z]\n") + GLOB.active_turfs_startlist += T //now lets clear out these active turfs var/list/turfs_to_check = active_turfs.Copy() diff --git a/code/game/objects/effects/misc.dm b/code/game/objects/effects/misc.dm index ad84d203d2..0c08945fc6 100644 --- a/code/game/objects/effects/misc.dm +++ b/code/game/objects/effects/misc.dm @@ -30,4 +30,23 @@ icon_state = "white" plane = LIGHTING_PLANE layer = LIGHTING_LAYER - blend_mode = BLEND_ADD \ No newline at end of file + blend_mode = BLEND_ADD + +/obj/effect/abstract/marker + name = "marker" + icon = 'icons/effects/effects.dmi' + anchored = TRUE + icon_state = "wave3" + layer = RIPPLE_LAYER + +/obj/effect/abstract/marker/Initialize(mapload) + . = ..() + GLOB.all_abstract_markers += src + +/obj/effect/abstract/marker/Destroy() + GLOB.all_abstract_markers -= src + . = ..() + +/obj/effect/abstract/marker/at + name = "active turf marker" + diff --git a/code/modules/admin/verbs/mapping.dm b/code/modules/admin/verbs/mapping.dm index 9b8948cd13..125def9517 100644 --- a/code/modules/admin/verbs/mapping.dm +++ b/code/modules/admin/verbs/mapping.dm @@ -41,7 +41,7 @@ GLOBAL_LIST_INIT(admin_verbs_debug_mapping, list( /client/proc/disable_communication, /client/proc/print_pointers, /client/proc/cmd_show_at_list, - /client/proc/cmd_show_at_list, + /client/proc/cmd_show_at_markers, /client/proc/manipulate_organs )) diff --git a/code/modules/admin/verbs/mapping.dm.rej b/code/modules/admin/verbs/mapping.dm.rej new file mode 100644 index 0000000000..2b4bebd53d --- /dev/null +++ b/code/modules/admin/verbs/mapping.dm.rej @@ -0,0 +1,19 @@ +diff a/code/modules/admin/verbs/mapping.dm b/code/modules/admin/verbs/mapping.dm (rejected hunks) +@@ -156,7 +156,7 @@ GLOBAL_LIST_INIT(admin_verbs_debug_mapping, list( + + for(var/t in GLOB.active_turfs_startlist) + var/turf/T = t +- dat += "[T.x], [T.y], [T.z]\n" ++ dat += "[ADMIN_COORDJMP(T)]\n" + dat += "
" + + usr << browse(dat, "window=at_list") +@@ -181,7 +181,7 @@ GLOBAL_LIST_INIT(admin_verbs_debug_mapping, list( + count++ + to_chat(usr, "[count] AT markers placed.") + +- feedback_add_details("admin_verb", "Show Roundstart Active Turf Markers") ++ SSblackbox.add_details("admin_verb","Show Roundstart Active Turf Markers") + + /client/proc/enable_debug_verbs() + set category = "Debug" From 58909705e56cac237edfd87c6d8be175fa878251 Mon Sep 17 00:00:00 2001 From: LetterJay Date: Wed, 17 May 2017 10:01:38 -0500 Subject: [PATCH 2/2] MAPPING DEBUG! WOO! --- code/modules/admin/verbs/mapping.dm | 44 +++++++++++++++++++++-------- 1 file changed, 33 insertions(+), 11 deletions(-) diff --git a/code/modules/admin/verbs/mapping.dm b/code/modules/admin/verbs/mapping.dm index fce3380484..c15c28d0d0 100644 --- a/code/modules/admin/verbs/mapping.dm +++ b/code/modules/admin/verbs/mapping.dm @@ -41,7 +41,7 @@ GLOBAL_LIST_INIT(admin_verbs_debug_mapping, list( /client/proc/disable_communication, /client/proc/print_pointers, /client/proc/cmd_show_at_list, - /client/proc/cmd_show_at_markers, + /client/proc/cmd_show_at_markers, /client/proc/manipulate_organs )) @@ -81,7 +81,7 @@ GLOBAL_LIST_INIT(admin_verbs_debug_mapping, list( seen[T]++ for(var/turf/T in seen) T.maptext = "[seen[T]]" - SSblackbox.add_details("admin_verb","Show Camera Range") //If you are copy-pasting this, ensure the 2nd parameter is unique to the new proc! + SSblackbox.add_details("admin_verb","Show Camera Range") //If you are copy-pasting this, ensure the 2nd parameter is unique to the new proc! @@ -123,7 +123,7 @@ GLOBAL_LIST_INIT(admin_verbs_debug_mapping, list( output += "" usr << browse(output,"window=airreport;size=1000x500") - SSblackbox.add_details("admin_verb","Show Camera Report") //If you are copy-pasting this, ensure the 2nd parameter is unique to the new proc! + SSblackbox.add_details("admin_verb","Show Camera Report") //If you are copy-pasting this, ensure the 2nd parameter is unique to the new proc! /client/proc/intercom_view() set category = "Mapping" @@ -144,7 +144,7 @@ GLOBAL_LIST_INIT(admin_verbs_debug_mapping, list( var/obj/effect/debugging/marker/F = new/obj/effect/debugging/marker(T) if (!(F in view(7,I.loc))) qdel(F) - SSblackbox.add_details("admin_verb","Show Intercom Range") //If you are copy-pasting this, ensure the 2nd parameter is unique to the new proc! + SSblackbox.add_details("admin_verb","Show Intercom Range") //If you are copy-pasting this, ensure the 2nd parameter is unique to the new proc! /client/proc/cmd_show_at_list() set category = "Mapping" @@ -154,13 +154,35 @@ GLOBAL_LIST_INIT(admin_verbs_debug_mapping, list( var/dat = {"Coordinate list of Active Turfs at Roundstart
Real-time Active Turfs list you can see in Air Subsystem at active_turfs var
"} - for(var/i=1; i<=GLOB.active_turfs_startlist.len; i++) - dat += GLOB.active_turfs_startlist[i] + for(var/t in GLOB.active_turfs_startlist) + var/turf/T = t + dat += "[ADMIN_COORDJMP(T)]\n" dat += "
" usr << browse(dat, "window=at_list") - SSblackbox.add_details("admin_verb","Show Roundstart Active Turfs") //If you are copy-pasting this, ensure the 2nd parameter is unique to the new proc! + SSblackbox.add_details("admin_verb","Show Roundstart Active Turfs") //If you are copy-pasting this, ensure the 2nd parameter is unique to the new proc! + +/client/proc/cmd_show_at_markers() + set category = "Mapping" + set name = "Show roundstart AT markers" + set desc = "Places a marker on all active-at-roundstart turfs" + + var/count = 0 + for(var/obj/effect/abstract/marker/at/AT in GLOB.all_abstract_markers) + qdel(AT) + count++ + + if(count) + to_chat(usr, "[count] AT markers removed.") + else + for(var/t in GLOB.active_turfs_startlist) + new /obj/effect/abstract/marker/at(t) + count++ + to_chat(usr, "[count] AT markers placed.") + + SSblackbox.add_details("admin_verb","Show Roundstart Active Turf Markers") + /client/proc/enable_debug_verbs() set category = "Debug" @@ -169,14 +191,14 @@ GLOBAL_LIST_INIT(admin_verbs_debug_mapping, list( return verbs -= /client/proc/enable_debug_verbs verbs.Add(/client/proc/disable_debug_verbs, GLOB.admin_verbs_debug_mapping) - SSblackbox.add_details("admin_verb","Enable Debug Verbs") //If you are copy-pasting this, ensure the 2nd parameter is unique to the new proc! + SSblackbox.add_details("admin_verb","Enable Debug Verbs") //If you are copy-pasting this, ensure the 2nd parameter is unique to the new proc! /client/proc/disable_debug_verbs() set category = "Debug" set name = "Debug verbs - Disable" verbs.Remove(/client/proc/disable_debug_verbs, GLOB.admin_verbs_debug_mapping) verbs += /client/proc/enable_debug_verbs - SSblackbox.add_details("admin_verb", "Disable Debug Verbs") //If you are copy-pasting this, ensure the 2nd parameter is unique to the new proc! + SSblackbox.add_details("admin_verb", "Disable Debug Verbs") //If you are copy-pasting this, ensure the 2nd parameter is unique to the new proc! /client/proc/count_objects_on_z_level() set category = "Mapping" @@ -219,7 +241,7 @@ GLOBAL_LIST_INIT(admin_verbs_debug_mapping, list( to_chat(world, line)*/ to_chat(world, "There are [count] objects of type [type_path] on z-level [num_level]") - SSblackbox.add_details("admin_verb","Count Objects Zlevel") //If you are copy-pasting this, ensure the 2nd parameter is unique to the new proc! + SSblackbox.add_details("admin_verb","Count Objects Zlevel") //If you are copy-pasting this, ensure the 2nd parameter is unique to the new proc! /client/proc/count_objects_all() set category = "Mapping" @@ -246,7 +268,7 @@ GLOBAL_LIST_INIT(admin_verbs_debug_mapping, list( to_chat(world, line)*/ to_chat(world, "There are [count] objects of type [type_path] in the game world") - SSblackbox.add_details("admin_verb","Count Objects All") //If you are copy-pasting this, ensure the 2nd parameter is unique to the new proc! + SSblackbox.add_details("admin_verb","Count Objects All") //If you are copy-pasting this, ensure the 2nd parameter is unique to the new proc! //This proc is intended to detect lag problems relating to communication procs