Model
self:rotate_local
SharedRotates the model around an axis in its own local coordinate space
Syntax
local status = self:rotate_local(
axis,
degrees
)Parameters
| Type | Name | Description |
|---|---|---|
vector3 | axis | Axis to rotate around as {x, y, z} |
float | degrees | Angle to rotate by in degrees |
Returns
| Type | Name | Description |
|---|---|---|
bool | status | true on successful execution, false otherwise |
Examples
core.model.load("character", "models/character.glb")
local entity = core.model.create("character")
entity:rotate_local({0, 1, 0}, 45)