mirror of
https://github.com/TotalFreedomMC/TF-EssentialsX.git
synced 2025-07-25 15:03:48 +00:00
[trunk] /worth: don't access config directly, don't reload config after save and use getPrice() method.
git-svn-id: https://svn.java.net/svn/essentials~svn/trunk@1208 e251c2fe-e539-e718-e476-b85c1f46cddb
This commit is contained in:
parent
fc9a9c2b9f
commit
31dc8694b6
3 changed files with 3 additions and 4 deletions
|
@ -24,7 +24,7 @@ public class Commandsell extends EssentialsCommand
|
|||
int id = is.getTypeId();
|
||||
int amount = 0;
|
||||
if (args.length > 0) amount = Integer.parseInt(args[0].replaceAll("[^0-9]", ""));
|
||||
int worth = Essentials.getWorth().config.getInt("worth-" + id, 0);
|
||||
int worth = Essentials.getWorth().getPrice(String.valueOf(id));
|
||||
boolean stack = args.length > 0 && args[0].endsWith("s");
|
||||
boolean requireStack = parent.getConfiguration().getBoolean("trade-in-stacks-" + id, false);
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue