Ground Combat

A forum for chatting about in-development game features.
Post Reply
User avatar
sven
Site Admin
Posts: 1621
Joined: Sat Jan 31, 2015 10:24 pm
Location: British Columbia, Canada
Contact:

Ground Combat

Post by sven »

The new ground combat system is about done, and the patch is now posted to stable.

Be warned that the ground combat patch introduces new semantics around how troopships are handled, so all your old saves will be marked as "incompatible".

For those of you who enjoy digging into the gory details, the original ground combat design document can be found here, and my notes on some of the picky details of the implementation are posted here.

However, I'm hoping that the mechanics are intuitive enough that a little in-game experimentation will be sufficient gain a working understanding of the system.

As you'd expect, teching up the military tree will make your ground units stronger, and stronger units are better at conquering planets, and/or more likely to survive damage from orbital bombardment.

One interesting quirk of current mechanics is that saves from ground unit armor / energy shields apply to *defenders* only when hit by bombardment, but, the same saves are given to *attackers* if they're at risk of being destroyed when invading. Thus, shield/armor perks end up helping you both when you're attacking, and when you're defending, but, they do so in somewhat different ways.

Another current quirk is that only population of your own species is willing to fight for you as ground infantry. This is a temporary rule -- when the morale/diplomacy system goes in whether or not population can serve as infantry will depend on their morale.

Needless to say, the details of just how the combat numbers and techs interact will likely change once we've had more of a chance to balance the new mechanics. But, even so, any feedback on how the current system is playing would be appreciated ;)
mharmless
Posts: 235
Joined: Sun Feb 01, 2015 11:11 pm
Location: Washington State

Re: Ground Combat

Post by mharmless »

Read over the docs and I like where this is going. Thoughts here, mostly stream of consciousness.

The section 3c with aquatic vs terrestrial; perhaps tying the bonus or penalty into the existing climate numbers somehow? That way it could reflect more fine differences than ocean vs land, and also be easily extended into new situations in the future.

Second document, in the math notes section you point out that a strength ten mech with two strength one militia vs five strength two tanks, the mech has decent odds to beat all of the tanks but both militia units are likely to be killed off. From the rest of the documents it sounds as if a happy populous would mostly (if not all) be able to convert to militia; which makes them all eligible to fight to the death, Invasion-of-Honshu style. If my world is defended by strong units, such as these mechs, then introducing these volunteers to my deck is actually a penalty that dilutes the rate at which my strong ground units can be paired off against an invader and is paid for with worker's blood.

Picture Gaia with three of those powerful 10 str mechs defending a happy population of over 40 million citizens. Invader comes along with a half dozen crappy tanks and drops them on the planet; lets say 5 str each. Those mechs will win handily when they are pulled out of the deck, but they are only going to be 7% of the deck. 93% of the possible matchups are going to be solidly in favor of the invader; they will get to spend most of their time planting happy citizens by the millions. Permanent plus one to farm yields?

This creates a situation where I am actually advantaged by a low morale defensive population; less of my people are willing to fight and die for me, getting in the way of the machines built for that job. Perhaps calling up the militia should be an automatic response to the defeat of some fraction of the professional army first? Get back in that factory, Rosie, leave the dying to professionals!
User avatar
sven
Site Admin
Posts: 1621
Joined: Sat Jan 31, 2015 10:24 pm
Location: British Columbia, Canada
Contact:

Re: Ground Combat

Post by sven »

mharmless wrote:This creates a situation where I am actually advantaged by a low morale defensive population; less of my people are willing to fight and die for me, getting in the way of the machines built for that job. Perhaps calling up the militia should be an automatic response to the defeat of some fraction of the professional army first? Get back in that factory, Rosie, leave the dying to professionals!


Well argued. I think you're probably right -- a biased draw in the defender's deck is probably a good idea.

In theory, on a large world, a small number of professional troops probably shouldn't be capable of heading off all attacks from orbital invaders -- but, in the game world that we've created, setting up fights randomly between attackers and defenders does create perverse incentives.

