Skip to content

LegendEffects/OpenAFK

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

64 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

OpenAFK

An open source AFK plugin for Spigot.

Permissions

  • openafk.exempt - Prevents the player from being detected as AFK
  • openafk.isafk - Allows access to the /isafk command
  • openafk.admin - Allows access to the /openafk command
  • openafk.afk - Allows access to the /afk command =======

Commands

  • /isafk <username/uuid> - Checks if a player is AFK
  • /afkplayers - Gives a list of AFK players
  • /openafk - Admin OpenAFK Command
  • /afk - Toggles the executors AFK status

Understanding the annotations.

  • Parameters with an "(optional)" next to them don't need to be provided unless wanted.

  • Actions that support multiline are compatible with YAML multiline syntax on the content. Example:

- action: "message"
  content: |
    First line
    Second line
    Third line

Actions

Actions are OpenAFKs way to let you orchestrate what happens on events. (You can even register your own actions!)

Actionbar

Displays a temporary or permanent actionbar message to everyone or the actioned player.

- action: "actionbar"
  to: "player" #(Optional) - defaults to player, can be player or all
  content: "&cHello!"
  permanent: true #(Optional)

Resetting

- action: "actionbar"
  reset: true
  to: "player" #(Optional) - defaults to player, can be player or all

AfkArea

Teleports the actioned player to a defined location set with /openafk set afkarea.

- action: "afkarea"

Broadcast

Supports Multiline Broadcasts a message to an entire server.

- action: "broadcast"
  content: "&cContent to broadcast."
  permission: permission.node #(Optional) - Sends the broadcast only to people with this permission
  repeat: 2 #(Optional) - Amount of times to send the broadcast

Look

Changes where a players head is, using yaw and pitch.

(Only one is required but both can be used.)

- action: "look"
  yaw: 2
  pitch: 5

Command

Issues a command by a player or by console.

- action: "command"
  by: "player" #(Optional - defaults to player) accepts player or console
  command: "/help" # Console commands do NOT use the /

Message

Supports Multiline Messages the actioned player with given content once or multiple times.

- action: "message"
  content: "&cHello!"
  repeat: 2 #(Optional)

Title

Shows a temporary or permanent title to the actioned player.

- action: "title"
  title: "&cHello!"
  subtitle: "&aWelcome back."
  fadeIn: 10
  fadeOut: 10
  stay: 500 # Valid values: integer, "permanent"

Resetting

- action: "title"
  reset: true

Invisibility

Makes the actioned player visible or invisible to other players.

- action: "invisibility"
  type: "show" #Valid values: "show", "hide"

Nametag

REQUIRES NameTagEdit Sets the players prefix, suffix or both with NametagEdit

- action: "nametag"
  prefix: "&7[&c&lAFK&7] &9"
  suffix: "PlayersSuffix" #(Optional)

Invincibility

Makes the player invincible and sends a message to the attacker on hit.

- action: "invincibility"
  to: true # Also accepts false

Scripts

Scripts are lists of actions which are ran in order, these define what actions to do when certain events happen.

About

An open source AFK plugin for Spigot.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages