STEAMB

Меню

Cold Take #45 - Automatic Dodging

Simulated projectile physics is a core part of Zero-K, both for the aesthetics and as a balance tool. Rather than using armour classes, light units are nimble enough to dodge most of the projectiles meant for heavier targets. We also want to create powerful controls, so players can fight their opponents rather than the UI, and automation is part of achieving this goal. So you might expect us to have effective automation that lets units dodge automatically, but in fact dodging is barely automated at all. The apparent contradiction here is the subject of this post.

Technically, Zero-K units cannot even see projectiles. Our limited form of automated dodging happens when units expect to be shot at with slow projectiles, rather than based on the presence of projectiles. Sufficiently nimble units dodge by jinking from side to side as they approach enemies with certain weapon types, provided they were told to Attack Move or are attacking while not set to Hold Position. This behaviour is far from perfect, as it only causes units to avoid projectiles by chance.

1 / 1 · 100%

More powerful projectile dodging would involve tracking incoming projectiles and moving out of their way. There has been some experimentation in this area, but so far none of it has made it into the main game. Quite a bit of the technical work was done around 2021, first as player-made widgets, then later as a gadget. The design side of the problem has languished, though, since such a drastic change needs guardrails and careful testing to make sure it doesn't accidentally remove a vital part of Zero-K in the process.

The main problem with improved automatic dodging is that the game is currently designed and balanced around the current level of automation and player control. The balance could be adjusted to compensate, but there are reasons to think that something essential to Zero-K would be lost in the process. To start with, bestowing units with superhuman dodging capabilities would necessitate faster projectiles to match. We would also need to change units as well, as ours are quite responsive, with even large bots able to repeatedly pirouette in the time it takes a short-ranged rocket to land. So the rebalance would probably involve nerfing acceleration and turn rates, which would effectively make units feel less responsive.

1 / 1 · 100%

Unfettered automatic dodging risks sparking an arms race between units' AI and their capabilities, one that would leave players in the dust. Faster projectiles make the battle harder to parse and sluggish units are not as viscerally fun to use. Issuing basic unautomated Move commands would be tantamount to sending your units to die, which is a problem because nothing feels better to use than basic Move commands. A slew of Move commands lets the player dial in how much to prioritise safety versus closing with the target, while recapturing this nuance with automated controls would require various flavours of Attack Move, or worse, state toggles.

The theory above is just an informed guess, as we did not reach the point of widespread testing. The gadget needed a little more work and we would likely have to do a first pass of rebalancing before exposing it to players. The design side of things was held up by needing to convince everyone involved that there was a real risk that the result would not be fun. Zero-K can be different things to different people, which is why modding exists, and optimising the dodge AI is itself a fun optimisation problem. But for something to make it into the game we need to be pulling in the same direction, which means hammering out some design goals.

We did not get far enough to pin down an acceptable level of automatic dodging, but I can make a guess at what the answer might look like. As a starting point, an undeniable part of the appeal of Zero-K, for many people, is the responsiveness of the units as well as the expressiveness of the controls. It should feel good to observe and manipulate battles, which means players should be able to use simple move commands. So my proposal for where to draw the line is as follows: automatic dodging should only be as good as the average player. In other words, an attentive player should be able to take manual control of a battle without sacrificing unit performance. It is important to think about the most common situations, i.e. battles, because, while players may be able to perfectly dodge projectiles with a single unit, they cannot do so for several units at once.

1 / 1 · 100%

To bring automatic dodging down to the human level we would need to consider what makes it so powerful to begin with. One large advantage is the fact that code can read precise projectile positions and velocities, which for most projectiles is enough information to predict exactly where and when it will land. Humans are decent at this task, but it is made more difficult by the top-down camera. In any case, this precision is a feature of software, not a fact about the mechanics of the game world that the software is modelling. We could decide that units only ever have an approximate perception of projectiles, which would put them on equal footing with humans. We might also consider giving dodge AI built-in latency to further level the playing field.

The nice thing about deciding what units can see, effectively giving them perceptual abilities, is that we could then let programmers loose on the task of making units as smart as possible within these constraints. This is the sort of problem that people will tackle just for the fun of it. We would probably have to iterate on the limitations until we reach an appropriate level of automation. The resulting system may well end up being little more than the current Attack Move jinking system, which would mean a lot of work was done to end up back where we started.

The projectile dodge gadget remains in an open pull request, while the dodge widgets were blocked by removing their ability to read projectiles. I am not sure whether more work will be done in this area, but the best way forward would be to gradually introduce better dodging. Impaler would be a place to start, as it is designed to only hit structures, so few people would complain if their units stepped out of the way of its projectiles. But fundamentally, we do not seem to need much more automatic projectile dodging, even though a few of our design principles seem to want it. Ideals can guide us to places, but should not be followed so far that we lose sight of making a fun game.

Index of Cold Takes

Читать в Steam ↗

Комментарии 0

Гостевые никнеймы не подтверждают личность. Все комментарии проходят проверку владельцем сайта.

Обсуждение ещё не началось.

    Настройки cookies

    Вы можете изменить выбор в любой момент. Отказ от аналитики не ограничивает доступ к сайту.

    Технологии, провайдеры и сроки хранения