#include <ComposableCameraLockOnAimPointNode.h>
Inherits:
UComposableCameraCameraNodeBase
Builds a per-frame virtual aim point for lock-on composition.
Intended placement:
ScreenSpacePivot(follow) -> LockOnAimPoint -> ScreenSpacePivot(aim).
Public Attributes¶
| Return | Name | Description |
|---|---|---|
EComposableCameraLockOnAimPointSource |
FollowSource |
How the player/follow point is resolved at runtime. |
EComposableCameraActorInputSource |
FollowActorSource |
Selects whether the follow actor is the controller's controlled pawn or an explicit actor. |
FVector |
FollowWorldPosition |
Follow pivot in world space. Used when FollowSource == WorldPosition. |
TObjectPtr< AActor > |
FollowActor |
Actor whose world location supplies the follow point. Used when FollowSource == ActorPosition. |
float |
FollowWorldUpOffset |
World-up offset added to FollowActor->GetActorLocation(). |
EComposableCameraLockOnAimPointSource |
AimSource |
How the lock target/aim point is resolved at runtime. |
EComposableCameraActorInputSource |
AimActorSource |
Selects whether the aim actor is the controller's controlled pawn or an explicit actor. |
FVector |
AimWorldPosition |
Raw lock target pivot in world space. Used when AimSource == WorldPosition. |
TObjectPtr< AActor > |
AimActor |
Actor whose world location supplies the raw aim point. Used when AimSource == ActorPosition. |
float |
AimWorldUpOffset |
World-up offset added to AimActor->GetActorLocation(). |
float |
Radius |
Minimum horizontal projected distance before correction activates. |
FVector2D |
PitchRange |
Min/max pitch in degrees used by the pitch-preserving term while inside Radius. |
float |
BlendOutTime |
Seconds used to fade the correction offset back to zero after leaving Radius. |
FVector |
Weights |
Blend weights for pitch-preserving, camera-to-aim, and camera-forward additions. |
FollowSource¶
EComposableCameraLockOnAimPointSource FollowSource { EComposableCameraLockOnAimPointSource::WorldPosition }
How the player/follow point is resolved at runtime.
FollowActorSource¶
EComposableCameraActorInputSource FollowActorSource { EComposableCameraActorInputSource::ExplicitActor }
Selects whether the follow actor is the controller's controlled pawn or an explicit actor.
FollowWorldPosition¶
FVector FollowWorldPosition { FVector::ZeroVector }
Follow pivot in world space. Used when FollowSource == WorldPosition.
FollowActor¶
TObjectPtr< AActor > FollowActor { nullptr }
Actor whose world location supplies the follow point. Used when FollowSource == ActorPosition.
FollowWorldUpOffset¶
float FollowWorldUpOffset { 0.f }
World-up offset added to FollowActor->GetActorLocation().
AimSource¶
EComposableCameraLockOnAimPointSource AimSource { EComposableCameraLockOnAimPointSource::WorldPosition }
How the lock target/aim point is resolved at runtime.
AimActorSource¶
EComposableCameraActorInputSource AimActorSource { EComposableCameraActorInputSource::ExplicitActor }
Selects whether the aim actor is the controller's controlled pawn or an explicit actor.
AimWorldPosition¶
FVector AimWorldPosition { FVector::ZeroVector }
Raw lock target pivot in world space. Used when AimSource == WorldPosition.
AimActor¶
TObjectPtr< AActor > AimActor { nullptr }
Actor whose world location supplies the raw aim point. Used when AimSource == ActorPosition.
AimWorldUpOffset¶
float AimWorldUpOffset { 0.f }
World-up offset added to AimActor->GetActorLocation().
Radius¶
float Radius { 500.f }
Minimum horizontal projected distance before correction activates.
PitchRange¶
FVector2D PitchRange { -45.f, 45.f }
Min/max pitch in degrees used by the pitch-preserving term while inside Radius.
BlendOutTime¶
float BlendOutTime { 0.15f }
Seconds used to fade the correction offset back to zero after leaving Radius.
Weights¶
FVector Weights { 0.2f, 0.5f, 0.3f }
Blend weights for pitch-preserving, camera-to-aim, and camera-forward additions.
Public Methods¶
| Return | Name | Description |
|---|---|---|
UComposableCameraLockOnAimPointNode inline |
||
void |
OnInitialize_Implementation virtual |
|
void |
OnTickNode_Implementation virtual |
|
void |
GetPinDeclarations_Implementation virtual const |
|
void |
DrawNodeDebug virtual const |
Draws the stable aim-point gizmo when viewport debug is enabled. |
UComposableCameraLockOnAimPointNode¶
inline
inline UComposableCameraLockOnAimPointNode()
OnInitialize_Implementation¶
virtual
virtual void OnInitialize_Implementation()
OnTickNode_Implementation¶
virtual
virtual void OnTickNode_Implementation(float DeltaTime, const FComposableCameraPose & CurrentCameraPose, FComposableCameraPose & OutCameraPose)
GetPinDeclarations_Implementation¶
virtual const
virtual void GetPinDeclarations_Implementation(TArray< FComposableCameraNodePinDeclaration > & OutPins) const
DrawNodeDebug¶
virtual const
virtual void DrawNodeDebug(UWorld * World, bool bViewerIsOutsideCamera) const
Draws a blue sphere at the stable virtual aim point when CCS.Debug.Viewport.LockOnAimPoint 1 is enabled, or when CCS.Debug.Viewport.Nodes.All 1 enables all node gizmos. During correction and F8 eject, draws a line from the raw aim point to the corrected aim point. Compiled out in shipping builds.
Private Attributes¶
| Return | Name | Description |
|---|---|---|
FComposableCameraLockOnAimPointState |
AimPointState |
Runtime state used to retain and blend out the current correction offset. |
FVector |
LastRawAimPosition |
Last raw aim point cached for non-shipping viewport debug drawing. |
FVector |
LastOutputPivotPosition |
Last stable aim point cached for non-shipping viewport debug drawing. |
bool |
bLastAppliedCorrection |
Whether the last output differed from the raw aim point. |