ENDLESS™ Legend is a turn-based 4X fantasy-strategy game, where you control every aspect of your civilization as you struggle to save your homeworld Auriga. Create your own Legend!
I would like to make a City Improvement that gives enhancements depending on the level of the hero governing the city.
Is it possible to access the HeroLevel from CityImprovements, so that a calculation like the one for the administrator tomes can be used for City Improvements.
2) Unique Items
There is a command to show the unique text:
So it must be possible to create unique items. I tried the following with partially success:
Those are some very good questions. Accessing the heroes in te academy could be useful for all manner of bonuses and effects.
Regarding the first question, I believe you can not directly get the value from the hero. You may be able to work with an intermediate value, though.
Checking the way Redsang works, it accesses the hero under the path "./EmpireTypeMajor/Garrison/UnitRankHero", so it might be possible that your city improvement has a descriptor like this
while defining an intermediate value of "CityImprovementBonus" for heroes/units in SimulationDescriptors[Class].xml, and adding
to the hero.
I am not sure if that will work, though.
Report comment
Why do you report The-Cat-o-Nine-Tales?
Are you sure you want to block The-Cat-o-Nine-Tales ?
BlockCancel
Are you sure you want to unblock The-Cat-o-Nine-Tales ?
No, as far as I can tell, the "garrison" path is used to access heroes assigned as governors and as army leaders. A Governor counts as part of the cities garrison, and the xml files often refer to "ClassArmy/ClassGarrison" when applying unit bonuses. "ClassGarrison/UnitRankHero" specifies that is should only apply to heroes, not ordinary units.
Sadly, I haven't found any references to the academy yet other than a few references to number of exclusive heroes on the marketplace.
To elaborate on the solution to problem 1, though:
In the file SimulationDescriptors[Class].xml, under the Name="ClassUnit" section, you should add to the SimulationPropertyDescriptors, and you could add the BinarySimulationModifierDescriptor to the SimulationModifierDescriptors of the ClassUnit section.
That would mean that all units could potentially apply a bonus while garrisoned. However, since our building would specify "./ClassCity/Garrison/UnitRankHero" as a path, it should only increase the "CityImprovementBonus" value of the hero, leaving the other units without effect.
Of course, you could also add multiple different ImprovementBonus properties in order to have different improvements give different bonuses.
I can not guarantee this will work, though, as I haven't tried creating such an improvement yet, and I am not sure if the "HeroLevel" reference might break the game because ordinary units do not have such a property. If that does happen, you could move the BinaryModifier into the SimulationDescriptors[UnitRank].xml file.
Good luck with your modding.
Report comment
Why do you report The-Cat-o-Nine-Tales?
Are you sure you want to block The-Cat-o-Nine-Tales ?
BlockCancel
Are you sure you want to unblock The-Cat-o-Nine-Tales ?
Heroes in the academy are in the simulation under the following path > ClassEmpire/ClassUnit,UnitRankHero.
If you want to check they have the item equipped in order to disable the equipement for others you will have to add ClassEmpire/ClassUnit,UnitRankHero/ItemX
I confirm you 2 first path seem correct
For the city improvement I don't see any reason why your modifier could not work.
Did you try to implement it?
If it does not work I will take time to investigate.
Don't hesitate to ask if you have any other question.
eventually I was free to test your suggested solution.
It worked lol, but only with a few changes.
1) It seems impossible to access the Hero's level from "ClassUnit".
But it is possible from "UnitRankHero"
2) To access "CityImprovementBonus" in section "ClassUnit" the path in the CityImprovement-Descriptor have to be
Path="./ClassCity/UnitHero" not "./ClassCity/Garrison/UnitRankHero"
FINAL SOLUTION (veryfied)
1) new variable in SimulationDescriptors[Class].xml section ClassUnit
2) new modifier for Hero's only in SimulationDescriptors[UnitRank].xml section UnitRankHero
3) modify "CityImprovementBonus" from Improvements like
Now with a working solution I will check a few ideas to optimize it. Maybe it is possible to create an entry in ClassCity called "GovernorLevel". Then it will be easy to access the Hero's level from Improvements etc. without an additional entry in UnitRankHero.
Savertin
Newcomer
Savertin
Newcomer
100g2g ptsReport comment
Why do you report Savertin?
Are you sure you want to block Savertin ?
BlockCancelAre you sure you want to unblock Savertin ?
UnblockCancelVIPThe-Cat-o-Nine-Tales
Shifter
VIPThe-Cat-o-Nine-Tales
Shifter
53 100g2g ptsReport comment
Why do you report The-Cat-o-Nine-Tales?
Are you sure you want to block The-Cat-o-Nine-Tales ?
BlockCancelAre you sure you want to unblock The-Cat-o-Nine-Tales ?
UnblockCancelSavertin
Newcomer
Savertin
Newcomer
100g2g ptsReport comment
Why do you report Savertin?
Are you sure you want to block Savertin ?
BlockCancelAre you sure you want to unblock Savertin ?
UnblockCancelVIPThe-Cat-o-Nine-Tales
Shifter
VIPThe-Cat-o-Nine-Tales
Shifter
53 100g2g ptsReport comment
Why do you report The-Cat-o-Nine-Tales?
Are you sure you want to block The-Cat-o-Nine-Tales ?
BlockCancelAre you sure you want to unblock The-Cat-o-Nine-Tales ?
UnblockCancelDEVPikou
Dev
DEVPikou
Dev
19 600g2g ptsReport comment
Why do you report Pikou?
Are you sure you want to block Pikou ?
BlockCancelAre you sure you want to unblock Pikou ?
UnblockCancelSavertin
Newcomer
Savertin
Newcomer
100g2g ptsReport comment
Why do you report Savertin?
Are you sure you want to block Savertin ?
BlockCancelAre you sure you want to unblock Savertin ?
UnblockCancelDEVPikou
Dev
DEVPikou
Dev
19 600g2g ptsReport comment
Why do you report Pikou?
Are you sure you want to block Pikou ?
BlockCancelAre you sure you want to unblock Pikou ?
UnblockCancelSavertin
Newcomer
Savertin
Newcomer
100g2g ptsReport comment
Why do you report Savertin?
Are you sure you want to block Savertin ?
BlockCancelAre you sure you want to unblock Savertin ?
UnblockCancelDEVPikou
Dev
DEVPikou
Dev
19 600g2g ptsReport comment
Why do you report Pikou?
Are you sure you want to block Pikou ?
BlockCancelAre you sure you want to unblock Pikou ?
UnblockCancel