[MODCOMP] - XML Cleanup & Expansion

I know, I claimed I was done updating and there wouldn't be a 1.16c.

I lie sometimes.


:p


Truth is I noticed that I forgot to re-enable the effects for one of the panels, and it made seZ's amazing graphics look only superb. Can't have that, so I decided I wanted to re-upload. Since I got the Python sorted out to be cleaner than it was in 1.16b as well, I am doing a full revision change instead of a Ninja update


EDIT: Magister, that "Prize Ribbon" is where I was missing seZ's effects. It actually looks a hell of a lot better than what you saw if you are basing that off the in-game instead of the screenshot.

EDIT 2: read your post, will reply later. Need to run and finish some things before sundown. Decent points all around. Really wish I could figure out a way to pull off the Tech Bar being something animated like a scroll unfurling. Would be amazing. So far, not seeing how I can bend the code that way (still struggling to make it change icons on mouseover so we can make new buttons)
 
Hrm, based on some of your thoughts I'll add a few items to my own personal worklist. Promotions blocking each other is probably not going to happen since that is breaching the same territory as the equipmentmod. One of the main elements of that is which slot equipment items use, and a limit on how many of each slot type you have.

Though I had not thought about the standard "Cursed Item" characteristic of "cannot remove." That would allow you to make a promotion block other promotions easily by granting them a shared slot.


AI completely understands how to use the purchased by gold promotions, though there aren't any blocks in place for the Khazad to keep them from over-spending. Maybe it would be worthwhile to add a tag to the Leaderhead infos for a target minimum Gold threshold? Be a nice non-hardcoded way to slip the Khazad functions into the SDK.


I haven't taught the AI how to use ALL of the promotion fields yet though. The one that is kicking my ass right now is the promotional field to allow a unit to declare a golden age. Seems that no matter what I do the AI will never decide to use one of them in a test scenario. Maybe I'll place the tag on a lot of promotions and remove Great People from the game, run an AI AutoPlay for a while and then check the logs to see if anyone ever got a golden age....


Automatically gaining a Promotion when conditions are met would be a sweet tag, as would automatically losing it when conditions are no longer met. The second of those will require a lot of thinking about for how it'll consider each requirement though. I mean, if the Promotion has a GoldCost, should it charge your account that much each turn? Or remove the promotion if you go under that amount? Or just not use it?

Honestly, the second of those (promotion fails if you don't meet the conditions) would wind up leading to the addition of a LOT more tags. Could be enjoyable though.
 
Version 1.17 is now posted. The DLL works with both the latest versions of FF and FfH. The only file which should be REQUIRED to load either mod using this DLL would be the GameOptions.xml (Same file for both games). However, the changes in the other files are all highly reccomended for use with base FfH (most changes required to use new fields should already be incorporated into FF, but the main reason you want the rest of the files for FfH is the changes to how Civics & Improvements provide Happiness, which requires the values be multiplied by 100 to have any effect).

Quite a few new fields, I ought to have uploaded it two times along the process of getting to this point, so just read posts 1 & 2 for information on how things stand right now. I also overhauled quite a bit of the old code and refined how various fields will work.

No real work on the HUD with this version, except that the Unit Image is moved up to the new location, as well as the Civilization Flag. Though the flag still has a huge honking stick dangling out the bottom of it and all that :)
 
Some great changes here... :) I definetly can use many of them.

I am not sure if Kasdar's requests include extra yelds/health from terrain/feature for civilizations or traits, but I think no.
It could be a great addition to be able to allow an additiona hammer from tundra for Doviello, some trade from desert for Malakim or some extra food/health from jungle for Mazatl :)
I never did any dll changes so I am not sure how hard would it be to implement, but I always wanted to be able do do that.
 
  • Summoned Units now display who summoned them (specific Unit)
  • Limit of 1 Permanent Summon per caster is now directly linked to the specific caster and Summon. Thus you cannot have 20 units CAPABLE of summoning skeletons, but only 1 unit who actually DID summon your 20 skeletons. But at the same time, should you get a bonus pair of skeletons by conjuring one while on a Graveyard, that doesn't mean that now 2 of your other units are unable to conjure skeletons of their own
    • This limit is set by UnitCLASS, not by UnitTYPE. So now you can make a person decide between 2 different Permanent Summons by making them be of the same UnitClass. Thus if Wraiths were Permanent, and used the same Unitclass as Skeletons, you would be able to have out a Wraith OR a Skeleton, but not both (per unit capable of summoning each)
  • If a Player normally has enhanced Duration applied to their summons (ie - summoner trait), their mages will gain 50% of the XP from the Summoned unit upon the death of the Summon.

How did you manage to do all that? I was under the impression it would be impossible. May I assume that Kael can borrow this code to get around to implementing the Divided Soul Sidar UU/contest winner?


Does the free xp to summons with enhanced duration also apply when duration is increased by promotion instead of trait? Why only do it for those with increased duration? Letting fireballs give their casters free xp could be cool.


