clientEntity

A client entity, such as other players.

To see the type of an individual property, please look at the struct here.

Available Properties

  • clientNumber

  • origin

  • angles

  • isAlive

  • isOnGround

  • team

Methods

getName()

Returns the name of this player.

Example:

-- Print closest players name
local closestPlayer = engine.getClosestPlayer()
print("The closest player is: " .. closestPlayer:getName())

getBoneOrigin(bone)

  • bone - The bone you wish to get the origin for

Returns the origin of the given bone of this clientEntity as a Vec3

Available Bones:

  • head

  • helmet

  • spine

  • neck

  • pelvis

Example:

-- The head position of the closest player
local closestPlayer = engine.getClosestPlayer()
local head = closestPlayer:getBoneOrigin("head")
print("The closest players head is at " .. head:toString())

Find the type of properties here

struct clientEntity
{
 	int clientNumber;
	Vec3 origin;
	Vec3 angles;
	bool isAlive;
	bool isOnGround;
	bool isInAir;
};

Last updated