aboutsummaryrefslogtreecommitdiff
path: root/src/main/java
diff options
context:
space:
mode:
Diffstat (limited to 'src/main/java')
-rw-r--r--src/main/java/io/github/moulberry/notenoughupdates/ItemPriceInformation.java39
-rw-r--r--src/main/java/io/github/moulberry/notenoughupdates/NEUEventListener.java31
-rw-r--r--src/main/java/io/github/moulberry/notenoughupdates/NEUManager.java2
-rw-r--r--src/main/java/io/github/moulberry/notenoughupdates/auction/CustomAH.java2
-rw-r--r--src/main/java/io/github/moulberry/notenoughupdates/commands/Commands.java9
-rw-r--r--src/main/java/io/github/moulberry/notenoughupdates/dungeons/DungeonMap.java6
-rw-r--r--src/main/java/io/github/moulberry/notenoughupdates/miscfeatures/CustomItemEffects.java4
-rw-r--r--src/main/java/io/github/moulberry/notenoughupdates/miscfeatures/EnchantingSolvers.java22
-rw-r--r--src/main/java/io/github/moulberry/notenoughupdates/miscfeatures/NPCRetexturing.java3
-rw-r--r--src/main/java/io/github/moulberry/notenoughupdates/miscfeatures/PetInfoOverlay.java4
-rw-r--r--src/main/java/io/github/moulberry/notenoughupdates/miscgui/GuiCustomEnchant.java3
-rw-r--r--src/main/java/io/github/moulberry/notenoughupdates/options/NEUConfig.java4
-rw-r--r--src/main/java/io/github/moulberry/notenoughupdates/options/seperateSections/Enchanting.java13
-rw-r--r--src/main/java/io/github/moulberry/notenoughupdates/options/seperateSections/ItemOverlays.java26
-rw-r--r--src/main/java/io/github/moulberry/notenoughupdates/options/seperateSections/Misc.java8
-rw-r--r--src/main/java/io/github/moulberry/notenoughupdates/options/seperateSections/MiscOverlays.java504
-rw-r--r--src/main/java/io/github/moulberry/notenoughupdates/options/seperateSections/SkillOverlays.java9
-rw-r--r--src/main/java/io/github/moulberry/notenoughupdates/options/seperateSections/SlotLocking.java15
-rw-r--r--src/main/java/io/github/moulberry/notenoughupdates/options/seperateSections/TooltipTweaks.java9
-rw-r--r--src/main/java/io/github/moulberry/notenoughupdates/overlays/FarmingOverlay.java99
-rw-r--r--src/main/java/io/github/moulberry/notenoughupdates/overlays/FishingSkillOverlay.java2
-rw-r--r--src/main/java/io/github/moulberry/notenoughupdates/overlays/MiningOverlay.java15
-rw-r--r--src/main/java/io/github/moulberry/notenoughupdates/overlays/TimersOverlay.java26
-rw-r--r--src/main/java/io/github/moulberry/notenoughupdates/profileviewer/GuiProfileViewer.java3
24 files changed, 512 insertions, 346 deletions
diff --git a/src/main/java/io/github/moulberry/notenoughupdates/ItemPriceInformation.java b/src/main/java/io/github/moulberry/notenoughupdates/ItemPriceInformation.java
index 0aa80126..8fbb7c40 100644
--- a/src/main/java/io/github/moulberry/notenoughupdates/ItemPriceInformation.java
+++ b/src/main/java/io/github/moulberry/notenoughupdates/ItemPriceInformation.java
@@ -4,6 +4,7 @@ import com.google.gson.JsonObject;
import io.github.moulberry.notenoughupdates.auction.APIManager;
import io.github.moulberry.notenoughupdates.core.config.KeybindHelper;
import io.github.moulberry.notenoughupdates.util.Constants;
+import io.github.moulberry.notenoughupdates.util.Utils;
import net.minecraft.item.ItemStack;
import net.minecraft.nbt.NBTTagCompound;
import net.minecraft.util.EnumChatFormatting;
@@ -37,6 +38,7 @@ public class ItemPriceInformation {
boolean bazaarItem = bazaarInfo != null;
NumberFormat format = NumberFormat.getInstance(Locale.US);
+ boolean shortNumber = NotEnoughUpdates.INSTANCE.config.tooltipTweaks.shortNumberFormatPrices;
if (bazaarItem) {
List<Integer> lines = NotEnoughUpdates.INSTANCE.config.tooltipTweaks.priceInfoBaz;
@@ -64,7 +66,7 @@ public class ItemPriceInformation {
}
int bazaarBuyPrice = (int) bazaarInfo.get("avg_buy").getAsFloat() * stackMultiplier;
tooltip.add(EnumChatFormatting.YELLOW.toString() + EnumChatFormatting.BOLD + "Bazaar Buy: " +
- EnumChatFormatting.GOLD + EnumChatFormatting.BOLD + format.format(bazaarBuyPrice) + " coins");
+ EnumChatFormatting.GOLD + EnumChatFormatting.BOLD + (shortNumber && bazaarBuyPrice > 1000 ? Utils.shortNumberFormat(bazaarBuyPrice, 0) : format.format(bazaarBuyPrice)) + " coins");
}
break;
case 1:
@@ -77,7 +79,7 @@ public class ItemPriceInformation {
}
int bazaarSellPrice = (int) bazaarInfo.get("avg_sell").getAsFloat() * stackMultiplier;
tooltip.add(EnumChatFormatting.YELLOW.toString() + EnumChatFormatting.BOLD + "Bazaar Sell: " +
- EnumChatFormatting.GOLD + EnumChatFormatting.BOLD + format.format(bazaarSellPrice) + " coins");
+ EnumChatFormatting.GOLD + EnumChatFormatting.BOLD + (shortNumber && bazaarSellPrice > 1000 ? Utils.shortNumberFormat(bazaarSellPrice, 0) : format.format(bazaarSellPrice)) + " coins");
}
break;
case 2:
@@ -90,7 +92,7 @@ public class ItemPriceInformation {
}
int bazaarInstantBuyPrice = (int) bazaarInfo.get("curr_buy").getAsFloat() * stackMultiplier;
tooltip.add(EnumChatFormatting.YELLOW.toString() + EnumChatFormatting.BOLD + "Bazaar Insta-Buy: " +
- EnumChatFormatting.GOLD + EnumChatFormatting.BOLD + format.format(bazaarInstantBuyPrice) + " coins");
+ EnumChatFormatting.GOLD + EnumChatFormatting.BOLD + (shortNumber && bazaarInstantBuyPrice > 1000 ? Utils.shortNumberFormat(bazaarInstantBuyPrice, 0) : format.format(bazaarInstantBuyPrice)) + " coins");
}
break;
case 3:
@@ -103,7 +105,7 @@ public class ItemPriceInformation {
}
int bazaarInstantSellPrice = (int) bazaarInfo.get("curr_sell").getAsFloat() * stackMultiplier;
tooltip.add(EnumChatFormatting.YELLOW.toString() + EnumChatFormatting.BOLD + "Bazaar Insta-Sell: " +
- EnumChatFormatting.GOLD + EnumChatFormatting.BOLD + format.format(bazaarInstantSellPrice) + " coins");
+ EnumChatFormatting.GOLD + EnumChatFormatting.BOLD + (shortNumber && bazaarInstantSellPrice > 1000 ? Utils.shortNumberFormat(bazaarInstantSellPrice, 0) : format.format(bazaarInstantSellPrice)) + " coins");
}
break;
case 4:
@@ -115,8 +117,8 @@ public class ItemPriceInformation {
tooltip.add("");
added = true;
}
- tooltip.add(EnumChatFormatting.YELLOW.toString() + EnumChatFormatting.BOLD + "Raw Craft Cost: " +
- EnumChatFormatting.GOLD + EnumChatFormatting.BOLD + format.format((int) craftCost.craftCost) + " coins");
+ tooltip.add(EnumChatFormatting.YELLOW.toString() + EnumChatFormatting.BOLD + "Raw Craft Cost: " + EnumChatFormatting.GOLD + EnumChatFormatting.BOLD +
+ (shortNumber && craftCost.craftCost > 1000 ? Utils.shortNumberFormat(craftCost.craftCost, 0) : format.format((int) craftCost.craftCost)) + " coins");
}
break;
}
@@ -137,7 +139,7 @@ public class ItemPriceInformation {
added = true;
}
tooltip.add(EnumChatFormatting.YELLOW.toString() + EnumChatFormatting.BOLD + "Lowest BIN: " +
- EnumChatFormatting.GOLD + EnumChatFormatting.BOLD + format.format(lowestBin) + " coins");
+ EnumChatFormatting.GOLD + EnumChatFormatting.BOLD + (shortNumber && lowestBin > 1000 ? Utils.shortNumberFormat(lowestBin, 0) : format.format(lowestBin)) + " coins");
}
break;
case 1:
@@ -148,13 +150,13 @@ public class ItemPriceInformation {
}
if (auctionInfo.has("clean_price")) {
- tooltip.add(EnumChatFormatting.YELLOW.toString() + EnumChatFormatting.BOLD + "AH Price (Clean): " + EnumChatFormatting.GOLD +
- EnumChatFormatting.BOLD +
- format.format((int) auctionInfo.get("clean_price").getAsFloat()) + " coins");
+ tooltip.add(EnumChatFormatting.YELLOW.toString() + EnumChatFormatting.BOLD + "AH Price (Clean): " + EnumChatFormatting.GOLD + EnumChatFormatting.BOLD +
+ (shortNumber && auctionInfo.get("clean_price").getAsFloat() > 1000 ? Utils.shortNumberFormat(auctionInfo.get("clean_price").getAsFloat(), 0) : format.format((int) auctionInfo.get("clean_price").getAsFloat())
+ + " coins"));
} else {
int auctionPrice = (int) (auctionInfo.get("price").getAsFloat() / auctionInfo.get("count").getAsFloat());
- tooltip.add(EnumChatFormatting.YELLOW.toString() + EnumChatFormatting.BOLD + "AH Price: " + EnumChatFormatting.GOLD +
- EnumChatFormatting.BOLD + format.format(auctionPrice) + " coins");
+ tooltip.add(EnumChatFormatting.YELLOW.toString() + EnumChatFormatting.BOLD + "AH Price: " + EnumChatFormatting.GOLD + EnumChatFormatting.BOLD +
+ (shortNumber && auctionPrice > 1000 ? Utils.shortNumberFormat(auctionPrice, 0) : format.format(auctionPrice)) + " coins");
}
}
@@ -168,11 +170,13 @@ public class ItemPriceInformation {
if (auctionInfo.has("clean_price")) {
tooltip.add(EnumChatFormatting.YELLOW.toString() + EnumChatFormatting.BOLD + "AH Sales (Clean): " +
EnumChatFormatting.GOLD + EnumChatFormatting.BOLD +
- format.format(auctionInfo.get("clean_sales").getAsFloat()) + " sales/day");
+ (auctionInfo.get("clean_sales").getAsFloat() < 2 ? format.format(auctionInfo.get("clean_sales").getAsFloat()) + " sale/day"
+ : format.format(auctionInfo.get("clean_sales").getAsFloat()) + " sales/day"));
} else {
tooltip.add(EnumChatFormatting.YELLOW.toString() + EnumChatFormatting.BOLD + "AH Sales: " +
EnumChatFormatting.GOLD + EnumChatFormatting.BOLD +
- format.format(auctionInfo.get("sales").getAsFloat()) + " sales/day");
+ (auctionInfo.get("sales").getAsFloat() < 2 ? format.format(auctionInfo.get("sales").getAsFloat()) + " sale/day"
+ : format.format(auctionInfo.get("sales").getAsFloat()) + " sales/day"));
}
}
break;
@@ -185,8 +189,8 @@ public class ItemPriceInformation {
tooltip.add("");
added = true;
}
- tooltip.add(EnumChatFormatting.YELLOW.toString() + EnumChatFormatting.BOLD + "Raw Craft Cost: " +
- EnumChatFormatting.GOLD + EnumChatFormatting.BOLD + format.format((int) craftCost.craftCost) + " coins");
+ tooltip.add(EnumChatFormatting.YELLOW.toString() + EnumChatFormatting.BOLD + "Raw Craft Cost: " + EnumChatFormatting.GOLD + EnumChatFormatting.BOLD +
+ (shortNumber && craftCost.craftCost > 1000 ? Utils.shortNumberFormat(craftCost.craftCost, 0) : format.format((int) craftCost.craftCost)) + " coins");
}
break;
case 4:
@@ -196,7 +200,8 @@ public class ItemPriceInformation {
added = true;
}
tooltip.add(EnumChatFormatting.YELLOW.toString() + EnumChatFormatting.BOLD + "AVG Lowest BIN: " +
- EnumChatFormatting.GOLD + EnumChatFormatting.BOLD + format.format(lowestBinAvg) + " coins");
+ EnumChatFormatting.GOLD + EnumChatFormatting.BOLD +
+ (shortNumber && lowestBinAvg > 1000 ? Utils.shortNumberFormat(lowestBinAvg, 0) : format.format(lowestBinAvg)) + " coins");
}
break;
case 5:
diff --git a/src/main/java/io/github/moulberry/notenoughupdates/NEUEventListener.java b/src/main/java/io/github/moulberry/notenoughupdates/NEUEventListener.java
index aca9a8c5..6ba3c244 100644
--- a/src/main/java/io/github/moulberry/notenoughupdates/NEUEventListener.java
+++ b/src/main/java/io/github/moulberry/notenoughupdates/NEUEventListener.java
@@ -838,6 +838,7 @@ public class NEUEventListener {
NotEnoughUpdates.INSTANCE.config.apiKey.apiKey = unformatted.substring("Your new API key is ".length());
Minecraft.getMinecraft().thePlayer.addChatMessage(new ChatComponentText(EnumChatFormatting.YELLOW +
"[NEU] API Key automatically configured"));
+ NotEnoughUpdates.INSTANCE.config.apiKey.apiKey = NotEnoughUpdates.INSTANCE.config.apiKey.apiKey.substring(0, 36);
}
if (e.message.getFormattedText().equals(EnumChatFormatting.RESET.toString() +
EnumChatFormatting.RED + "You haven't unlocked this recipe!" + EnumChatFormatting.RESET)) {
@@ -2005,23 +2006,25 @@ public class NEUEventListener {
missing.add(enchId);
}
}
- newTooltip.add("");
- StringBuilder currentLine = new StringBuilder(EnumChatFormatting.RED + "Missing: " + EnumChatFormatting.GRAY);
- for (int i = 0; i < missing.size(); i++) {
- String enchName = WordUtils.capitalizeFully(missing.get(i).replace("_", " "));
- if (currentLine.length() != 0 && (Utils.cleanColour(currentLine.toString()).length() + enchName.length()) > 40) {
- newTooltip.add(currentLine.toString());
- currentLine = new StringBuilder();
+ if (!missing.isEmpty()) {
+ newTooltip.add("");
+ StringBuilder currentLine = new StringBuilder(EnumChatFormatting.RED + "Missing: " + EnumChatFormatting.GRAY);
+ for (int i = 0; i < missing.size(); i++) {
+ String enchName = WordUtils.capitalizeFully(missing.get(i).replace("_", " "));
+ if (currentLine.length() != 0 && (Utils.cleanColour(currentLine.toString()).length() + enchName.length()) > 40) {
+ newTooltip.add(currentLine.toString());
+ currentLine = new StringBuilder();
+ }
+ if (currentLine.length() != 0 && i != 0) {
+ currentLine.append(", ").append(enchName);
+ } else {
+ currentLine.append(EnumChatFormatting.GRAY).append(enchName);
+ }
}
- if (currentLine.length() != 0 && i != 0) {
- currentLine.append(", ").append(enchName);
- } else {
- currentLine.append(EnumChatFormatting.GRAY).append(enchName);
+ if (currentLine.length() != 0) {
+ newTooltip.add(currentLine.toString());
}
}
- if (currentLine.length() != 0) {
- newTooltip.add(currentLine.toString());
- }
}
passedEnchants = true;
}
diff --git a/src/main/java/io/github/moulberry/notenoughupdates/NEUManager.java b/src/main/java/io/github/moulberry/notenoughupdates/NEUManager.java
index 59332f23..f9c5b01b 100644
--- a/src/main/java/io/github/moulberry/notenoughupdates/NEUManager.java
+++ b/src/main/java/io/github/moulberry/notenoughupdates/NEUManager.java
@@ -1219,7 +1219,7 @@ public class NEUManager {
HashMap<String, String> replacements = new HashMap<>();
if (level < 1) {
- if (Constants.PETS.has("custom_pet_leveling") && Constants.PETS.getAsJsonObject("custom_pet_leveling").has(petname) && Constants.PETS.getAsJsonObject("custom_pet_leveling").getAsJsonObject(petname).has("max_level")) {
+ if (Constants.PETS != null && Constants.PETS.has("custom_pet_leveling") && Constants.PETS.getAsJsonObject("custom_pet_leveling").has(petname) && Constants.PETS.getAsJsonObject("custom_pet_leveling").getAsJsonObject(petname).has("max_level")) {
int maxLvl = Constants.PETS.getAsJsonObject("custom_pet_leveling").getAsJsonObject(petname).get("max_level").getAsInt();
replacements.put("LVL", "1\u27A1" + maxLvl);
} else {
diff --git a/src/main/java/io/github/moulberry/notenoughupdates/auction/CustomAH.java b/src/main/java/io/github/moulberry/notenoughupdates/auction/CustomAH.java
index 75af7de1..a408100d 100644
--- a/src/main/java/io/github/moulberry/notenoughupdates/auction/CustomAH.java
+++ b/src/main/java/io/github/moulberry/notenoughupdates/auction/CustomAH.java
@@ -915,7 +915,7 @@ public class CustomAH extends Gui {
256 - (scrollClicked ? 12 : 24), 0, 12, 15);
if (!NotEnoughUpdates.INSTANCE.config.neuAuctionHouse.enableNeuAuctionHouse) {
- Utils.drawStringCentered(EnumChatFormatting.RED + "NEUAH is DISABLED! Enable in /neusettings.",
+ Utils.drawStringCentered(EnumChatFormatting.RED + "NEUAH is DISABLED! Enable in /neu.",
Minecraft.getMinecraft().fontRendererObj, guiLeft + getXSize() / 2, guiTop + getYSize() / 2 - 5, true, 0);
}
diff --git a/src/main/java/io/github/moulberry/notenoughupdates/commands/Commands.java b/src/main/java/io/github/moulberry/notenoughupdates/commands/Commands.java
index 591d7053..7d1ef905 100644
--- a/src/main/java/io/github/moulberry/notenoughupdates/commands/Commands.java
+++ b/src/main/java/io/github/moulberry/notenoughupdates/commands/Commands.java
@@ -95,6 +95,7 @@ public class Commands {
ClientCommandHandler.instance.registerCommand(new FairySouls.FairySoulsCommandAlt());
ClientCommandHandler.instance.registerCommand(neuHelp);
ClientCommandHandler.instance.registerCommand(neuFeatures);
+ ClientCommandHandler.instance.registerCommand(neuRepoMode);
}
SimpleCommand.ProcessCommandRunnable collectionLogRun = new SimpleCommand.ProcessCommandRunnable() {
@@ -336,6 +337,14 @@ public class Commands {
}
});
+ SimpleCommand neuRepoMode = new SimpleCommand("neurepomode", new SimpleCommand.ProcessCommandRunnable() {
+ public void processCommand(ICommandSender sender, String[] args) {
+ NotEnoughUpdates.INSTANCE.config.hidden.dev = !NotEnoughUpdates.INSTANCE.config.hidden.dev;
+ NotEnoughUpdates.INSTANCE.config.hidden.enableItemEditing = !NotEnoughUpdates.INSTANCE.config.hidden.enableItemEditing;
+ Minecraft.getMinecraft().thePlayer.addChatMessage(new ChatComponentText("\u00a75Toggled NEU repo dev mode."));
+ }
+ });
+
SimpleCommand dungeonWinTest = new SimpleCommand("neudungeonwintest", new SimpleCommand.ProcessCommandRunnable() {
public void processCommand(ICommandSender sender, String[] args) {
if (args.length > 0) {
diff --git a/src/main/java/io/github/moulberry/notenoughupdates/dungeons/DungeonMap.java b/src/main/java/io/github/moulberry/notenoughupdates/dungeons/DungeonMap.java
index 6f42ab10..c3dc3244 100644
--- a/src/main/java/io/github/moulberry/notenoughupdates/dungeons/DungeonMap.java
+++ b/src/main/java/io/github/moulberry/notenoughupdates/dungeons/DungeonMap.java
@@ -507,7 +507,7 @@ public class DungeonMap {
GlStateManager.translate(centerX - mapSizeX / 2, centerY - mapSizeY / 2, 100);
}
- if (NotEnoughUpdates.INSTANCE.config.dungeonMap.dmBackgroundBlur > 0.1) {
+ if (NotEnoughUpdates.INSTANCE.config.dungeonMap.dmBackgroundBlur > 0.1 && NotEnoughUpdates.INSTANCE.config.dungeonMap.dmBackgroundBlur < 100 && NotEnoughUpdates.INSTANCE.config.dungeonMap.dmEnable) {
GlStateManager.translate(-centerX + mapSizeX / 2, -centerY + mapSizeY / 2, 0);
BackgroundBlur.renderBlurredBackground(NotEnoughUpdates.INSTANCE.config.dungeonMap.dmBackgroundBlur,
scaledResolution.getScaledWidth(), scaledResolution.getScaledHeight(),
@@ -518,7 +518,7 @@ public class DungeonMap {
GlStateManager.translate(mapCenterX, mapCenterY, 10);
- if (!useFb || NotEnoughUpdates.INSTANCE.config.dungeonMap.dmBackgroundBlur > 0.1) {
+ if (!useFb || NotEnoughUpdates.INSTANCE.config.dungeonMap.dmBackgroundBlur > 0.1 && NotEnoughUpdates.INSTANCE.config.dungeonMap.dmBackgroundBlur < 100) {
GlStateManager.enableBlend();
GL14.glBlendFuncSeparate(GL11.GL_SRC_ALPHA, GL11.GL_ONE_MINUS_SRC_ALPHA, GL11.GL_ONE, GL11.GL_ONE_MINUS_SRC_ALPHA);
}
@@ -1050,7 +1050,7 @@ public class DungeonMap {
String line = ScorePlayerTeam.formatPlayerName(scoreplayerteam1, score.getPlayerName());
line = Utils.cleanColour(line);
- if (line.contains("(F1)") || line.contains("(E)") || line.contains("(M1)")) {
+ if (line.contains("(F1)") || line.contains("(E0)") || line.contains("(M1)")) {
isFloorOne = true;
break;
}
diff --git a/src/main/java/io/github/moulberry/notenoughupdates/miscfeatures/CustomItemEffects.java b/src/main/java/io/github/moulberry/notenoughupdates/miscfeatures/CustomItemEffects.java
index 34b444c6..78777538 100644
--- a/src/main/java/io/github/moulberry/notenoughupdates/miscfeatures/CustomItemEffects.java
+++ b/src/main/java/io/github/moulberry/notenoughupdates/miscfeatures/CustomItemEffects.java
@@ -784,7 +784,7 @@ public class CustomItemEffects {
}
}
}
- } else if (heldInternal.equals("INFINIDIRT_WAND") && event.target.typeOfHit == MovingObjectPosition.MovingObjectType.BLOCK) {
+ } else if (heldInternal.equals("INFINIDIRT_WAND") && event.target.typeOfHit == MovingObjectPosition.MovingObjectType.BLOCK && NotEnoughUpdates.INSTANCE.config.itemOverlays.enableDirtWandOverlay) {
BlockPos hover = event.target.getBlockPos().offset(event.target.sideHit, 1);
IBlockState hoverState = Minecraft.getMinecraft().theWorld.getBlockState(event.target.getBlockPos().offset(event.target.sideHit, 1));
if (hoverState.getBlock() == Blocks.air) {
@@ -889,7 +889,7 @@ public class CustomItemEffects {
GlStateManager.depthMask(true);
GlStateManager.enableTexture2D();
GlStateManager.disableBlend();
- } else if ((heldInternal.equals("HOE_OF_GREAT_TILLING") || heldInternal.equals("HOE_OF_GREATER_TILLING") && onPrivateIsland) &&
+ } else if ((heldInternal.equals("HOE_OF_GREAT_TILLING") || heldInternal.equals("HOE_OF_GREATER_TILLING") && NotEnoughUpdates.INSTANCE.config.itemOverlays.enableHoeOverlay && onPrivateIsland) &&
event.target.typeOfHit == MovingObjectPosition.MovingObjectType.BLOCK) {
BlockPos target = event.target.getBlockPos();
IBlockState targetState = Minecraft.getMinecraft().theWorld.getBlockState(target);
diff --git a/src/main/java/io/github/moulberry/notenoughupdates/miscfeatures/EnchantingSolvers.java b/src/main/java/io/github/moulberry/notenoughupdates/miscfeatures/EnchantingSolvers.java
index 6e7dfc20..15eb7102 100644
--- a/src/main/java/io/github/moulberry/notenoughupdates/miscfeatures/EnchantingSolvers.java
+++ b/src/main/java/io/github/moulberry/notenoughupdates/miscfeatures/EnchantingSolvers.java
@@ -32,7 +32,6 @@ public class EnchantingSolvers {
}
private static final NBTTagCompound enchTag = new NBTTagCompound();
-
static {
enchTag.setTag("ench", new NBTTagList());
}
@@ -143,7 +142,7 @@ public class EnchantingSolvers {
return retStack;
}
} else {
- if (chronomatronReplayIndex + 1 < chronomatronOrder.size()) {
+ if (chronomatronReplayIndex + 1 < chronomatronOrder.size() && NotEnoughUpdates.INSTANCE.config.enchantingSolvers.showNextClick) {
String chronomatronNext = chronomatronOrder.get(chronomatronReplayIndex + 1);
if (chronomatronNext.equals(displayName)) {
ItemStack retStack = new ItemStack(Item.getItemFromBlock(Blocks.stained_glass), 1, stack.getItemDamage());
@@ -309,19 +308,19 @@ public class EnchantingSolvers {
if (chronomatronReplayIndex < chronomatronOrder.size()) {
String chronomatronCurrent = chronomatronOrder.get(chronomatronReplayIndex);
- /*if(!NotEnoughUpdates.INSTANCE.config.enchantingSolvers.preventMisclicks ||
+ if(!NotEnoughUpdates.INSTANCE.config.enchantingSolvers.preventMisclicks1 ||
chronomatronCurrent.equals(displayName)) {
chronomatronReplayIndex++;
Minecraft.getMinecraft().playerController.windowClick(windowId, slotId,
2, mode, Minecraft.getMinecraft().thePlayer);
millisLastClick = currentTime;
- }*/
- if (chronomatronCurrent.equals(displayName)) {
+ }
+ /*if (chronomatronCurrent.equals(displayName)) {
chronomatronReplayIndex++;
}
Minecraft.getMinecraft().playerController.windowClick(windowId, slotId,
2, mode, Minecraft.getMinecraft().thePlayer);
- millisLastClick = currentTime;
+ millisLastClick = currentTime;*/
}
return true;
}
@@ -338,22 +337,22 @@ public class EnchantingSolvers {
return true;
}
long currentTime = System.currentTimeMillis();
- /*if(currentTime - millisLastClick > 150 &&
- (!NotEnoughUpdates.INSTANCE.config.enchantingSolvers.preventMisclicks ||
+ if(currentTime - millisLastClick > 150 &&
+ (!NotEnoughUpdates.INSTANCE.config.enchantingSolvers.preventMisclicks1 ||
current.containerIndex == slotId)) {
ultrasequencerReplayIndex++;
Minecraft.getMinecraft().playerController.windowClick(windowId, slotId,
2, mode, Minecraft.getMinecraft().thePlayer);
millisLastClick = currentTime;
- }*/
- if (currentTime - millisLastClick > 150) {
+ }
+ /*if (currentTime - millisLastClick > 150) {
if (current.containerIndex == slotId) {
ultrasequencerReplayIndex++;
}
Minecraft.getMinecraft().playerController.windowClick(windowId, slotId,
2, mode, Minecraft.getMinecraft().thePlayer);
millisLastClick = currentTime;
- }
+ }*/
return true;
} else {
return true;
@@ -528,6 +527,7 @@ public class EnchantingSolvers {
}
}
+
@SubscribeEvent
public void onItemTooltip(ItemTooltipEvent event) {
if (NotEnoughUpdates.INSTANCE.config.enchantingSolvers.hideTooltips &&
diff --git a/src/main/java/io/github/moulberry/notenoughupdates/miscfeatures/NPCRetexturing.java b/src/main/java/io/github/moulberry/notenoughupdates/miscfeatures/NPCRetexturing.java
index e234c458..9180cca6 100644
--- a/src/main/java/io/github/moulberry/notenoughupdates/miscfeatures/NPCRetexturing.java
+++ b/src/main/java/io/github/moulberry/notenoughupdates/miscfeatures/NPCRetexturing.java
@@ -4,6 +4,7 @@ import com.google.gson.Gson;
import com.google.gson.GsonBuilder;
import com.google.gson.JsonElement;
import com.google.gson.JsonObject;
+import io.github.moulberry.notenoughupdates.NotEnoughUpdates;
import net.minecraft.client.Minecraft;
import net.minecraft.client.entity.AbstractClientPlayer;
import net.minecraft.client.resources.IResourceManager;
@@ -52,7 +53,7 @@ public class NPCRetexturing implements IResourceManagerReloadListener {
ResourceLocation loc = player.getLocationSkin();
gettingSkin = false;
- if (skinMap.containsKey(loc.getResourcePath())) {
+ if (skinMap.containsKey(loc.getResourcePath()) && !NotEnoughUpdates.INSTANCE.config.misc.disableNPCRetexturing) {
Skin skin = skinMap.get(loc.getResourcePath());
skinOverrideCache.put(player, skin);
return skin;
diff --git a/src/main/java/io/github/moulberry/notenoughupdates/miscfeatures/PetInfoOverlay.java b/src/main/java/io/github/moulberry/notenoughupdates/miscfeatures/PetInfoOverlay.java
index fc5fdef8..0415c629 100644
--- a/src/main/java/io/github/moulberry/notenoughupdates/miscfeatures/PetInfoOverlay.java
+++ b/src/main/java/io/github/moulberry/notenoughupdates/miscfeatures/PetInfoOverlay.java
@@ -759,13 +759,13 @@ public class PetInfoOverlay extends TextOverlay {
if (currentTime - lastPetSelect > 500) {
boolean foundDespawn = false;
for (String line : lore) {
- if (line.equals("\u00a77\u00a7cClick to despawn ")) {
+ if (line.equals("\u00a77\u00a7cClick to despawn.")) {
config.selectedPet = petIndex;
foundDespawn = true;
break;
}
}
- if (foundDespawn && config.selectedPet == petIndex) {
+ if (!foundDespawn && config.selectedPet == petIndex && currentTime - lastPetSelect > 500) {
clearPet();
}
}
diff --git a/src/main/java/io/github/moulberry/notenoughupdates/miscgui/GuiCustomEnchant.java b/src/main/java/io/github/moulberry/notenoughupdates/miscgui/GuiCustomEnchant.java
index 2b92a86c..218076a5 100644
--- a/