Class Position
java.lang.Object
com.palmergames.bukkit.towny.object.Position
- Direct Known Subclasses:
SpawnPointLocation
-
Constructor Summary
ModifierConstructorDescriptionprotected
Position
(TownyWorld world, double x, double y, double z, float pitch, float yaw) -
Method Summary
Modifier and TypeMethodDescription@NotNull org.bukkit.Location
@NotNull Position
int
blockX()
int
blockY()
int
blockZ()
static Position
deserialize
(@NotNull String[] data) boolean
int
hashCode()
static Position
ofLocation
(@NotNull org.bukkit.Location location) float
pitch()
static Position
positionOf
(@NotNull TownyWorld world, double x, double y, double z) static Position
positionOf
(@NotNull TownyWorld world, double x, double y, double z, float pitch, float yaw) @NotNull String[]
world()
double
x()
double
y()
float
yaw()
double
z()
-
Constructor Details
-
Position
@Internal protected Position(TownyWorld world, double x, double y, double z, float pitch, float yaw)
-
-
Method Details
-
world
-
x
public double x() -
y
public double y() -
z
public double z() -
pitch
public float pitch() -
yaw
public float yaw() -
blockX
public int blockX() -
blockY
public int blockY() -
blockZ
public int blockZ() -
worldCoord
-
positionOf
-
positionOf
public static Position positionOf(@NotNull @NotNull TownyWorld world, double x, double y, double z, float pitch, float yaw) -
asLocation
@NotNull public @NotNull org.bukkit.Location asLocation() -
blockPosition
-
ofLocation
-
equals
-
hashCode
public int hashCode() -
serialize
-
deserialize
- Throws:
IllegalArgumentException
-