Results 1 to 3 of 3

Thread: Modding Help - How do I change EXP amount given when using a tool to upgrade blocks?

  1. #1
    Refugee
    Join Date
    Apr 2017
    Posts
    4
    Rep Power
    0

    Modding Help - How do I change EXP amount given when using a tool to upgrade blocks?

    Hi, I'm trying to make a mod that changes a few things up and part of it I am trying to change is XP.

    How can I change it so that when I use a Nailgun to upgrade a block, it will give me say half as much XP as it usually does?

    I've looked everywhere and can't find the answer. If you could help that would be great. Thanks.

    This is as close as I got to trying to figure it out but Im new-ish to modding.

    LIST OF PASSIVE EFFECTS (it does not matter on which item/entity a passive is active. Only a few require a certain scope, like being on an item or mod)

    PlayerExpGain, Tags: Kill, Harvesting, Upgrading, Crafting, Selling, Quest, Looting, Party, Other

    <passive_effect name="PlayerExpGain" operation "base_subtract" value= "100.0"/>

    I just want the Nailgun to give less XP when upgrading blocks.

  2. #2
    Colony Founder KhaineGB's Avatar
    Join Date
    Apr 2017
    Location
    Liverpool, UK
    Posts
    2,147
    Rep Power
    1
    Code:
    <passive_effect name="PlayerExpGain" operation="perc_add" value="-.5" tags="Upgrading"/>
    Add that to the effect_group of the nailgun. That way it will only take effect while the nailgun is held.

  3. #3
    Refugee
    Join Date
    Apr 2017
    Posts
    4
    Rep Power
    0
    Thanks a lot that worked. I'm also experiencing a problem changing settings with xpath. I know how to change settings but I'm struggling to change two settings in one line of an xpath.

    This is what I want to edit with the Auger settings:

    Code:
    	
    <passive_effect name="BlockDamage" operation="perc_add" value="-.15,.15"/> <!-- random BlockDmg -->
    <passive_effect name="BlockDamage" operation="perc_add" value=".1,.5" tier="2,6"/> <!-- tier bonus -->
    The first one I can do and have done. But the second one I can't figure out as its containing two changes in one. How would I go about this?

    Code:
    <set xpath="/items/item[@name='meleeToolAuger']/effect_group/passive_effect[@name='BlockDamage'][@operation='base_set']/@value">100.0</set>
    <set xpath="/items/item[@name='meleeToolAuger']/effect_group/passive_effect[@name='BlockDamage'][@operation='perc_add']/@value">.15,.15</set>
    	
    <set xpath="/items/item[@name='meleeToolAuger']/effect_group/passive_effect[@name='BlockDamage'][@operation='perc_add']/@value">.5,2.5</@tier>1,6</set>
    The top two are changing two different things. If I did them both separate, how would it identify the specific change I want. Any ideas how to change two in one? The code ends at </ so @tier does nothing. I'm still messing around with it trying to figure it out.

    Thanks again.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •