Exotic Unit Pack - Mod Collaboration Thread

Agreed. Will set it up so it's easy to turn off and/or turn up.

And I agree the % needs to be almost negligible, unless you're running a large deficit or significant unhappiness - and cap the total % lower, say 3-5%?
 
Last edited:
OK. I believe the "merc function" is completed. Have been testing various scenarios for about 5 hours now, and haven't seen anything "break" yet.

The basic design criterion is related to the fact the AI simply does not buy units. In a way, that simplified the code, as the merc function needs to completely manage when AI spawns units, which units, where, and when to remove them.

For removing merc units already in the game: at turn 15 of a unit's lifespan, the function begins testing whether to remove or not. The test is ' lifespan * 2 '. This is the % chance to remove unit. So, if the unit is 15 turns old, there is a 30% chance to remove it. By the time it gets to age 50 turns, the unit will automatically be removed. From what I've seen, most of the units desert in their early 20's (turns, that is).

The current code gives a 5% chance per turn of an AI civ attempting to spawn a unit each turn. If the civ passes that test, the function will determine what are the possible/legal merc units available to that civ, based on their tech level, any overrides that are in place, etc. Once it has a list of possible units, it picks one of them on a random basis (i.e. each possible unit has an equal chance of being picked).

At that point, the function checks if the unit is a ship or not. If it is a boat, the function checks each city the civ has, and spawns the boat in the first coastal city it finds (almost always the earliest founded). If there are no coastal cities, no unit is spawned.

If the proposed unit is not a ship (land, air, hover), the function tests if the civ has a capital. If not, no unit is spawned and the function moves on to the next civ. The only time a civ doesn't have a capital is when it's Barbarian or when the game option "Complete Kills" is selected. In either of those cases, it doesn't seem right for a merc hiring action to happen.

If the civ has a capital, the merc unit will spawn there, and be available to the AI that turn.

Kind of brute force in the spawning/removing of units, but as most of this occurs out side of the human player sight, I think it will appear like the AI is using the units in a similar way to using other units it builds normally. That's probably good enough.

Some of the things I'll ask you to look for while you're testing: are the units spawning in a logical manner (too many, too few, too often, etc.), and are they being removed in a logical manner.

It doesn't have to be a perfect representation of how a human player might use mercs, and they will appear more often than they might for a human, simply because these units don't "cost" the AI anything - no gold is removed from their treasury. This is necessary, as we don't want a random merc unit or two to break any ongoing AI operations. It is a slight advantage to the AI, but given its overall effectiveness, they can probably use the help.

Will spend a couple of hours this morning examining the "desert & rebel" possibilities we discussed yesterday. Will set it up so it's a one line change to turn on/off in the mod, and default it to OFF.

After all this, I'll move on to the "hard part" this afternoon: folding the Merc Function code into the Exotic Units mod. Overall, it's not complicated, but there are usually a few gotchas hiding in code that is set up for testing, as opposed to code ready for the final mod. Am hoping to have a new version of Exotic Units posted today for you to test.
 
The desertion/mutiny functions are in place and working fine. And defaulted to OFF. Only set to human player. Thought about adding them to the AI, but really, doesn't the AI have enough challenges already...? :lol:

Starting the code merge now. Fingers crossed... :badcomp:
 
The code merge is done. A couple of screen shots from the combined mods:

upload_2017-12-18_13-1-52.jpeg upload_2017-12-18_13-2-16.jpeg

There are a couple of odd error messages in the log files, but I honestly can't see how the mod's code would cause them. They don't seem to break the code, so I suppose it's ok to publish/test the latest version - with the caveat that I'm not 100% comfortable with a mod if there's even a minor "advisory" message in the logs. So, feel free to beat up the mod, but don't be completely shocked if there are some odd behaviors observed.

Will troubleshoot these as I build the next class of ranged mounted units.

Will remove my testing "cheat codes" from the mod, then rebuild/republish. About 20 minutes, I think...
 
Kind of a bad timing. Not your fault, obviously. I'm not going to be home the entire day, and will come back at around night time. So, I can test it out tomorrow...

Sorry.
 
No worries - will save me some time if I can put of uploading the interim version, and just add the new units, the release that later version. Will send a note when it's up.
 
Have researched the available artwork, and here is what I'm planning to build the "Mounted Ranged" class around - first thing is to come up with a much cooler name... :hammer2:

upload_2017-12-18_16-19-39.jpeg

Unit Models (in 1 through 6 order):

upload_2017-12-18_16-20-8.jpeg upload_2017-12-18_16-20-23.jpeg upload_2017-12-18_16-20-32.jpeg upload_2017-12-18_16-20-42.jpeg upload_2017-12-18_16-20-53.jpeg upload_2017-12-18_16-21-7.jpeg

Still need to do some testing on the models to make sure they can manage ranged combat. Pretty confident on the first 4, but have never used the last 2, and they're basically "melee" models. You can convert them to ranged, but it takes a few "tricks" to get the animation to look at least half a**** correct.

I'll try to have all these incorporated and "unit tested" (models load, move, attack as they should) into the version uploaded tonight.
 
Latest mod version posted. So far, so good with respect to stability.

Was able to add 3 working models for the first 3 mounted ranged units. They build, move, and attack OK, so the models look to be loaded successfully. I expect to add the other 3 tomorrow.

