Jump to content

Issues with xpathing


Iceburg71

Recommended Posts

Ok. I have a working modlet, but the settings are not applying correctly. I have been doing some extended testing on my Baby Animals modlet and some of the changes don't seem to be applying.

 

I get no errors when loading the modlet. I get no errors with either me, or the game spawning in the animals.

 

But (for example) the baby snake is still doing 2 block damage instead of one. I think it is in how I am addressing "Action0" but not sure how to do that within the xml to apply these settings correctly.

 

Any Help appreciacted.

 

EntiityClasses:

<IceBurg>

 

<append xpath="/entity_classes">

<!-- Baby Snake -->

<entity_class name="animalIceburgBabySnake" extends="animalSnake">

<property name="Mass" value="15"/>

<property name="Weight" value="35"/>

<property name="SizeScale" value="0.5"/>

<property name="ExperienceGain" value="65"/>

<property name="DeadBodyHitPoints" value="75"/>

<property name="HandItem" value="meleeHandanimalIceburgBabySnake"/>

<property name="HasRagdoll" value="false"/>

<effect_group name="Base Effects">

<passive_effect name="HealthMax" operation="base_set" value="10"/>

<passive_effect name="HealthMax" operation="perc_add" value="0"/>

</effect_group>

<drop event="Harvest" name="foodRawMeat" count="0" tool_category="Butcher"/>

<drop event="Harvest" name="foodRawMeat" tag="butcherHarvest" count="5"/>

<drop event="Harvest" name="resourceLeather" tag="butcherHarvest" count="1"/>

<drop event="Harvest" name="resourceAnimalFat" tag="butcherHarvest" count="1"/>

<drop event="Harvest" name="resourceBone" tag="butcherHarvest" count="1"/>

<drop event="Harvest" name="resourceBone" tag="allToolsHarvest" count="1"/>

<drop event="Harvest" name="foodRawMeat" count="1" tag="WasteTreasuresCompleteHarvest"/>

<drop event="Harvest" name="resourceLeather" count="1" tag="WasteTreasuresCompleteHarvest"/>

<drop event="Harvest" name="resourceBone" count="1" tag="WasteTreasuresCompleteHarvest"/>

</entity_class>

 

</append>

 

</IceBurg>

 

 

Items.xml:

 

<IceBurg>

<append xpath="/items">

 

<!-- Baby Snake Range and Damage -->

<item name="meleeHandanimalIceburgBabySnake">

<property name="Extends" value="meleeHandAnimalSnake">

<property class="Action0">

<property name="Range" value="1"/>

<property name="DamageEntity" value="7"/>

<property name="DamageBlock" value="1"/>

</property>

</property>

</item>

 

</append>

</IceBurg>

 

Link to comment
Share on other sites

Ok. I have a working modlet, but the settings are not applying correctly. I have been doing some extended testing on my Baby Animals modlet and some of the changes don't seem to be applying.

 

I get no errors when loading the modlet. I get no errors with either me, or the game spawning in the animals.

 

But (for example) the baby snake is still doing 2 block damage instead of one. I think it is in how I am addressing "Action0" but not sure how to do that within the xml to apply these settings correctly.

 

Any Help appreciacted.

 

EntiityClasses:

<IceBurg>

 

<append xpath="/entity_classes">

<!-- Baby Snake -->

<entity_class name="animalIceburgBabySnake" extends="animalSnake">

<property name="Mass" value="15"/>

<property name="Weight" value="35"/>

<property name="SizeScale" value="0.5"/>

<property name="ExperienceGain" value="65"/>

<property name="DeadBodyHitPoints" value="75"/>

<property name="HandItem" value="meleeHandanimalIceburgBabySnake"/>

<property name="HasRagdoll" value="false"/>

<effect_group name="Base Effects">

<passive_effect name="HealthMax" operation="base_set" value="10"/>

<passive_effect name="HealthMax" operation="perc_add" value="0"/>

</effect_group>

<drop event="Harvest" name="foodRawMeat" count="0" tool_category="Butcher"/>

<drop event="Harvest" name="foodRawMeat" tag="butcherHarvest" count="5"/>

<drop event="Harvest" name="resourceLeather" tag="butcherHarvest" count="1"/>

<drop event="Harvest" name="resourceAnimalFat" tag="butcherHarvest" count="1"/>

<drop event="Harvest" name="resourceBone" tag="butcherHarvest" count="1"/>

<drop event="Harvest" name="resourceBone" tag="allToolsHarvest" count="1"/>

<drop event="Harvest" name="foodRawMeat" count="1" tag="WasteTreasuresCompleteHarvest"/>

<drop event="Harvest" name="resourceLeather" count="1" tag="WasteTreasuresCompleteHarvest"/>

<drop event="Harvest" name="resourceBone" count="1" tag="WasteTreasuresCompleteHarvest"/>

</entity_class>

 

</append>

 

</IceBurg>

 

 

Items.xml:

 

<IceBurg>

<append xpath="/items">

 

<!-- Baby Snake Range and Damage -->

<item name="meleeHandanimalIceburgBabySnake">

<property name="Extends" value="meleeHandAnimalSnake">

<property class="Action0">

<property name="Range" value="1"/>

<property name="DamageEntity" value="7"/>

<property name="DamageBlock" value="1"/>

</property>

</property>

</item>

 

</append>

</IceBurg>

 

 

What I would try to do is this and see if it works:

 

<IceBurg>

<append xpath="/items">

 

<!-- Baby Snake Range and Damage -->

<item name="meleeHandanimalIceburgBabySnake">

<property name="Extends" value="meleeHandAnimalSnake"/> <---Close this out here instead of at the very end-->

<property class="Action0">

<property name="Range" value="1"/>

<property name="DamageEntity" value="7"/>

<property name="DamageBlock" value="1"/>

</property>

 

Also, you may not get any errors when it's loading but it may be giving a warning that a particular setting didn't apply (in Yellow) during game load. Hit F1 after loading all the way into the game and look for the WRN in yellow that may have to do with your modlet.

 

Good luck with it and hope you figure it out.

 

 

 

 

Link to comment
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...