• This is a read only backup of the old Emudevs forum. If you want to have anything removed, please message me on Discord: KittyKaev

Company of Heroes 2 - Increased Population Cap Modification

Tommy

Founder
This will increase your max population cap to 300 in Company of Heroes 2. However, if you want to increase the population cap even further, you can extract the .sga file located in the PopcapMod/Archives/ with Santo's TOOLS, then you can increase the population to whatever you want and convert it back to a .sga with COH2_SGABUILDER_TOOL

COH2 Population Cap Modification Download


INSTALLATION:

(STEAM):

1. Extract the files into your Steam\steamapps\common\Company of Heroes\ directory.
2. Find your game shortcut in your steam library.
2. Right click it and click on 'SET LAUNCH OPTIONS'
3. Put -mod popcapmod inside of the box that pops up.
4. Click OK and you're done. Launch the game have enjoy!

(NON-STEAM):

1. Extract contents of the downloaded .zip archive to your Company of Heroes 2 installation directory and create a new shortcut to RelicCoH2.exe
One way of making a new shortcut:
-Right click on RelicCoH2.exe and select Send to -> Desktop (create shortcut)
-Default path to Company of Heroes 2 installation folder in Windows 7 is C:\Program Files (x86)\Steam\steamapps\common\Company of Heroes 2\
-RelicCoH2.exe is located in this folder.

2. Right click on your newly created shortcut. Select Properties.
3. Add -mod popcapmod after the last quotation mark in Field called "Target" under "Shortcut" Tab. Notice the space before last quotation mark and -mod.
3 EXAMPLE: "C:\Program Files (x86)\Steam\steamapps\common\Company of Heroes 2\RelicCoH2.exe" -mod popcapmod
4. Press Apply and OK
5. Double click the shortcut to launch Company of Heroes 2.


TOOL INFORMATION:

Santo's TOOLS, allows you to extract the .sga file located in "PopcapMod/Archives/". Once you extract the .sga file, search for "Player_SetPopCapOverride(player, 300);" and change "300" to whatever you want it to be.

COH2_SGABUILDER_TOOL, allows you to build your edited file back into .sga. Replace your old .sga file with your new one and have fun!

Enjoy!


UPDATE:
There has been some updates to WorldBuilder so when you edit the Player_SetPopCapOverride() you need to
completely remove that line and add the following:
Code:
g_popCapOverRide = 500
for i = 1, World_GetPlayerCount() do
	local player = World_GetPlayerAt(i)
	Player_SetPopCapOverride(player, g_popCapOverRide)
end

Obviously change the g_popCapOverRide amount to what you prefer.

You can also add when you are making a custom map. You simply add it to the (mapname)_ID.scar under
function OnInitID() AFTER you save the map and BEFORE you export the map package.
 
Last edited by a moderator:

Hyperion

Founder
You can also raise your resources in the same code by doing:

Code:
Player_SetResource(player, RT_Manpower, #)
Player_SetResource(player, RT_Munition, #)
Player_SetResource(player, RT_Fuel, #)

just replace # with the number amount you want.
 

PSYCHO Ghost

Enthusiast
I cant get your mod to work?

I have followed all steps you listed and the game wont even lunch when I add the "-mod popcapmod" to the target location.

Please help, the pop cap is killing me.
 

Tommy

Founder
Where did you add it, steam or a desktop shortcut? After adding it, did you run it as administrator? Also, make sure you put the files in the right place.
 

PSYCHO Ghost

Enthusiast
Where did you add it, steam or a desktop shortcut? After adding it, did you run it as administrator? Also, make sure you put the files in the right place.


I extracted the files into the COH2 Directory (the mod folder and file) then I added the -mod target to the launcher on both steam and desktop and tried both ways, nether worked. When I try to open in on the desktop I get a "bug splat" error report popup. When I open it on steam it acts like it wants to open and runs what appears to be a update that will not work.
 

Tommy

Founder
I extracted the files into the COH2 Directory (the mod folder and file) then I added the -mod target to the launcher on both steam and desktop and tried both ways, nether worked. When I try to open in on the desktop I get a "bug splat" error report popup. When I open it on steam it acts like it wants to open and runs what appears to be a update that will not work.

Both Faded and I never received that issue. But, the game is very sensitive. I mean very, very sensitive. All we did was add the -mod popcapmod to our launch options, started the game and it worked the first time.
 

Hyperion

Founder
I extracted the files into the COH2 Directory (the mod folder and file) then I added the -mod target to the launcher on both steam and desktop and tried both ways, nether worked. When I try to open in on the desktop I get a "bug splat" error report popup. When I open it on steam it acts like it wants to open and runs what appears to be a update that will not work.

Your mod is like this right?
gaag0pj.png

TjEPyxR.png

iID3A01.png


If you're getting an instant bugsplat while launching it via desktop then the mod isn't getting read. Are you getting a COH2 update every time you run it with steam?
 

PSYCHO Ghost

Enthusiast
Your mod is like this right?
gaag0pj.png

TjEPyxR.png

iID3A01.png


If you're getting an instant bugsplat while launching it via desktop then the mod isn't getting read. Are you getting a COH2 update every time you run it with steam?

Yes,

Mine looks just like that, I have no other mods or extra files added.. brand new install.
 

PSYCHO Ghost

Enthusiast
Ok so I deleted all desktop launchers and now it is currently updating on steam and I am waiting to see if it will work. I am using your files.

- - - Updated - - -

It still did not work, BUG SPLAT haha...
 

Hyperion

Founder
Hmm..

Take out the launch command, run COH2 like normal, start a random skirmish game.

Then exit, readd the launch command and try running it again. (leave the mod files where they are)
 

PSYCHO Ghost

Enthusiast
No dice, I ran the game as is with no -mod popcapmod in the launcher. It worked fine and then I exited the game to windows and inserted the target back into the launcher, then BUG SPLAT! lol
 

Hyperion

Founder
Is there any other trouble shooting steps that anyone can think of?

I have no idea. This is actually an on-going issue with COH2 and custom mods. There
are some posts out there of people complaining about the mod working but the game
always wanting to update when you start it. I think there are a few suggestions from
other people.

We know the mod works, it's this issue with how COH2 is handling it that keeps
trying to update the game when using the mod.. Never bothered to look in to it
because we didn't experience the problem more than a few times.
 

alwaysbehumble

Enthusiast
What to enter the box?

Just to confirm:
You mean to enter the entire "-mod PopcapMod“ into the box? Not just "-mod"?
If I only enter "-mod", the game loads properly.
However, when I try the whole line of "-mod popcapmod", it invariably fails to launch with an error message.
Also, does the modification apply to custom maps or only to campaign missions?
Thanks a lot!
 

Hyperion

Founder
Just to confirm:
You mean to enter the entire "-mod PopcapMod“ into the box? Not just "-mod"?
If I only enter "-mod", the game loads properly.
However, when I try the whole line of "-mod popcapmod", it invariably fails to launch with an error message.
Also, does the modification apply to custom maps or only to campaign missions?
Thanks a lot!

The mod is for both campaign and multiplayer (both players must use mod)

Also, yes -mod PopcapMod to load

What error are you receiving?
 
Top