[MODCOMP] Mercenaries Mod

great work theLopez!
I was about to start writing it sooner or later, but you've already done it, and better than the way I would have made it!
just grand.
I hope you don't mind if in one day I'll merge it with some other mods
 
Rhye said:
great work theLopez!
I was about to start writing it sooner or later, but you've already done it, and better than the way I would have made it!
just grand.
I hope you don't mind if in one day I'll merge it with some other mods

No I don't mind, which mods were you planning to merge with it?
 
TheLopez,

I am finishing up right now adding this mod to Unit Stats mod, Sevo Fusion mod, great specialists mod, military bases mod, random events mods and caravan mod. Plus I'm adding a naming option that I made with help from Teg Navanis.

Would you like to look at it when I am done? (Should be this evening my time)
 
No I wouldn't mind looking at it, but understand that most of my mods, except for the merc mod, are going to be updated some time this weekend.
 
Can you create a building that allows the purchase of units outright for gold? Specifically "foreign" mercenaries as opposed renting them from the other civs.
 
Not in my mod, if that was the case then they would be considered part of your regular army and not mercenaries right? Someone could do a separate mod to achieve this or if you want me to add this you will have to wait until I have some free time to add it and make a new release.
 
TheLopez,

Not a problem. I will just add the changes as you make updates. I will start a thread in complete mods today. It will be beta, as there are a couple minor bugs I need help with finding. Then I will release it as a full version and include all you updates in it.



I love the merc mod, it's just great!
 
The problem I have seen is that Mercs are too expensive. I wanted to hire some when I was attacked and they were like 486 to begin and then like 96 maintence. At most I could buy 1 and it would totally drain my funds. It was much cheaper and quicker to just build a unit.

I have also set several of my units to be merced out and recieved no money. One time I saw a message that Cyrus has hired (insert name). Then when I went to the CTRL+M screen there was my catapult hired by Cyrus and me still recieving no income from Mercs.

I have tried to read through the whole thread and I did not see anybody else talking about these problems. If there is something I am missing please let me know.

I too would love to see the ability to sell units to other nations. I just love causing wars late in the game to make my top rivals waste time and money fighting eachother!
 
Well, the best way to tone down the mercenaries prices is by tweaking the hiring cost through the "Mercenaries Mod Config.ini" file. You need to play around with the "Hire Cost Modifier" which is currently set to 0.8. You might want to change it to 0.4 or so. Just remember if you make it cheaper to hire mercenaries you are also making it cheaper for the AI.
 
Just a thought that occurred, not having yet tried this mod...

But could "inflation" be implemented? If most of the civs are hiring out mercs, and it's relatively peacefull, prices are smaller. If half the globe is at war, and only one civ is hiring out, prices are much steeper. Suply and demand, ne? :)
 
Tattila the Hun said:
Just a thought that occurred, not having yet tried this mod...

But could "inflation" be implemented? If most of the civs are hiring out mercs, and it's relatively peacefull, prices are smaller. If half the globe is at war, and only one civ is hiring out, prices are much steeper. Suply and demand, ne? :)

I agree and it is already in my future features list in the readme file.
 
J_Period said:
Each unit could have it's own list of names, so the basic format could be:
Firstname + Lastname + Unitdescription

What do you think?


I took the liberty to add this.

To the ini file I add an option to use the default or firstname + lastname + unitdesc.
Spoiler :
;0 = default naming
;1 = first + last name + unit type
Merc Naming = 1


Thus to MercenaryNameUtils.py I added this:
Spoiler :

#######Nexus mod start#######
# Load the Mercenaries Mod Config INI file containing all of the configuration information
config = CvConfigParser.CvConfigParser("Mercenaries Mod Config.ini")

# If we actually were able to open the "Mercenaries Mod Config.ini" file then read in the values.
# otherwise we'll keep the default values that were set at the top of this file.
if(config != None):
g_intmercn = config.getint("Mercenaries Mod", "Merc Naming", 1)
#######Nexus mod end########

