Package io.papermc.paper.event.block
Class BlockFailedDispenseEvent
java.lang.Object
org.bukkit.event.Event
org.bukkit.event.block.BlockEvent
io.papermc.paper.event.block.BlockFailedDispenseEvent
Called when a block tries to dispense an item, but its inventory is empty.
-
Nested Class Summary
Nested classes/interfaces inherited from class org.bukkit.event.Event
Event.Result
-
Field Summary
Fields inherited from class org.bukkit.event.block.BlockEvent
block
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionboolean
Calls the event and tests if cancelled.static @NotNull HandlerList
boolean
void
shouldPlayEffect
(boolean playEffect) Sets if the effect for empty dispensers should be playedMethods inherited from class org.bukkit.event.block.BlockEvent
getBlock
Methods inherited from class org.bukkit.event.Event
asynchronous, getEventName, isAsynchronous
-
Constructor Details
-
BlockFailedDispenseEvent
-
-
Method Details
-
shouldPlayEffect
public boolean shouldPlayEffect()- Returns:
- if the effect should be played
-
shouldPlayEffect
public void shouldPlayEffect(boolean playEffect) Sets if the effect for empty dispensers should be played- Parameters:
playEffect
- if the effect should be played
-
callEvent
public boolean callEvent()Calls the event and tests if cancelled.- Overrides:
callEvent
in classEvent
- Returns:
shouldPlayEffect()
-
getHandlers
- Specified by:
getHandlers
in classEvent
-
getHandlerList
-