When you get around to dealing with my other suggestions on Improvements/Feutures/etc., it could be quite nice if you'd also merge in this modcomp. (I haven't had time to try it, and it could probably be improved, but it looks quite nice.)


Also, I think that you should borrow several things from this mod by Dom Pedro, like allowing units to have and see multiple invisibility types and have withdrawals based on terrain.
 
No, Kael may not borrow this code to implement the design contest winner, because I am writing it as a personal challenge to design it myself :) Main reason he cannot borrow it is because it isn't done yet. Vehem & partner are improving on the formula I started and we are bug testing it. Then I'll invent the new spell to snag your master (and one to snag your summons while I am at it most likely). At that point the unit will be done and Kael is quite welcome to enjoy the code.

And nobody every said it was impossible to track the summons to the masters, they just said that the game engine couldn't do it. And the reason for that was because nobody had written the code yet :)


How I presently have it written, the XP transfer is only granted if the Player (as in CvPlayer) granted enhanced duration. Thus at present coding that means only if they had the summoner trait. But as with all code, it is easily re-written to suit your fancy. It would take 2 lines (else + a formula) to allow all summons to pass XP back to their masters upon death, with Summoner Trait merely meaning you get MORE of it returned. I also have placed the same block that Kael uses to keep Summoner Trait from enhancing the duration of a Fireball to block a Fireball from granting bonus XP to the summoner. So without modding my code, no fireballs give anyone XP. However, fireballs are still tracked like any other summon to monitor who owns them.


As for the Improvement Culture mod, I suppose if Vehem has a use for it I'll import it soon, otherwise it'll get placed on the backburner list and compared with Lutefisk's Claim Flags to see which one is better. Or I'll just write something along those lines from scratch if neither seems quite right. But I personally have no designs to use such a thing at present.
 
I really don't see the point in having traits or duration effect the xp from the summons at all. It is pretty pointless, since units without enhanced duration wouldn't really be able to get much xp to begin with. I'd get rid of those checks altogether. A summon would typically only be able to get 1 xp in 1 turn, and I presume half of that is 0 (unless you are changing xp from an integer to double, or rounding up).


If and when you do add Improvement Culture mod, or Lutefisk's Claim Flags, or something similar, I'd really like to see the ability for the culture provided by the improvements to be able to depend on the strength of the player's garrison on the improvement tile.

Perhaps you should consider implemented Influence Driven War too/instead.



I guess you responded before edited it to recommend including some things from of Dom Pedro II's [MEGA MODCOMP] Conqueror's Delight. Having looked over it a little more (but not having actually played it yet), I'm thinking you should include everything, including some of the things he is still working on (I always really wanted my Dimensional summons to act like his helicopters). Of course, some of it was already in FfH, and more in your version.


I also just noticed that Broader Alignments as an option now. Thank you. I personally would prefer if the graphical changes were not included. I'd rather the numerical value of the alignment instead only be displayed in mouseovers of the leader's score, and in diplomacy. It could go where the espionage points are normally shown.



I hope such suggestions don't delay the SDK/schema release too long. I will pretty much need you to release a stable base for my modmod within one week from now if I'm going to be able to release it before I get busy with school again in the Fall.
 
DP and I have talked quite a bit about his Conqueror's Delight while he was in the pre-posting stage. Hence the overlap of many ideas. He and I are actually collborating/racing to implement Equipment Mods, him basically just needing to figure out a graphical interface, and me having taken time away from coding to play with other Interfaces and learn what I need to know to make one. But most of the other ideas aren't ones I feel a need for (some are nifty though). And I have looked at Influence Driven wars and liked the idea, but am relatively certain it won't fit FfH because the mod is already complex enough, and because there is a fair deal more death and fighting to deal with, most of which possess completely different meaning (you ought not to lose culture when your fireball dies, nor gain it when it wins).

Vehem already removed the Broader Alignments Bar from FF before I made it an option, so no worries there at all.


And yeah, don't worry about reccomendations slowing down release. Most of them will probably never see the light of day to be quite honest. Still a lot of my own ideas to work with, and now that I am essentially the SDK programmer for FF, plenty of Vehem's ideas as well. I still look over post #3 every now and then when I am needing a break from code which is frustrating me, but that is becoming a rare situation now that I am getting a better feel for the entire SDK layout.

