Uploaded image for project: 'Spigot'
  1. Spigot
  2. SPIGOT-3034

PlayerKickEvent.setLeaveMessage(String) doesn't actually do anything

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Fixed
    • Icon: Minor Minor
    • None
    • None

      PlayerKickEvent.setLeaveMessage does not actually do anything; the message is ignored. (PlayerQuitEvent.setLeaveMessage does work, however).

      To reproduce, create a plugin with the following:

       @EventHandler
       public void onKick(PlayerKickEvent e) {
        e.setLeaveMessage("... a leave message ...");
       }
      

      ... and then run /kick on a player. The normal "<player> left the game" message will be displayed instead of the custom "... a leave message ..." one.

      I'm cleaning up some of the related parts of the code for a larger PR, so I'll end up fixing this within that soon; I'm just creating this ticket as a reference until then.

            Unassigned Unassigned
            pokechu22 pokechu22
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

              Created:
              Updated:
              Resolved: