Ballistic Trajectory Turret Demo
Unity tech demo solving projectile-arc firing solutions for a turret against static and moving targets, with a live tuning UI.

A small Unity 2018.3 tech demo built to evaluate ballistic-arc math for an artillery/shooting mechanic: a turret automatically tracks a target, computes a valid projectile launch velocity for the current gravity and muzzle speed, and fires along a physically simulated arc.
Two aiming modes were implemented: a standard high/low arc solver against static or moving targets, and a 'lateral' mode that solves for a fixed apex height, useful for lobbing shots over obstacles. A runtime UI (sliders) exposes projectile velocity, gravity, turret height, target height/distance and rate of fire, plus a ground projector that visualizes maximum range live as parameters change.
My role
Team
Platforms
- PC
Stack
- Unity 2018.3
- C#
- Unity UI (uGUI)
Lead
What I did
- 01Implemented turret aim-and-fire state machine (searching / aiming / firing / cooldown) with target acquisition by tag
- 02Integrated a public-domain ballistic solver (fts_ballistic_trajectory) for arc and lateral (fixed-apex) firing solutions
- 03Wrote projectile motion via Verlet integration under gravity and impulse (BallisticMotion.cs)
- 04Built a moving-target script with velocity-aware lead prediction for the solver
- 05Added a live-tunable parameter UI (sliders) and a range-indicator ground projector driven by the current firing solution
What stands out
- 01Two selectable aiming solutions: standard high/low ballistic arc and fixed-apex 'lateral' arc
- 02Live UI tuning of muzzle velocity, gravity, turret height, target height/distance and rate of fire
- 03Ground projector visualizing maximum firing range in real time as physics parameters change
- 04Handles both stationary and moving targets, with velocity-lead solving for the latter
See it in action

