Navigation
API > API/Plugins > API/Plugins/AudioMotorSimStandardComponents
Uses throttle input to run a physics simulation to drive RPM and shift gears when needed.
| Name | UMotorPhysicsSimComponent |
| Type | class |
| Header File | /Engine/Plugins/Runtime/AudioMotorSim/Source/AudioMotorSimStandardComponents/Public/MotorPhysicsSimComponent.h |
| Include Path | #include "MotorPhysicsSimComponent.h" |
Syntax
UCLASS (ClassGroup="AudioMotorSim", Meta=(BlueprintSpawnableComponent))
class UMotorPhysicsSimComponent : public UAudioMotorSimComponent
Inheritance Hierarchy
- UObjectBase → UObjectBaseUtility → UObject → UActorComponent → UAudioMotorSimComponent → UMotorPhysicsSimComponent
Implements Interfaces
Variables
Public
| Name | Type | Remarks | Include Path | Unreal Specifiers |
|---|---|---|---|---|
| bAlwaysDownshiftToZerothGear | bool | If enabled, will always downshift to 0th gear when a downshift occurs. | MotorPhysicsSimComponent.h |
|
| BrakingHorsePower | float | The force applied when braking. Large values will slow down the vehicle more quickly. | MotorPhysicsSimComponent.h |
|
| bUseInfiniteGears | bool | If true, the model will keep upshifting past the last defined gear. Gear ratio will be defined by the InfiniteGearRatio param. | MotorPhysicsSimComponent.h |
|
| ClutchedDecelScale | float | How much more quickly the engine decelerates off-throttle while clutched. | MotorPhysicsSimComponent.h |
|
| ClutchedForceModifier | float | Engine Torque multiplier applied when clutched. | MotorPhysicsSimComponent.h |
|
| ClutchedGearRatio | float | The gear ratio to apply when clutched. | MotorPhysicsSimComponent.h |
|
| DownShiftStartRpm | float | The rpm at which a downshift occurs. | MotorPhysicsSimComponent.h |
|
| EngineFriction | float | How much of the torque is lost due to engine friction. | MotorPhysicsSimComponent.h |
|
| EngineGearRatio | float | The main gear ratio of the engine. | MotorPhysicsSimComponent.h |
|
| EngineTorque | float | The force of the engine. Large values will accelerate the vehicle more quickly, but also apply more friction when engine braking. | MotorPhysicsSimComponent.h |
|
| GearRatios | TArray< float > | How each gear responds to speed, expressed as a ratio. Higher number means a larger RPM range within that gear and quicker progression through the gear. | MotorPhysicsSimComponent.h |
|
| GroundFriction | float | Coefficient of Rolling Resistance. | MotorPhysicsSimComponent.h |
|
| InfiniteGearRatio | float | How much to scale gear ratio per gear past the max gear | MotorPhysicsSimComponent.h |
|
| OnGearChangedEvent | FOnGearChanged | MotorPhysicsSimComponent.h |
|
|
| RpmInterpSpeed | float | Interpolation value to when changing RPM. | MotorPhysicsSimComponent.h |
|
| ThrottleInterpolationTime | float | MotorPhysicsSimComponent.h |
|
|
| UpShiftMaxRpm | float | The rpm at which an upshift occurs. | MotorPhysicsSimComponent.h |
|
| Weight | float | The weight of the vehicle, used to calculate the generated RPM. Heavier weight means a slower rpm increase due to weight resistance and ground friction. | MotorPhysicsSimComponent.h |
|
| WindResistancePerVelocity | float | Multiplier to apply to the velocity value to calculate wind resistance. | MotorPhysicsSimComponent.h |
|
Functions
Public
Overridden from IAudioMotorSim
| Name | Remarks | Include Path | Unreal Specifiers |
|---|---|---|---|
virtual void ConfigMotorSim
(
const FInstancedStruct& InConfigData |
MotorPhysicsSimComponent.h | ||
virtual void Update
(
FAudioMotorSimInputContext& Input, |
MotorPhysicsSimComponent.h |