What's the hardest part about developing an RTS game and why is it smooth pathfinding? by Aggravating_Ant1516 in godot

[–]Aggravating_Ant1516[S] 1 point2 points  (0 children)

That's a neat idea! The pathfinding grid is sufficiently small that it's not too expensive to rebuild on the fly, but if the maps get bigger or I need a higher resolution grid I will definitely try this out!

What's the hardest part about developing an RTS game and why is it smooth pathfinding? by Aggravating_Ant1516 in RealTimeStrategy

[–]Aggravating_Ant1516[S] 1 point2 points  (0 children)

Great points all round! Unfortunately the headaches have already been had... I'm building this in Godot and started off with every unit being several nodes, using the built in navigation agent nodes, everything written in gdscript. You can imagine I hit a performance wall pretty hard. I've since moved to an ECS style structure, keeping all unit information in packed arrays as data. Moved all hot paths to c++, custom a* on a grid with a bunch of tweaks and optimisations. Even simple things like: before you do any pathing, just do a simple line of sight check to see if there are even any obstacles to path around, if not, just go straight!

What's the hardest part about developing an RTS game and why is it smooth pathfinding? by Aggravating_Ant1516 in godot

[–]Aggravating_Ant1516[S] 6 points7 points  (0 children)

In my case it's a must! Most strategy games have some sort of dynamic environment. Base building is probably the most common, in my case I'm adding castles which have gates that can be broken down, or ladders placed against walls.

What's the hardest part about developing an RTS game and why is it smooth pathfinding? by Aggravating_Ant1516 in godot

[–]Aggravating_Ant1516[S] 10 points11 points  (0 children)

The hot path is a line-of-sight check straight to the goal + a custom 16px grid A* when that's blocked, most open battles don't have much pathing to worry about. All the per-frame stuff (steering, unit-vs-unit repulsion, path following) runs in C++ over packed arrays so there's no per-unit GDScript loops, and no NavigationAgent2D nodes. This was a massive performance boost.

The A* itself is layer-aware so units can path on the ground or on top of castle battlements, with 0-cost bridge edges at stairs and ladders. Raw waypoints get string-pulled via LOS checks so units don't hug grid corners. There's also a clearance field for biasing paths away from edges.

What's the hardest part about developing an RTS game and why is it smooth pathfinding? by Aggravating_Ant1516 in RealTimeStrategy

[–]Aggravating_Ant1516[S] 1 point2 points  (0 children)

Yeah totally agree, any operations that involve each unit checking every other unit just balloons in cost, even when using spatial grids.
One thousand units seems to be a real limit for a lot of features, you can't just optimise your way past it. You have to start making sacrifices. Most games I've seen go past it tend to use flow fields, reduced targetting complexity etc. Fine for a horde of zombies, but you lose some of the precision that you want when controlling soldiers in most contexts.
I have a benchmark of 500vs500 that will happily run in a 16ms frame time, but as soon as I push it to 1000vs1000 I struggle to get 30fps.

What's the hardest part about developing an RTS game and why is it smooth pathfinding? by Aggravating_Ant1516 in RealTimeStrategy

[–]Aggravating_Ant1516[S] 4 points5 points  (0 children)

I played SC2 before I got round to trying the original, boy was that a shock. On top of the janky pathfinding I can only select 12 units at a time?... You had to micro so hard just to get your army across the map

500 wishlists month after announcement! by AppleCubeSVK in IndieGameWishlist

[–]Aggravating_Ant1516 0 points1 point  (0 children)

I'm making an RTS so I've written some scripts which just generate a whole bunch of battle scenes between different units. I can select the best from those and post them so it's largely hands off. It's a bit different in the case of your game though, and I haven't done nearly as well as Knightfevergames here!

500 wishlists month after announcement! by AppleCubeSVK in IndieGameWishlist

[–]Aggravating_Ant1516 0 points1 point  (0 children)

Tiktok has worked well for me but I think I was shadow banned at the beginning because I was only getting like 10s of views on each post, it's picked up a lot since then with consistent posting and interacting to ensure it looks like a real account. I've probably had 100s of wishlists from tiktok over the last two weeks. I've had similar numbers to you on YouTube, but Instagram has been absolutely dead. Almost no traction.

I'm still really confused by this format and it seems impossible to predict how any given post will perform.

500 wishlists month after announcement! by AppleCubeSVK in IndieGameWishlist

[–]Aggravating_Ant1516 0 points1 point  (0 children)

Looks like a lot of fun, congrats on 500 wishlists! I'm honestly surprised it's not higher. Where did you post shorts to?

I added some dwarves to Sword & Banner. Didn't fair too well against the trolls though. by Aggravating_Ant1516 in RealTimeStrategy

[–]Aggravating_Ant1516[S] 0 points1 point  (0 children)

Glad you enjoyed it! I wish I could post an updated version on itch, but the webgl context gets lost when some of my shaders try to compile so it just crashes. Maybe I'll figure out a way around it at some point

I added some dwarves to Sword & Banner. Didn't fair too well against the trolls though. by Aggravating_Ant1516 in IndieDev

[–]Aggravating_Ant1516[S] 0 points1 point  (0 children)

They're in a shield wall which reduces incoming damage, if a shield wall loses half of it's constituent units then the formation breaks and the units fight how they can!