Also, more simply, if I put one variant per rank I'd clog the alien race with Spitters, leaving too little room for other species of aliens (ranks are AFAIK a fixed number).
You can have more than 8 ranks on each alienRace entry (on my Area 51 mod all the alienRaces have 12 ranks), so you could define the alienRace as:
alienRaces:
- id: STR_MY_ALIEN_RACE
members:
- STR_ALIEN_COMMANDER
- STR_ALIEN_LEADER
- STR_ALIEN_ENGINEER
- STR_ALIEN_MEDIC
- STR_ALIEN_NAVIGATOR
- STR_ALIEN_A
- STR_ALIEN_B
- STR_ALIEN_C
- STR_ALIEN_MONSTER
- STR_ALIEN_TERRORIST
But for it to work, you'll also need to adjust the alienDeployment entries where these extended alienRaces are used, such as:
- type: STR_TERROR_MISSION
data:
- alienRank: 5
lowQty: 4
highQty: 8
dQty: 1
- alienRank: 3
lowQty: 3
highQty: 3
dQty: 1
- alienRank: 1
lowQty: 1
highQty: 1
dQty: 0
- alienRank: 6
lowQty: 0
highQty: 1
dQty: 1
- alienRank: 7
lowQty: 0
highQty: 1
dQty: 1
- alienRank: 8
lowQty: 0
highQty: 1
dQty: 1
- alienRank: 9
lowQty: 0
highQty: 1
dQty: 1
However, there's
one major caveat that you need to be aware concerning the spawning of the additional ranks: the map files can only contain information about 8 ranks, so what OXC does to place these units is that it considers all additional ranks (8 and 9 on this example) as rank 0, which is used on the map files to spawn alien scouts (units that start outside the UFO), terror units and civilians. So, if you have rank 8, 9 or more, they'll only spawn on route nodes assigned to rank 0.
The way I solved this issue in Area 51 was that I simply assigned the 4 additional ranks only to terror units, so those will always spawn on correct locations. But you can also use enlarged alienRaces to spawn non-terror units of ranks 8 or more, if you use builtInWeaponSets to ensure that they'll start equipped with weapons (assuming that you don't want to assign weapons to those ranks through alienDeployments). However, remember that those non-terror units will always be spawned in rank 0 nodes.
One final suggestion I make is that you either convert all alienRaces to the enlarged format, or there's a risk that an alienDeployment will require the enlarged alienRace to work but the missionScript will randomly assign it a vanilla alienRace, and the missing ranks will cause the game to crash. But, if you limit the enlarged alienRaces to specific alienDeployments you don't run this risk.