Navigation
API > API/Runtime > API/Runtime/ChaosVehiclesCore
Interface base class for all simulation module building blocks
| Name | ISimulationModuleBase |
| Type | class |
| Header File | /Engine/Source/Runtime/Experimental/ChaosVehicles/ChaosVehiclesCore/Public/SimModule/SimulationModuleBase.h |
| Include Path | #include "SimModule/SimulationModuleBase.h" |
Syntax
class ISimulationModuleBase :
public Chaos::FSimulationModuleTypeContainer ,
public Chaos::TSimulationModuleTypeableBase< ISimulationModuleBase >
Inheritance Hierarchy
- FSimulationModuleTypeContainer → ISimulationModuleBase
- TSimulationModuleTypeableBase → ISimulationModuleBase
Derived Classes
ISimulationModuleBase derived class hierarchy
Constructors
| Name | Remarks | Include Path | Unreal Specifiers |
|---|---|---|---|
ISimulationModuleBase() |
SimModule/SimulationModuleBase.h |
Destructors
| Name | Remarks | Include Path | Unreal Specifiers |
|---|---|---|---|
virtual ~ISimulationModuleBase() |
SimModule/SimulationModuleBase.h |
Constants
| Name | Type | Remarks | Include Path |
|---|---|---|---|
| INVALID_IDX | const int | SimModule/SimulationModuleBase.h |
Variables
Public
| Name | Type | Remarks | Include Path | Unreal Specifiers |
|---|---|---|---|---|
| IsInitialized | bool | SimModule/SimulationModuleBase.h |
Protected
| Name | Type | Remarks | Include Path | Unreal Specifiers |
|---|---|---|---|---|
| FSimOutputData | friend | SimModule/SimulationModuleBase.h |
Functions
Public
| Name | Remarks | Include Path | Unreal Specifiers |
|---|---|---|---|
void AddForceAtCOMPosition
(
const FVector& Force, |
SimModule/SimulationModuleBase.h | ||
void AddLocalForce
(
const FVector& Force, |
Force application function, handles deferred force application and applying the force at the collect location based on whether the GC cluster is intact or fractured Note: forces are applied in local coordinates of the module | SimModule/SimulationModuleBase.h | |
void AddLocalForceAtPosition
(
const FVector& Force, |
Force application function, handles deferred force application and applying the force at the collect location based on whether the GC cluster is intact or fractured Note: forces are applied in local coordinates of the module | SimModule/SimulationModuleBase.h | |
void AddLocalTorque
(
const FVector& Torque, |
Torque application function Note: forces are applied in local coordinates of the module | SimModule/SimulationModuleBase.h | |
virtual void Animate() |
Animate/modify the childToParent transforms, to say rotate a wheel, or rudder, etc | SimModule/SimulationModuleBase.h | |
virtual void DrawDebugInfo() |
Option to draw debug for this module requires CVar p.Chaos.DebugDraw.Enabled 1 | SimModule/SimulationModuleBase.h | |
TSharedPtr< FModuleNetData > GenerateNetData
(
const int32 NodeArrayIndex |
This is the replication datas | SimModule/SimulationModuleBase.h | |
virtual FSimOutputData * GenerateOutputData() |
SimModule/SimulationModuleBase.h | ||
const FSimModuleAnimationData & GetAnimationData() |
SimModule/SimulationModuleBase.h | ||
const FVector & GetAnimationOffset() |
SimModule/SimulationModuleBase.h | ||
int GetAnimationSetupIndex() |
SimModule/SimulationModuleBase.h | ||
const FVector & GetAppliedForce() |
For headless chaos testing | SimModule/SimulationModuleBase.h | |
const FName & GetBoneName() |
SimModule/SimulationModuleBase.h | ||
const FTransform & GetClusteredTransform() |
SimModule/SimulationModuleBase.h | ||
Chaos::FPBDRigidClusteredParticleHandle * GetClusterParticle
(
Chaos::FClusterUnionPhysicsProxy* Proxy |
Void SetClusterParticle(FPBDRigidClusteredParticleHandle* ParticleIn) { ClusterParticle = ParticleIn; } | SimModule/SimulationModuleBase.h | |
const FTransform & GetComponentTransform() |
SimModule/SimulationModuleBase.h | ||
const FString GetDebugName() |
Get the friendly name for this module, primarily for logging & debugging module tree | SimModule/SimulationModuleBase.h | |
virtual bool GetDebugString
(
FString& StringOut |
Option to return debug text for drawing on the HUD in the Game Thread | SimModule/SimulationModuleBase.h | |
ISimulationModuleBase * GetFirstChild() |
SimModule/SimulationModuleBase.h | ||
int GetGuid() |
SimModule/SimulationModuleBase.h | ||
const FTransform & GetInitialParticleTransform() |
SimModule/SimulationModuleBase.h | ||
const FTransform & GetIntactTransform() |
SimModule/SimulationModuleBase.h | ||
const FVector & GetLocalAngularVelocity() |
SimModule/SimulationModuleBase.h | ||
const FVector & GetLocalLinearVelocity() |
SimModule/SimulationModuleBase.h | ||
ISimulationModuleBase * GetParent() |
SimModule/SimulationModuleBase.h | ||
const FTransform & GetParentRelativeTransform() |
The modules transform relative to the simulating body will depend on whether the GC is intact (get the transform relative to intact cluster) or fractured (transform relative to fractured part) | SimModule/SimulationModuleBase.h | |
Chaos::FPBDRigidParticleHandle * GetParticleFromUniqueIndex
(
int32 ParticleUniqueIdx, |
SimModule/SimulationModuleBase.h | ||
const FUniqueIdx GetParticleIndex() |
SimModule/SimulationModuleBase.h | ||
FVehicleBlackboard * GetSimBlackboard() |
SimModule/SimulationModuleBase.h | ||
const int GetTransformIndex() |
SimModule/SimulationModuleBase.h | ||
int GetTreeIndex() |
SimModule/SimulationModuleBase.h | ||
bool IsAnimationEnabled() |
SimModule/SimulationModuleBase.h | ||
bool IsBehaviourType
(
eSimModuleTypeFlags InType |
Is Module of a specific behavioral data type | SimModule/SimulationModuleBase.h | |
bool IsClustered() |
SimModule/SimulationModuleBase.h | ||
virtual bool IsEnabled() |
Is Module active and simulating | SimModule/SimulationModuleBase.h | |
virtual void OnConstruction_External
(
const Chaos::FPhysicsObjectHandle& PhysicsObject |
Any post construction initialisation - called from Game Thread | SimModule/SimulationModuleBase.h | |
virtual void OnContactModification
(
Chaos::FCollisionContactModifier& Modifier, |
SimModule/SimulationModuleBase.h | ||
virtual void OnTermination_External() |
Any cleaning up required - called from game thread | SimModule/SimulationModuleBase.h | |
void SetAnimationData
(
const FName& BoneNameIn, |
SimModule/SimulationModuleBase.h | ||
void SetAnimationEnabled
(
bool bInEnabled |
SimModule/SimulationModuleBase.h | ||
void SetClustered
(
bool IsClusteredIn |
Let the module know if it is still clustered or not | SimModule/SimulationModuleBase.h | |
void SetClusteredTransform
(
const FTransform& TransformIn |
Set the COM relative transform of module when it is clustered, so relative to parent COM | SimModule/SimulationModuleBase.h | |
void SetComponentTransform
(
const FTransform& TransformIn |
SimModule/SimulationModuleBase.h | ||
void SetGuid
(
int GuidIn |
SimModule/SimulationModuleBase.h | ||
void SetInitialParticleTransform
(
const FTransform& TransformIn |
SimModule/SimulationModuleBase.h | ||
void SetIntactTransform
(
const FTransform& TransformIn |
Set the COM relative transform of module when it is broken off, so relative to itself | SimModule/SimulationModuleBase.h | |
void SetLocalAngularVelocity
(
const FVector& VelocityIn |
SimModule/SimulationModuleBase.h | ||
void SetLocalLinearVelocity
(
const FVector& VelocityIn |
Update the module with its current velocity | SimModule/SimulationModuleBase.h | |
void SetParticleIndex
(
FUniqueIdx ParticleIndexIn |
The Particle unique index, should be valid on game and physics threads | SimModule/SimulationModuleBase.h | |
void SetSimModuleTree
(
FSimModuleTree* SimModuleTreeIn |
Very useful to store the simulation tree pointer in which we are stored, then we can access other modules that we reference through an index | SimModule/SimulationModuleBase.h | |
void SetStateFlags
(
eSimModuleState StateFlagsIn |
Set Module state, if simulating or not | SimModule/SimulationModuleBase.h | |
void SetTransformIndex
(
int TransformIndexIn |
The transform index references the transform collection, mapping the simulation module to the geometry collection data | SimModule/SimulationModuleBase.h | |
void SetTreeIndex
(
int TreeIndexIn |
The modules own index in the simulation tree array | SimModule/SimulationModuleBase.h | |
virtual void Simulate
(
float DeltaTime, |
The main Simulation function that is called from the physics async callback thread | SimModule/SimulationModuleBase.h | |
virtual void Simulate
(
IPhysicsProxyBase* Proxy, |
The main Simulation function that is called from the physics async callback thread | SimModule/SimulationModuleBase.h |
Static
| Name | Remarks | Include Path | Unreal Specifiers |
|---|---|---|---|
static FName CHAOSTYPENAMERETRIVAL() |
SimModule/SimulationModuleBase.h |