Sarakatunga Posted December 15, 2021 Share Posted December 15, 2021 (edited) hi folks, i'm trying to modify the "prob" of this item "modGunScopeSmall" but i can't get it to work. What am I doing wrong? <configs> <set xpath="/traders/trader_item_groups/trader_item_group[@name='modGunT1']/item[@name='modGunScopeSmall']/@prob">0.05</set> </configs> Edited December 15, 2021 by Sarakatunga (see edit history) Link to comment Share on other sites More sharing options...
Telric Posted December 15, 2021 Share Posted December 15, 2021 The modgunscopesmall doesn't have a prob in vanilla. You'll need to use setattribute. Link to comment Share on other sites More sharing options...
Sarakatunga Posted December 15, 2021 Author Share Posted December 15, 2021 Yes, if I know, I just want to lower the odds in which it appears. Link to comment Share on other sites More sharing options...
BFT2020 Posted December 15, 2021 Share Posted December 15, 2021 39 minutes ago, Sarakatunga said: Yes, if I know, I just want to lower the odds in which it appears. This is what Telric is trying to tell you: <setattribute xpath="/traders/trader_item_groups/trader_item_group[@name='modGunT1']/item[@name='modGunScopeSmall']" name="prob">0.05</setattribute> The set command can only change attributes already in that line. Since prob doesn't exist, nothing happens. 1 Link to comment Share on other sites More sharing options...
Sarakatunga Posted December 21, 2021 Author Share Posted December 21, 2021 On 12/15/2021 at 12:15 PM, BFT2020 said: This is what Telric is trying to tell you: <setattribute xpath="/traders/trader_item_groups/trader_item_group[@name='modGunT1']/item[@name='modGunScopeSmall']" name="prob">0.05</setattribute> The set command can only change attributes already in that line. Since prob doesn't exist, nothing happens. If I have tried it and it works, thank you very much Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now