public class PlayerElementHitEvent extends PlayerEvent
World3DModel.setHittable(boolean) is set to true).| Constructor and Description |
|---|
PlayerElementHitEvent(Player player,
WorldElement worldElement,
Vector3f hitPosition,
Vector3f hitNormal) |
| Modifier and Type | Method and Description |
|---|---|
Vector3f |
getHitNormal()
Gets the normal, i.e. the normal of the surface that was hit
(the direction in which the surface points).
|
Vector3f |
getHitPosition()
Gets the coordinates where the element was hit exactly.
|
WorldElement |
getWorldElement()
Gets the world element that was hit by the player.
|
getPlayerpublic PlayerElementHitEvent(Player player, WorldElement worldElement, Vector3f hitPosition, Vector3f hitNormal)
public WorldElement getWorldElement()
public Vector3f getHitPosition()
public Vector3f getHitNormal()
Vector3f.