Class KonquestPlayerCombatTagEvent

java.lang.Object
org.bukkit.event.Event
konquest.api.event.KonquestEvent
konquest.api.event.player.KonquestPlayerEvent
konquest.api.event.player.KonquestPlayerCombatTagEvent
All Implemented Interfaces:
org.bukkit.event.Cancellable

public class KonquestPlayerCombatTagEvent extends KonquestPlayerEvent implements org.bukkit.event.Cancellable
Called when a player is attacked by another player.

Attacking another player causes the victim to become combat tagged. A player that is combat tagged is restricted from using a list of commands from the Konquest configuration. Canceling this event will prevent the victim from becoming combat tagged.

Author:
Rumsfield
  • Constructor Details

    • KonquestPlayerCombatTagEvent

      public KonquestPlayerCombatTagEvent(KonquestAPI konquest, KonquestPlayer player, KonquestPlayer attacker, org.bukkit.Location location)
      Default constructor
      Parameters:
      konquest - The API instance
      player - The player
      attacker - The attacking player
      location - The location
  • Method Details

    • getAttacker

      public KonquestPlayer getAttacker()
      Gets the attacking player.
      Returns:
      The attacker
    • getLocation

      public org.bukkit.Location getLocation()
      Gets the location that the player was combat tagged at.
      Returns:
      The location
    • isCancelled

      public boolean isCancelled()
      Specified by:
      isCancelled in interface org.bukkit.event.Cancellable
    • setCancelled

      public void setCancelled(boolean val)
      Specified by:
      setCancelled in interface org.bukkit.event.Cancellable