Developer postOriginal post (opens in a new tab)

Development Blog #16

Part 1. Finding a Path

Greetings, Officers!
Seasoned veterans of Blitzkrieg 3 might have already noticed better reactions from battle units under their command to their orders.

We agree that our pathfinding, or the algorithm for finding routes from point A to point B, was far from optimal for a very long time. Tanks exhibited poor navigational behavior in narrow passes and failed to interact with terrain obstacles properly. However, it was perfect for reenacting a big city driver in their natural habitat:

The future of improving pathfinding was at first rather unclear. For quite a while, the team would just patch and polish what was already there – until it became clear that the gameplay demanded a completely new pathfinding algorithm.

Behind the new system is a huge body of intellectual and analytical effort from our programmer's time spent experimenting, testing theories, and researching new methods.

Our researchers trained our tank crews to race,

turn into transformers,

and politely avoid illegally parked drivers.

Funny bugs during this process were unavoidable. Take a look at what happens when you make a mistake when converting arcdegrees to radians:

After long iterations, we've succeeded in creating an efficient, fast, and well-optimised pathfinding system that allows the player to be fully submerged in commanding their army without having to deal with misunderstood orders.

Let's compare our old and new pathfinding systems with the help of this collection of GIFs.

Old pathfinding: to avoid an obstacle, the Tank Destroyer stops, turns, and only then continues moving.

New pathfinding: the Tank Destroyer changes its direction while moving.

Reporters from our battle front newspaper asked Artem Pavlenko, our chief officer, to share the details of the algorithms that shape the new pathfinding.

Artem Pavlenko, Senior Programmer::
"The route for co-op pathfinding is built on a modified jump point search across layouts with a recursive clearance function that allows route calculation to account for the width of units.
Then the resulting high-level route is used with phantoms of the physical model in a swarming algorithm.
During movement, the route planner corrects the route based on the actual change of the position of the vehicle, which is modified indeterminately depending on the swarming algorithm phantoms."

As you can see, writing a pathfinding algorithm really isn't that difficult!

Part 2. Our Week

And now, as usual, a few words from the development team about how the latest week went.

Ivan Zvonarev, Balance Designer:
"I dream of unit spreadsheets at night. For the past two weeks I've been adding new vehicles, new infantry, and new fortifications. I dug through a bunch of vehicle stats and reports to tune everything. I'm especially looking forward to the Wirbelwind and the KV-2. Then I'm planning to balance everything out. The game will have completely new unit models that require a bunch of work from scratch, and it's a great opportunity to fix some issues."

Manuel, Operations Manager:
"The last days before releasing an update are the most nerve wrecking, because during playtests we discover new bugs that haven't been there before, and we have to make a choice between postponing the release or releasing an unpolished version on time. Devblogs have to be written, newsletters created, PR messages sent over to the press – and there are always unpredicted obstacles."

Part 3. Coming up...

Our next episode's topic will be the project's graphics. Time keeps ticking on, and the visual part of the game has been evolving. Our artists, animators, and graphic programmers will tell you about their work. Don't forget to check out the next dev blog!

See you on the battlefield, officers.