How it works!
How It Works
Client-side
The client-side script (client.lua
) continuously monitors player activity. It checks for:
Movement controls
Walking, running, or sprinting
Camera rotation (mouse movement)
If no activity is detected for the duration specified in Config.IdleTimeThreshold
, the player is marked as AFK.
Server-side
The server-side script (server.lua
) manages the AFK states of all players. It:
Receives AFK notifications from clients
Manages the list of AFK players
Handles the kicking of AFK players (if enabled)
Checks for admin/mod exemptions
AFK Visual Indicator
When a player is AFK, a 3D "AFK" text appears above their character, visible to all players.
Last updated