Menu

Show posts

This section allows you to view all posts made by this member. Note that you can only see posts made in areas you currently have access to.

Show posts Menu

Topics - moumix

#1
So, I had a code that was like this for a custom <ToughtDef>:


   <defName>CustomThought</defName>
   [...]
   <requiredTraits>
      <li>Trait1</li>
      <li>Trait2</li>
   </requiredTraits>


But now in my code, Trait1 is part of a "spectrum" trait, with different degrees, and only the negative degree (-1) should have the ThoughtDef. Trait2 is still a standalone trait, with no degrees. As a workaround for now, I duplicated my ThoughtDef and made one for each, like this:


<ThoughtDef>
   <defName>CustomThoughtTrait1</defName>
   [...]
   <requiredTraits>
      <li>Trait1</li>
   </requiredTraits>
   <requiredTraitsDegree>-1</requiredTraitsDegree>
   [...]
</ThoughtDef>

<ThoughtDef>
   <defName>CustomThoughtTrait2</defName>
   [...]
   <requiredTraits>
      <li>Trait2</li>
   </requiredTraits>
   [...]
</ThoughtDef>


Is it the best/only way to make that work, or is it possible to have both a standalone trait and a specific degree for another trait in the same ThoughtDef?



Second question about a similar thing, is it possible to have several different degrees in the tag "<requiredTraitsDegree>"? Like this for example:


   <requiredTraits>
      <li>Trait1</li>
   </requiredTraits>
   <requiredTraitsDegree>
      <li>-2</li>
      <li>-1</li>
   </requiredTraitsDegree>