Closed Iamblichos closed 8 years ago
I could have just initialized a whole new database unit when I hit the modern era, but I didn't like that. It's just one UnitType entry and another table that reads values for new Era Combat Strength and New Era UnitCombat Type.
interesting idea. same thing is in prehistoric mod, where ,,Hero'' is skirmisher and meele cavalry too. was funny, but there will be problem with stack him with another units, since he is military unit now?
This unit can't stack because he's not a civilian unit (the CP does have the ability to stack combat units if the flag is set manually for that particular unit without giving all combat units that ability). The challenge (which wasn't a huge challenge, just sorta cool ya know?), was to have a singular unit (not two units), that had two different CombatClasses (UNITCOMBAT_MOUNTED and UNITCOMBAT_ARMOR) in distinct Eras (Ancient - Industrial -> Mounted, Modern - Future -> Armor). I don't think that mod can do that with 1 unit without some DLL manipulation unless it's a unit that has a unitclass upgrade( but then you are dealing with multiple units and clutter, and if its a Special Unit, which one would spawn on creation?)
i got one idea. absolutely no clue if it would be possible to do and if so, how dificult it would be.
What do you have?
what are those general/admiral points right now? that is some kind of special yields? can those be changed for GG/GA to something maybe faith related for them being rather purchasable than born when you filled pool.
They are normal yields like culture and science. Although, I think you could already buy Great Generals and Great Admirals through faith with the right social policy branch?
bad english as always. i didnt ment it this way. i ment it do those GG/GA yields like normal yields, which will not trigger born of those persons. but i have no idea what would replace those faith pruchases in authority/imperialism branch. or nothing what would not demand some complete rebalance or rework. rather i leave it for profesionals :D
You mean like when they hit the GG/GA threshold points, they become a trainable unit?
It has often struck me that UnitCombatTypes aren't a variable, and therefore not changeable in CvUnit.cpp on the fly (it has no variable). What if you had a Hero Unit (i.e. a Great General that was a Combat Unit) that started as a Mounted Unit and then became a Tank once it progressed to the appropriate era? So I made it a variable. Note the combat modifers for the barbarian units (my values are a little different from the CBP):
then I immediately advanced myself to the modern era which triggered the unit in the DLL to have new database read values, barbarian no longer has bonus vs. mounted:
...but anti-Tank applies:
Just to show that the variable is setting the CombatClass correctly for regular units: