self:set_shape_separation_ray
Client
Assigns a separation ray shape to the collision shape, which helps a body smoothly stay on top of geometry without catching on edges
Syntax
local status = self:set_shape_separation_ray(
length
)Parameters
| Type | Name | Description |
|---|---|---|
float | length | Ray length to apply |
Returns
| Type | Name | Description |
|---|---|---|
bool | status | true on successful execution, false otherwise |
Examples
local body = physics.rigid.create()
local entity = physics.collision_shape.create(body)
entity:set_shape_separation_ray(1.0)