New Attack Formula and Logic

Revamp Attack Formula is currently our most wanted feature. I can use some help getting my head around a sense of balance, based on your guys’ experience.

This is the root of our problem:

Our battles are turn-based, with defender acting first

and:

The consensus for a solution so far is:

Scrap Turn-Based

The question now is, what do we replace it with? As a baseline, given a battle between 2 identical empires with no bonuses, what should happen at every phase of the battle? Some specific factors to consider:

  • How much randomness do we want baked in?
  • If 10,000 units fight 10,000 of the same units, what is the outcome, between a scale of “everybody dies” and “complete stalemate”?
  • What is the ideal cap on losses?

Additionally, the answer to the questions above will also effect each subsequent phase of battle. How we balance air casualties, for example, will directly impact the scale of the ground fight.

There may be other factors to consider as well, though we should keep it as simple as possible to start. So no new features or anything, just working with what we already have.

My most immediate next step is to build “battle version” as a galaxy setting, so we can test new versions without disturbing regular galaxies. While I do that, I’d be grateful to hear opinions here on what an ideal example battle might look like.

This is going to be my next priority, so we’ll have a test galaxy up for it ASAP.

Ouch. I never realized that the defender had such a large advantage.

I always find it interesting that bombers get a free shot at lasers then withdraw from the battle. Apparently everyone in the galaxy has all their fighters in hangers and only bring them out to defend once a bomber attacks their planet. Which begs the question why no fighters or ground troops are killed by bomber payloads hitting the ground.

But I digress.

Based on this information I really screwed up the math when coming back to play in MW64. That also explains why I lost more ground attacks than I expected.

Solution C is the fairest, but I also like Solution B for more randomness that must be accounted for when picking a target to attack.

And along that same line I really like @Byakko’s thoughts on implementing it.

I know that many people will want everything to be perfectly fair, but I like the unpredictability in the game. Not knowing with 100% certainty what your target will be mounting as a defense but doing your best to make an educated guess is the fun part of the game. The more variables – i.e. research bonuses, race bonuses, no fear, fleet estimation based on NW, etc. – that must be accounted for by an attacker the better IMO. It keeps the game lively and enhances the re-playability of it.

1 Like

Another variable that could be worked into the attack formula is Random Luck, or in this case we could call it Commander’s Skill, Rallying Cry, etc.

Maybe a “luck” factor of 1-5% difference in troop kills/losses for each attack/defense based on a random generator.

It is something that has been worked into digital versions of Risk-like games for years now.
Not really much different than rolling a dice in a D&D game to determine success or failure.

1 Like

What about introducing a new ship that attacks long-range and avoids being hit by lasers? This means whether or not your attacking force gets hit by lasers - or how much of your attacking force gets hits by lasers - depends on your use of the long-range destroyers. I think this would work well combined with any of the ideas above.

1 Like

Now that Infinitum has arisen to test a new attack formula, what do you have in the pipeline @I_like_pie? Details please.

1 Like

I’m glad you asked!

Support for different battle logic is complete. When this rolls out in the test galaxy, existing galaxies will be entirely unaffected. Score a point for modular code!

As for the logic itself, it’s coming along nicely. There are 3 key differences that haven’t been announced yet, but will be very dramatic changes which will change battle entirely.

To re-emphasize, this will be heavily tested and adjusted before being used in any real galaxy.


Pre and Post Ground Deployment

Pre and Post Ground Deployment

Even though we wanted to get entirely away from turn-based, we still need a bit of this due to the nature of transports and ground troops. Everything can’t happen in a single step because ground troops need to leave the trannies.

We are still getting away from the existing phases of battle and having all units fight each other simultaneously, it just happens twice: once before ground troops land and again after.


Everything can hit everything

Everything can hit everything

Every unit has the following:

  • Air attack
  • Air defense
  • Ground attack
  • Ground defense

Interestingly, even buildings already have this on the database side, it just isn’t used by the code.