There's a bunch of ways we could bias the draws -- but, the simplest I can think of right now is just to take all the defending tanks, and put them ontop of the defender's deck. Then, instead of putting tanks aside to be reshuffled, if they win a matchup, just put them back ontop of the defense deck. That way, your tanks form a hard-buffer between your infantry and the enemy troops.

Again, not super realistic, but, I think it would largely fix the perverse incentive problem.

Edit: Now that I think about it, there's really no reason we couldn't do about the same thing for attackers. Just make it a hard rule: armor always goes in the front.
Edit (2): As of r14636, tanks start on top of their combat deck, and defending tanks *stay* ontop of their deck until they're defeated.
User avatar
sven
Site Admin
Posts: 1621
Joined: Sat Jan 31, 2015 10:24 pm
Location: British Columbia, Canada
Contact:

Re: Ground Combat

Post by sven »

As of r14640, the ground combat patch is now marked as 'stable'. There are a few more things I'm planning to clean up before moving on -- mostly having to do with making the UI a little more useable in places where the new icons aren't fitting well. Also, Arioch is still working on the art assets for the mechs and hover tanks.

Finally, right now, the only animation you'll see when bombing a planet is a simple colored box that appears over whatever you hit (the color of the box provides a hint as to what type of saving throw, if any, prevented the target from being destroyed). I'd like to replace these with prettier animations at some point, but, that will probably need to wait until I can scrounge up a little "free time" ;)

All that said, the ground combat features should be pretty much there, and working as intended.
User avatar
Arioch
Posts: 1403
Joined: Sun Feb 01, 2015 12:56 am
Location: San Jose, California
Contact:

Re: Ground Combat

Post by Arioch »

Unable to start a new game on dev. "Relations" accessed at nil.
User avatar
sven
Site Admin
Posts: 1621
Joined: Sat Jan 31, 2015 10:24 pm
Location: British Columbia, Canada
Contact:

Re: Ground Combat

Post by sven »

Arioch wrote:Unable to start a new game on dev. "Relations" accessed at nil.


Ok, that's embarrassing. Should be fixed as of r14641 (now marked 'stable').
mharmless
Posts: 235
Joined: Sun Feb 01, 2015 11:11 pm
Location: Washington State

Re: Report - Current Bugs and Issues

Post by mharmless »

Build r14675 (01/31/16)
Defending Militia died before an Armor Brigade

Invading a Yoral planet, none of our tanks died but he lost a militia unit. From the thread about ground combat it sounded like the tanks should be fighting to the death before the militia get involved.

Militia died, not tank.PNG
Militia died, not tank.PNG (475.47 KiB) Viewed 18159 times
mharmless
Posts: 235
Joined: Sun Feb 01, 2015 11:11 pm
Location: Washington State

Re: Ground Combat

Post by mharmless »

There are a few technologies like 'Advanced Field Theory' which provide a bonus to the survivability of mechs and infantry.

First thing that pops to mind; some say armor, some say hovertanks, and some say mechs. Are these bonuses actually specific to that unit type, or do they all mean armor generally? Or perhaps even same plus, such as hovertank bonuses also mean mechs, but do not mean armor?

Second thing, infantry survivability; does that apply to militia? Does it apply to my militia? If I am invaded and possess these sorts of techs, is it going to increase the fraction of my militia that survive, and are therefore captured and destined for slavery? Or, alternately, if the planet is considered flipped before those survival rolls, do these techs increase the number of former-militia-population I am likely to capture after an invasion?
User avatar
sven
Site Admin
Posts: 1621
Joined: Sat Jan 31, 2015 10:24 pm
Location: British Columbia, Canada
Contact:

Re: Report - Current Bugs and Issues

Post by sven »

mharmless wrote:Build r14675 (01/31/16)
Defending Militia died before an Armor Brigade
Invading a Yoral planet, none of our tanks died but he lost a militia unit. From the thread about ground combat it sounded like the tanks should be fighting to the death before the militia get involved.


