playerswitch

Called when a player switches servers.

player_switched_servers:
  # The type of event.
  type: "playerjoin"
  
  # [OPTIONAL] Used to enable and disable the event.
  # Defaults to true.
  enabled: false
  
  # [OPTIONAL] Add commands to be run.
  commands:
  - "leaf"
  
  # [OPTIONAL] Add servers to be sent to.
  # If more than 1 server is stated the player will
  # go to the server with the least amount of players
  servers:
  - "hub1"
  - "hub2"
  
  # [OPTIONAL] Add a discord webhook.
  discord_webhook:
    url: "url"
    message:
      username: "<player>"
       avatar: "https://crafatar.com/avatars/<uuid>?overlay"
       message: "Hello there!"
    embed:
      color: 0x00FF00
      title:
        message: "Title"
        url: "url"
      description: "Description"
      footer:
        message: "Footer"
        icon: "url"
      author:
        name: "Smudge"
        iconUrl: "url"
        url: "url"
      imageUrl: "url"
      thumbnailUrl: "url"