ULimenWeaponFireMethod
Overview
ULimenWeaponFireMethod is a base class that provides a blueprint for implementing various weapon firing behaviors. It supports customization and extension for specific use cases, making it suitable for different types of weapons within the game.
Properties
Type | Name | Access | Description |
|---|---|---|---|
bool | bDebugMode | EditDefaultsOnly | Enables debug mode to visualize bullet tracers and hit detection. |
ECollisionChannel | TraceChannel | EditDefaultsOnly | Specifies the collision channel for line tracing. |
UMaterialInterface | BulletHoleDecalMaterial | EditDefaultsOnly | Material used for bullet hole decals. |
UNiagaraSystem | BulletTracer | EditDefaultsOnly | Niagara system for bullet tracers. |
float | BulletTracerSpeed | EditDefaultsOnly | Speed at which bullet tracers move. |
float | TracerLifetimeSeconds | EditDefaultsOnly | Duration for which bullet tracers are visible. |
FVector | DecalSize | EditDefaultsOnly | Size of the bullet hole decals. |
float | DecalLifetime | EditDefaultsOnly | Lifetime of bullet hole decals in seconds. |
Functions
Return Type | Signature | Description |
|---|---|---|
void | ProcessFire(ALimenWeapon* Weapon, const uint64 ShotsToSimulate) | Processes the firing logic for a weapon. |
bool | IsSupportedForNetworking() const override | Determines if the class is supported for networking. |
int32 | GetFunctionCallspace(UFunction* Function, FFrame* Stack) override | Gets the function callspace based on network replication rules. |
bool | CallRemoteFunction(UFunction* Function, void* Parameters, FOutParmRec* OutParms, FFrame* Stack) override | Calls a remote function if necessary. |
Usage & Implementation Notes
Threading Constraints: This class is designed to be tickable and can operate in both the editor and game modes.
Replication Requirements: The class supports network replication for bullet tracers and decals through multicast RPCs.
Memory Lifetime Management: Bullet tracer components are destroyed when their lifetime expires, ensuring efficient memory management.
Initialization Dependencies: The
ULimenLineTraceFireMethodconstructor initializes default values for various properties.