Hi guys, I am trying to create a pioneer variant that is only able to spawn outpost. Name I am working on now is Outlander. I took the entire pioneer code for 10 races from the CoreUnits file and pasted in into a new XML, added UnitTypes tag, and change the all non-file-name-related instances of Pioneer to Outlander (maintaining the TrainUnitIcon reference). I also change all the pop cost to "5" for Outlanders.
Try as I might, I cannot make Outlanders appear in the training list for a new settlement (except for one time when I accidentally kept the InternalName reference, and couldn't build Pioneers for that game). Any help on this problem will be appreciated.
Also, just a related question. Why is the pop cost in the units file 10 while the in-game unit pop cost is 30? What is affecting this multiplier?
Oh, one more thing. Any idea whether this unit will sit well with AI or will it screw them up bad?
Thanks a lot!
The pop cost in the XML is for a single unit of Pioneer, but when you train a pioneer you get a group of 3, that is why it is 30 pop in game. If the AI for it is the same preset as it is for the original Pioneer it should be fine.
To make a unit appear in the training list make sure these are in:
No more than 4 abilities
<CanBeDesigned>1</CanBeDesigned>
<IsUniqueButBuildable>1</IsUniqueButBuildable>
This will let you train the unit without adding it to any racetypes.
It wasn't showing up for you because Pioneer is down as <IsStartingUnitType>1</IsStartingUnitType> but this can't be used for modded units without editing the RaceConfig file.
I did not realize about the necessity of editing the RaceConfig file and that explains why I could not get some custom units to show up for starting factions, thanks for that tid bit of information there.
Yeah, but if you use
Then you don't need to edit a race config, delete the line about being a starting unit
OK, having already done this (making Pioneer type traits), if you want to make a 'designable' pioneer, this is all you need:
Save the above code into it's own .xml file in the mods folder, with it's own name (settlers.xml or whatever), and Pioneer Gear will appear as a trait which you can choose, in the same place/row that the Scouting trait appears.
If you wanted to allow outpost building but not town building, simply delete the UnlockAction/BuildTown Game Modifier, which I'm sure you already did. Note that, as an above poster pointed out, you can't design a unit with less than 3 individuals, so keep this in mind when arriving at your values. BTW, my values were something I was experimenting with, choose any resource, training turns, etc. that you feel is appropriate for whatever you are trying to do.
This will, of course, allow your Outpost builders to buy armor and such as well, if you feel the need for armored outpost builders, but I personally don't take an issue with this as the world of Elemental is a dangerous place, and packing some iron to protect yourself is usually a very good idea if you can afford it...
I am (eventually) planning to release this as part of my mini E:LH mod (my roadbuilding trait mod), but of course feel free to use/share this code as you see fit!
You CAN design a unit with less than three inidividuals if you use <AllowGrouping>0</AllowGrouping>, which will make it an individual unit.
This is good to know. I'll give it a whirl!
Edit: I'm about to try this to see what happens, but in my case, I'm good with the group size of 3 in this case, i.e. a construction CREW, not a lone construction dude. If there was some way to figure construction time into the unit size (i.e. a size 6 unit builds things twice as fast), that'd be cool, but I'm guessing that isn't within the realm of modders...
Of coursing a crew of six should last a bit longer against maurading wolves, if they are packing clubs, but that's another story.
Followup.
Simply adding <AllowGrouping>0</AllowGrouping> to my .xml won't allow you to build individuals. You still only have Party/Group/Etc. to choose from, and the interface doesn't show individuals.
This may work another way, but not within my trait .xml as presented. As I noted before, I'm good with a minimum unit size of 3 for engineers/settlers/etc. though. Plus, I like keeping things simple, and the above .xml is short, sweet, and works.
<AllowGrouping>0</AllowGrouping> goes on the unit, not a trait
Updated code:
Main changes here are the descriptions for <provides>, and assigning the additional training turns of 30, which gives a build cost of 109 with the weak attribute and staves (normal 'weak' pioneers without any weapons have a build cost of 103). Note that the designer forces you to choose at least a club, stave, or spear. As I think Pioneers would/should have walking staffs handy if they are ambushed, I'm good with this.
Note that the 'Weak' Attribute no longer appears in the unit design/traits window as a choosable option. This reduces training turns by -10, and reduces attack strength by -2. Hence, 'Average Strength' Pioneers will have a higher build cost. A workaround for this is to modify the 'scout', which has the 'Weak' Attribute, and add the Pioneer Gear to that unit. Or, you could just add 'Weak' back into the designer...
Note the <Multiplier>, which now reduces attack strength by 50%, instead of by -2, which makes more sense to me from a balancing perspective. If you prefer the -2, simply change <Multiplier>.5</Multiplier> to <Value>-2</Value>.
Now, off to figure out how to upload this, and update/post my mod thread.
I don't even have a mod thread on here I should probably make one, all my stuff is just on the nexus
Please don't take this the wrong way, but this isn't going to work. You will be able to certainly have the unit appear in game and you can make it build outposts, that is easy enough, however the AI will not use it. I already tried this once before in the past. I had even removed the ability for pioneers to build outposts but the AI will still build only pioneers and will be able to build settlements and outposts with pioneers only. It is hardcoded.
Yeah, I noticed. I never imagined that the AI will be smart enough to notice a cheaper outpost builder. It just does not make sense that that outpost cost so much (30 pop), especially when LH pop growth seems so much slower than FE.
Now I'm stuck between "taking advantage" of the AI weakness, or spending an exorbitant amount on outposts. Or I can just keep going for them Arcane Outposts, which I also feel is somewhat overpowered. =/
Anyway, here is my outpost builders, if anybody is interested. Didn't put much thought to it, but props to DatedSandwich for his help on making the unit parseable. Sorry if it's a bit long, I was too lazy to take out the unneeded parts of the Pioneer.
There are many great features available to you once you register, including:
Sign in or Create Account