Class PhysicsSettings
Physics simulation settings container.
Namespace: FlaxEditor.Content.Settings
Assembly: FlaxEngine.CSharp.dll
Syntax
public sealed class PhysicsSettings : SettingsBase
Constructors
PhysicsSettings()
Fields
BounceThresholdVelocity
Minimum relative velocity required for an object to bounce. A typical value for simulation stability is about 0.2 * gravity
Declaration
[EditorOrder(30)]
[EditorDisplay("Simulation", null)]
public float BounceThresholdVelocity
Field Value
System.Single
|
BroadPhaseType
Broad phase algorithm to use in the simulation.
Declaration
[EditorOrder(71)]
[EditorDisplay("Simulation", null)]
public PhysicsBroadPhaseType BroadPhaseType
Field Value
PhysicsBroadPhaseType
|
DefaultGravity
The default gravity force value (in cm^2/s).
Declaration
[EditorOrder(0)]
[EditorDisplay("Simulation", null)]
public Vector3 DefaultGravity
Field Value
Vector3
|
DisableCCD
If true CCD will be ignored. This is an optimization when CCD is never used which removes the need for physics to check it internally.
Declaration
[EditorOrder(70)]
[EditorDisplay("Simulation", null)]
public bool DisableCCD
Field Value
System.Boolean
|
EnableEnhancedDeterminism
Enables enhanced determinism in the simulation. This has a performance impact.
Declaration
[EditorOrder(71)]
[EditorDisplay("Simulation", null)]
public bool EnableEnhancedDeterminism
Field Value
System.Boolean
|
EnableSubstepping
Whether to substep the physics simulation.
Declaration
[EditorOrder(1005)]
[EditorDisplay("Framerate", null)]
public bool EnableSubstepping
Field Value
System.Boolean
|
FrictionCombineMode
Default friction combine mode, controls how friction is computed for multiple materials.
Declaration
[EditorOrder(40)]
[EditorDisplay("Simulation", null)]
public PhysicsCombineMode FrictionCombineMode
Field Value
PhysicsCombineMode
|
LayerMasks
The collision layers masks. Used to define layer-based collision detection.
Declaration
[EditorOrder(1040)]
[EditorDisplay("Layers Matrix", null)]
[CustomEditor]
public uint[] LayerMasks
Field Value
System.UInt32[]
|
MaxDeltaTime
The maximum allowed delta time (in seconds) for the physics simulation step.
Declaration
[EditorOrder(1000)]
[EditorDisplay("Framerate", null)]
public float MaxDeltaTime
Field Value
System.Single
|
MaxSubsteps
The maximum number of substeps for physics simulation.
Declaration
[EditorOrder(1020)]
[EditorDisplay("Framerate", null)]
public int MaxSubsteps
Field Value
System.Int32
|
QueriesHitTriggers
If enabled, any Raycast or other scene query that intersects with a Collider marked as a Trigger will returns with a hit. Individual raycasts can override this behavior.
Declaration
[EditorOrder(1200)]
[EditorDisplay("Other", null)]
public bool QueriesHitTriggers
Field Value
System.Boolean
|
RestitutionCombineMode
Default restitution combine mode, controls how restitution is computed for multiple materials.
Declaration
[EditorOrder(40)]
[EditorDisplay("Simulation", null)]
public PhysicsCombineMode RestitutionCombineMode
Field Value
PhysicsCombineMode
|
SolverType
The solver type to use in the simulation.
Declaration
[EditorOrder(73)]
[EditorDisplay("Simulation", null)]
public PhysicsSolverType SolverType
Field Value
PhysicsSolverType
|
SubstepDeltaTime
Delta time (in seconds) for an individual simulation substep.
Declaration
[EditorOrder(1010)]
[EditorDisplay("Framerate", null)]
public float SubstepDeltaTime
Field Value
System.Single
|
SupportCookingAtRuntime
Enables support for cooking physical collision shapes geometry at runtime. Use it to enable generating runtime terrain collision or convex mesh colliders.
Declaration
[EditorOrder(1100)]
[EditorDisplay("Other", null)]
public bool SupportCookingAtRuntime
Field Value
System.Boolean
|
TriangleMeshTriangleMinAreaThreshold
Triangles from triangle meshes (CSG) with an area less than or equal to this value will be removed from physics collision data. Set to less than or equal 0 to disable.
Declaration
[EditorOrder(1110)]
[EditorDisplay("Other", null)]
public float TriangleMeshTriangleMinAreaThreshold
Field Value
System.Single
|