Class PhysicsHelper
Hierarchy
- PhysicsHelper
Index
Constructors
Methods
Constructors
constructor
-
Initializes the Physics helper
Parameters
-
scene: Scene
Babylon.js scene
Returns PhysicsHelper
-
Methods
apply Radial Explosion ForceSearch playground for applyRadialExplosionForce
-
Applies a radial explosion force
Parameters
-
origin: Vector3
the origin of the explosion
-
radiusOrEventOptions: number | PhysicsRadialExplosionEventOptions
the radius or the options of radial explosion
-
Optional strength: number
the explosion strength
-
Optional falloff: PhysicsRadialImpulseFalloff
possible options: Constant & Linear. Defaults to Constant
Returns Nullable<PhysicsRadialExplosionEvent>
A physics radial explosion event, or null
-
apply Radial Explosion ImpulseSearch playground for applyRadialExplosionImpulse
-
Applies a radial explosion impulse
Parameters
-
origin: Vector3
the origin of the explosion
-
radiusOrEventOptions: number | PhysicsRadialExplosionEventOptions
the radius or the options of radial explosion
-
Optional strength: number
the explosion strength
-
Optional falloff: PhysicsRadialImpulseFalloff
possible options: Constant & Linear. Defaults to Constant
Returns Nullable<PhysicsRadialExplosionEvent>
A physics radial explosion event, or null
-
gravitational FieldSearch playground for gravitationalField
-
Creates a gravitational field
Parameters
-
origin: Vector3
the origin of the explosion
-
radiusOrEventOptions: number | PhysicsRadialExplosionEventOptions
the radius or the options of radial explosion
-
Optional strength: number
the explosion strength
-
Optional falloff: PhysicsRadialImpulseFalloff
possible options: Constant & Linear. Defaults to Constant
Returns Nullable<PhysicsGravitationalFieldEvent>
A physics gravitational field event, or null
-
updraftSearch playground for updraft
-
Creates a physics updraft event
Parameters
-
origin: Vector3
the origin of the updraft
-
radiusOrEventOptions: number | PhysicsUpdraftEventOptions
the radius or the options of the updraft
-
Optional strength: number
the strength of the updraft
-
Optional height: number
the height of the updraft
-
Optional updraftMode: PhysicsUpdraftMode
possible options: Center & Perpendicular. Defaults to Center
Returns Nullable<PhysicsUpdraftEvent>
A physics updraft event, or null
-
vortexSearch playground for vortex
-
Creates a physics vortex event
Parameters
-
origin: Vector3
the of the vortex
-
radiusOrEventOptions: number | PhysicsVortexEventOptions
the radius or the options of the vortex
-
Optional strength: number
the strength of the vortex
-
Optional height: number
the height of the vortex
Returns Nullable<PhysicsVortexEvent>
a Physics vortex event, or null A physics vortex event or null
-
A helper for physics simulations
https://doc.babylonjs.com/how_to/using_the_physics_engine#further-functionality-of-the-impostor-class