Having more than 18 civilizations in a game

Tempas

Chieftain
Joined
Oct 5, 2008
Messages
2
Whenever I try to play a mod that uses more than 18 civs my game crashes, can someone help me with this? :/ thanks.
 
i have been thinking about this a bit myself. Until now, I have had no issue with having more than 18 civs in my game, but now I'd like to add the nineteenth on my map. In essence, I would like to create a map with 19 civilizations on it; just a scenario map, nothing fancy and not randomly generated ones. Random maps in my game can still be 18 at most. Is there anything I should think about when adding 19 kingdoms to a scenario map or can I just go ahead and add the 19th?

I've been thinking about this because 18 was the standard amount of civs in vanilla and I originally only planned to add 18 to my game as well, but now I've found that I will indeed have more than that.
 
.....aaaaaaaaahhhhhhhh.....an advanced modder, and doesn't know this.

I guess i somewhen have to write a FAQ.


Okay:
The 18 civs are hardcoded in the CvGameCoreDll. Without a new .dll, you can't get more than 18 civs on the map.
There is one 3.19 .dll for 50 civs in the database, you can use it.

If you then look at the scenario files/maps:
Normal maps have all the slots for 18 civs in them, even when they are "empty" (but they are there).
If you use a more civ .dll, then all these slots have to be added via a texteditor, because without your maps/scenarios will just crash.
 
No. I didn't know that, actually. I've decided against using 19 civs, since I won't be touching my dll, but thanks anyways.
 
@The_J How do I add more slots via texteditor? And where in the coding do I add more slots? I have the 50 civs .dll but I want to run scenarios. Please respond. If you do I will be so impressed :crazyeye: because I came 10 years late
 
@The_J How do I add more slots via texteditor? And where in the coding do I add more slots? I have the 50 civs .dll but I want to run scenarios. Please respond. If you do I will be so impressed :crazyeye: because I came 10 years late
To add more slots edit the CvDefines.h in the DLL folder and change the number 18 to whatever you want.
PHP:
#define MAX_CIV_PLAYERS                                                (18)
I tried this method to do a 200 civ dll and it didn't really work so I think I might be missing something or there is simply a limit as to how many max civs you can put.
Also don't forget to recompile the DLL after you finish.

To play on maps that ship with BtS or that simply where created in BtS you have to add more slots.
Here is an example:
HTML:
EndGame                       
BeginPlayer
    LeaderType=NONE
    CivType=NONE
    Team=0
    RandomStartLocation=false
EndPlayer
BeginPlayer
    LeaderType=NONE
    CivType=NONE
    Team=1
    RandomStartLocation=false
If you added 50 civs in the DLL you will have to make 50 teams.
Hopefully The_J does reply to tell us if there actually is another file that has to be edited.
 
I tried this method to do a 200 civ dll and it didn't really work so I think I might be missing something or there is simply a limit as to how many max civs you can put.
Also don't forget to recompile the DLL after you finish.
Maybe 128?
If you added 50 civs in the DLL you will have to make 50 teams.
But don't forget that the index goes only till 49. (I did once when converting a map :twitch: )
 
Hm... I wonder if you could turn that define into a global variable and have it be read from the XML.

Maybe 128?
Doubtful. I am looking at the source for the game and nowhere is the define used to fill anything but an integer. So unless the game is compiled in 8 bit mode 128 won't be the limit. Not that there might not be a 128 limit anyway but if so it's hardcoded in the exe.
 
Hm... I wonder if you could turn that define into a global variable and have it be read from the XML.


Doubtful. I am looking at the source for the game and nowhere is the define used to fill anything but an integer. So unless the game is compiled in 8 bit mode 128 won't be the limit. Not that there might not be a 128 limit anyway but if so it's hardcoded in the exe.
Till now the record is 100 with Merkava's 100 CIV DLL.
The thing I don't understand and makes me think that I was missing something is that if it is literally this easy to change one number to anything why hasn't a 200 civ DLL been created, or 300? So I'm probably missing some important information.
But anyway even if someone manages to edit the EXE and recompile it (which I doubt will happen) and changes the code to let up to 1000 Civs to be edited in the DLL the game will simply crash. Even with 100 Civs it's extremely laggy and with the 200 Civ one it took so long to load I just gave up waiting.
 
Decompiling and recompiling the exe isn't practical. If it was Java you might just get away with it but with C++ you will at best get something that only the original developers might recognize and be able to work with. And that's before we get into the whole legality issue.
 
Hi everyone,
I tried to install a mod to have more than 18 civs and i found a mod than let you play with 40civs (34 if you want colonies) but i cannot get him to work, ive downloaded it and i have a file named "40civs" with "40civs.ini" "readme" and "assets" in it and in "assets" there is the .dll file , i want to merge it with my CIV GOLD folders (all is done in the steamapps/common folders)
1)
put the .dll file into the "assets" folder of my "CIV GOLD" mod, it didnt work.
1681141800088.png
(deleted here)

2)
put the .dll file before my "assets" folder , didnt work
1681141820492.png
(at the bottom)
3)
put the "40civs" all together into the my "assets" folder, same result

now i dont know what to do or where to put the files !
1681141738923.png
1681141755427.png
1681141771030.png
 
You can't merge mods like that. CIV4 mods are standalone things that you install into the MODS folder of your CIV4 folder and load individually. And you can only run one at a time.
 
Top Bottom