Package net.minestom.server.event.player
Class PlayerEntityInteractEvent
java.lang.Object
net.minestom.server.event.player.PlayerEntityInteractEvent
- All Implemented Interfaces:
Event
,EntityEvent
,EntityInstanceEvent
,InstanceEvent
,PlayerEvent
,PlayerInstanceEvent
-
Constructor Summary
ConstructorDescriptionPlayerEntityInteractEvent
(@NotNull Player player, @NotNull Entity entityTarget, Player.Hand hand, @NotNull Point interactPosition) -
Method Summary
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Methods inherited from interface net.minestom.server.event.trait.EntityInstanceEvent
getInstance
Methods inherited from interface net.minestom.server.event.trait.PlayerEvent
getEntity
-
Constructor Details
-
PlayerEntityInteractEvent
public PlayerEntityInteractEvent(@NotNull @NotNull Player player, @NotNull @NotNull Entity entityTarget, @NotNull Player.Hand hand, @NotNull @NotNull Point interactPosition)
-
-
Method Details
-
getPlayer
Description copied from interface:PlayerEvent
Gets the player.- Specified by:
getPlayer
in interfacePlayerEvent
- Returns:
- the player
-
getTarget
Gets theEntity
with whogetPlayer()
is interacting.- Returns:
- the
Entity
-
getHand
Gets with which hand the player interacted with the entity.- Returns:
- the hand
-
getInteractPosition
Gets the position at which the entity was interacted- Returns:
- the interaction position
- See Also:
-