MILESTONE UPDATE

Milestone 13: Basic Combat

Project Nightfall’s thirteenth milestone brings the first real fighting to the game: units can now attack, take damage, and die. Everything up to this point — moving units around, gathering resources, placing buildings, training units — was preparation. Milestone 13 is where those systems finally have something to fight over.

Melee and Ranged Attacks

Two kinds of attackers now exist. Melee units strike the moment an enemy is in range. Ranged units fire a projectile that actually travels through the air over time rather than dealing damage instantly, so a fast-moving target can, in principle, get clear of a shot that’s already been fired. Each attacker’s range, damage, and cooldown come from its own definition data rather than being hardcoded — the same approach already used for buildings and resources. That keeps combat numbers easy to tune, and later milestones will be able to build on the same structure instead of requiring a rewrite.

Giving Orders

Players can now right-click an enemy unit to issue a direct Attack order. There’s also an Attack-Move order: press T, then click a destination, and the unit heads there while automatically engaging any enemy it comes within range of along the way, then resumes toward the original destination once that fight is over. It’s a small but important piece of real-time-strategy feel — armies that move together don’t need to be babysat past every enemy they pass.

Units that lose all their health die and are cleanly removed from the match, both from the simulation and from what’s visible on screen. Earlier milestones only ever created units at fixed points; this is the first time something can vanish mid-game, and stray visuals left behind after a unit’s “death” would be an easy, ugly bug to miss.

Catching a Real Bug

A review pass over this milestone’s implementation caught a genuine issue: if an Attack-Move unit was chasing a target that died mid-chase, the order could get confused about where the unit was actually headed, either stalling or “arriving” at the dead target’s last known position instead of continuing on to the player’s original destination. It’s now fixed, with a test added specifically to catch a regression of this exact scenario.

This milestone intentionally leaves some things alone — damage isn’t mitigated by armor yet, there are no abilities, and the numbers involved (health, damage, range) are all placeholder values rather than tuned design targets. Those come later. For now, the goal was narrower: prove that two units can meet on the field, fight, and one of them can lose.

Discover more from Project Nightfall

Subscribe now to keep reading and get access to the full archive.

Continue reading