Still need to update their icons and flags, but wanted to do that last, after all 6 models are working, so I can pick the most matching artwork. Also need to add the Horse strategic requirement to these units.

Also, these units are basically "shells" - with nothing really special about them. If you have any suggestions about what promotions, weaknesses, required buildings, etc., they should have, let me know

Close up of the 3 new units:

upload_2017-12-18_18-3-19.jpeg

Looking over my notes, I don't see a lot left after the changes mentioned above are made. Have notes about possible adding some more merc units: Hessians, Assassins, and Mamlukes. Possibly add a "Fighting Great General" like the Fighting Admiral. May also take a stab at improving the animation of the Fire Ship, but that's probably not going to work out very well. Finally, was thinking about a merc-wide promotion (applicable to all merc units) that reduces earned XP by 50% and makes them ignore Great General bonus.

If you have any other thoughts about what else to add/remove/adjust, now's a good time to pass them along.
 
Hey, sorry couldn't get to you sooner.

I think they look great. I'll obviously test them out tomorrow when I come back from school, which should be around 12 ish.

I think the weakness for the ranged mounted units should just be spearmen more than anything. Other than that, I think they're good.

The Hunnic horse arcger is unique because it doesn't require horses, and is available quite early while also having the accuracy promotion.

The Keshik is unique due to generating great general points.

I think the new units shouldn't have any promotions. I think they're fine the way they are.

You think we could get a unit that destroys buildings in enemy cities? I think that would be a cool idea. As a merry unit, though.

I get get idea from Rome: Total War. They had a unit that could kill the current ruler or destroy a building to hurt infrastructure.
 
No worries. Am still "improving" the mod. All 6 of the mounted ranged units are added and tested. Had to adjust animation files on the last two (native Americans) to give them a ranged attack where they didn't have one before. Am currently cleaning up the new units - adding text, horse requirements to units 3-6, and adjusting the promotions just a bit. Done with that in the next half hour. After that, I need to update the Icon/Flag files to give the new units their own look. And that's about all I'll be able to manage by 12 eastern. But that's also largely where I wanted to leave V1 - understanding of course that there's still work to be done on civilopedia/unit texts and any/all findings from testing.

The "saboteur" unit you're describing was actually in Civ 2 - a nice feature, actually. I believe Tomatekh's Great Spy mod does some things similar to this:

http://steamcommunity.com/sharedfiles/filedetails/?id=883589180

Could always incorporate some of these features into this mod, but that's more of a V2 kind of thing, I think, as it's such a different "goal" of the mod from this one.
 
Cool cool.

I'll be testing out the mod now, or do you want me to wait until the next update?

I'll just do a full game to see what the AI does. I'll make progress reports on it, or something.
 
Also, I think we should rename the new units?

I think we could start with Skirmishers, and then upgrade those to heavy skirmishers.

So, Akkadian Horse Archers become the Frankish Crossbowman. And then the Iriqouis Musket Riders. Although, I think they should have a range of 1 with that upgrade. I think we can just call them Musket Riders.

Now for the other unit tree. The Scythian Horse Archers would become Horse Bowman. (Same with what we did to the Camel Archers.) They upgrade into the Corrazzieri. That name's good. Then they can upgrade to the Sioux Dog Riders. I think we can call them . . . Harassers, as I think that's pretty much all the horses would be used for in that time.

I think they should still be ranged to compliment the Lancers and Cavalry units. Also for harassment.

The names I suggested are just there because I feel like calling them that might make them feel like replacements rather than new units.

If that's gonna take too long, you can just make it for the next update, or something.
 
New version posted.

I'll look at adding the upgrades next. There are none in there now.

I have no problems with renaming, but in most military traditions, a Skirmisher is a lightly armed infantry unit who resides in front of the formation to provide early warning to the main force. Also known s "Pickets." Giving a mounted unit a traditionally infantry naming would be confusing to many players, I think.

The game has already taking up most of the good "cavalry" unit names. There are a few, but most of them are melee type units (dragoons, chasseurs). Sometimes the hardest part about modding is the creation of new "content" - the kinds of things we're looking for here. I spent quite a few minutes to come up with a better name for the whole class, as "mounted ranged" doesn't paint much of a picture to me.

Changing the names, ranges, stats, upgrades, promotions, etc., is quite trivial - takes seconds literally. The hard part is figuring out what to put in these blocks...
 
Oh, okay then.

To me, Skirmisher was just anything that shoots stuff, lol.

Anyways, I'll go ahead and download it. I'll play a full game, and make key points about it, and post them here.
 
Also - I put a note on the download page, but just in case you didn't see it. I haven't had the chance to run this mod through a few 500+ turn test games, like I usually do before uploading. So, I'm not sure how stable it actually is. If there are any crashes, it's probably better to download the version I published yesterday - that version has been tested, so would probably be more stable.

About the only thing that could cause problems are my reworking the animation trigger files for the Musket Riders and Dog Soldiers. I gave them a ranged attack when there really isn't one associated with those models. I've done this before several times with no problems, so it should be ok. But as I didn't get a chance to test this, it's just a bit more risk in testing this mod.

Will do a bit more research, and post another table on the class - with the information you've given me here, and get closer to fully defining the class.
 
Back
Top Bottom