by ddtaylor · 9mo ago · 0 comments
The crux of the issue is that their simulation is single threaded. It's a complicated problem to do both deterministic and multi-threaded, but I feel some of us could help them.
Realistically soldiers should head in the right compass direction and hope for the best. But then you (the player) shouldn't have a proper map of your own, either.
[0] https://en.wikipedia.org/wiki/Battlezone_(1998_video_game)
It would depend where and when. An army on their own territory might know the terrain. An army on enemy's territory would try to send scouts ahead as opposed to wondering randomly, too.
So at the army level it would almost work out like the they have "psychic" powers because they have scouts. At the individual units it would depend. But it would also be kind of annoying to play if the realism is increased too much. Like they wander into the woods and get stuck in a bog and die of hypothermia.
> But then you (the player) shouldn't have a proper map of your own, either.
In aoe2 you don't have a full map. I imagine 0ad is similar being a clone
I'm sorry but huh? It's a RTS game, aren't moving units around on the map kind of a fundamental part of the genre and this game?
> Realistically soldiers should head in the right compass direction and hope for the best
If you implement unit movements in a RTS like this, they'll get stuck half the time you ask them to move anywhere, unless you want micromanagement of unit movement to be 90% of the game, which I don't think anyone would find fun.
It would be even fancier if there was some logic to take into account the position of your mobile units as well - for example, to avoid massed troops except in favorable conditions.
When a player looses the connection the game just continues. Usually one of the remaining player then pauses the game until the player who lost the connection returned.
The game state becoming out-of-sync is often a problem of players using buggy mods. That this happens without mods is pretty rare and of course clearly a bug.
> It's also impossible to save and restore in multiplayer.
It seems you haven't played 0ad in a while, as that's possible since a27 (see https://play0ad.com/new-release-0-a-d-alpha-27-agni/).
There was the Total Annihilation RTS and while it had the normal 2d overhead view, all the data was in 3d.
A Swedish gaming clan put together an accelerated full 3d engine to replay Total Annihilation recorded demos. As it got more and more features it was realized that most of what was needed to play TA was being recreated so they closed the loop and made it into a full game engine which they called SpringRTS. There was the default accurate TA game code but there was also a very popular mod that was not afraid to change things a bit, basically "we like Total Annihilation but also think it could be better" and they called it Balanced Annihilation. We are almost there. BA lived under the Spring project for a few years, but really when you think about it there are ip problems with it using the TA assets, also, I suspect someone wanted to do engine work but was having a hard time with upstreaming it, so it forked off the Spring project, they rebuilt all the units(same unit different skin) are doing a ton of great engine work and called it BAR (retronymed into Beyond All Reason but I suspect it originally stood for Balanced Annihilation Reborn or something like that). So BAR is basically a highly modified legally distinct Total Annihilation.
Zero-K is another great RTS based on this engine. It drifts further off the TA formula than BAR does.
Some of the pathfinding is precomputed, some cannot be as it involves other units and formations.
Most other RTS games work around this by either relaxing the constraints or implement some amount of parallelism.
Also, we've always played the game as in-person LAN, and for the most part the lag has been just fine. Only for really huge end of game final battles with the screen packed with troops did it lag out for us, but being free and all, we'd often gather around one monitor and talk crap at each other while we waited for it to clear up.
Good times.
We're not calling it Alpha anymore, but we still don't consider it a polished major release. The announcement of the last Alpha, Alpha 27 had a section explaining the motivation for the change: https://play0ad.com/new-release-0-a-d-alpha-27-agni/
> Only for really huge end of game final battles with the screen packed with troops did it lag out for us, but being free and all, we'd often gather around one monitor and talk crap at each other while we waited for it to clear up.
I'm not sure when you last tried the game, but a27 notably improved performance and feedback so far suggests that r28 did as well.
The huge battle toward the end of the game dropping or making the game unplayable was what killed it for us. We didn't want to spend all that time making our army and strategy only to be disappointed. At the time we went back to playing Age of Empires 2 DE.
That's correct. While 0ad is an RTS, behind the scenes it's still turn-based and in multiplayer games turns can only progress once every participants PC has responded. That's also why the game also feels slow when a player has a bad latency to the player hosting the game.
They also make heavy use of pre-computed pathing maps (Dijkstra) and place restrictions on how that pathing map can be changed.
It's also worth mentioning it's not just the pathing that is single threaded, it's ALL of the game logic, since it all has to be deterministic. All players must agree on the input, then run ALL of the game logic with the same inputs and same deterministic functions so that they agree on the game state without having to synchronize it.
I don't really know 0ad well enough to know if the game logic is more complex than Starcraft or Age of Empires.
Also, both Starcraft and Age of Empires have struggled with lag once above the unit counts. AoE in specific has always had a lot of lag once players start to get full armies. There are well known patches for Age of Empires 2 before the Definitive Edition (DE) where people just hand optimized the binary and figured it out.