Platforms to show: All Mac Windows Linux Cross-Platform
SCNPhysicsWorldMBS class
Type | Topic | Plugin | Version | macOS | Windows | Linux | iOS | Targets |
class | SceneKit | MBS Mac64bit Plugin | 20.2 | ✅ Yes | ❌ No | ❌ No | ✅ Yes | Desktop & iOS |
You do not create SCNPhysicsWorldMBS objects directly; instead, read the physicsWorld property of an SCNSceneMBS object. Use physics world object to perform the following tasks:
- Manage global properties of the simulation, such as its speed and constant gravity. (For more precise control of gravity and similar effects, see the SCNPhysicsFieldMBS class.)
- Register behaviors that modify interactions between the scene’s physics bodies, such as joints and vehicles. For more details, see SCNPhysicsBehaviorMBS.
- Specify a delegate object to receive messages when two physics bodies contact each other
- Perform specific contact tests, and search for physics bodies in the scene using ray and sweep tests.
- 3 events
- event didBeginContact(contact as SCNPhysicsContactMBS)
- event didEndContact(contact as SCNPhysicsContactMBS)
- event didUpdateContact(contact as SCNPhysicsContactMBS)
- 4 properties
- property gravity as SCNVector3MBS
- property Handle as Integer
- property speed as Double
- property timeStep as Double
- 11 methods
- method addBehavior(behavior as SCNPhysicsBehaviorMBS)
- method allBehaviors as SCNPhysicsBehaviorMBS()
- method Constructor(fireContactEvents as Boolean = false)
- method contactTest(body as SCNPhysicsBodyMBS, options as Dictionary = nil) as SCNPhysicsContactMBS()
- method contactTest(bodyA as SCNPhysicsBodyMBS, bodyB as SCNPhysicsBodyMBS, options as Dictionary = nil) as SCNPhysicsContactMBS()
- method convexSweepTest(shape as SCNPhysicsShapeMBS, fromTransform as SCNMatrix4MBS, toTransform as SCNMatrix4MBS, options as Dictionary = nil) as SCNPhysicsContactMBS()
- method EnableContactsEvents
- method rayTestWithSegment(origin as SCNVector3MBS, dest as SCNVector3MBS, options as Dictionary = nil) as SCNPhysicsBehaviorMBS()
- method removeAllBehaviors
- method removeBehavior(behavior as SCNPhysicsBehaviorMBS)
- method updateCollisionPairs
- 6 shared methods
- shared method SCNPhysicsTestBackfaceCullingKey as String
- shared method SCNPhysicsTestCollisionBitMaskKey as String
- shared method SCNPhysicsTestSearchModeAll as String
- shared method SCNPhysicsTestSearchModeAny as String
- shared method SCNPhysicsTestSearchModeClosest as String
- shared method SCNPhysicsTestSearchModeKey as String
This class has no sub classes.
Some properties using for this class:
- SCNSceneMBS.physicsWorld as SCNPhysicsWorldMBS
Blog Entries
- MonkeyBread Software Releases the MBS Xojo Plugins in version 20.2
- MBS Xojo Plugins, version 20.2pr2
Videos
Release notes
- Version 20.2
- Added SCNPhysicsWorldMBS class and related classes for physics.
The items on this page are in the following plugins: MBS Mac64bit Plugin.
SCNPhysicsVehicleWheelMBS - SCNPlaneMBS