self:get_up_direction
Client
Retrieves the up direction used by the character body to determine floor, wall, and ceiling surfaces
Syntax
local direction = self:get_up_direction()Parameters
| No parameters are accepted by this function |
|---|
Returns
| Type | Name | Description |
|---|---|---|
vector3 | direction | Current up direction as {x, y, z} |
Examples
local entity = physics.character.create()
local direction = entity:get_up_direction()
core.engine.print("info", "Character body direction:", util.table.unpack(direction))