aboutsummaryrefslogtreecommitdiff
path: root/src/main/java/me/shedaniel/rei/client/ClientHelper.java
diff options
context:
space:
mode:
Diffstat (limited to 'src/main/java/me/shedaniel/rei/client/ClientHelper.java')
-rw-r--r--src/main/java/me/shedaniel/rei/client/ClientHelper.java8
1 files changed, 4 insertions, 4 deletions
diff --git a/src/main/java/me/shedaniel/rei/client/ClientHelper.java b/src/main/java/me/shedaniel/rei/client/ClientHelper.java
index b91d43f32..ad14db62f 100644
--- a/src/main/java/me/shedaniel/rei/client/ClientHelper.java
+++ b/src/main/java/me/shedaniel/rei/client/ClientHelper.java
@@ -64,13 +64,13 @@ public class ClientHelper implements ClientModInitializer {
}
public static boolean isCheating() {
- return RoughlyEnoughItemsCore.getConfigHelper().getConfig().cheating;
+ return RoughlyEnoughItemsCore.getConfigManager().getConfig().cheating;
}
public static void setCheating(boolean cheating) {
- RoughlyEnoughItemsCore.getConfigHelper().getConfig().cheating = cheating;
+ RoughlyEnoughItemsCore.getConfigManager().getConfig().cheating = cheating;
try {
- RoughlyEnoughItemsCore.getConfigHelper().saveConfig();
+ RoughlyEnoughItemsCore.getConfigManager().saveConfig();
} catch (IOException e) {
e.printStackTrace();
}
@@ -95,7 +95,7 @@ public class ClientHelper implements ClientModInitializer {
} else {
Identifier identifier = Registry.ITEM.getId(cheatedStack.getItem());
String tagMessage = cheatedStack.copy().getTag() != null && !cheatedStack.copy().getTag().isEmpty() ? cheatedStack.copy().getTag().asString() : "";
- String og = cheatedStack.getAmount() != 1 ? RoughlyEnoughItemsCore.getConfigHelper().getConfig().giveCommand.replaceAll(" \\{count}", "").replaceAll("\\{count}", "") : RoughlyEnoughItemsCore.getConfigHelper().getConfig().giveCommand;
+ String og = cheatedStack.getAmount() != 1 ? RoughlyEnoughItemsCore.getConfigManager().getConfig().giveCommand.replaceAll(" \\{count}", "").replaceAll("\\{count}", "") : RoughlyEnoughItemsCore.getConfigManager().getConfig().giveCommand;
String madeUpCommand = og.replaceAll("\\{player_name}", MinecraftClient.getInstance().player.getEntityName()).replaceAll("\\{item_identifier}", identifier.toString()).replaceAll("\\{nbt}", tagMessage).replaceAll("\\{count}", String.valueOf(cheatedStack.getAmount()));
if (madeUpCommand.length() > 256) {
madeUpCommand = og.replaceAll("\\{player_name}", MinecraftClient.getInstance().player.getEntityName()).replaceAll("\\{item_identifier}", identifier.toString()).replaceAll("\\{nbt}", "").replaceAll("\\{count}", String.valueOf(cheatedStack.getAmount()));