Logo Platform
logo amplifiers simplified

How to make colonization depending on two (instead of one) technology?

Reply
Copied to clipboard!
7 years ago
Dec 29, 2017, 6:18:37 PM

I would like to make a mod in which the colonization of a planet type is depending not on one but on two technologies.


Currently the prerequisites for colonizing a planet are defined in ConstructibleElement_Industry[PlanetColonization].xml

<MetaPrerequisite Operator="Or">
            <TechnologyPrerequisite Flags="Prerequisite,Technology">TechnologyColonization6</TechnologyPrerequisite>
            <PathPrerequisite Flags="Prerequisite">../ClassEmpire/ClassSenate/LawEffectP04L00</PathPrerequisite>
            <PathPrerequisite Flags="Prerequisite">../ClassEmpire/ClassSenate/LawEffectP04L00Republic</PathPrerequisite>
            <PathPrerequisite Flags="Prerequisite">../ClassEmpire,EmpireTypeMinor</PathPrerequisite>
</MetaPrerequisite>

Is there a possiblity to have two technologies so that both have to be researched to be able to colonize a planet? The simplest solution seems to be if there was a way to have nested MetaPrerequisite Operator="And" nested in there so that it reads something like


[(TechnologyColonization6 AND TechnologyColonization7) OR ../ClassEmpire/ClassSenate/LawEffectP04L00 OR ../ClassEmpire/ClassSenate/LawEffectP04L00Republic OR ../ClassEmpire,EmpireTypeMinor]


I am also open to other suggestions.


While I am asking: Is the colonization action of colony ships defined at the same place as the colonizations that is constructed in a colonized system?

0Send private message
7 years ago
Jan 2, 2018, 10:39:13 AM

Hey Jaecaron!


The solution is quite easy: you can have several TechnologyPrerequisites in one by doing this:

<TechnologyPrerequisite Flags="Prerequisite,Technology">TechnologyColonization6,TechnologyColonization7</TechnologyPrerequisite>

TechnologyPrerequisites are actually PathPrerequisites preceeded by ".../ClassEmpire/ClassResearch," and work exactly the same.

That means you can check for multiple tags at once, each given by a different technology!

0Send private message
7 years ago
Jan 6, 2018, 2:33:15 PM

Thank you very much, this is really helpful.

0Send private message
?

Click here to login

Reply
Comment

Characters : 0
No results
0Send private message