How does Barbarian Spawning work?

Look in CvGame.cpp: CvGame::createBarbarianUnits(), it could give you a hint.

Note that you need a minimum of cities for "non-animal" barbs to spawn: if (getNumCivCities() < ((countCivPlayersAlive() * 3) / 2), in other words, if you have 5 Players alive, you need to have (5 *3 /2) a minimum of 8 cities in total on the map for the "non-animals" to spawn.
 
Hmmm.. I stillo don't seem to be getting human barbs.. I changed the code to this:

if (getNumCivCities() < ((countCivPlayersAlive()))

But I still don't seem to get any human barbs spawning, even when I add a couple extra cities...

I must be missing something but I have no idea what!

(I have also lowered the numbers in handicapinfos to try and get them spawning...)
 
Well, the other usual suspects are GamespeedInfo & EraInfos.

Maybe it has to do with the already high number of strong animals that I've seen on the map launching your game a few times. I know that you have the Kael trick to not kill animals when humans are out, but if nobody goes out to kill the animals, their number and strength might prevent the spawning of humans. Just a thought, I haven't played your mod long enough to know for sure.

I have krakens in my oceans and as long as they are not killed, barbs ships do not come in numbers.
 
yeah, my latest game has a few human barbs wandering around, but I was thinking the same, that the high number of animals might some how be limiting humans... Not sure what to do about fixing this.

I wonder if an animal on a tile counts that tile as being 'owned' for the purposes of the calculation of unowned tiles for barbs... I don't know..
 
animals don't own tiles. owned tiles are those that are colored in the team color, including barbarian tiles themself.
in the CIV4EraInfos.xml there are two settings:

Code:
			<bNoAnimals>1</bNoAnimals>
			<bNoBarbUnits>0</bNoBarbUnits>

if the second one is 1 then it will spawn only animals in that era. if it is 0 then the animals will get randomly deleted one at a time and normal barbs will spawn instead.
but as long as the animals are still around they will count as barb units, so the game may decide there are already enough barbs for that continent and not spawn any more.
also the barbs actually will need units avaiable to be spawned. in normal game the warrior needs no tech so it is always avaiable. if you changed that in your mod though, the barbs may simply have no unit to spawn until they catch up in tech.
 
Back
Top Bottom