mjrice
New member
Hello, I have created a mod to the RWG system using xpath, and am trying to figure out if it is possible to make some mod variables (specifically biome distribution) based on a combobox value from the UI. I can add the selection I want by mod'ing windows.xml using the snippet below:
But how can I use the selected value of "BiomeStyle" elsewhere (in rwgmixer.xml) to change a value such as the (0,.2) range in this snippet:
What I am hoping for is a way to say (in xml),
Code:
<append xpath="/windows/window[@name='newContinueGame']/rect[@pos='0,-50']/rect[@name='newContent']/rect[@visible='{isgenerateworld}']/grid">
<rect>
<label depth="4" width="250" height="30" text="Biome Style" font_size="28" color="[white]" justify="right" pivot="topleft" />
<combobox depth="108" pos="255,0" width="300" height="32" name="BiomeStyle" type="ComboBoxList<System.String>" values="Balanced,More Snowy,More Desert,More Forested,More Prairie" value_wrap="false" />
</rect>
</append>
Code:
<set xpath="/rwgmixer/biome_generators/biome_generator[@name='vanillaSmall']/module[@name='biomeOutput'][@type='BiomeIDMapper']/property[@name='biomemap0.Range']/@value">0.00,0.2</set> <!-- forest -->
Code:
if(BiomeStyle = 'More Forested') then biomemap0.Range/@value=0,.5"