Calculate Lead Aim Position

Pure
CalculateLeadAimPosition

Calculates where to aim to hit a moving target with a projectile of known speed.

Type: Pure (no side effects)
Category: Fortuna|Gameplay Utilities
Keywords: gameplay utilities

Inputs

NameTypeDefaultDescription
ShooterPositionFVectorShooterPosition parameter
TargetPositionFVectorTargetPosition parameter
TargetVelocityFVectorTargetVelocity parameter
ProjectileSpeedfloatProjectileSpeed parameter

Outputs

NameTypeDescription
AimPositionFVectorAimPosition output
bSolutionFoundboolbSolutionFound output

Example Use Cases

Example 1

AI leading shots on a moving player.

Example 2

Auto-aim assist for slow projectiles.