mirror of
https://github.com/Bubberstation/Bubberstation.git
synced 2025-12-14 19:51:59 +00:00
* World Initialization Refactor * Update .github/CODEOWNERS * Update code/__HELPERS/global_lists.dm * Add logging for manually changing your targeted zone (#72814) See title. Surgery hud is exempt from this. Requested by @Mothblocks Signed-off-by: GitHub <noreply@github.com> Co-authored-by: Mothblocks <35135081+Mothblocks@users.noreply.github.com> Co-authored-by: dragomagol <66640614+dragomagol@users.noreply.github.com> * eee * Update tgstation.dme --------- Signed-off-by: GitHub <noreply@github.com> Co-authored-by: Jordan Dominion <Cyberboss@users.noreply.github.com> Co-authored-by: Tom <8881105+tf-4@users.noreply.github.com> Co-authored-by: Zephyr <12817816+ZephyrTFA@users.noreply.github.com> Co-authored-by: Mothblocks <35135081+Mothblocks@users.noreply.github.com> Co-authored-by: dragomagol <66640614+dragomagol@users.noreply.github.com> Co-authored-by: Gandalf <9026500+Gandalf2k15@users.noreply.github.com>
19 lines
726 B
Plaintext
19 lines
726 B
Plaintext
//these are real globals so you can use profiling to profile early world init stuff.
|
|
GLOBAL_REAL(PROFILE_STORE, /list)
|
|
GLOBAL_REAL_VAR(PROFILE_LINE)
|
|
GLOBAL_REAL_VAR(PROFILE_FILE)
|
|
GLOBAL_REAL_VAR(PROFILE_SLEEPCHECK)
|
|
GLOBAL_REAL_VAR(PROFILE_TIME)
|
|
|
|
|
|
/proc/profile_show(user, sort = GLOBAL_PROC_REF(cmp_profile_avg_time_dsc))
|
|
sortTim(PROFILE_STORE, sort, TRUE)
|
|
|
|
var/list/lines = list()
|
|
|
|
for (var/entry in PROFILE_STORE)
|
|
var/list/data = PROFILE_STORE[entry]
|
|
lines += "[entry] => [num2text(data[PROFILE_ITEM_TIME], 10)]ms ([data[PROFILE_ITEM_COUNT]]) (avg:[num2text(data[PROFILE_ITEM_TIME]/(data[PROFILE_ITEM_COUNT] || 1), 99)])"
|
|
|
|
user << browse("<ol><li>[lines.Join("</li><li>")]</li></ol>", "window=[url_encode(GUID())]")
|