You are here: Lua Scripting Resources eGuide > Lua Scripting API Reference Guide > Physics Library > setGroup

19.5.14 setGroup

self = physics.Shape:setGroup(group)

Parameter

Type

Description

self

in physics.Shape

The input Shape

group

in number

Group number

self

out physics.Shape

The input Shape is returned as the output

Sets the group (a number defined by the programmer) of the shape. Shapes in the same group do not generate collisions. Returns self.

Note

The group number is converted to a positive whole number when stored.

Introduced in platform.apiLevel = '2.0'