What this means though, is that any unit or building can target any other unit or building. A bomber can target a building (targeted bombing), a droid can target a fighter (rocket launcher), a building can target a transport (anti aircraft guns), etc.

We likely won’t go all out with this at first, but I at least want to consider what it means for bombers to be able to target buildings. This will likely make nukes obsolete in their current form, which I am fine with because their current implementation is kind of silly.


Targeting options

Targeting options

The biggest math challenge has been figuring out how to distribute damage in a setup that is no longer turn based. I’ve been experimenting with 2 options, and ideally will support both and let players choose which they want on a per-battle basis for attackers and by a default-behavior basis for defenders.

1. spread by target unit ratio

Fire is drawn according to the ratio of target units. For example, if I send 10k droids and you have 8k droids and 12k soldiers, my droids would match your split: my 4k droids hit your 8k droids, and my remaining 6k droids hit your 12k soldiers.

I would lose most of my ground troops, and you would incur losses fairly evenly.

This is similar to how it works now.

2. focused on target order

Instead of spreading, you could order your units to focus on a single unit at a time, and only move onto the next one if the primary target is destroyed. For example, if I send 10k droids and you have 8k droids and 12k soldiers, I can say to focus 100% on droids first because I know you have an iron shortage. My remaining (unfired) droids would then move onto soldiers.

I would lose most of my ground troops, but you would lose most of your droids.

This is very different than how it works now.


Any one of these things would be a huge improvement over what we have now, but the combination of all 3 is going to make things very interesting. The biggest challenge, once all the math is worked out, will be presenting it in a way that isn’t overwhelming or too confusing.

We’re going to need to figure out reasonable defaults for the 80% of players to use if they don’t care to optimize further. If we do this right, the game will still be fun if you don’t bother with this, but will offer a ton of strategic depth to those who do.


A crazy-sounding example

As an example of how crazy this could get, imagine the following battle:

You:

  • 1k bombers
  • 5k fighters
  • 200 transports
  • 5k droids
  • 15k soldiers

Your target (main + stationed)

  • 5k bombers
  • 10k fighters
  • 5k droids
  • 5k soldiers
  • 100 lasers
  • 100 collective building defense

What happens:

Pre-ground deployment

  • Your bombers drop bombs on everything except defending fighters

    • If your bomber force is larger than necessary, “unused” bombers provide light attack against enemy air units.
  • Your fighters attack defending air units

    • If your fighters force is larger than necessary, “unused” fighters provide light attack against enemy ground units.
  • You transports optionally provide light attack against enemy air and ground units as they land.

Meanwhile, for your enemy, they target all of your air units with:

  • Defending fighters (same as now)
  • Lasers (similar to now)
  • Building anti-aircraft (new)
  • Ground units light anti-aircraft (new)

Post-ground deployment

Everything from before happens again, but now the following also occurs:

  • Your ground troops now target enemy ground troops but also provide light anti-aircraft if able
  • Your ground troops, if configured, also attack buildings as directed

And for your enemy:

  • Your enemy’s defensive bombers deploy to target incoming ground troops, and optionally provide light attack against your fighters if able
  • Your enemy’s fighters, if able, now also target your ground troops
  • Your enemy’s buildings target your ground troops (snipers towers?)

It’s gonna be very messy as we test out the initial versions, but if we can pull it off in a way that feels smooth and not confusing, this will breathe a ton of new life into the game. I also think it will change the pacing entirely, and make it harder for any person or group of people to stay on top.

Loving it so far.

Shouldn’t an attacker be able to throw everything, including the kitchen sink, toward building annihilation? If so, that would definitely take the pizzazz out of nukes.

1 Like

Exactly!

Now, we could still have nukes in a revised and super powerful form, but right now they have this weird ability to target a specific % of buildings but only at random… pretty odd way for a nuke to behave.

Improved nukes is a whole 'nother ball of wax though.

I’ve gone ahead and posted this update on the Revamp Attack Formula thread. Feel free to discuss there as well.