Collision Shape

self:translate

Shared

Translates the collision shape by an offset in the parent's coordinate space

Syntax

local status = self:translate(
    offset
)

Parameters

TypeNameDescription
vector3offsetOffset to translate by as {x, y, z}

Returns

TypeNameDescription
boolstatustrue on successful execution, false otherwise

Examples

Translate a collision shape
local entity = physics.collision_shape.create()

entity:translate({0, 1, 0})

On this page