mirror of
https://github.com/PolarisSS13/Polaris.git
synced 2025-12-29 19:43:16 +00:00
May fix the debug verbs showing up for non-debuggers. Probably not.
This commit is contained in:
@@ -16,12 +16,12 @@ var/global/list/power_update_requests_by_area = list()
|
||||
power_update_requests_by_machine[machine_type] += 1
|
||||
else
|
||||
power_update_requests_by_machine[machine_type] = 1
|
||||
|
||||
|
||||
if (A.name in power_update_requests_by_area)
|
||||
power_update_requests_by_area[A.name] += 1
|
||||
else
|
||||
power_update_requests_by_area[A.name] = 1
|
||||
|
||||
|
||||
power_profiled_time += (world.time - power_last_profile_time)
|
||||
power_last_profile_time = world.time
|
||||
|
||||
@@ -33,25 +33,27 @@ var/global/list/power_update_requests_by_area = list()
|
||||
|
||||
if(enable_power_update_profiling)
|
||||
enable_power_update_profiling = 0
|
||||
|
||||
|
||||
usr << "Area power update profiling disabled."
|
||||
message_admins("[key_name(src)] toggled area power update profiling off.")
|
||||
log_admin("[key_name(src)] toggled area power update profiling off.")
|
||||
else
|
||||
enable_power_update_profiling = 1
|
||||
power_last_profile_time = world.time
|
||||
|
||||
|
||||
usr << "Area power update profiling enabled."
|
||||
message_admins("[key_name(src)] toggled area power update profiling on.")
|
||||
log_admin("[key_name(src)] toggled area power update profiling on.")
|
||||
|
||||
|
||||
feedback_add_details("admin_verb","APUP") //If you are copy-pasting this, ensure the 2nd parameter is unique to the new proc!
|
||||
|
||||
/client/proc/view_power_update_stats_machines()
|
||||
set name = "View Area Power Update Statistics By Machines"
|
||||
set desc = "See which types of machines are triggering area power updates."
|
||||
set category = "Debug"
|
||||
|
||||
|
||||
if(!check_rights(R_DEBUG)) return
|
||||
|
||||
usr << "Total profiling time: [power_profiled_time] ticks"
|
||||
for (var/M in power_update_requests_by_machine)
|
||||
usr << "[M] = [power_update_requests_by_machine[M]]"
|
||||
@@ -60,7 +62,9 @@ var/global/list/power_update_requests_by_area = list()
|
||||
set name = "View Area Power Update Statistics By Area"
|
||||
set desc = "See which areas are having area power updates."
|
||||
set category = "Debug"
|
||||
|
||||
|
||||
if(!check_rights(R_DEBUG)) return
|
||||
|
||||
usr << "Total profiling time: [power_profiled_time] ticks"
|
||||
usr << "Total profiling time: [power_profiled_time] ticks"
|
||||
for (var/A in power_update_requests_by_area)
|
||||
|
||||
Reference in New Issue
Block a user