Player
player.jump
Makes the player jump
player.jump()player.setPosition
Parameters
Type
Description
x
double
x coordinate
y
double
y coordinate
z
double
z coordinate
player.setPosition(x,y,z)player.getBaseMoveSpeed
Returns the player base move speed
player.getBaseMoveSpeed() - doubleplayer.setSpeed
Sets the player speed
Parameters
Type
speed
double
player.setSpeed(speed);player.getSpeed
Returns the player motion speed
player.getSpeed() - doubleplayer.isOnGround
Returns the ground state of a player
player.isOnGround() - booleanplayer.setOnGround
Sets player ground state
Parameters
Type
state
boolean
player.setOnGround(state);player.getName
Returns the player name
player.getName() - stringplayer.getLastTickDistance
Returns the distance travelled during the last tick
player.getLastTickDistance() - doubleplayer.getHeldItemName
Returns unlocalized name of the held item
player.getHeldItemName() - stringplayer.getHeldItemDisplayName
Returns the display name of the held item
player.getDisplayName() - stringplayer.getTagCompound
Returns the tag compound string of the held item
player.getTagCompound() - stringplayer.setMotionX
Sets the player motion X. Returns the motion you set
Parameters
Type
motionX
double
player.setMotionX(motionX) - doubleplayer.setMotionY
Sets the player motion Y. Returns the motion you set
Parameters
Type
motionY
double
player.setMotionY(motionY) - doubleplayer.setMotionZ
Sets the player motion Z. Returns the motion you set
Parameters
Type
motionZ
double
player.setMotionY(motionZ) - doubleplayer.getX
Returns the X position of a player
player.getX() - doubleplayer.getY
Returns the Y position of a player
player.getY() - doubleplayer.getZ
Returns the Z position of a player
player.getZ() - doubleplayer.setX
Sets the X position for the player. Returns the position you set
Parameters
Type
x
double
player.setX(x) - doubleplayer.setY
Sets the Y position for the player. Returns the position you set
Parameters
Type
y
double
player.setY(y) - doubleplayer.setZ
Sets the Z position for the player. Returns the position you set
Parameters
Type
z
double
player.setZ(z) - doubleplayer.attackEntity
Attacks the entity you provide
Parameters
Type
entity
Entity
player.attackEntity(entity)player.getDistanceToEntity
Returns a distance from the player to an entity in blocks
Parameters
Type
entity
Entity
player.getDistanceToEntity(entity)player.getDistanceToEntity2D
Returns a distance from the player to an entity in blocks (XZ axis only)
Parameters
Type
entity
Entity
player.getDistanceToEntity2D(entity)player.swingItem
Makes the player swing the item
player.swingItem()player.getFallDistance
Returns player's fall distance in blocks
player.getFallDistance() - doubleplayer.getHeldItem
Returns the held item of a player
player.getHeldItem() - ItemStackplayer.isMoving
Returns true if the player is moving
player.isMoving() - booleanplayer.getHealth
Returns the health of the player (number of hearts multiplied by 2)
player.getHealth() - doubleplayer.sendMessage
Sends the message you provide in the chat
Parameters
Type
message
String
player.sendMessage(message)player.getDisplayName
Returns the display name of a player
player.getDisplayName()player.setSlot
Sets the current slot to the slot you provide
Parameters
Type
slotId
Integer
player.setSlot(slotId)player.getHurtTime
Returns the hurt timer of the player
player.getHurtTime() - Integerplayer.getHurtResistantTimer
Returns the hurt resistant time of a player
player.getHurtResistantTime() - Integerplayer.getFoodLevel
Returns the food level of a player
player.getFoodLevel() - Integerplayer.isBurning
Returns true if the player is burning
player.isBurning() - booleanplayer.leftClick
Left clicks
player.leftClick()player.rightClick
Right Clicks
player.rightClick()player.isInWater
Returns true if the player is in water
player.isInWater() - booleanplayer.isInLava
Returns true if the player is in lava
player.isInLava() - booleanplayer.isSneaking
Returns true if the player is sneaking
player.isSneaking() - booleanplayer.setSneaking
Sets the player's sneaking state
Parameters
Type
state
Boolean
player.setSneaking(state)player.isRiding
Returns true if the player is riding an entity
player.isRiding() - Booleanplayer.isCollidedVertically
Returns true if the player is collided vertically
player.isCollidedVertically() - Booleanplayer.isCollidedHorizontally
Returns true if the player is collided vertically
player.isCollidedHorizontally() - Booleanplayer.ticksExisted
Returns the amount of ticks player exists in the world
player.ticksExisted() - Integerplayer.setYaw
Sets the player rotation yaw
Parameters
Type
angle
float
player.setYaw(angle)player.setPitch
Sets the player rotation pitch
Parameters
Type
angle
float
player.setPitch(angle)player.getUUID
Returns the unique ID of the player
player.getUUID() - UUIDplayer.getPrevPosX
Returns the previous position X of the player
player.getPrevPosX() - doubleplayer.getPrevPosY
Returns the previous position Y of the player
player.getPrevPosY() - doubleplayer.getPrevPosZ
Returns the previous position Z of the player
player.getPrevPosZ() - doubleLast updated
Was this helpful?