Description
Changelog
Reviews (2)

BallisticSolutions

Ballistic solutions for moving targets: interception time, position, and firing velocity, accounting for projectile and target acceleration.


Download


Quickstart

  1. Install the addon.
  2. Compute the vector to the target:
    var to_target = target.global_position - global_position
    
  3. Call BsVelocity*D.best_by_speed to get initial projectile velocity.
  4. Instantiate your projectile and assign velocity.

Warning

Godot Physics Consideration:
Godot applies linear damping to physics bodies by default, which gradually reduces object velocity. This can significantly affect ballistic accuracy if not properly accounted for.

Recommendations:

  • Set default_linear_damp = 0 in the project settings, if you want pure projectile motion
  • Test thoroughly with your specific physics settings

Contributing

  • Contributions are welcome. Open an issue or PR.
  • Demo scene is included for testing. Run it in Godot to validate behavior.

How it Works ?

  • The library sets up an interception equation between target and projectile motion and solves for t.
  • Each positive solution t corresponds to a valid hit time and gives a required initial velocity.
  • If no positive solutions exist, interception is impossible with current parameters.

Changelog for version 6.1.0

No changelog provided for this version.

Reviews

Recommended by Permotion - 12 July 2026

Does what it says, little bit confusing but documentation is not bad at all. In other words, even usable for someone that doesn't understand the physics.

Recommended by JekSun - 24 June 2026

Login to write a review.