Package dev.boze.api.interaction
Class RotationHelper
java.lang.Object
dev.boze.api.interaction.RotationHelper
RotationHelper
Provides methods to calculate rotations
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionstatic Rotation
calculateAngle
(net.minecraft.util.math.Vec3d to) static Rotation
calculateAngle
(net.minecraft.util.math.Vec3d from, net.minecraft.util.math.Vec3d to)
-
Constructor Details
-
RotationHelper
public RotationHelper()
-
-
Method Details
-
calculateAngle
- Parameters:
to
- the vector to calculate the angle to- Returns:
- the angle between the player's eyes and the given vector
-
calculateAngle
public static Rotation calculateAngle(net.minecraft.util.math.Vec3d from, net.minecraft.util.math.Vec3d to) - Parameters:
from
- the vector to calculate the angle fromto
- the vector to calculate the angle to- Returns:
- the angle between the given vectors
-