Jump to content
Sign in to follow this  

Just need a little guidance with an addon issue.

Recommended Posts

Kind of a wall of text but hear me out please.

Hey there, kinda new to getting involved with the OFP community and modding the game in general. I have a decent amount of experience in vanilla Flashpoint, but in regards to addons and the like, I'm pretty cherry.

Anyway, I'm working on a scenario in the mission editor that is basically an open world ghillie sniper sandbox, with civilian populated towns and commuting villagers all on the island of Everon. I won't bore you with details but I really want to get this done because it could very well be the best experience I have yet to have in this game.

My main issue is the whole 63 group limit per side crap. By exploiting groups and such I was able to make civilians walk around in an idle manner and react to western forces and firefights. This caused for some really cool situations and added a whole new breath of life to Everon. The problem is that in order to make them behave this way, I had to do the 'never spawning Russian leader' alliance exploit and tweak the fleeing settings. Then I added some waypoints with a placement radius on some casual settings and some timeouts and boom, they walk around like regular people. It looks great, but the problem is that each civilian counts as one group, and placing them in a group together stops them from acting independent. As you can imagine, making towns realistically populated hits the 63 mark pretty quick. And what's worse is that due to the leader exploit, these groups are actually counting towards the Russian group tickets. So I can't even add any enemies.

After hours of scouring the internet, I found this:


I screamed like a girl because this is exactly what I need. The issue is, I stuck it in the addons folders for OFP, Res, and FFUR (I'm running FFUR 2.5 on this map, in case that's a factor), but when I load the game (through a standard OFPRES shortcut with an edited target to include FFUR 2007) I see nothing different in the editor, and when I try to preview a map with a ton of groups, it still prevents me because of the limit.

Is there something I could be doing wrong? Perhaps reference something? Because I also have a gore addon in all those folders and that doesn't seem to work either. Not even in regular OFPRes, as well as the limit remover. I would love to hear it, because I really need this.

Or if anyone has a script that would remove the need for this group crap or any other workaround that'd be great too.

Share this post

Link to post
Share on other sites


To make civilian react to western forces and firefights the solution would be to make resistance friendly to east (click one the date/hour button and set resistance friendly to east). Civilians will react if they knowsAbout west. Keep civilians CIV side don't need to change to EAST like that it will solve your 63 groups issue.

For the walk around stuff I'm afraid there's no other elegant scripting solution than set the civilians in individual group or they will move in formation and sometimes run and it doesn't look natural.

You could make a script like this (not tested):


_grp=select 0

_u=leader _grp
_gp=getPos _u

? !(alive _u): goto _ende
_idlewpdist=-25+random 50
_idlemovepos=[(_gp select 0)+_idlewpdist,(_gp select 1)+_idlewpdist,_gp select 2]
_grp move _idlemovepos
goto "idle"



Give each civilian a group name with groupName=group this and execute the script with [groupName] exec "scriptName.sqs"

EDIT: Just remember that kenoxite made civilian population script. I suggest to use this since there's much more possibilities.



Share this post

Link to post
Share on other sites

Hey. Big thanks for responding. Really appreciate it.

The mission I'm working on is a dynamic, explorable world. I have a big agenda for it, and that agenda unfortunately includes Resistance forces being hostile to everyone. Just about every faction is at play here. So I can't exploit another group for units any more than I already am.

As for the script, it could very well be a fix for taking up Russian tickets, I'll have to test it. And Kenoxite's script looks like it'd do the trick as well.

Thanks for the help, man. I'll get back to you with the result.

Edit: Forgot. A sure fix though would be getting the addon I posted to work. After some testing and such, the addon does indeed load (I can spawn the new civilian units) and is working to the extent it can, but the group limit is the only thing not changing. There's no documentation at all on it. Would I maybe have to reference it in a file header or something? Make a target with some settings or...?

Any idea?

Another Edit: Alright, so I opened the PBO and found a lone .cpp file. Here's what Visual C++ gave me:

