Files
Aurora.3/code/controllers/Processes/nanoui.dm
skull132 02b42862c1 processScheduler Update to 510 (#398)
Updates code to be 510 compile compatible.

Also introduces the new updates to the GOON processScheduler, which should make for better gameplay and less lag. Specially on high population.
2016-06-23 02:47:12 +03:00

20 lines
523 B
Plaintext

/datum/controller/process/nanoui/setup()
name = "nanoui"
schedule_interval = 20 // every 2 seconds
/datum/controller/process/nanoui/statProcess()
..()
stat(null, "[nanomanager.processing_uis.len] UIs")
/datum/controller/process/nanoui/doWork()
for(last_object in nanomanager.processing_uis)
var/datum/nanoui/NUI = last_object
if(istype(NUI) && isnull(NUI.gcDestroyed))
try
NUI.process()
catch(var/exception/e)
catchException(e, NUI)
else
catchBadType(NUI)
nanomanager.processing_uis -= NUI