This is actually working as intended. The guts of the "card game" behind ground combat make it more likely that tanks will die before militia, but, they don't actually guarantee it. In this case, I would assume that at least 1 defending tank, +1 or more defending militia units, were "defeated" by your attacking forces. However, defeated units only have a 50% chance of being destroyed. So, it's possible for tanks survive to fight another day, even if they're unsuccessful in their attempts to defend the population of a planet.
mharmless
Posts: 235
Joined: Sun Feb 01, 2015 11:11 pm
Location: Washington State

Re: Ground Combat

Post by mharmless »

I typed this up in the bug thread, then decided it really made more sense to go here.

sven wrote:
mharmless wrote:Build r14675 (01/31/16)
Defending Militia died before an Armor Brigade
Invading a Yoral planet, none of our tanks died but he lost a militia unit. From the thread about ground combat it sounded like the tanks should be fighting to the death before the militia get involved.


This is actually working as intended. The guts of the "card game" behind ground combat make it more likely that tanks will die before militia, but, they don't actually guarantee it. In this case, I would assume that at least 1 defending tank, +1 or more defending militia units, were "defeated" by your attacking forces. However, defeated units only have a 50% chance of being destroyed. So, it's possible for tanks survive to fight another day, even if they're unsuccessful in their attempts to defend the population of a planet.


Replying here to make sure I've got it now.
1) Each side gets a virtual card for each unit they own in the combat.

2) The virtual cards are shuffled.
2a) Defender's armor cards are shuffled to the top, militia cards are under that.
2b) Attackers cards receive no preferential shuffleing
2c) The above isn't very complicated because we really only have armor + militia, although it leaves open room to add cards for fighters or other things.

3) The top card of each deck fights, strength to strength. Attacker has a chance of winning equal to A / (A+D), where A is attacker's str and D is defender's unit str.

4) The loser is defeated.
4a) Some tech might provide a defeat-negation chance at this point. If such tech fires, the actual result of that fight is nobody was defeated.

5) Actually defeated units are set aside in a defeated pile, one pile each for attackers and defenders.

6) Undefeated units are sent to the bottom of their deck.
6a) Undefeated defending armor are sent to the bottom of their armor deck, which sits on top of the militia.

7) The decks are gone through some number of times? Super hazy here.
7a) A set number of passes though the larger deck?
7b) A set number of passes through the smaller deck?
7c) A set number of card comparisons?
7d) A variable number of card comparisons?
7e) If one deck becomes empty before the card/round/deck limits are reached, combat ends and that that deck is the winner.

8) If there is no winner, attacker's units return to their ships.

9) After the combat, each side goes through their own defeated units and has a base fifty percent chance to save each unit. Technology can increase this.
9a) Additive or multiplicative? Does +20% from tech mean a total of 70% to save, or is it 20% reduction in the 50% to lose, resulting in 60% to save?
9b) Technology increases apply only to your own deck? Upping your tech can improve odds of your defeated militia during an invasion being captured?

10) Check the planet to see if enough population survived. Needs to be at least one million people left or the world is lost (along with its fractional millions)
10a) If the attacker had surviving infantry and depopulation is on the table, an attacking infantry is converted to a citizen to prevent depopulation.
10a1) At random? First by unit ID? A unit of invading population most suited to the world, as judged by maximum population size? Matching the type of fractional remains of the defender?
10b) Does the fractional remains of the defender persist if an invader pop is used to prevent depopulation, or is it lost as it would have been in the absence of attacking infantry?


Look about right? Where are the holes? Which parts am I understanding wrong? Which questions have answers?
User avatar
sven
Site Admin
Posts: 1621
Joined: Sat Jan 31, 2015 10:24 pm
Location: British Columbia, Canada
Contact:

Re: Ground Combat

Post by sven »

mharmless wrote:2) The virtual cards are shuffled.
2a) Defender's armor cards are shuffled to the top, militia cards are under that.
2b) Attackers cards receive no preferential shuffleing


