Feature Requests and Discussion

could Auric and Cassiel be set to ignore AIreligionweights when leading non-Agnostic civs? It's kinda sad to see them never adopt a religion when they show up using unrestricted leader ;)
 
could Basium's and Hyborem's starting armies be set to spawn with iron weapons, and bannor demagogues spawn with the max weapon tier the civ has access to? that would make those more convenient for the player and might help the AI as well :)
 
Here is an updated version of Platy World Builder for FfH2.




The biggest change is the ability to set a unit's summoner. (This would be -1 for non-summons, and the Unit ID of the summoner otherwise.)

It also displays the Unit ID. This lets you know what to put as the summoner of another unit. It also helps you identify a unit in the game with a unit in the logs, which can help track down bugs.


Duplicate Unit now sets the copy as having the same summoner as the original unit. It deletes all of the new unit's promotions before copying those of the old one, so the copy would not have promotions that the original had somehow lost. (In my modmod, this may prevent duplicate great persons from having different free promotions.) I also fixed the minor bug (extra set of parentheses) that this had the last time I shared it.



I tried to change the diplomacy so that it would allow you to change Embassy and Right of Passage Agreement statuses, but it did not really work out. I don't think everything necessary is exposed to python yet.
 
I'd like to be able to use the minor leaders in regular games. I know you can activate them somehow and it would be cool to see a larger variety of starting characters (though I do love how revolutions will often involve a minor leader taking over)

Anyone else notice that the Infernals aren't very aggressive and don't use their world spell to get the Ashen Veil cities? They just kinda start in a terrible spot, which is also something that I think should be changed, and act like any other civ.

Aren't the Mercurians and Infernal supposed to be extremely aggressive? I feel that when they come in wars should break out more and things should isolate more than they do.
 
I would very much like pNewUnit.convert(pOldUnit) to set pNewUnit as the summoner of all of pOldUnit's summons.


It would also be nice if there were a function that would return a list of all a unit's summons.

Edit:
I guess I'll go ahead and share another little update to Platy World Builder for FfH2 while I'm here.

This one introduces the ability to use World Builder to change a city's civilization type (useful for Tolerant trait players) and its Revolution Index.

(Note that the Rev Index part would make it incompatible with Base FfH2, but it is very nice to have in MNAI.)

It also tells you the name and location of a unit's summoner, rather than making you check the unit IDs of every unit on the map.
 
Tholal, would it be possible to add some means of removing the "Crazed" promotion from Lunatics? Priest spell/Pool of tears/Spirit III/entering a city with Infirmary?

Or do you think it would make them too OP?

In comparison: You can remove the "Diseased" promotion from Diseased corpses, which are to some extent a Luantic equivalent.
 
Can the difficulty be changed from WB?
 
is it possible to have the game detect when simultaneous turns is on, and subtract 1 to immobileturns entries in civ4spellinfos? those spells are broken under those circumstances as they last double than intended and allow to keep a stack frozen indefinitely.
 
it would be awesome if autocasting were reintroduced along with denev's fix that stopped the UI automatically switching to another unit after you move the current one, IF the current one can cast a spell. it would make magic a lot less micromanagement intensive :)
 
I think it would be nice if Advanced Tactics option would allow you to build cities and superforts in territory owned by rivals with whom you are at war.
 
Here is an updated version of Platy World Builder for FfH2.

Thanks again!

I tried to change the diplomacy so that it would allow you to change Embassy and Right of Passage Agreement statuses, but it did not really work out. I don't think everything necessary is exposed to python yet.

Do you know what functions need to be exposed for this?


I'd like to be able to use the minor leaders in regular games.

Added to the feature request list.

Anyone else notice that the Infernals aren't very aggressive and don't use their world spell to get the Ashen Veil cities?

They do use their World Spell. They just dont get access to it until they research Malevolent Designs.

Aren't the Mercurians and Infernal supposed to be extremely aggressive? I feel that when they come in wars should break out more and things should isolate more than they do.

They are pretty aggressive. The main issue is that they only start with a handful of troops, so unless they are summoned super-early, they are outmatched by most of the other civs until the Manes/Angels start rolling in.

I would very much like pNewUnit.convert(pOldUnit) to set pNewUnit as the summoner of all of pOldUnit's summons.

Think that would get a little strange if a unit is captured or traded. I'm guessing that you're mainly concerned with units that get upgraded?

It would also be nice if there were a function that would return a list of all a unit's summons.

Added to the feature request list.


Tholal, would it be possible to add some means of removing the "Crazed" promotion from Lunatics? Priest spell/Pool of tears/Spirit III/entering a city with Infirmary?

That's beyond the scope of this mod.


Can the difficulty be changed from WB?

No idea.


[to_xp]Gekko;12607448 said:

I dont see how that is particularly useful. A human player will still see through the disguise and an AI player will still react the same as well. Seems like a lot of work for no real gain. In addition, Selrahc has not made his code public which makes it difficult to import anything from there.

[to_xp]Gekko;12609857 said:
is it possible to have the game detect when simultaneous turns is on, and subtract 1 to immobileturns entries in civ4spellinfos? those spells are broken under those circumstances as they last double than intended and allow to keep a stack frozen indefinitely.

I've seen this mentioned a couple of times but never really understood what was causing the issue. Can someone give me a clear, detailed explanation of the problem?


[to_xp]Gekko;12631611 said:
denev's fix that stopped the UI automatically switching to another unit after you move the current one, IF the current one can cast a spell.

I tried to add this in not long ago and couldn't get it to work. On the feature request list.

I think it would be nice if Advanced Tactics option would allow you to build cities and superforts in territory owned by rivals with whom you are at war.

Interesting idea. Added to the list.
 
consider scaling the number of troops the infernals/mercurians get based on the turn they enter the world, that would balance them out nicely ;)

regarding immobileturns: blinding light for example is set to a value of 2, which in SP means the unit is immobile on the turn the spell is cast ( useless since it has to wait for its turn anyway ) , AND the turn after that, which essentially means it keeps it from moving for 1 turn.

when playing simultaneous turns MP however, the fact that the unit cannot move as soon as the spell is cast is very valuable, and this basically means the spell lasts twice as much as intended. couple this with the way the spell works and it's easy to keep stacks frozen in place indefinitely.

for this reason I changed blinding light, spores and entangle to work via promotions ( similar to charm, slow etc. ) in Essentials, but I guess changing the way the tag works in simulturns MP instead would be "cleaner" :)
 
Yeah you are right about the infernal world spell, forgot about the tech requirement. And it's hit or miss on the aggressiveness, if they spawn in an ok location they can kick butt, but sometimes they sit and are crap (I think that's fine as it's a bit of luck). Thanks for answering!
 
Thanks again!

You're welcome, but perhaps should have waited as I have another version ready.


This one allows you to select a unit typing in its Unit ID. This can be copied and pasted straight from a file like BBAI.log or MPLog.txt, and so makes it much easier find the unit that is causing the AI to get stuck in loops and to delete it before it causes a problem.

(You do have to select another unit belonging to the same player first though. I may eventually try to switch this so that you instead find a unit by ID through the owner's player data screen, but I'm not quite sure how to do that yet. )

It also displays the unit's Group ID (there does not seem to be any way to change this in python), and adds a button to change whether the unit is immortal (which cannot be deselected so long as the unit has a promotion making it immortal).

The city data screen allows you to change the city's Revolution Index and civilization type (useful for tolerant leaders).

Do you know what functions need to be exposed for this?

The 4 functions that deal with Open Borders Agreements are these:
pTeam.isOpenBorders(iTeam)
pTeam.changeOpenBordersTradingCount( iCount )
pTeam.getOpenBordersTradingCount()
pTeam.signOpenBorders(iTeam)


For Right of Passage Agreements, the only equivalent function that is currently exposed to python is this:
pTeam.isLimitedBorders(iTeam)

These three exist in CvTeam.h/cpp, but not in the CyTeam files:
pTeam.changeLimitedBordersTradingCount( iCount )
pTeam.getLimitedBordersTradingCount()
pTeam.signLimitedBorders(iTeam)

It should be easy for me to let worldbuilder control Right of Passage agreements if you expose those 3.



For embassies, I don't have as clear an example to follow and am less sure what I'm doing. I even might be able to figure out how to make it work with only the two functions which are already exposed:
pTeam.isHasEmbassy(iTeam)
pTeamisHasEmbassy(iTeam)

Think that would get a little strange if a unit is captured or traded. I'm guessing that you're mainly concerned with units that get upgraded?
Couldn't you make that part of the pNewUnit.convert(pOldUnit) code run only if pNewUnit.getOwner() == pOldUnit.getOwner() ?


Yeah, I'm mostly concerned with upgrades, although that can include units upgraded through spells.

In my modmod, the dimensional promotions that the caster has cause it to gain a share of its summons' xp when they die. This would not happen if the summoner upgrades first.

Having a summoner is also the fastest way for my Ring of Warding code to know to prevent a hostile unit from entering the city. (I also check for non-living units of limited duration

I also try to limit certain permanent summons per summoner (in python), and upgrading the summoner can get around this. (For example, a Malakim Radiant Guard can summon one Sand Lion, and then another when he upgrades to a Champion, and another when he upgrades to a Knight.) The standard FfH2 way of limiting the number of permanent summons based on the number of summoners could allow the best summoner to create all the summons while the others just boost the numbers allowed. (Adepts could allow Archmages to make more puppets, for example.) Also, the standard method only takes promotions into account, not other prereqs like religion. Permanent summons summoned by priests

Added to the feature request list.
Thanks
That's beyond the scope of this mod.

It is however quite easy to do.

In my modmod Crazed can be removed by entering the tile with the Pool of Tears or by the Spirit III spell. It can also be removed temporarily by using the Commit to Asylum ability, although it then comes back (with Enraged) whenever the unit leaves a city with an Asylum building.

There is no compelling reason for Tholal to add this to MNAI, but others can easily implement such features on their own.

I am pretty sure that it cannot currently.

It is easy to find out the difficulty level in python, but I have not yet found a function that can change it mid game.

The Increasing Difficulty and Flexible Difficulty game options can change the difficulty in the middle of a game, but they seems to be handled entirely in the DLL (except for the text that shows the current difficulty). It should be possible for Tholal to expose a difficulty changing function to python, which would make it easy enough for me to add that functionality to Worldbuilder.


I think that these are the functions that would need to be exposed to python:

void CvInitCore::setHandicap(PlayerTypes eID, HandicapTypes eHandicap)

void CvGame::setHandicapType(HandicapTypes eHandicap)


Interesting idea. Added to the list.

Thanks.

It just makes sense that if you are fighting a war for territory, you'd want to go ahead and settle or fortify the territory.

At one point I actually made it possible to build forts in enemy territory using CvGameUtils.py's def canBuild(self,argsList):, but I ran into a complication; the superforts would always belong to the player in whose territory I built them, rather than to the owner of the units that built it. The python functions don't seem to keep up with who actually builds improvements. Maybe you can get around that problem better in C++.


------

Would it be possible to make it so that you can enter worldbuilder while facing an event popup, rather than having to make a choice first?

Also, could it be made so that worldbuilder is more responsive when you try to use it during another player's turn, particularly during an AI loop you are trying to break?

I'm guessing those are both outside of your abilities, but it sure would be nice.
------
Edit1: I just noticed that there is a new version of Platy World Builder out now. You may wish to wait for me to merge in those changes.

------
Edit2: Ok, I now have a working merge that includes the latest version of Platy World Builder.

I renamed this one Platy World Builder 2 for MNAI, as Platyping called the new version World Builder 2.0 and I had to include an MNAI-specific version of CvGameUtils.py to make it work. (I have not actually merged it into my modmod yet, which would require a different CvGameUtils.py.)

Platyping made this new version a Modular modmod, but I find modular components more confusing than helpful so I changed that in this merge. The only thing that the modular part was really used for was assigning the path to the new icons he used to represent attitudes in the diplomacy screen. I moved those to the Art/Platy folder and just wrote out the path in WBDiplomacyScreen.py. I'm thinking that it might be better for me to figure out who to use the BUG attitude icons instead though.

The religion screen is now combined with a corporation screen, which seems a little odd when there are no corporations. I removed the button for corporations, since it went the same place as the religion screen. I also decided not to sort the religions alphabetically and not to break them up into different rows, and that just makes things more confusing imho.

There are several other little changes I have in mind (like making the promotion screen separate equipment, spell effects, spell spheres, and other promotions) to make it better fit FfH2, but I don't feel like working on it any longer tonight.

-----
Edit3:
Well, I went ahead and merged it with my modmod. So far things seem fine, except I notice that the way it handled Great Person Point rates is a bit odd. It is assigning them based on the GPP provided by specialists, which in my momdod (where settled great people can provide GPP too) means that they are all on their twice. There is also now no way to adjust the GPP for Adventurers, Shades, and Great Commanders. I think I'll have to change how this code works, some other time.
 
Here is another update of World Builder, which incorporates the changes Platyping released yesterday (which includes a fix for the great person rate issues which I shared with him).

I eliminated the Corporation half of the Corporation/Religion screen, as Corporations do not exist in FfH2. I did not see a point of having multiple columns when all religions fit easily in one, so I eliminated that too. I commented out the sorting part, as in my modmod I'd rather them appear in alignment based rather than alphabetical order.

I also eliminated the Spaceship half of the Project/Spaceship screen, since Spaceships do not exist in FfH2, but used parts of that code so that you can adjust the number of Rituals completed rather than just set them as completed or not. I also made it take into account world and team limits on rituals.

I also added the ability to sort promotions into various types: Normal Promotions, Spell Spheres, Effects, Races, Items, Hidden Options, and All.

(Note that the spell spheres category is based on having a mana prereq, so in Magister Modmod it includes all spell spheres but in MNAI it only includes the first levels. I don't feel like making the code more complicated for your modmod when the simpler way works well in mine.)

I also changed the sorting categories for Buildings from simply being Buildings or Wonders to being Buildings, Wonders, National Wonders, Team Wonders, World Wonders, Unique Buildings, Religious Buildings, Spell Buildings, Items, Hidden Buildings, and All.

(Note that Spell Buildings would be empty in MNAI, as it checks for BUILDINGCLASS_SPELL, which in Magister Modmod was given to all of the buildings that have bRequiresCaster since BuildingInfo.isRequiresCaster() is not exposed to python.)


I'm afraid that the new way Diplomacy is handled seems more complicated, so it may take me a while to figure out how to let it changed embassies and right of passage agreements even if you do expose all the necessary python functions.
 
number of Kuriotate cities could scale better with map size. it's currently 2 for duel/tiny, 3 for small/standard, 4 for large and 5 for huge. I think 1 for duel, 2 for tiny, 3 for small, 4 for standard, 5 for large and 6 for huge would be an improvement :)
 
Here is another update of World Builder

Excellent! Couple of issues I noticed.

Attachment 1 - some of the widgets are overly large. Looks like they're taking up two rows instead of one

Attachment 2 - A lot of the button text has these boxes at the end
 

Attachments

  • wb2_large widgets.jpg
    wb2_large widgets.jpg
    304.9 KB · Views: 53
  • wb2_text_issues.jpg
    wb2_text_issues.jpg
    187 KB · Views: 57
[to_xp]Gekko;12563344 said:
could Auric and Cassiel be set to ignore AIreligionweights when leading non-Agnostic civs? It's kinda sad to see them never adopt a religion when they show up using unrestricted leader ;)

Hmmm. I'll see what I can do there. I think the religionWeights are mainly just used for flavor. If so, I'll consider just disabling them for higher difficulties, though that will also require some improvements to the AI religion-choosing code.

The 4 functions that deal with Open Borders Agreements are these:
pTeam.isOpenBorders(iTeam)
pTeam.changeOpenBordersTradingCount( iCount )
pTeam.getOpenBordersTradingCount()
pTeam.signOpenBorders(iTeam)


For Right of Passage Agreements, the only equivalent function that is currently exposed to python is this:
pTeam.isLimitedBorders(iTeam)

These three exist in CvTeam.h/cpp, but not in the CyTeam files:
pTeam.changeLimitedBordersTradingCount( iCount )
pTeam.getLimitedBordersTradingCount()
pTeam.signLimitedBorders(iTeam)


For embassies, I don't have as clear an example to follow and am less sure what I'm doing. I even might be able to figure out how to make it work with only the two functions which are already exposed:
pTeam.isHasEmbassy(iTeam)
pTeamisHasEmbassy(iTeam)

It should be possible for Tholal to expose a difficulty changing function to python, which would make it easy enough for me to add that functionality to Worldbuilder.

I think that these are the functions that would need to be exposed to python:

void CvInitCore::setHandicap(PlayerTypes eID, HandicapTypes eHandicap)

void CvGame::setHandicapType(HandicapTypes eHandicap)

BuildingInfo.isRequiresCaster() is not exposed to python.)

OK. I'll try to take care of all this for the next release.

Couldn't you make that part of the pNewUnit.convert(pOldUnit) code run only if pNewUnit.getOwner() == pOldUnit.getOwner() ?

Yeah, I'm mostly concerned with upgrades, although that can include units upgraded through spells.

I'll look into it.


Would it be possible to make it so that you can enter worldbuilder while facing an event popup, rather than having to make a choice first?

Also, could it be made so that worldbuilder is more responsive when you try to use it during another player's turn, particularly during an AI loop you are trying to break?

I'm guessing those are both outside of your abilities, but it sure would be nice.

Definitely beyond my abilities and not something I really want to dig into.
 
Back
Top Bottom