#define TEast		0
#define TWest		1
#define TGuerrila		2
#define TCivilian		3
#define TSideUnknown	4
#define TEnemy		5
#define TFriendly		6
#define TLogic		7
#define true		1
#define false		0
#define private		0
#define protected		1
#define public		2
#define WeaponNoSlot	0
#define WeaponSlotPrimary	1
#define WeaponSlotSecondary	16
#define WeaponSlotItem	256
#define WeaponSlotBinocular	4096
#define WeaponHardMounted	65536
class CfgPatches{
class SoldierCBRus{units[]={SoldierCBRus};weapons[]={};requiredVersion=1.75;};
class SoldierGBRus{units[]={SoldierGBRus};weapons[]={};requiredVersion=1.75;};
class CfgVehicles{
//	russische Soldaten für Resistance und Civilian
class All{};
class AllVehicles:All{};
class Land:AllVehicles{};
class Man:Land{};
class Soldier:Man{};
class SoldierEB:Soldier{};
class SoldierCBRus:SoldierEB{displayName=" rus. Soldier";Side=3;};
class SoldierGBRus:SoldierEB{displayName=" rus. Soldier";Side=2;};
class SoldierEG:SoldierEB{};
class SoldierCGRus:SoldierEG{displayName=" rus. Grenadier";Side=3;};
class SoldierGGRus:SoldierEG{displayName=" rus. Grenadier";Side=2;};
class SoldierEMG:SoldierEB{};
class SoldierCMGRus:SoldierEMG{displayName=" rus. PK Gunner";Side=3;};
class SoldierGMGRus:SoldierEMG{displayName=" rus. PK Gunner";Side=2;};
class SoldierECrew:SoldierEB{};
class SoldierCCrewRus:SoldierECrew{displayName=" rus. Crew";Side=3;};
class SoldierGCrewRus:SoldierECrew{displayName=" rus. Crew";Side=2;};
class SoldierELAW:SoldierEB{};
class SoldierCLAWRus:SoldierELAW{displayName=" rus. RPG Gunner";Side=3;};
class SoldierGLAWRus:SoldierELAW{displayName=" rus. RPG Gunner";Side=2;};
class SoldierEAT:SoldierELAW{};
class SoldierCATRus:SoldierEAT{displayName=" rus. AT4 Gunner";Side=3;};
class SoldierGATRus:SoldierEAT{displayName=" rus. AT4 Gunner";Side=2;};
class SoldierEAA:SoldierELAW{};
class SoldierCAARus:SoldierEAA{displayName=" rus. AA Gunner";Side=3;};
class SoldierGAARus:SoldierEAA{displayName=" rus. AA Gunner";Side=2;};
class SoldierESniper:SoldierEB{};
class SoldierCSniperRus:SoldierESniper{displayName=" rus. Sniper";Side=3;};
class SoldierGSniperRus:SoldierESniper{displayName=" rus. Sniper";Side=2;};
class SoldierEMedic:SoldierEB{};
class SoldierCMedicRus:SoldierEMedic{displayName=" rus. Medic";Side=3;};
class SoldierGMedicRus:SoldierEMedic{displayName=" rus. Medic";Side=2;};
class SoldierEMiner:SoldierEB{};
class SoldierCMinerRus:SoldierEMiner{displayName=" rus. Ingenieur";Side=3;};
class SoldierGMinerRus:SoldierEMiner{displayName=" rus. Ingenieur";Side=2;};
class SoldierEPilot:SoldierEB{};
class SoldierCPilotRus:SoldierEPilot{displayName=" rus. Pilot";Side=3;};
class SoldierGPilotRus:SoldierEPilot{displayName=" rus. Pilot";Side=2;};
class HeavyGrenadier:SoldierEB{};
class HeavyGrenadierCGRus:HeavyGrenadier{displayName=" rus. Heavy Grenadier";Side=3;};
class HeavyGrenadierGGRus:HeavyGrenadier{displayName=" rus. Heavy Grenadier";Side=2;};
class OfficerE:SoldierEB{};
class OfficerCRus:OfficerE{displayName=" rus. Officer (Day)";Side=3;};
class OfficerGRus:OfficerE{displayName=" rus. Officer (Day)";Side=2;};
class OfficerENight: SoldierEB{};
class OfficerCNightRus:OfficerENight{displayName=" rus. Officer (Night)";Side=3;};
class OfficerGNightRus:OfficerENight{displayName=" rus. Officer (Night)";Side=2;};
class SoldierESaboteur:SoldierESniper{};
class SoldierESaboteurPipe:SoldierESaboteur{};
class SoldierCSaboteurPipeRus:SoldierESaboteurPipe{displayName=" rus. Speznaz (AK74SU)";Side=3;};
class SoldierGSaboteurPipeRus:SoldierESaboteurPipe{displayName=" rus. Speznaz (AK74SU)";Side=2;};
class SoldierESaboteurBizon:SoldierESaboteurPipe{};
class SoldierCSaboteurBizonRus:SoldierESaboteurBizon{displayName=" rus. Speznaz (Bizon)";Side=3;};
class SoldierGSaboteurBizonRus:SoldierESaboteurBizon{displayName=" rus. Speznaz (Bizon)";Side=2;};

//	Amerikanische Soldaten für Resistance und Civilian
class SoldierWB:Soldier{};
class SoldierCBUS:SoldierWB{displayName=" US Soldier";Side=3;};
class SoldierGBUS:SoldierWB{displayName=" US Soldier";Side=2;};
class SoldierWG:SoldierWB{};
class SoldierCGUS:SoldierWG{displayName=" US Grenadier";Side=3;};
class SoldierGGUS:SoldierWG{displayName=" US Grenadier";Side=2;};
class SoldierWMG:SoldierWB{};
class SoldierCMGUS:SoldierWMG{displayName=" US M60 Gunner";Side=3;};
class SoldierGMGUS:SoldierWMG{displayName=" US M60 Gunner";Side=2;};
class SoldierWCrew:SoldierWB{};
class SoldierCCrewUS:SoldierWCrew{displayName=" US Crew";Side=3;};
class SoldierGCrewUS:SoldierWCrew{displayName=" US Crew";Side=2;};
class SoldierWLAW:SoldierWB{};
class SoldierCLAWUS:SoldierWLAW{displayName=" US LAW Gunner";Side=3;};
class SoldierGLAWUS:SoldierWLAW{displayName=" US LAW Gunner";Side=2;};
class SoldierWAT:SoldierWLAW{};
class SoldierCATUS:SoldierWAT{displayName=" US AT Gunner";Side=3;};
class SoldierGATUS:SoldierWAT{displayName=" US AT Gunner";Side=2;};
class SoldierWAA:SoldierWLAW{};
class SoldierCAAUS:SoldierWAA{displayName=" US AA Gunner";Side=3;};
class SoldierGAAUS:SoldierWAA{displayName=" US AA Gunner";Side=2;};
class SoldierWSniper:SoldierWB{};
class SoldierCSniperUS:SoldierWSniper{displayName=" US Sniper";Side=3;};
class SoldierGSniperUS:SoldierWSniper{displayName=" US Sniper";Side=2;};
class SoldierWMedic:SoldierWB{};
class SoldierCMedicUS:SoldierWMedic{displayName=" US Medic";Side=3;};
class SoldierGMedicUS:SoldierWMedic{displayName=" US Medic";Side=2;};
class SoldierWMiner:SoldierWB{};
class SoldierCMinerUS:SoldierWMiner{displayName=" US Ingenieur";Side=3;};
class SoldierGMinerUS:SoldierWMiner{displayName=" US Ingenieur";Side=2;};
class SoldierWPilot:SoldierWB{};
class SoldierCPilotUS:SoldierWPilot{displayName=" US Pilot";Side=3;};
class SoldierGPilotUS:SoldierWPilot{displayName=" US Pilot";Side=2;};
class OfficerW:SoldierWB{};
class OfficerCUS:OfficerW{displayName=" US Officer (Day)";Side=3;};
class OfficerGUS:OfficerW{displayName=" US Officer (Day)";Side=2;};
class HeavyGW:SoldierWB{};
class HeavyGCGUS:HeavyGW{displayName=" US Heavy Grenadier";Side=3;};
class HeavyGGUS:HeavyGW{displayName=" US Heavy Grenadier";Side=2;};
class OfficerWNight:SoldierWB{};
class OfficerCNightUS:OfficerWNight{displayName=" US Officer (Night)";Side=3;};
class OfficerGNightUS:OfficerWNight{displayName=" US Officer (Night)";Side=2;};
class SoldierWSaboteur:SoldierWSniper{};
class SoldierWSaboteurDay:SoldierWSaboteur{};
class SoldierCSaboteurDayUS:SoldierWSaboteurDay{displayName=" US SpecOp Day (HK)";Side=3;};
class SoldierGSaboteurDayUS:SoldierWSaboteurDay{displayName=" US SpecOp Day (HK)";Side=2;};
class SoldierWSaboteurPipe:SoldierWSaboteur{};
class SoldierCSaboteurPipeUS:SoldierWSaboteurPipe{displayName=" US SpecOp (HK)";Side=3;};
class SoldierGSaboteurPipeUS:SoldierWSaboteurPipe{displayName=" US SpecOp (HK)";Side=2;};

//	Zivilisten für Resistance, East und West
class Civilian:Man{};
class CivilianE:Civilian{displayName=" rus. 1. Men";Side=0;};
class CivilianW:Civilian{displayName=" US 1. Men";Side=1;};
class CivilianG:Civilian{displayName=" res. 1. Men";Side=2;};
class Civilian2:Civilian{};
class Civilian2E:Civilian2{displayName=" rus. 2. Men";Side=0;};
class Civilian2W:Civilian2{displayName=" US 2. Men";Side=1;};
class Civilian2G:Civilian2{displayName=" res. 2. Men";Side=2;};
class Civilian3:Civilian{};
class Civilian3E:Civilian3{displayName=" rus. 3. Men";Side=0;};
class Civilian3W:Civilian3{displayName=" US 3. Men";Side=1;};
class Civilian3G:Civilian3{displayName=" res. 3. Men";Side=2;};
class Civilian4:Civilian{};
class Civilian4E:Civilian4{displayName=" rus. 4. Men";Side=0;};
class Civilian4W:Civilian4{displayName=" US 4. Men";Side=1;};
class Civilian4G:Civilian4{displayName=" res. 4. Men";Side=2;};
class Civilian5:Civilian{};
class Civilian5E:Civilian5{displayName=" rus. 5. Men";Side=0;};
class Civilian5W:Civilian5{displayName=" US 5. Men";Side=1;};
class Civilian5G:Civilian5{displayName=" res. 5. Men";Side=2;};
class Civilian6:Civilian{};
class Civilian6E:Civilian6{displayName=" rus. 6. Men";Side=0;};
class Civilian6W:Civilian6{displayName=" US 6. Men";Side=1;};
class Civilian6G:Civilian6{displayName=" res. 6. Men";Side=2;};
class Civilian7:Civilian{};
class Civilian7E:Civilian7{displayName=" rus. 7. Men";Side=0;};
class Civilian7W:Civilian7{displayName=" US 7. Men";Side=1;};
class Civilian7G:Civilian7{displayName=" res. 7. Men";Side=2;};
class Civilian8:Civilian{};
class Civilian8E:Civilian8{displayName=" rus. Police (Scorpion)";Side=0;};
class Civilian8W:Civilian8{displayName=" US Police (Scorpion)";Side=1;};
class Civilian8G:Civilian8{displayName=" res. Police (Scorpion)";Side=2;};
class Civilian9:Civilian{};
class Civilian9E:Civilian9{displayName=" rus. 9. Men";Side=0;};
class Civilian9W:Civilian9{displayName=" US 9. Men";Side=1;};
class Civilian9G:Civilian9{displayName=" res. 9. Men";Side=2;};
class Civilian10:Civilian{};
class Civilian10E:Civilian10{displayName=" rus. 10. Men";Side=0;};
class Civilian10W:Civilian10{displayName=" US 10. Men";Side=1;};
class Civilian10G:Civilian10{displayName=" res. 10. Men";Side=2;};
class Civilian11:Civilian{};
class Civilian11E:Civilian11{displayName=" rus. Police (CZ 75)";Side=0;};
class Civilian11W:Civilian11{displayName=" US Police (CZ 75)";Side=1;};
class Civilian11G:Civilian11{displayName=" res. Police (CZ 75)";Side=2;};
class Woman1:Civilian{};
class Woman1E:Woman1{displayName=" rus. 1. Woman";Side=0;};
class Woman1W:Woman1{displayName=" US 1. Woman";Side=1;};
class Woman1G:Woman1{displayName=" res. 1. Woman";Side=2;};
class Woman2:Civilian{};
class Woman2E:Woman2{displayName=" rus. 2. Woman";Side=0;};
class Woman2W:Woman2{displayName=" US 2. Woman";Side=1;};
class Woman2G:Woman2{displayName=" res. 2. Woman";Side=2;};
class Woman3:Civilian{};
class Woman3E:Woman3{displayName=" rus. 3. Woman";Side=0;};
class Woman3W:Woman3{displayName=" US 3. Woman";Side=1;};
class Woman3G:Woman3{displayName=" res. 3. Woman";Side=2;};
class Woman4:Civilian{};
class Woman4E:Woman4{displayName=" rus. 4. Woman";Side=0;};
class Woman4W:Woman4{displayName=" US 4. Woman";Side=1;};
class Woman4G:Woman4{displayName=" res. 4. Woman";Side=2;};
class Woman5:Civilian{};
class Woman5E:Woman5{displayName=" rus. 5. Woman";Side=0;};
class Woman5W:Woman5{displayName=" US 5. Woman";Side=1;};
class Woman5G:Woman5{displayName=" res. 5. Woman";Side=2;};

I don't know about you, but I can't say I see anything I would assume would pertain to increasing that unit cap. All I see is the civilian feature.

Could it just be a case of false advertising?

Yet Another Edit: Thought about it a bit. I think it was actually a case of really, really bad German translated context. By adding soldiers from one faction to another, you could theoretically triple the amount of units of that faction that can be created. The description sort of claims this, but also claims it physically changed the actual limit. Whatever. I guess it's useful.

Anyway, I get to work testing that stuff out now. Thanks for the help again.

Edited by PivMan
Forgot a detail.

Share this post

Link to post
Share on other sites

Is spawning civilian AI only to exist near the player out of question? That would solve both bad performance and the group limit.

When I tried maxing out two sides (1512 units) with every unit fighting, my fps drops to single digits. OFP wasn't programmed to have that many AI active at once.

Share this post

Link to post
Share on other sites

I had actually never considered that kind of an approach.

I didn't encounter much if any FPS loss when I had a ton of AI existing because they were all in a near idle manner. All they did was repeat a waypoint, and only got into what was considered combat when a Western soldier approached and they ran for the hills. The whole setup wasn't very CPU taxing, as long as they weren't being rendered in large amounts, and there was maybe twenty planned at most per town in Everon.

Wouldn't that kind of an approach involve scripting though? Do units spawned via script even count towards group total? If yes, then that may be my answer, as CivPop didn't do things in the manner I'd like them.

A potential issue with that would be keeping it MP compatible, as I plan on using this mission for.

Share this post

Link to post
Share on other sites

Even idly walking AI use considerable CPU because of the path finding. Yes, it would involve scripting, why, is that an issue? Spawned units count, you cannot exceed group count or group size.

If it's internet MP, with these kinds of numbers you are pretty much forced to create the AI dynamically or have terrible desync as every moving unit will use server bandwidth constantly.

There are several ready MP compatible solutions but you will probably have to modify them slightly for your needs. Dynamic AI-creator (DAC) and Chain of Command AI-on-demand come to mind.

Share this post

Link to post
Share on other sites

Are you sure about the idle units and CPU? I'm using a laptop grade i3 and haven't had any issue with a ton of civilians walking around the island. Combat is a whole 'nother story, but two waypoints with large placement radii per unit ran fine. I guess it's good to cut back as much as possible though.

Anyway, I'd never been sure if units created via script could exceed the group limit. What does the game do if you exceed it in-game? Just crash or something?

There must be some kind of workaround in place if CivPop is able to handle hundreds of civilians doing their own thing.

I'll be sure to look into CoC, but isn't DAC an ArmA 2 add-on? Or was it ported to it or am I all sorts of wrong?

Share this post

Link to post
Share on other sites

Yes I am sure. If you don't see it, you just haven't placed enough units to cause a noticeable fps drop. With 756 units standing still doing nothing, on my PC I get 52 fps and if the AI is running forwards 30 fps. Without the AI it's 220 fps on Everon.

The scripting commands simply don't allow you to exceed the limit (createUnit will not create a unit, join grpNull will not disband the unit from its group). If you'd manage to bypass the limits with some trickery, it would probably cause the game to crash or some other unexpected results such as schizophrenic AI.

DAC was originally made for OFP.

Share this post

Link to post
Share on other sites

Gotcha. I guess CivPop couldn't actually be unlimited then.

I'll take a look at DAC for Flashpoint. Big thanks.

Share this post

Link to post
Share on other sites


Why not use kenoxite's civilian population script instead of modifying DAC, IMHO it's well coded and exactly made for your needs. It dynamically spawns/despawns civilians on each town player approach/go away. With this solution you have the feeling of populated island.



Edited by Nikiller

Share this post

Link to post
Share on other sites

Please sign in to comment

You will be able to leave a comment after signing in

Sign In Now
Sign in to follow this