Both attacker and defender decks get the same preferential shuffling -- armor units always go ontop.


mharmless wrote:3) The top card of each deck fights, strength to strength. Attacker has a chance of winning equal to A / (A+D), where A is attacker's str and D is defender's unit str.
4) The loser is defeated.


Note that both cards attack each other "simultaneously", and thus, there's a chance that neither will be defeated, or that both will.

mharmless wrote:4a) Some tech might provide a defeat-negation chance at this point. If such tech fires, the actual result of that fight is nobody was defeated.


At present there is no such tech. Techs that provide "saving throws" of various sorts are all applied in the "destroyed roll" phase, which is different than the "defeated roll".

mharmless wrote:6) Undefeated units are sent to the bottom of their deck.
6a) Undefeated defending armor are sent to the bottom of their armor deck, which sits on top of the militia.


Not that it really matters, but, technically, undefeated defending armor simply stays ontop of its deck. There's no separate "armor" and "militia" decks.

mharmless wrote:7) The decks are gone through some number of times? Super hazy here.


Combat continues until we've gone through the attacking deck twice, or all defenders have been defeated.

mharmless wrote:9) After the combat, each side goes through their own defeated units and has a base fifty percent chance to save each unit. Technology can increase this.
9a) Additive or multiplicative? Does +20% from tech mean a total of 70% to save, or is it 20% reduction in the 50% to lose, resulting in 60% to save?


Formally, neither. If you get a 20% saving throw from energy shields tech, and then another 50% throw from your tank armor, first you roll for the energy shields save, and then, if that fails, roll again for your armor save. There are presently 2 different "types" of ground combat saves -- energy shields (a 20%-50% chance unlocked by Advanced Field Theory / Personal Shields, usable only by both militia and armor units), and the various tank armor saves (which increase from 20% to 50% to 70%, depending on armor tech level). Only "armored" units get the armor save -- so, your infantry is limited to personal energy shields, or nothing.

Interestingly, only units in the *attacking* deck receive any technology saves at the end of the ground combat phase -- defending units also get all the same saves, but, they apply during bombardment, rather than post-combat. This means that if you have equally matched attacking and defending ground forces, and fight out multiple strategic turns worth of invasions, the attackers are considerably more likely to win than the defenders -- especially if both sides have access to high-level armor and shields tech. I'm not certain that's wrong -- as a high-level consequence, having the attacking side get an edge sortof makes sense -- strategic initiative is good and all that. But, that the attackers edge comes from their *armor* tech is admittedly a little strange.

Conversely -- if you're planing to defend planets, the big benefit of researching ground armor/shields/bunker tech is that it protects you from bombardments.

mharmless wrote:9b) Technology increases apply only to your own deck? Upping your tech can improve odds of your defeated militia during an invasion being captured?


No, it can't, because armor/shield saves never apply to defending units defeated during ground combat.

mharmless wrote:10) Check the planet to see if enough population survived. Needs to be at least one million people left or the world is lost (along with its fractional millions)
10a) If the attacker had surviving infantry and depopulation is on the table, an attacking infantry is converted to a citizen to prevent depopulation.
10a1) At random? First by unit ID? A unit of invading population most suited to the world, as judged by maximum population size? Matching the type of fractional remains of the defender?
10b) Does the fractional remains of the defender persist if an invader pop is used to prevent depopulation, or is it lost as it would have been in the absence of attacking infantry?


All of these special rules got simplified when I actually coded up the ground combat logic. The way it currently works is: any time we have a chance to destroy a unit of population post-ground combat, if destroying that pop unit would reduce the planet to < 250,000 total inhabitants, and the invasion has succeeded, then the chance of destruction goes to 0. I.e., it's not possible to both succeed in the invasion, and not have any population survive to be conquered. You'll end up with a planet of at least 250,000. (Which will show as 0 in the many of the game screens -- but, is big enough to recover to 1+ pop sizes via natural growth over a few turns.)


