Xcom 2 Random Stats
Is a lot more mod-friendly than its predecessor, which is great news for people with the time and knowledge required to create their own modifications and content. It’s also highly tweakable, with a huge amount of the game’s values and mechanics open to alteration through its exposed config files. All you need is a simple text editor like Notepad (or preferably, ), some basic familiarity with the game, and the time and patience to find what you’re looking for. In this article I’ll show you how to implement some basic tweaks to get you started—then, once you’re familiar with how it works, you’ll be able to find and alter the game to your heart’s content.Don’t forget to backup any files before you modify them! When your tinkering breaks your game, you’ll want to be able to set things back to normal without reinstalling. Time to get your hands dirty.
XCOM 2.ini filesAll the files you’ll need are in the config folder within the game directory (default C:Program Files (x86)SteamsteamappscommonXCOM 2XComGameConfig). Out of the files you’ll find within, here’s a quick rundown of the ones you’ll work with most:DefaultGameData.ini Covers a very wide variety of mechanics, from how big a squad you can take to how fast the aliens grow in power.DefaultGameCore.ini Another general variety file. Adjust things like how much aim a unit loses when disoriented or how much damage you take while burning.DefaultGameDataWeaponData.ini Adjust values for all the weapons in the game, both friendly and enemy.
Add more ammo to your shotgun, lower the damage on the Viper’s Plasma Rifle, increase the radius of Frag Grenade explosions, and so on.DefaultGameDataCharacterStats.ini Adjust every stat for every unit in the game. Give ADVENT Troopers more aim, reduce the mobility of Chrysallids, add extra health to Berserkers, whatever you like.DefaultClassData.ini Covers the four classes and their growth as they gain ranks. You can adjust how much aim and health you gain per promotion, allow soldiers to carry weapons from other classes, adjust who gets what perks, and more.DefaultGameDataSoldierSkills.ini Adjust variables relating to the game’s perks. You could increase Blademaster’s melee damage bonus, reduce how much a Shieldbearer guards his allies for, or make Lightning Strike grant you its bonus mobility forever, just to name a few ideas.DefaultNameList.ini A very important file that lets you decide which random names the game creates its recruits with. You can also adjust the chance of new soldiers having hats, props and beards in here.DefaultMissions.ini Adjust which aliens show up on missions and how many of them should appear.
You could add extra enemies to every mission, remove Stun Lancers from the game or make every operation a Chrysallid hunt.DefaultGameBoard.ini Governs much of the Geoscape/strategy layer of the game. Make the Skyranger fly ten times faster and ensure you never miss a mission.DefaultAI.ini One of the more complex files to understand, it governs how the AI decides what to do each turn. There’s still a few simple changes you can make in here even if you’re not technically minded, such as setting the ideal engagement range each enemy type will try to fight from or increase how much the AI values High Cover over other alternatives.Now that you’ve got a general idea of what file covers what, I’m going to show you a handful of example tweaks to demonstrate how simple it is to shape XCOM 2 to your liking, even if you’re not a modder yourself. Another thing to know: modding from earning achievements, if you care about those.
Basic tweaksIncrease the size of your squadHere’s something everyone should play with at some point—increasing your squad size can range from the reasonable (adding a couple more soldiers) to the insane (adding a couple dozen more soldiers).Open DefaultGameData.ini with your text editor and search for MaxSoldiersOnMission. By default, it’s set to 4 (and then you increase it by 2 with upgrades in the campaign). You can emulate the Long War mod’s sizes by changing this value to 6, or go nuts and set it to whatever you like—while XCOM 2’s default UI only supports 8 soldiers at once on the pre-mission equipment screen, the game will still send extra soldiers from your roster onto the operation until it hits the limit you’ve set. Stomping ADVENT with a platoon of 60 XCOM soldiers is something you should try at least once in your life.Lowering the health of ADVENT OfficersHaving trouble taking down ADVENT’s finest? Don’t worry, I won’t tell anyone. Head to DefaultGameDataCharacterStats.ini and search for AdvCaptainM1. The first entry you find is the unit’s default stats—to reduce their health, you’d look for CharacterBaseStatseStatHP and lower the entry’s value.
Repeat this process with any of the other stat lines to tweak each unit to your liking.Be aware that XCOM’s different difficulty settings override the default values we just changed, though. To adjust this, keep searching for AdvCaptainM1 and you’ll discover more entries in four difficulty sections throughout the file—Rookie, Veteran, Commander and Legend, also known as difficulties 0, 1, 2 and 3 respectively.
So if you’re playing on Veteran, you’d find the AdvCaptainM1 entry under the Veteran Difficulty section and adjust the overrides there. Alternatively, simply look for the Difficulty stated above each set of entries—ADVENT Officer stats can be found under AdvCaptainM1Diff1. Players using Commander difficulty would look for AdvCaptainM1Diff2, and so on.Adjusting the damage of a Magnetic RifleOpen DefaultGameDataWeaponData.ini and find AssaultRifleMagneticBaseDamage string.
By default, you’ll see Magnetic rifles have Damage=6 with Spread=1—that means the center of the damage range is 6 but it can roll plus or minus that number by 1, for a damage range of 5 to 7. If we change the string to read Damage=5 and Spread=4, the Mag Rifle will now have a damage range of 1 to 9!
Have fun relying on that next time you need an ADVENT Officer to die. Perhaps you’d like the Mag Rifle to be your personal Sectopod slayer—that’s easy. Change the string’s Pierce value to 1000 to have your rifle ignore up to 1000 armor, or adjust the Shred value to 4 to remove that much armor with every hit.Increasing a grenade’s explosive radiusYou can increase a grenade’s damage in the same way, but to tweak its explosion size we need a different section of DefaultGameDataWeaponData.ini.
Search for FragGrenadeRadius and you’ll find another set of different entries relating to the item. Changing the value changes how big your explosion will be in tiles—setting it to 30 would make your nade wipe out an entire city block by itself, while reducing it to 1 would make it only effect a single tile at once. Remember that the Grenadier’s Grenade Launcher increases the range and radius of grenades as well, so factor that into your personal balancing act.Make your new recruits wear more stuff and have more beardsIf you want your new recruits to stand out a bit more, you can adjust how likely they are to come with props or facial hair when the game creates them. Open DefaultNameList.ini and find the section starting with NewSoldierHatChance.Adjust these values as you see fit—setting HatChance = 0.40 gives every recruit a 40% chance to come wearing a hat. NewSoldierBeardChance = 0.66 would make 66% of your male rookies come with some manner of facial hair.There’s another section below that deals with Civilian hat and prop chances as well—set NewCivlianHatChance = 0.10 for a 10% chance that non-combatants like Engineers and Scientists will be born with some manner of hat on their noggin. Be warned that after playing with this setting, my Central Officer Bradford started walking around the Avenger wearing a kevlar helmet. Be warned that it was awesome.Slow down units when they’re carrying bodiesFind it odd that your soldiers can move at full speed even while they’re hauling another adult human over their shoulder?
While still in DefaultGameCore.ini, find CARRYUNITMOBILITYADJUST and change the value to -6. This will apply a -6 mobility penalty to any unit currently carrying a wounded ally, unconscious VIP, and so on.
Advanced tweaksAdding extra uses of Conceal and improving ShadowstrikeOpen DefaultGameDataSoldierSkills.ini and find XComGame.X2AbilityRangerAbilitySet. If you’re familiar with XCOM 2 you can guess what most of these values represent; for example, we can increase the STEALTHCHARGES value to allow the Conceal perk to be used more than once per mission.What are we going to do with all that extra stealth? Set SHADOWSTRIKECRIT to equal 100. Now your Ranger is guaranteed to crit whenever he attacks from stealth, which local Sectoids will find highly unwelcome.Give Shotguns to your Specialists, and increase their HP growthOpen DefaultClassData.ini and find Specialist X2SoldierClassTemplate.
In this section, find AllowedWeapons=(SlotType=eInvSlotPrimaryWeapon, WeaponType=”rifle”) and, underneath, insert the following: AllowedWeapons=(SlotType=eInvSlotPrimaryWeapon, WeaponType=”shotgun”).Easy as that, your Specialists can now equip Shotguns. But they need a bit more beef if they’re going to fight up close and personal—so look a few lines down and see the stat strings for the various Specialist promotions such like squaddie, corporal, sergeant, and so on.
Xcom 2 Soldier Stat Editor
Within these entries, adjust the (StatType=eStatHP, StatAmount=0) to be however much health you want them to gain for that particular rank. So if you went to the lieutenant section and set its StatType=eStatHP,StatAmount=0 to instead be StatAmount=10, your Specialists will gain 10 health once they’re promoted to Lieutenant. That’ll probably be enough to keep them alive.Giving the enemies aim bonuses at close rangeBy default, XCOM 2’s enemies don’t get more accurate at close range like you do—a big departure from Enemy Unknown which sees a lot of hilarious incompetence from charging ADVENT Troopers. It’s not too hard to return the aim bonuses to the enemy, though, it just takes a few minutes and some patience.Find the FLATCONVENTIONALRANGE0 line within DefaultGameDataWeaponData. Ini to get started. These are the bonuses the AI gets when they’re a certain range in tiles from their target. By default they don’t get any bonuses but if you were to change FLATCONVENTIONALRANGE1 to equal 20, the AI would gain +20 aim when a tile away from their target.
If the distribution scheme is changed but the KIP target data is not updated, then similar problems would occur in the future. This is due to the fact that until the 31 August 2016 deadline, the KIP data submitted to the Dapodik had only reached 40 percent, and a number of KIPs have not been distributed and is still withheld in the village office / district (lurah) office.Meanwhile, education observer Indra Charismiadji said that the issues in the process of distribution and disbursement of the KIP was due to invalid data. However, the Minister did not want to explain further of the changes.The Director General of Primary and Secondary Education (Dikdasmen) of the Kemendikbud, Hamid Muhammad, said that before the new scheme is implemented, the Ministry will see the development of the KIP registrations in the Education Data Base (Dapodik) up to the end of September.As is understood, Kemendikbud has already issued a circular letter extending the KIP registration period in Dapodik until September 30, 2016.
FLATCONVENTIONALRANGE2 governs the aim bonus they’d gain when 2 tiles away from their target, and so on.If you’re not sure what you’d like their bonuses to be, the easiest way is to simply copy the range bonuses your own soldiers gain. Scroll up until you find MEDIUMCONVENTIONALRANGE—this section is the aim bonus your soldiers gain with proximity while wielding a ballistic rifle. Reference these values to see what you should give the AI in order to level the playing field.Back in the AI bonus section, I’d guess that FLATMAGNETICRANGE and FLATBEAMRANGE relate to more advanced types of enemies. To be safe, put the same values in these sections as you did for FLATCONVENTIONALRANGE.
The result should be a lot more accurate enemies at close range and a lot less hilarious misses at point blank from your local ADVENT peacekeepers.Change how powerful your weapon attachments areWould you use the Repeater if it was just a little bit more reliable? Open DefaultGameCore.ini and find XComGame.X2ItemDefaultUpgrades within. This entire section governs the stats associated with each attachment you can tape onto your guns in XCOM 2. Find FREEKILLBSC—that’s Free Kill Basic, aka the basic Repeater—and adjust its value to whatever you like. Setting it to 33 would confer a 33% chance to instantly kill any target you hit.Perhaps you think it’s odd the Autoloader only has a limited number of uses?
Set FREERELOADSBSC to equal 0—this removes the basic Autoloader’s limitations entirely and allows you free reloads as many times as you want with that weapon. Try not to litter as you dump dozens of half-full magazines throughout the countryside.Add extra enemies to your missionsThis’ll be a little more complicated, but still not too hard. Open DefaultMissions.ini and find;ADVENT ENCOUNTER DEFS FOR All Missions. This file may not immediately make sense to you, but don’t worry—just focus on each text block that starts with ConfigurableEncounters. Each of these is a configuration for a different group or ‘pod’ of enemies that will then be placed onto any mission that requests it.
To add more bad guys, simply increase the block’s MaxSpawnCount value to equal the number of enemies you desire, and repeat for each ConfigurableEncounters block until you’re happy.For example, increasing the MaxSpawnCount of the ConfigurableEncounters=(EncounterID=”ADVx2Standard”, section will increase the number of enemies spawned everytime the ADVx2Standard encounter is placed onto a mission. Once you’ve got your head around how this file works, you can adjust the numbers and types of enemies present on every mission in the game at your choosing.Alter the AI’s engagement ranges, movement patterns, and how much it cares about coverDefaultAI.ini is perhaps the most complicated file to mess with, but don’t worry, we’re only changing a few simple things to start with. Once you’ve opened the file, we’ll first find the FallbackChance line. Increasing this value to 0.75f should make enemies more likely to fall back to allies when they’re the only survivor of their patrol. Next, find CURRTILELINGERPENALTY and set it to 1.0. By default the AI is encouraged to move every turn to prevent camping—by changing this value we allow the AI free reign to hold their positions, meaning they won’t run around for the sake of running (and getting shot by your Overwatches). A few lines lower you’ll find CALCFULLCOVERFACTOR—make it equal 2.5f.
This increases how much the AI values Full / High cover when making its moves.Finally, open up DefaultGameDataWeaponData.ini again and find AdvTrooperM1idealRange. This entire section governs how close or far each enemy wants to be from your soldiers. For example, increasing the first value to AdvTrooperM1idealRange=12 encourages all ADVENT Troopers to stay around 12 tiles away from your squad. Setting AdvMECM1idealRange=1 encourages ADVENT MECs to charge your position, ending up 1 tile away from you in close combat.With this simple set of AI tweaks, you can radically alter how the game plays.
Setting ADVENT’s soldiers to fight you from a longer distance increases their survivability by keeping them away from your shotguns and grenades, while their MECs and tankier units can be configured to charge in and truly mess up your positioning. By more strongly prioritizing full cover and being allowed to hold position more often, the enemy will play more defensively and effectively, which is particularly challenging on timed missions as they stall you for turns. Increasing their likelihood to fall back when overwhelmed keeps enemies from suicide charging you in last ditch attacks, instead linking up with allies and living to fight another turn. It’s a lot tougher, but you might really appreciate the extra self-preservation instinct the AI will display—particularly when their new defensive tactics make those timed missions all the more intense to beat.ClosingThere’s absolutely tons of things you can change in XCOM 2’s config files, and we’ve only scratched the surface here. Once you’ve spent some time experimenting with some tweaks, you’ll gain familiarity and be able to tweak and adjust the game quickly and confidently. I can only hope next time you can’t find a ‘Make Incendiary Grenades cover the entire map in cleansing fire’ mod on the Steam Workshop, I’ll have equipped you with all you need to make your dream a reality.
Recently I've been working on a new method for randomizing soldier stats.While vanilla game includes the second wave option Not Created Equal, this option suffers from a few defects in my mind:. It confuses the idea of soldiers being 'not equal' with 'not identical'.
With the option on, some soldiers are better than others, but without it all soldiers are identical. It allows 'cherry picking' of the best soldiers, which overall makes the game slightly easier, in constrast to most of the other SW options.My original concept was to create a system by which soldier stats could be randomized so that not all soldiers were identical, but in which all such randomized soldiers were roughly equivalent (soldiers would be 'equal but not identical').The initial design was a form of point-buying system. Each stat would cost a certain number of points, and each soldier would have a fixed number of points to spend. IMO, classes and stat randomization are mutually exclusive.
In the OG there were no classes, but all the soldiers had different stats and could use any weapon/equipment, so players did manually what the new XCOM does automatically: they looked through soldiers and assigned a 'roles' to each one. XCOM Util helped very much to automate that job by adding marker strings to soldier names. Now we have a class system and any randomization is done within a class, so you can get a good sniper or a bad sniper, but you can't make a bad sniper to be a heavy.I think, even with the weighting system it will still be a bad soldier vs a good soldier.
Bads soldiers will be dismissed and good will contribute to an army of superhumans. But, if it would be possible to get rid of the classes completely, random stats would make sense. It would mean the return of micromanagement, but some people still like it (I certainly don't ).Or player should at least have an ability to pick a class manually, based on soldiers stats or his needs. If player could make use of all the soldiers he gets, it would make randomization more interesting.
Especially, if rookies were expensive, so one couldn't afford to recruit a dozens of rookies and keep only 2-3 with the best stats.Edited by wghost81, 30 January 2014 - 05:53 PM. Could you replace it with a system that requires you 'train' your soldiers? If they have bad stats you stick them in strength training for mobility, or rifle training to improve aim or something. It would work like the psi lab. The type of training a soldier gets could either be set when put into training or class locked. They can only be trained to some max increase, and each time you train them the cost (in meld or cash or whatever) goes up.
I have no idea if it's practical code wise, as I know the UE can be tricky to mode, but it seems like a good solution in that if you want super soldiers you have to work to get them. This would entirely replace the way NCE and HP work now so they would become defunct perhaps freeing up some coding space?It could be further hindered by making it so soldiers in rest can't train.Edited by hambil, 30 January 2014 - 06:06 PM. I like the idea and the work that you have done. I possibly would want a 'little' modification to what you have above. Instead of the base 54 for everyone, I would randomize that from 52-56 with 54 being the average.This way you can get a little more of a swing on the stats.The cost of soldiers can be increased so that it is hard to 'dismiss' a soldier because of the loss of funds.I tend to find use for all of my soldiers. Those that have poor stats still can contribute to the team (as red shirts.) and some of these soldiers can graduate to the regular squad based on luck and performance.Great work!.
IMO, classes and stat randomization are mutually exclusive. In the OG there were no classes, but all the soldiers had different stats and could use any weapon/equipment, so players did manually what the new XCOM does automatically: they looked through soldiers and assigned a 'roles' to each one. XCOM Util helped very much to automate that job by adding marker strings to soldier names. Now we have a class system and any randomization is done within a class, so you can get a good sniper or a bad sniper, but you can't make a bad sniper to be a heavy.I think, even with the weighting system it will still be a bad soldier vs a good soldier. Bads soldiers will be dismissed and good will contribute to an army of superhumans. But, if it would be possible to get rid of the classes completely, random stats would make sense.
It would mean the return of micromanagement, but some people still like it (I certainly don't ).Or player should at least have an ability to pick a class manually, based on soldiers stats or his needs. If player could make use of all the soldiers he gets, it would make randomization more interesting. Especially, if rookies were expensive, so one couldn't afford to recruit a dozens of rookies and keep only 2-3 with the best stats.From what I've read, about 6-8 months before release the classes weren't in the game. It was one of the design contributions that Ananda Gupta made after joining the project. I believe that the reasoning was the the perks were mostly assigned to weapons and gear, and feedback was that the playtesters were more attached to the gear than the soldiers, which wasn't ideal.That said, with only the basic 4 classes, and no player input into the process, I could definitely see a bit of frustration with particular stat combinations, such as having low aim on a sniper or low mobility on an assault. For Long War with the ability to select 1 of 2 subclasses it makes a bit more sense.
A low aim scout-sniper can be made into a scout, and a low mobility soldier can be made into an infantry instead of an assault.I'm curious though about the 'good soldier' vs 'bad soldier' sorting. Which of the above soldiers would you consider 'good' and which are 'bad'? Could you replace it with a system that requires you 'train' your soldiers? If they have bad stats you stick them in strength training for mobility, or rifle training to improve aim or something.
It would work like the psi lab. The type of training a soldier gets could either be set when put into training or class locked. They can only be trained to some max increase, and each time you train them the cost (in meld or cash or whatever) goes up.
I have no idea if it's practical code wise, as I know the UE can be tricky to mode, but it seems like a good solution in that if you want super soldiers you have to work to get them. This would entirely replace the way NCE and HP work now so they would become defunct perhaps freeing up some coding space?It could be further hindered by making it so soldiers in rest can't train.It might be possible, but would involve a fair bit of work. Reworking the perk tree interface to support the new psionics training system involved upwards of 50 changes to the upks, so it wasn't a trivial task at all.X-COM Apocalypse had a similar system by which your soldier stats could improve either directly through battle experience or via training in a dedicated facility ). However we can't exactly duplicate such a system, nor would I want to.I feel like there's a fine balance in giving the player 'too much control' vs 'not enough control'. If the player doesn't have enough controls, then she is at the mercy of the RNG, and the game doesn't allow enough meaningful decisions, which is fairly obvious a mistake. On the flip side giving the player too many controls leads to situations where the player doesn't have to be innovative in response to randomized events, and leads to each game developing in the same manner, which hurts replayability.One option that occurs to me is to reduce the auto-generated stats and tie some stat increases to the level-up perks instead, convolving perk selection with stat training to a degree. This could be a good way to help balance out different perks, since balancing them based just on the ability can be a bit tricky.
I'm curious though about the 'good soldier' vs 'bad soldier' sorting. Which of the above soldiers would you consider 'good' and which are 'bad'?Those are rookies. Low mobility/aim rookies will be 'bad' by themselves, as they would be hard to level up. And when they will receive a random class, their usefulness will depend on that class. Low mobility is bad for all classes, IMO.
Except, may be heavy rocketeer. Other stats are class dependent. HP/Defense/Will has little meaning for squadsight snipers, aim matters less for heavies and assaults with shotguns, etc. Point is, classes are assigned randomly, so you can't make your highest aim soldier a sniper and your highest HP soldier an assault, for example. If you could, it would be more fun, IMO.Classes or no classes, every player eventually end up with certain 'archetypes' he likes. There wasn't actually more variety in classless in OG than in new XCOM: there were scouts, snipers, stationary rocketeers, psionics.
New XCOM classes pretty much cover this. I miss only scouts, as battle scanners on squadsight snipers aren't that useful and snapshot sniper isn't actually a scout equivalent.IMO, random stats are more appropriate for RPG-like systems. If you could assign stat points manually on level up and choose a perks from a whole list, based on certain skill requirements, it would make more sense. At least to me.