self:get_position

Client

Retrieves the local position of the collision shape


Syntax

local position = self:get_position()

Parameters

No parameters are accepted by this function

Returns

TypeNameDescription
vector3positionCurrent local position as {x, y, z}

Examples

Get the local position of a collision shape
local entity = physics.collision_shape.create()
local position = entity:get_position()

core.engine.print("info", "Collision shape position:", util.table.unpack(position))

On this page