public class PlayerToggleFlyingEvent extends PlayerEvent implements Cancellable
If a player can't change into this mode due to their fly mode being false, then the server will call this event already cancelled, and plugins may uncancel it.
Constructor and Description |
---|
PlayerToggleFlyingEvent(Player player,
boolean toggleState,
boolean flyMode) |
Modifier and Type | Method and Description |
---|---|
void |
cancel(boolean cancelled) |
boolean |
isFlyMode() |
boolean |
isIgnored() |
boolean |
toggleState()
Returns the state the player is attempting to toggle into, true for flying, false for not
|
player
public PlayerToggleFlyingEvent(Player player, boolean toggleState, boolean flyMode)
public boolean toggleState()
public boolean isFlyMode()
public boolean isIgnored()
isIgnored
in interface Cancellable
public void cancel(boolean cancelled)
cancel
in interface Cancellable
cancelled
- set the cancellation state of the eventCopyright © 2016. All rights reserved.