1.17.x extra actions for Bungeecord command?

Discussion in 'Spigot Plugin Development' started by parpar8090, Aug 16, 2021.

  1. Hello, first of all, I'm not sure if this is the correct section.

    So basically, I am making a /leave command in my Bungeecord plugin. Now, in my minigames server, I want it to remove the player from the game and say "You left your game".

    I tried using PlayerCommandPreprocessEvent in my spigot plugin but I think it only fires on spigot commands only. AsyncPlayerChatEvent does not work because it's only for chat messages, not commands.

    I don't want to OVERRIDE the command because I still want to connect the player to the hub.

    How can I do so?
  2. SteelPhoenix


  3. Yes but I don't want it. I can do that in 1 line in the Bungeecord plugin.
  4. You could implement a layer on your BungeeCord server that transmits the executed commands to the Spigot server that the player is currently connected on. Then you can check for the "leave" command and handle whatever else you need there.