public interface IPosition extends Persistenceable
Version 1.1
MIT License
Copyright (c) 2017 by Shynixn
Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:
The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
| Modifier and Type | Interface and Description |
|---|---|
static class |
IPosition.Direction
Defines different relative positions
|
| Modifier and Type | Method and Description |
|---|---|
IPosition |
addCoordinates(double x,
double y,
double z)
Adds or Subs the given coordinates x, y, z to or from the builder.
|
int |
getBlockX()
Returns the x coordinate as int of the builder.
|
int |
getBlockY()
Returns the y coordinate as int of the builder.
|
int |
getBlockZ()
Returns the z coordinate as int of the builder.
|
double |
getPitch()
Returns the pitch of the builder.
|
String |
getWorldName()
Returns the worldname of the builder.
|
double |
getX()
Returns the x coordinate of the builder.
|
double |
getY()
Returns the y coordinate of the builder.
|
double |
getYaw()
Returns the yaw of the builder.
|
double |
getZ()
Returns the z coordinate of the builder.
|
IPosition |
relativePosition(double distance,
IPosition.Direction direction)
Returns the relativePosition to a given direction.
|
IPosition |
setCoordinates(double x,
double y,
double z)
Sets the coordinates x, y, z.
|
IPosition |
setPitch(double pitch)
Sets the pitch of the builder.
|
IPosition |
setRotation(double yaw,
double pitch)
Sets the rotation yaw, pitch.
|
IPosition |
setWorldName(String worldName)
Sets the worldName of the builder.
|
IPosition |
setX(double x)
Sets the x coordinate of the builder.
|
IPosition |
setY(double y)
Sets the y coordinate of the builder.
|
IPosition |
setYaw(double yaw)
Sets the yaw of the builder.
|
IPosition |
setZ(double z)
Sets the z coordinate of the builder.
|
getIdIPosition setCoordinates(double x, double y, double z)
x - xy - yz - zIPosition setRotation(double yaw, double pitch)
yaw - yawpitch - pitchIPosition addCoordinates(double x, double y, double z)
x - xy - yz - zIPosition setWorldName(String worldName)
worldName - worldNameIPosition setYaw(double yaw)
yaw - yawIPosition setPitch(double pitch)
pitch - pitchIPosition setX(double x)
x - xIPosition setY(double y)
y - yIPosition setZ(double z)
z - zdouble getYaw()
double getPitch()
double getX()
double getY()
double getZ()
int getBlockX()
int getBlockY()
int getBlockZ()
String getWorldName()
IPosition relativePosition(double distance, IPosition.Direction direction)
distance - distancedirection - directionCopyright © 2017. All rights reserved.