player
Local player related functions
player.jump
Makes the local player jump
player.click_mouse
Left clicks
player.right_click_mouse
Right clicks
player.message
Sends a message in chat, can also run client commands such as ".killaura" to toggle modules or set any option.
player.strafe
Returns the forward and strafing speed the player is moving at
player.position
Returns the player's x, y and z positions.
player.camera_position
Returns the camera's x, y and z positions.
player.prev_position
Returns the player's previous x, y and z positions.
player.motion
Returns the player's x, y and z motion amount.
player.set_motion
Sets the local player motion
player.set_position
Sets the local player position
player.set_sprinting
Sets local player's sprinting state
player.distance_to_entity
Returns the distance in blocks between you and the entity.
player.distance_to
Returns the distance in blocks between you and the coordinates.
player.send_packet
Sends a packet to the server.
Packet IDs can be found here: https://wiki.vg/index.php?title=Protocol&oldid=7368#Serverbound_2
Packets supported: 0x0A, 0x07, 0x08, 0x0B, 0x03, 0x04, 0x05, 0x06, 0x07, 0x0F
player.angles
Returns yaw and pitch.
player.prev_angles
Returns prev yaw and prev pitch.
player.set_angles
Sets the player in-game look angles
player.using_item
Returns if the player is using an item or not.
player.swing_item
Swings the item
player.use_item
Uses the item you're holding
player.id
Returns your current player entity ID
player.health
Returns your current player health, divide by two for getting heart amount
player.fall_distance
Returns the amount of blocks you're falling
player.max_health
Returns the max amount of health your player can have, divide by two for getting hearts
player.held_item
Returns the name of the item you're holding
player.name
Returns the player name
player.base_speed
Returns the base speed amount, used for speed calculations.
player.held_item_slot
Returns the slot number of the item you're holding. Counting from 1 to 9
player.set_held_item_slot
Sets your hotbar slot to the desired one
player.hurt_time
Returns how much ticks of hurt time left
player.food_stats
Returns the hunger you have, divide by two to get muslito amount
player.absorption
Returns amount of yellow health that you have, divide by two to get heart amount
player.eye_height
Returns
player.facing
This function will return a direction on a number.
1: Down 2: Up 3: North 4: South 5: West 6: East
player.over_mouse
This function will return different values depending on the first returned number.
If the first number is 1, this means your player is not aiming at anything.
If the number is 3, this means its aiming at an entity, second number will return the index of that entity
If the number is 2, this means its aiming at a block, will return side_hit, block_x, block_x, block_x, hit_x, hit_y, hit_z
player.convert_speed
This function will return a table that sets the on_player_move
table values to ones that will make the player strafe according to the speed assigned
player.kill_aura_target
Returns the player id of KillAura's target
player.on_ground
Returns if the player is on the ground
player.is_in_water
Returns if the player is in water
player.is_in_lava
Returns if the player is in lava
player.burning
Returns if the player is currently burning
player.is_sneaking
Returns if the player is currently sneaking
player.set_sneaking
player.is_in_cobweb
Returns if the player is currently in a cobweb
player.angles_for_cords
This function returns a yaw and pitch to look at the desired coordinates.
player.dead
Returns if the player is currently dead
player.sprinting
Returns if the player is currently sprinting
player.riding
Returns if the player is currently riding an entity
player.on_ladder
Returns if the player is currently on a ladder
player.collided_vertically
Returns if the player is currently colliding with any block vertically
player.collided_horizontally
Returns if the player is currently colliding with any block horizontally
player.is_potion_active
Returns if the desired potion is currently active
player.ticks_existed
Returns the amount of ticks the player has existed in the world
player.ray_cast
This function will return different values depending on the first returned number.
If the first number is 1, this means your player is not aiming at anything.
If the number is 3, this means its aiming at an entity, second number will return the index of that entity
If the number is 2, this means its aiming at a block, will return side_hit, block_x, block_x, block_x, hit_x, hit_y, hit_z
player.place_block
hit_x
, hit_y
and hit_z
are values used to check where the actual placement took place, this are the values sent to the server in the 0x08 packet
This means that the hit_* values you'll put in the function will be applied to the example shown before
Places a block
player.is_on_edge
Returns if the player is at the edge of a block
player.get_speed
Returns the players speed
player.set_speed
Sets the player's speed
Last updated