PhysicsGetChildShapes
Jump to navigation
Jump to search
Returns all child shape of compound shape.
Syntax
table physicsGetChildShapes(physics-shape compoundShape)
Required Arguments
- compoundShape: Must be compound shape
Returns
Returns table of all shapes. {shape, shape, shape, ...}. False otherwise
Example
Creates something that reminds chain
local compound = physicsCreateShape(physics, "compound") local capsule = physicsCreateShape(physics, "capsule", 1, 1) physicsAddChildShape(compound, capsule) physicsAddChildShape(compound, capsule) physicsAddChildShape(compound, capsule) local childShapes = physicsGetChildShapes(compound); outputChatBox("Your compound shape is made of ".. #childShapes .. " capsules")
See Also
- physicsCreateWorld
- physicsDestroy
- physicsCreateShape
- physicsCreateShapeFromModel
- physicsCreateRigidBody
- physicsCreateStaticCollision
- physicsCreateConstraint
- physicsAddChildShape
- physicsRemoveChildShape
- physicsGetChildShapes
- physicsSetChildShapeOffsets
- physicsGetChildShapeOffsets
- physicsGetShapes
- physicsGetRigidBodies
- physicsGetStaticCollisions
- physicsGetConstraints
- physicsSetProperties
- physicsGetProperties
- physicsDrawDebug
- physicsSetDebugMode
- physicsBuildCollisionFromGTA
- physicsApplyVelocity
- physicsApplyVelocityForce
- physicsApplyAngularVelocity
- physicsApplyAngularVelocityForce
- physicsApplyDamping
- physicsRayCast
- physicsShapeCast
- physicsGetElementType
- physicsIsElement