....

#######Nexus mod start#######
if (g_intmercn == 1):
mercenaryName = firstName + " " + lastName

elif (g_intmercn == 0):
if(len(mercenaryName) < 14):
middleName = mercenaryMiddleNames[gc.getGame().getMapRand().get(len(mercenaryMiddleNames), "Random Name")]
mercenaryName = firstName + " " + middleName + " " + lastName
#######Nexus mod end########


And to MercenaryUtils.py I added this:
Spoiler :
#######Nexus mod start#######
g_intmercn = 1
#######Nexus mod end########

...

#######Nexus mod start#######
g_intmercn = config.getint("Mercenaries Mod", "Merc Naming", 1)
#######Nexus mod end########

...

#######Nexus mod start#######
if (g_intmercn == 1):
mercname2 = MercenaryNameUtils.getRandomMercenaryName()
mercname = mercname2 + " " + gc.getUnitInfo(iUnitType).getDescription()
mercenary = Mercenary(mercname, gc.getUnitInfo(iUnitType), promotionList, tmpUnit.getExperience(), tmpUnit.experienceNeeded())

elif (g_intmercn == 0):
mercenary = Mercenary(MercenaryNameUtils.getRandomMercenaryName(), gc.getUnitInfo(iUnitType), promotionList, tmpUnit.getExperience(), tmpUnit.experienceNeeded())
#######Nexus mod end#######



I have atatched the files so you can use the code. I have already added this to my mod.
 

Attachments

  • MercNaming.zip
    64 KB · Views: 125
So, one of the questions I have is why do you need the unit type description when it already shows up when you select a mercenary in the game?

So, what I mean is that your changes will make a warrior named
"Foo Bar Snafu" be "Foo Bar Snafu Warrior (Warrior) when selected in the game. Shouldn't it be more like "Foo Bar Snafu's Warriors"? For all intents and purposes I cannot see how your could would do that.
 
I agree. The extra (warrior) gives away what the name is.

I just added the option because J_Period said that is what he'd like to have the option to do.


I like to give people the options to make the unit names whatever they want. It has always been my pet pev in previous versions of civ. I used to have to manually rename all units. So I made it so if someone wants to see "Foo Bar Snafu Warrior (Warrior)" Vs "Foo Bar Snafu (Warrior)" They can.

That's all. Just giving people thier options. For the record I will not use this. I will use "Foo Bar Snafu (Warrior)"
 
Nexushyper, its more then just displaying the extra Warrior in the name. What he wants is "Foo Bar Snafu's Warrior" not just "Foo Bar Snafu Warrior". But lets not assume anything and just ask J. So J what is it exactly what you want?
 
Well just finished a game with your mod, i like it, spent the early game hiring out axemen, sometimes they come back with good xp. and as said before they are to expencive to hire yourself. to hire cav i had to shell out 1000g and 64pt ... i think they should be expencive but not this expencive .... oh yea, i saw the AI using mercs and getting mercs that they cant build (i got a screen of the AI using a redcoat to defend a vital city) very cool (and impossable to attack when all i have are macemen)

btw, this was an epic game, do the prices change for teh speed of the game?
 
Selous, the best way to tone down the mercenaries prices is by tweaking the hiring cost through the "Mercenaries Mod Config.ini" file. You need to play around with the "Hire Cost Modifier" which is currently set to 0.8. You might want to change it to 0.4 or so. Just remember if you make it cheaper to hire mercenaries you are also making it cheaper for the AI.
 
I finally took some time off from playing Fall from Heaven and my own modding (and of course all that real life stuff) to mess around with mod some. Damn dude,, this is a lot of work. And professionally done too.

Nice job.
 
Thanks naf4ever, I'm glad you like it. As for it being a lot of work, yep, it took over 1 1/2 months to complete with me just concentrating on the design and development and another 1/2 month of testing by several people.

As for it being professionally done, I would hope it would look like it since I am in the industry. :)
 
Top Bottom