mharmless wrote:Look about right? Where are the holes? Which parts am I understanding wrong? Which questions have answers?


The bottom line, really, is that the ground combat system, like the population growth system, and the guts of some of the ship to-hit and weapon/system damage rules, is actually complex enough that we've not trying to explain all the details to players. What's most important, I think, is that the system behaves in ways that make sense, given what we are telling players about how everything works. So, having more high strength units is good, teching up to get armor/shield saves is good, bunkers and/or better tank armor can protect your colonies from bombardment, etc. I think the current system achieves all that. The next important priority is balance; there I'm a bit fuzzier on just how successful we've been. Hovertanks are probably unlocked too early, atm, and the AI probably isn't prioritizing ground techs as much as it should -- but, I think there's certainly room to get the balance right inside the current rule set. After those two -- I'd like to make the rules as transparent and clear as possible -- that we're not doing a great job at -- in particular, we could probably do a better job of explaining some important details, like the way the various saving throws interact. But under the current rules, I don't think we'll ever have a truly transparent system. The defeated/destroyed distinction is important for balance/mechanics reasons, but I think it's too inherently complex to be worth trying to explain through the UIs.
User avatar
enpi
Posts: 92
Joined: Sat Feb 07, 2015 12:13 pm
Location: Vienna

Re: Ground Combat

Post by enpi »

sven wrote:
No, it can't, because armor/shield saves never apply to defending units defeated during ground combat.


thats the part I find a little bit strange. What is the reason, that the defender has the problem of not beeing able to use his defensive techs in actual combat? Shouldnt he have a little bit home advantage? Also in military theory the defender has in many cases a tremendous advantage. In your concept defense techs are not that important when playing more peaceful races and thats IMO anti-logical. The shield techs should work for both against bombs and for ground defense brigades too.

The rest of the "deck building" system sounds quite interesting. It enables in future addons to include more "cards" into the deck. How about

-tactical advantage cards (TAC)
which you get by a military academy building? these cards could be allocated to individual brigade cards before the combat begins eg. to give them better stats. (eg. scout card, planetary invasion training card, heavy assault card, defensive tactics card etc.) Eg. each military academy"produces" a part of a TAC each turn. When its finished you can use it once in one your ground combats. (similar to the point bar which builds the famous characters in CiV5)

-other card unit types
like exo-troops (have a bonus on dangerous radiation or exotic planets), special forces, mechs, water navy (on ocean worlds), rebel units (can fight even after the planet is conquered), orbital strike fighters or flak rocket units (against ships in orbit and flyers)
User avatar
Captainspire
Posts: 153
Joined: Mon Mar 30, 2015 8:30 pm

Re: Ground Combat

Post by Captainspire »

Planets Destroyed by Bombardment:

A planet is destroyed by bombardment if it’s total population is reduced to less than 0.25. Planets “destroyed by bombardment” revert to an uncontrolled state, and any remaining defending tanks are immediately destroyed. Any remaining improvements are converted to a “ruins” special.


Wouldn't this negate the defense bonuses the armor/troops have against bombardment or is this a way of beating a planet without bothering with invasion?

I did not read all in detail but will there be a "Drop all Bombs" button so I'm not pressing the bombard button 200 times?
User avatar
Arioch
Posts: 1403
Joined: Sun Feb 01, 2015 12:56 am
Location: San Jose, California
Contact:

Re: Ground Combat

Post by Arioch »

Captainspire wrote:Wouldn't this negate the defense bonuses the armor/troops have against bombardment or is this a way of beating a planet without bothering with invasion?

If you have sufficient firepower, you can "glass the planet" and remove the settlement on it. This doesn't give you control of the planet, but it reverts the planet to a "neutral" state that can then be re-colonized.

Captainspire wrote:I did not read all in detail but will there be a "Drop all Bombs" button so I'm not pressing the bombard button 200 times?

There should be, yes.
Post Reply