Ported the core of the overlays management subsystem from /tg

- Added SSoverlays subsystem for compiling overlay lists and applying them to atoms in a controlled anti-lag subsystem.
- Added vars and procs to atom which should eventually replace all direct interaction with BYOND's /atom/overlays var outside the subsystem.
- Added OVERLAY_QUEUED flag to var/atom/flags bitfield.
- Added small framework for subsystem performance tracking. So far used only by SSoverlays
- Added admin debug command "Display overlay Log" to see performance stats mid-round.
This commit is contained in:
Leshana
2018-02-24 17:40:06 -05:00
parent 9b36c4da49
commit f2f630fa89
10 changed files with 343 additions and 5 deletions

View File

@@ -36,3 +36,9 @@
. = b.head_position - a.head_position
if (. == 0) //Already in head/nothead spot, sort by name
. = sorttext(b.title, a.title)
// Sorts entries in a performance stats list.
/proc/cmp_generic_stat_item_time(list/A, list/B)
. = B[STAT_ENTRY_TIME] - A[STAT_ENTRY_TIME]
if (!.)
. = B[STAT_ENTRY_COUNT] - A[STAT_ENTRY_COUNT]