Skip to content

AFK

The AFK (away-from-keyboard) module tracks players active time and automatically flags them as "AFK" after a configurable time span of inactivity.

The placeholder solstice:afk displays an AFK tag.

Activity is currently tracked by:

  • Player movement
  • Chat messages and commands
  • Block and entity events
  • Item use events

The /afk command manually triggers AFK.

AFK

Configuring

AFK can be configured in the afk section in the config file.

enable

Whether to enable the AFK module. This setting requires a server restart.

Use the solstice.afk.base permission node for fine tuning to specific users.

time-trigger

How many seconds the player has to be inactive to trigger the AFK.

announce

Whether to announce in chat a player has gone to or returned from AFK.

tag

This tag is displayed with solstice:afk placeholder when the player is AFK.

triggers

on-movement

Trigger on player movement.

on-look-change

Trigger on player changing head direction (yaw, pitch).

on-chat

Trigger on chat messages (or attempt of).

on-command

Trigger on command (or attempt of).

Fake players

The following events may be triggered by fake players, preventing the player from going AFK automatically.

on-block-attack

Trigger on attack on block (dig, left click) event.

on-block-interact

Trigger on interaction with block (place, right click) event.

on-entity-attack

Trigger on attack on entity event.

on-entity-interact

Trigger on interact with entity event.

on-item-use

Trigger on item use event.

Commands

afk

Set player state as AFK.

Permissions

  • solstice.afk.base - Default: true
    Enable AFK feature for the player.

Permissions for commands below subject to changes.

activetime

View your active time.

Permissions

  • solstice.afk.base - Default: true

activetime player <player>

View a player's active time.

Permissions

  • solstice.afk.others - Default: 1

activetime leaderboard

View a top 10 leaderboard of most active players.

Permissions

  • solstice.afk.leaderboard - Default: true

activetime set <player> [time]

Set the active time of a player.

This command does not update the leaderboard.

Permissions

  • solstice.afk.set - Default: 3