Very interesting file I came across that everyone should see

I was trying to mod a shipyard to see if I could produce hyperion [$whatever] type effects where ships built from that shipyard would be granted a configurable bonus.. While my results were ultimately quite unsuccessful & resulted in "no errors or effect" at best, I cae across ModifierEffectTypes.xsd in GalcivIII\data\schema with a lot of very cool looking modder doors spotlighted

<xs:simpleType name="OnEventTypes">
<xs:restriction base="xs:string">
<xs:enumeration value="OnConstructShip"/>
<xs:enumeration value="OnConstructImprovment"/>
<xs:enumeration value="OnPlanetTileOwnerChangeToForeign"/>
<xs:enumeration value="OnPlanetTileOwnerChangeToSelf"/>
<xs:enumeration value="OnGenocidePlanet"/>
<xs:enumeration value="OnCollideAtAnomaly"/>
<xs:enumeration value="OnArriveAtAnomaly"/>
<xs:enumeration value="OnEventChoice"/>
<xs:enumeration value="OnUPResolutionPassed"/>
<xs:enumeration value="OnCultureTraitUnlock"/>
</xs:restriction>
</xs:simpleType>

End of quote

The hyperion $whatever improvements make use of the OnConstructShip event & the ideological ones onConstructImprovement and give an example of how we might be able to use some others in that grouping.  What about UPResolutionFails?!  I can't quite figure out what the difference between arrive & collide at anomaly either :(.  I 

 

<xs:simpleType name="ValueTypes">
<xs:restriction base="xs:string">
<xs:enumeration value="Value"/>
<xs:enumeration value="Range"/>
<xs:enumeration value="Special"/>
<xs:enumeration value="BestOf"/>
<xs:enumeration value="ModifierInstance"/>
</xs:restriction>
</xs:simpleType>

End of quote

The BestOf/Special tags are in use on one of the anomalies & they work as a pair..  But LeastOf is conspicuously absent & would allow things to be created with a cap as well/instead.

I just wish there were more of these to go with them.  I wish we had the ability to create/choose from more options, PercentOfFaction/PlanetPopulation for instance.  GetValueFromStarbase does not appear to be in use anywhere

 

<xs:simpleType name="SpecialValueTypes">
<xs:restriction base="xs:string">
<xs:enumeration value="PercentOfFactionCredits"/>
<xs:enumeration value="PercentOfResearchCost"/>
<xs:enumeration value="NumTurnsCultureBenevolent"/>
<xs:enumeration value="NumTurnsCultureNeutral"/>
<xs:enumeration value="NumTurnsCultureMerciless"/>
<xs:enumeration value="GetValueFromStarbase"/>
<xs:enumeration value="TradeRouteRaidBonus"/>
<xs:enumeration value="ResearchTag"/>
<!--VALUES BELOW USED BY UP VOTING LOGIC-->
<xs:enumeration value="Stat"/>
<xs:enumeration value="Tech"/>
<xs:enumeration value="Colonies"/>
</xs:restriction>
</xs:simpleType>

End of quote

 

This right here is another block with some huge glaring holes, FactionAtPeace/NotInWar


<xs:simpleType name="TargetQualifierType">
<xs:restriction base="xs:string">
<xs:enumeration value="TradingWithAllUPMembersNotAtWar"/>
</xs:restriction>
</xs:simpleType>

End of quote

on and on and on, very interesting options among the completely bewildering ones

 

Cross referencing some of the types in the file that I don't readily recognize eith places they get used makes me giddy with possibilities  (Trojan Horse structures that generate negative influence and some benefit that makes destroying them an iffy choice after planettileownerchange), research pathways that give the researcher a prototype(?)...  Can I do a RangeMin/Max with math using SpecialValues as a variable?on and on

2,001 views 3 replies
Reply #1 Top

GetValueFromStarbase appears in StrategicResourceDefs.xml for the relics, it's a short xml so keeping the paste short

<SpecialValue>
                <Special>GetValueFromStarbase</Special>
            </SpecialValue>

The value it gets comes from StarbaseModuleDefs.xml based on which modules the starbase has installed, the relevant info appearing to be

<Stats>
      <EffectType>ModifierValue</EffectType>
      <Target>
        <TargetType>StrategicResource</TargetType>
        <StrategicResourceType>Relic</StrategicResourceType>
      </Target>
      <BonusType>Flat</BonusType>
      <Value>0.125</Value>
    </Stats>

This being from the XenoArcheologyLabModule, possibly of importance also is the RequiredTarget tag.

This is taken from ImprovementDefs.xml for HyperionSensorSystem

<Triggers>
      <OnEvent>OnConstructShip</OnEvent>
      <Target>
        <TargetType>Ship</TargetType>
      </Target>
      <Lifetime>Instant</Lifetime>
      <Modifier>
        <EffectType>SensorRange</EffectType>
        <Target>
          <TargetType>Ship</TargetType>
        </Target>
        <BonusType>Multiplier</BonusType>
        <Value>0.1</Value>
      </Modifier>
    </Triggers>

You could possibly try a starbase module with a combination of these things with the appropriate target tags and everything else where needed of which I assume  you are most capable being more ambitious than me in this respect. Maybe this is something you have already attempted but I thought that I would throw my 2 cents in since you mentioned the GetValueFromStarbase and I knew where it appeared off the top of my head so maybe you hadn't tried that approach. Good luck! And as always, can't wait for quite some time from now when the devs have come out with everything they want.

Reply #2 Top

I must have missed that line, seems you've tried the triggers, maybe i'll tinker some myself(time permitting), sorry if that was a completely unnecessary post.

Reply #3 Top

Quoting Moogle65535, reply 2

I must have missed that line, seems you've tried the triggers, maybe i'll tinker some myself(time permitting), sorry if that was a completely unnecessary post.
End of Moogle65535's quote

LOl, don't worry.  xml file modding is one of those things that a lot of people assume to be super technical because it tends to have a "pretty"/readable format with lots of CamelCase and <SeemingGibberish>, discussion about it is almost always a good thing to help people get comfortable