Closed
thanks Star/Clad for replying. I've found an acceptable solution.
i am not a dev, but have you tried the gameconstants file in the gameinfo folder? you can set the max amout of pirates, i believe default is set at from 1 to 220, and there are options breaking down each group by type of craft. I haven't tried it this way, but i did create a map with 9 pirate bases on it just for fun in galaxyforge. ![]()
From my understanding, the only chance in choosing a template is which one is desired. there's values that give probability of whether a pirate system shows up, but from playing the different maps several times, there's always at least one pirate base, heavily defended. The template info each galaxy references is from the GalaxyScenarioDef.galaxyScenarioDef file. The galaxy files that do randomization pick from one of the templates, and probably put a main pirate base somewhere in the middle.
I know the probablities of spawn, the Param "". I'm not messing with the constant file that governs what a pirate raid generates; it's the template I'm after.
Take the general Vanilla PirateBase Template:
| planetItemsTemplate | ||||
| templateName "Template:PirateBase" | ||||
| subTemplates 0 | ||||
| groups 1 | ||||
| group | ||||
| condition | ||||
| type "Always" | ||||
| param "" | ||||
| owner "Pirate" | ||||
| colonizeChance 1 | ||||
| items 52 | ||||
| item "Pirate:Frigate:Heavy" | ||||
| item "Pirate:Frigate:Heavy" | ||||
| item "Pirate:Frigate:Heavy" | ||||
| item "Pirate:Frigate:Heavy" | ||||
| item "Pirate:Frigate:Heavy" | ||||
| item "Pirate:Frigate:Heavy" | ||||
| item "Pirate:Frigate:Heavy" | ||||
| item "Pirate:Frigate:Heavy" | ||||
| item "Pirate:Frigate:Heavy" | ||||
| item "Pirate:Frigate:Heavy" | ||||
| item "Pirate:Frigate:Heavy" | ||||
| item "Pirate:Frigate:Heavy" | ||||
| item "Pirate:Frigate:Heavy" | ||||
| item "Pirate:Frigate:Heavy" | ||||
| item "Pirate:Frigate:Scout" | ||||
| item "Pirate:Frigate:Siege" | ||||
| item "Pirate:Frigate:Siege" | ||||
| item "Pirate:Frigate:Siege" | ||||
| item "Pirate:Frigate:AntiFighter" | ||||
| item "Pirate:Frigate:AntiFighter" | ||||
| item "Pirate:Frigate:AntiFighter" | ||||
| item "Pirate:Frigate:AntiFighter" | ||||
| item "Pirate:Frigate:AntiFighter" | ||||
| item "Pirate:Frigate:AntiFighter" | ||||
| item "Pirate:Frigate:AntiFighter" | ||||
| item "Pirate:Frigate:AntiFighter" | ||||
| item "Pirate:Frigate:AntiFighter" | ||||
| item "Pirate:Frigate:Medium" | ||||
| item "Pirate:Frigate:Medium" | ||||
| item "Pirate:Frigate:Medium" | ||||
| item "Pirate:Frigate:Medium" | ||||
| item "Pirate:Frigate:Medium" | ||||
| item "Pirate:Frigate:Medium" | ||||
| item "Pirate:Module:GaussDefense" | ||||
| item "Pirate:Module:GaussDefense" | ||||
| item "Pirate:Module:GaussDefense" | ||||
| item "Pirate:Module:GaussDefense" | ||||
| item "Pirate:Module:GaussDefense" | ||||
| item "Pirate:Module:GaussDefense" | ||||
| item "Pirate:Module:GaussDefense" | ||||
| item "Pirate:Module:GaussDefense" | ||||
| item "Pirate:Module:GaussDefense" | ||||
| item "Pirate:Module:GaussDefense" | ||||
| item "Pirate:Module:GaussDefense" | ||||
| item "Pirate:Module:GaussDefense" | ||||
| item "Pirate:Module:GaussDefense" | ||||
| item "Pirate:Module:GaussDefense" | ||||
| item "Pirate:Module:GaussDefense" | ||||
| item "Pirate:Module:GaussDefense" | ||||
| item "Pirate:Module:GaussDefense" | ||||
| item "Pirate:Module:GaussDefense" | ||||
| item "Pirate:Module:GaussDefense" | ||||
and the LocalMilitiaStrong Template:
| planetItemsTemplate | ||||
| templateName "Template:LocalMilitiaStrong" | ||||
| subTemplates 0 | ||||
| groups 10 | ||||
| group | ||||
| condition | ||||
| type "PlanetOwnerIsMilitia" | ||||
| param "" | ||||
| owner "PlanetOwner" | ||||
| colonizeChance 0 | ||||
| items 10 | ||||
| item "Tech:Frigate:Light" | ||||
| item "Tech:Frigate:LongRange" | ||||
| item "Tech:Frigate:AntiFighter" | ||||
| item "Tech:Frigate:Heavy" | ||||
| item "Tech:Frigate:Heavy" | ||||
| item "Tech:Module:GaussDefense" | ||||
| item "Tech:Module:GaussDefense" | ||||
| item "Tech:Module:HangarDefense" | ||||
| item "Tech:Module:MetalExtractor" | ||||
| item "Tech:Module:MetalExtractor" | ||||
| group | ||||
| condition | ||||
| type "PlanetOwnerIsMilitiaWithChance" | ||||
| param "0.3" | ||||
| owner "PlanetOwner" | ||||
| colonizeChance 0 | ||||
| items 5 | ||||
| item "Tech:Frigate:LongRange" | ||||
| item "Tech:Frigate:LongRange" | ||||
| item "Tech:Frigate:Heavy" | ||||
| item "Tech:Module:GaussDefense" | ||||
| item "Tech:Module:HangarDefense" | ||||
| group | ||||
| condition | ||||
| type "PlanetOwnerIsMilitiaWithChance" | ||||
| param "0.3" | ||||
| owner "PlanetOwner" | ||||
| colonizeChance 0 | ||||
| items 8 | ||||
| item "Tech:Frigate:Light" | ||||
| item "Tech:Frigate:Light" | ||||
| item "Tech:Frigate:Light" | ||||
| item "Tech:Frigate:Light" | ||||
| item "Tech:Frigate:Light" | ||||
| item "Tech:Frigate:Light" | ||||
| item "Tech:Frigate:Heavy" | ||||
| item "Tech:Module:HangarDefense" | ||||
| group | ||||
| condition | ||||
| type "PlanetOwnerIsMilitiaWithChance" | ||||
| param "0.3" | ||||
| owner "PlanetOwner" | ||||
| colonizeChance 0 | ||||
| items 5 | ||||
| item "Tech:Frigate:AntiFighter" | ||||
| item "Tech:Frigate:AntiFighter" | ||||
| item "Tech:Frigate:AntiFighter" | ||||
| item "Tech:Frigate:Heavy" | ||||
| item "Tech:Module:GaussDefense" | ||||
| group | ||||
| condition | ||||
| type "PlanetOwnerIsMilitiaWithChance" | ||||
| param "0.3" | ||||
| owner "PlanetOwner" | ||||
| colonizeChance 0 | ||||
| items 5 | ||||
| item "Tech:Frigate:Siege" | ||||
| item "Tech:Frigate:Siege" | ||||
| item "Tech:Frigate:Heavy" | ||||
| item "Tech:Frigate:Heavy" | ||||
| item "Tech:Module:HangarDefense" | ||||
| group | ||||
| condition | ||||
| type "NoPlanetOwner" | ||||
| param "" | ||||
| owner "RandomMilitia" | ||||
| colonizeChance 0 | ||||
| items 5 | ||||
| item "Tech:Frigate:Light" | ||||
| item "Tech:Frigate:LongRange" | ||||
| item "Tech:Frigate:AntiFighter" | ||||
| item "Tech:Frigate:Heavy" | ||||
| item "Tech:Frigate:Siege" | ||||
| group | ||||
| condition | ||||
| type "NoPlanetOwnerWithChance" | ||||
| param "0.3" | ||||
| owner "RandomMilitia" | ||||
| colonizeChance 0 | ||||
| items 3 | ||||
| item "Tech:Frigate:Light" | ||||
| item "Tech:Frigate:LongRange" | ||||
| item "Tech:Frigate:LongRange" | ||||
| group | ||||
| condition | ||||
| type "NoPlanetOwnerWithChance" | ||||
| param "0.3" | ||||
| owner "RandomMilitia" | ||||
| colonizeChance 0 | ||||
| items 5 | ||||
| item "Tech:Frigate:Light" | ||||
| item "Tech:Frigate:Light" | ||||
| item "Tech:Frigate:Light" | ||||
| item "Tech:Frigate:Siege" | ||||
| item "Tech:Frigate:Siege" | ||||
| group | ||||
| condition | ||||
| type "NoPlanetOwnerWithChance" | ||||
| param "0.3" | ||||
| owner "RandomMilitia" | ||||
| colonizeChance 0 | ||||
| items 4 | ||||
| item "Tech:Frigate:AntiFighter" | ||||
| item "Tech:Frigate:AntiFighter" | ||||
| item "Tech:Frigate:Light" | ||||
| item "Tech:Frigate:Heavy" | ||||
| group | ||||
| condition | ||||
| type "NoPlanetOwnerWithChance" | ||||
| param "0.3" | ||||
| owner "RandomMilitia" | ||||
| colonizeChance 0 | ||||
| items 4 | ||||
| item "Tech:Frigate:AntiFighter" | ||||
| item "Tech:Frigate:Light" | ||||
| item "Tech:Frigate:Siege" | ||||
| item "Tech:Frigate:Heavy" | ||||
The PirateBase Template dictates what spawns at a "PirateBase" just like the LocalStrongMilitia template states what spawns under different circumstances and by set probability.
I want a hybrid of these that works and I can't figure out how to make it work and still be PIRATE and not MILITIA.
I've tried replacing [type "PlanetOwnerIsMilitia"], [type "PlanetOwnerIsMilitiaWithChance"] with [type "PlanetOwnerIsPirate"] and ["...WithChance"] with no success. Same when I made the first group [type "Always"] with [owner "Pirate"] then using militia forms for other groups.
Also tried, to no avail, replacing [owner "RandomMilitia"] with [owner "Pirate"]; Same for [owner "PlanetOwner"] with [owner "Pirate"] and even changed the first group [colonizeChance 0] to [colonizeChance 1] and nothing works...
Which is why I'm asking Star/Clad's help in this to create a PirateBase that isn't always the exact same composition all the time. Sometimes it'll be the flat group that is always there, but sometimes additional pirate forces/structures are present.
Sorry, but good luck.
-T
the only way i see it is to modify the starting Pirate ship list, otherwise youre on your own
I've decided to go the Militia route. I can randomize what spawns via multiple groups whereas the pirate base has only one group and adding other "Chance" based groups isn't possible because of the game itself.
Suggestion Star/Clad:
Add: PlanetOwnerIsPirate, PlanetOwnerIsPirateWithChance
I really want to randomize the PirateBase template so people aren't so sure what's gonna be there from one game to the next.
Mixing: Type "Always", param "", owner "Pirate", colonizeChance 1
with
Type "PlanetOwnerIsMilitiaWithChance", param "x", owner "Pirate", colonizeChance 0
... it just doesn't work. PlanetOwnerIsPirateWithChance might let me do it right.
Welcome Guest! Please take the time to register with us.