And though he may kick me for saying so, you are probably better off bugging Vehem to get new ideas implemented at this stage. I'm just now working with him on FF, so I don't quite feel enough ownership of the product to steamroll him on any decisions for what to implement (ie - I won't add any code unless he approves it first, or it is minimally invasive). And Vehem himself is just now getting to the point of being willing to change fundamental concepts/workings of base FfH, so I'm not sure how many things on the scale of Influence Driven war he would go for.
 
Yeah, well...I'm still hoping I can get you to include pretty much all of the SDK/schema side of Conqueror's Delight. I'd like to use most of it in my modmod, and I don't think it would really cause problems to have it in FF even if it is never really used. (I guess some aspects of the mod could be better as Game Options though.)

Edit: I just realized that his change adding a nationality of origin would probably mean that you could make units revert to their old owner, as many people in this forum really seem to want. That could be used to balance Domination, to let units go mad (turn barb) but then regain their sanity (return to their owner), etc.


As for Influence Driven Wars, I was really thinking that it would be best as a Game Option, like Broader Alignments now is. Naturally there are units which should not be able to effect borders. New tags for units and promotions would probably be needed. It might be best for these to be int tags instead of booleans, so some units could be much more influential than others and some could actually hurt their owner's influence.


The bar is gone, but what about the number displayed next to the alignment? While I liked knowing exactly the alignment of my rivals, I don't like seeing the number all the time or having them move the leaders' names further to the left. Displaying it in the diplomacy mouseover would be better.
 
Not sure on precisely how things are changed for the display, but now would be the time to talk to Vehem about possibilities. We'll have to completely overhaul the interface when .33 comes out with seZ's new HUD designs and a layout location shift. And all of this BUG Mod stuff looks out of place enough already, once we have fancy seZ layouts (ideally with integrated button designs) it will just be horrendous, unless we overhaul that as well.

So basically, post .33 everything will change for what is integrated or not most likely. All of the BUG mod is probably up for debate on how worthwhile it is for inclusion, and in what way to tweak how it works to fit FfH/FF better.
 
I've tried to look it up, but it doesn't look like a unit could provide a bonus (horses for example) to a city. Is it something that is very hard to add?

If it were there, a "Bonus" unit would not have to be converted to a building, and could expire thanks to those handy tags you already have. It would make adding movable resources a much easier job.
 
You want the Bonus to be provided to the city only while the unit is standing on the tile? Code would look exactly like CityBonusHappy/Health in that case, except instead of adding Happy or Health you'd add a resource.
 
You want the Bonus to be provided to the city only while the unit is standing on the tile? Code would look exactly like CityBonusHappy/Health in that case, except instead of adding Happy or Health you'd add a resource.

Thanks! That makes sense. I'll put it on my list of possible SDK changes. Another question - how do you reference the <NewName> in python? pUnit.setNewName?

Edit: and one more: which schema files are now optimized to have more minOccurs?
 
I haven't exposed the ability to set the new name to python so far. So that is something which would have to be adjusted in the DLL if someone had a use for it. However that is the most likely method to do it (I don't deal with python much myself unless forced to, hence I am only familiar with how to do Interface things & very basic other pieces thus far).

Schema optimized in this with MinOccurs would be UnitInfos & PromotionInfos. In FF SpellInfos is also optimized so far. To optimize some yourself just go through and add the MinOccurs to each element, then feel free to delete anything which you are certain matches the default (blank, NONE, or 0 typically. Though there are a few notably important exceptions. You can peek at the DLL to see the defaults, or just load the game and see if things go wacky)
 
Here is one more modcomp that I think should be added.



I just thought of some questions that are completely unrelated, but I didn't want to waste posts:
Can python easily identify what summons belong to a caster, ans what caster belongs to a summon? (For instance, could you easily add a <PythonPostCombatLost> that dispels all of a caster's summons when the caster is vanquished? Or that makes them turn barb and lose the limits on their duration? )

What happens if a unit's summon were to upgrade to another unit? Or to be changed to another type of unit via the .convert() function? Would the caster and the summon still be connected? (I assume that they would not still count against the permanent summon limit.)
 
Yes, slaves and masters are exposed to Python for checking. They are not exposed for control however, so anything you attempt to do will be overridden by the SDK without changing it there.

Why dispell all the summons when the caster dies? They already die, I just allow them to wait until the start of the next turn because I highly dislike instantaneous and moderately unexplained loss of summons. That is why I set up negative DurationFromCombat fields to do the same thing. Summon won't die till the start of your next turn if their duration EVER goes negative/0 mid-turn.


Anyway... go and actually play using my changes and almost all of your questions ought to be answered. Or open the code and look at it :) I could easily answer the last few questions, but they are only going to lead to more questions, all of which are easily tested in game, or understood via code.
 
Is it possible to modify the goody code, so that instead of popping Tech, it pops science? Either a percentage of what you are currently researching, or a random quantity, like done with gold?

As I mentioned in another thread, popping a tech from a goody hut or graveyard/barrow when running on Epic speed seems a bit too powerful, at least in the early game. Later with all the tech trading going on with the AI, it isn't as big a deal.
 
That is possible, and a good idea. I've often hated how many Techs the Goody Huts are able to grant you (ought to be Tier 1 only, maybe a few Tier 2 as well though). Normally not an issue, but with Graveyards not being insta-popped by Culture Borders it means you can save up to hope for some of the more advanced techs free later in the game. Changing it to grant an amount of science instead would be a lovely modification. I'll probably have to add a field to GoodyInfos for that one.... hrm.
 
Back
Top Bottom