mirror of
https://github.com/vgstation-coders/vgstation13.git
synced 2025-12-10 18:32:03 +00:00
* Code done. Doesn't compile for shit. * IT COMPILES! * Hey it almost works. * Fixes lighting * Remove thing I had to double check after asking mso. * More fixes. * WiP, fixed everything but waitfor * Done. * Damnit DM. * Fixes priorities
23 lines
628 B
Plaintext
23 lines
628 B
Plaintext
var/datum/subsystem/inactivity/SSinactivity
|
|
|
|
|
|
/datum/subsystem/inactivity
|
|
name = "Inactivity"
|
|
wait = INACTIVITY_KICK
|
|
flags = SS_NO_INIT | SS_BACKGROUND | SS_FIRE_IN_LOBBY
|
|
priority = SS_PRIORITY_INACTIVITY
|
|
|
|
|
|
/datum/subsystem/inactivity/New()
|
|
NEW_SS_GLOBAL(SSinactivity)
|
|
|
|
|
|
/datum/subsystem/inactivity/fire(resumed = FALSE)
|
|
if (config.kick_inactive)
|
|
for (var/client/C in clients)
|
|
if (C.is_afk(INACTIVITY_KICK))
|
|
if (!istype(C.mob, /mob/dead))
|
|
log_access("AFK: [key_name(C)]")
|
|
to_chat(C, "<SPAN CLASS='warning'>You have been inactive for more than 10 minutes and have been disconnected.</SPAN>")
|
|
del(C)
|