sm.areaTrigger.createBoxWater
Creates a new box area trigger that represent water ie. certain objects cant be placed in it.
Kind: Function
Environments: Game
Game
sm.areaTrigger.createBoxWater(
dimension,
position,
rotation,
filter,
userdata
)
Deprecated: use sm.areaTrigger.createBox with sm.areaTrigger.areaTriggerProxyType instead.
If a filter is specified, the trigger area will only be able to detects objects of that certain type. See sm.areaTrigger.filter for more information about filters.
Parameters:
| Name | Type | Description |
|---|---|---|
dimension |
Vec3 | The dimensions of the box. |
position |
Vec3 | The world position. |
rotation (optional) |
Quat | The world rotation. (Defaults to sm.quat.identity) |
filter (optional) |
integer | The object types the area trigger may detect. (See sm.areaTrigger.filter). (Defaults to sm.areaTrigger.filter.all) |
userdata (optional) |
table | An optional table of user data |
Returns:
| Type | Description |
|---|---|
| AreaTrigger | The created area trigger. |