aboutsummaryrefslogtreecommitdiff
path: root/src/main/java
diff options
context:
space:
mode:
authorWalker Selby <git@walkerselby.com>2022-10-21 13:25:11 -0700
committerGitHub <noreply@github.com>2022-10-21 15:25:11 -0500
commite4d4a7c4179d2359dcdadcc49b38470c9db873e3 (patch)
tree6d5756eb215fd55cd685b79d3db8d5d15225a7f8 /src/main/java
parent2f57d3891a25630a41323c029bbe0b0a87d2fd33 (diff)
downloadNotEnoughUpdates-e4d4a7c4179d2359dcdadcc49b38470c9db873e3.tar.gz
NotEnoughUpdates-e4d4a7c4179d2359dcdadcc49b38470c9db873e3.tar.bz2
NotEnoughUpdates-e4d4a7c4179d2359dcdadcc49b38470c9db873e3.zip
Code Cleanup (#333)
* Remove NeuConfigTutorial.java * Remove NeuTutorial.java * Remove TutorialBase.java * Remove NEU Tutorial Command Initialization from Commands.java * Remove commented-out filter defaults Remove commented-out and replaced rarities String array Remove commented out code for old rendering Invert if statement due to empty if body and used else body * Remove commented-out render Remove commented out divine mentions Remove duplicate additions of Divine rarity * Remove ButtonsCommand.java - Unused, empty, and uninitialized * Remove excessive commented out code of old /neurename * Remove usused initialization Removed old debug console prints * Remove commented out removed options * Remove commented and unused String List Remove commented and unused size settings * Remove unused commented out code * Remove unused commented out code * Remove unused commented code
Diffstat (limited to 'src/main/java')
-rw-r--r--src/main/java/io/github/moulberry/notenoughupdates/auction/CustomAH.java16
-rw-r--r--src/main/java/io/github/moulberry/notenoughupdates/commands/Commands.java1
-rw-r--r--src/main/java/io/github/moulberry/notenoughupdates/commands/misc/ButtonsCommand.java35
-rw-r--r--src/main/java/io/github/moulberry/notenoughupdates/commands/misc/CustomizeCommand.java85
-rw-r--r--src/main/java/io/github/moulberry/notenoughupdates/dungeons/DungeonMap.java5
-rw-r--r--src/main/java/io/github/moulberry/notenoughupdates/dungeons/GuiDungeonMapEditor.java13
-rw-r--r--src/main/java/io/github/moulberry/notenoughupdates/infopanes/DevInfoPane.java159
-rw-r--r--src/main/java/io/github/moulberry/notenoughupdates/itemeditor/GuiElementTextField.java2
-rw-r--r--src/main/java/io/github/moulberry/notenoughupdates/listener/ChatListener.java1
-rw-r--r--src/main/java/io/github/moulberry/notenoughupdates/miscgui/tutorials/NeuConfigTutorial.java26
-rw-r--r--src/main/java/io/github/moulberry/notenoughupdates/miscgui/tutorials/NeuTutorial.java168
-rw-r--r--src/main/java/io/github/moulberry/notenoughupdates/miscgui/tutorials/TutorialBase.java399
-rw-r--r--src/main/java/io/github/moulberry/notenoughupdates/util/Utils.java5
13 files changed, 2 insertions, 913 deletions
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 7b4542d0..07ec4a59 100644
--- a/src/main/java/io/github/moulberry/notenoughupdates/auction/CustomAH.java
+++ b/src/main/java/io/github/moulberry/notenoughupdates/auction/CustomAH.java
@@ -190,8 +190,6 @@ public class CustomAH extends Gui {
private static final int SORT_MODE_LOW = 1;
private static final int SORT_MODE_SOON = 2;
- // private static final String[] rarities = {"COMMON", "UNCOMMON", "RARE", "EPIC",
-// "LEGENDARY", "MYTHIC", "SPECIAL", "VERY SPECIAL", "SUPREME", "DIVINE"};
private static final String[] rarityColours = {
"" + EnumChatFormatting.WHITE,
"" + EnumChatFormatting.GREEN, "" + EnumChatFormatting.BLUE, "" + EnumChatFormatting.DARK_PURPLE,
@@ -264,10 +262,8 @@ public class CustomAH extends Gui {
if (searchField == null || priceField == null) init();
if (System.currentTimeMillis() - lastOpen < 1000) Mouse.setGrabbed(false);
- //sortMode = SORT_MODE_HIGH;
rarityFilter = -1;
filterMyAuctions = false;
- //binFilter = BIN_FILTER_ALL;
enchFilter = ENCH_FILTER_ALL;
dungeonFilter = DUNGEON_FILTER_ALL;
@@ -995,14 +991,6 @@ public class CustomAH extends Gui {
searchField.drawTextBox();
GlStateManager.color(1.0F, 1.0F, 1.0F, 1.0F);
- /*if(auctionIds.size() == 0 && searchField.getText().length() == 0) {
- drawRect(guiLeft+8, guiTop+17, guiLeft+170, guiTop+107+18*splits,
- new Color(100, 100, 100, 100).getRGB());
-
- FontRenderer fr = Minecraft.getMinecraft().fontRendererObj;
- int strWidth = fr.getStringWidth("Loading items...");
- fr.drawString("Loading items...", guiLeft+(8+170-strWidth)/2, guiTop+(17+107+18*splits)/2, Color.BLACK.getRGB());
- }*/
Minecraft.getMinecraft().getTextureManager().bindTexture(creativeInventoryTabs);
GlStateManager.color(1.0F, 1.0F, 1.0F, 1.0F);
@@ -1409,9 +1397,7 @@ public class CustomAH extends Gui {
for (String internalname : itemMatches) {
for (String aucid : manager.auctionManager.getAuctionsForInternalname(internalname)) {
APIManager.Auction auc = manager.auctionManager.getAuctionItems().get(aucid);
- if (doesAucMatch(auc)) {
- //matches.add(aucid);
- } else {
+ if (!doesAucMatch(auc)) {
dontMatch.add(aucid);
}
}
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 62981a30..91365cd1 100644
--- a/src/main/java/io/github/moulberry/notenoughupdates/commands/Commands.java
+++ b/src/main/java/io/github/moulberry/notenoughupdates/commands/Commands.java
@@ -95,7 +95,6 @@ public class Commands {
ClientCommandHandler.instance.registerCommand(new ScreenCommand("neubuttons", GuiInvButtonEditor::new));
ClientCommandHandler.instance.registerCommand(new ScreenCommand("neuec", GuiEnchantColour::new));
ClientCommandHandler.instance.registerCommand(new ScreenCommand("neuoverlay", NEUOverlayPlacements::new));
- //ClientCommandHandler.instance.registerCommand(new ScreenCommand("neututorial", NeuTutorial::new));
ClientCommandHandler.instance.registerCommand(new AhCommand());
ClientCommandHandler.instance.registerCommand(new CalculatorCommand());
ClientCommandHandler.instance.registerCommand(new CalendarCommand());
diff --git a/src/main/java/io/github/moulberry/notenoughupdates/commands/misc/ButtonsCommand.java b/src/main/java/io/github/moulberry/notenoughupdates/commands/misc/ButtonsCommand.java
deleted file mode 100644
index 55113462..00000000
--- a/src/main/java/io/github/moulberry/notenoughupdates/commands/misc/ButtonsCommand.java
+++ /dev/null
@@ -1,35 +0,0 @@
-/*
- * Copyright (C) 2022 NotEnoughUpdates contributors
- *
- * This file is part of NotEnoughUpdates.
- *
- * NotEnoughUpdates is free software: you can redistribute it
- * and/or modify it under the terms of the GNU Lesser General Public
- * License as published by the Free Software Foundation, either
- * version 3 of the License, or (at your option) any later version.
- *
- * NotEnoughUpdates is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public License
- * along with NotEnoughUpdates. If not, see <https://www.gnu.org/licenses/>.
- */
-
-package io.github.moulberry.notenoughupdates.commands.misc;
-
-import io.github.moulberry.notenoughupdates.commands.ClientCommandBase;
-import net.minecraft.command.CommandException;
-import net.minecraft.command.ICommandSender;
-
-public class ButtonsCommand extends ClientCommandBase {
- protected ButtonsCommand(String name) {
- super(name);
- }
-
- @Override
- public void processCommand(ICommandSender sender, String[] args) throws CommandException {
-
- }
-}
diff --git a/src/main/java/io/github/moulberry/notenoughupdates/commands/misc/CustomizeCommand.java b/src/main/java/io/github/moulberry/notenoughupdates/commands/misc/CustomizeCommand.java
index 2b184fa0..28c2893d 100644
--- a/src/main/java/io/github/moulberry/notenoughupdates/commands/misc/CustomizeCommand.java
+++ b/src/main/java/io/github/moulberry/notenoughupdates/commands/misc/CustomizeCommand.java
@@ -60,89 +60,4 @@ public class CustomizeCommand extends ClientCommandBase {
NotEnoughUpdates.INSTANCE.openGui = new GuiItemCustomize(held, heldUUID);
}
-
- /*SimpleCommand itemRenameCommand = new SimpleCommand("neurename", new SimpleCommand.ProcessCommandRunnable() {
- public void processCommand(ICommandSender sender, String[] args) {
- if (args.length == 0) {
- args = new String[]{"help"};
- }
- String heldUUID = NotEnoughUpdates.INSTANCE.manager.getUUIDForItem(Minecraft.getMinecraft().thePlayer.getHeldItem());
- switch (args[0].toLowerCase()) {
- case "clearall":
- NotEnoughUpdates.INSTANCE.manager.itemRenameJson = new JsonObject();
- NotEnoughUpdates.INSTANCE.manager.saveItemRenameConfig();
- sender.addChatMessage(new ChatComponentText(EnumChatFormatting.GREEN + "[NEU] Cleared custom name for all items"));
- break;
- case "clear":
- if (heldUUID == null) {
- sender.addChatMessage(new ChatComponentText(EnumChatFormatting.RED + "[NEU] Can't clear rename - no UUID"));
- return;
- }
- NotEnoughUpdates.INSTANCE.manager.itemRenameJson.remove(heldUUID);
- NotEnoughUpdates.INSTANCE.manager.saveItemRenameConfig();
- sender.addChatMessage(new ChatComponentText(EnumChatFormatting.GREEN + "[NEU] Cleared custom name for held item"));
- break;
- case "copyuuid":
- if (heldUUID == null) {
- sender.addChatMessage(new ChatComponentText(EnumChatFormatting.RED + "[NEU] Can't clear rename - no UUID"));
- return;
- }
- StringSelection selection = new StringSelection(heldUUID);
- Toolkit.getDefaultToolkit().getSystemClipboard().setContents(selection, selection);
- sender.addChatMessage(new ChatComponentText(EnumChatFormatting.GREEN + "[NEU] UUID copied to clipboard"));
- break;
- case "uuid":
- if (heldUUID == null) {
- sender.addChatMessage(new ChatComponentText(EnumChatFormatting.RED + "[NEU] Can't get UUID - no UUID"));
- return;
- }
- ChatStyle style = new ChatStyle();
- style.setChatHoverEvent(new HoverEvent(HoverEvent.Action.SHOW_TEXT,
- new ChatComponentText(EnumChatFormatting.GRAY + "Click to copy to clipboard")));
- style.setChatClickEvent(new ClickEvent(ClickEvent.Action.RUN_COMMAND, "/neurename copyuuid"));
-
- ChatComponentText text = new ChatComponentText(EnumChatFormatting.YELLOW + "[NEU] The UUID of your currently held item is: " +
- EnumChatFormatting.GREEN + heldUUID);
- text.setChatStyle(style);
- sender.addChatMessage(text);
- break;
- case "set":
- if (heldUUID == null) {
- sender.addChatMessage(new ChatComponentText(EnumChatFormatting.RED + "[NEU] Can't rename item - no UUID"));
- return;
- }
- if (args.length == 1) {
- sender.addChatMessage(new ChatComponentText(EnumChatFormatting.RED + "[NEU] Usage: /neurename set [name...]"));
- return;
- }
- StringBuilder sb = new StringBuilder();
- for (int i = 1; i < args.length; i++) {
- sb.append(args[i]);
- if (i < args.length - 1) sb.append(" ");
- }
- String name = sb.toString()
- .replace("\\&", "{amp}")
- .replace("&", "\u00a7")
- .replace("{amp}", "&");
- name = new UnicodeUnescaper().translate(name);
- NotEnoughUpdates.INSTANCE.manager.itemRenameJson.addProperty(heldUUID, name);
- NotEnoughUpdates.INSTANCE.manager.saveItemRenameConfig();
- sender.addChatMessage(new ChatComponentText(EnumChatFormatting.GREEN + "[NEU] Set custom name for held item"));
- break;
- default:
- sender.addChatMessage(new ChatComponentText(EnumChatFormatting.RED + "[NEU] Unknown subcommand \"" + args[0] + "\""));
- case "help":
- sender.addChatMessage(new ChatComponentText(EnumChatFormatting.YELLOW + "[NEU] Available commands:"));
- sender.addChatMessage(new ChatComponentText(EnumChatFormatting.YELLOW + "help: Print this message"));
- sender.addChatMessage(new ChatComponentText(EnumChatFormatting.YELLOW + "clearall: Clears all custom names "
- + EnumChatFormatting.BOLD + "(Cannot be undone)"));
- sender.addChatMessage(new ChatComponentText(EnumChatFormatting.YELLOW + "clear: Clears held item name "
- + EnumChatFormatting.BOLD + "(Cannot be undone)"));
- sender.addChatMessage(new ChatComponentText(EnumChatFormatting.YELLOW + "uuid: Returns the UUID of the currently held item"));
- sender.addChatMessage(new ChatComponentText(EnumChatFormatting.YELLOW + "set: Sets the custom name of the currently held item"));
- sender.addChatMessage(new ChatComponentText(EnumChatFormatting.YELLOW + "Usage: /neurename set [name...]"));
-
- }
- }
- });*/
}
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 a4c5a60a..88c89773 100644
--- a/src/main/java/io/github/moulberry/notenoughupdates/dungeons/DungeonMap.java
+++ b/src/main/java/io/github/moulberry/notenoughupdates/dungeons/DungeonMap.java
@@ -122,9 +122,6 @@ public class DungeonMap {
private int startRoomY = -1;
private int connectorSize = 5;
private int roomSize = 0;
-
- //private final List<MapDecoration> decorations = new ArrayList<>();
- //private final List<MapDecoration> lastDecorations = new ArrayList<>();
private long lastDecorationsMillis = -1;
private long lastLastDecorationsMillis = -1;
@@ -1475,9 +1472,7 @@ public class DungeonMap {
}
}
- //System.out.println("--- PERM START ---");
for (Map.Entry<String, Integer> entry : smallestPermutation.entrySet()) {
- //System.out.println(entry.getKey() + ":" + entry.getValue() + " : Total dist: " + smallestTotalDistance);
finalUsedIndexes.add(entry.getValue());
playerMarkerMapPositions.put(entry.getKey(), positions.get(entry.getValue()));
}
diff --git a/src/main/java/io/github/moulberry/notenoughupdates/dungeons/GuiDungeonMapEditor.java b/src/main/java/io/github/moulberry/notenoughupdates/dungeons/GuiDungeonMapEditor.java
index 8ce9d505..735fa3e6 100644
--- a/src/main/java/io/github/moulberry/notenoughupdates/dungeons/GuiDungeonMapEditor.java
+++ b/src/main/java/io/github/moulberry/notenoughupdates/dungeons/GuiDungeonMapEditor.java
@@ -152,15 +152,6 @@ public class GuiDungeonMapEditor extends GuiScreen {
public GuiDungeonMapEditor() {
DungeonMapConfig options = NotEnoughUpdates.INSTANCE.config.dungeonMap;
- //Map Border Size
- //buttons.add(new Button(0, 6, 37, "Small", options.dmBorderSize));
- //buttons.add(new Button(1, 52, 37, "Medium", options.dmBorderSize));
- //buttons.add(new Button(2, 98, 37, "Large", options.dmBorderSize));
-
- //Map Rooms Size
- //buttons.add(new Button(3, 6, 67+19, "Small", options.dmRoomSize));
- //buttons.add(new Button(4, 52, 67+19, "Medium", options.dmRoomSize));
- //buttons.add(new Button(5, 98, 67+19, "Large", options.dmRoomSize));
//Map Border Styles
buttons.add(new Button(6, 6, 97 + 30, "None"));
@@ -241,9 +232,6 @@ public class GuiDungeonMapEditor extends GuiScreen {
e.printStackTrace();
}
- //buttons.add(new Button(29, 52, 86+19, "XLarge", options.dmRoomSize));
- //buttons.add(new Button(30, 52, 56, "XLarge", options.dmBorderSize));
-
{
double val = NotEnoughUpdates.INSTANCE.config.dungeonMap.dmBackgroundBlur;
String strVal;
@@ -466,7 +454,6 @@ public class GuiDungeonMapEditor extends GuiScreen {
button.render();
}
- //List<String> textLines, final int mouseX, final int mouseY, final int screenWidth, final int screenHeight, final int maxTextWidth, FontRenderer font
if (tooltipToDisplay != null) {
Utils.drawHoveringText(
tooltipToDisplay,
diff --git a/src/main/java/io/github/moulberry/notenoughupdates/infopanes/DevInfoPane.java b/src/main/java/io/github/moulberry/notenoughupdates/infopanes/DevInfoPane.java
index 0b1963d6..253cc245 100644
--- a/src/main/java/io/github/moulberry/notenoughupdates/infopanes/DevInfoPane.java
+++ b/src/main/java/io/github/moulberry/notenoughupdates/infopanes/DevInfoPane.java
@@ -60,24 +60,6 @@ public class DevInfoPane extends TextInfoPane {
private String getText() {
String text = "";
- /*for(Map.Entry<String, JsonObject> item : manager.getItemInformation().entrySet()) {
- if(!item.getValue().has("infoType") || item.getValue().get("infoType").getAsString().isEmpty()) {
- text += item.getKey() + "\n";
- }
- }*/
- /*for(String s : manager.neuio.getRemovedItems(manager.getItemInformation().keySet())) {
- text += s + "\n";
- }
-
- if(true) return text;*/
-
- /*for(Map.Entry<String, JsonObject> item : manager.getItemInformation().entrySet()) {
- if(!item.getValue().has("infoType") || item.getValue().get("infoType").getAsString().isEmpty()) {
- text += item.getKey() + "\n";
- }
- }*/
- //if(true) return text;
-
for (String internalname : manager.auctionManager.getItemAuctionInfoKeySet()) {
if (internalname.matches("^.*-[0-9]{1,3}$")) continue;
if (!manager.getItemInformation().containsKey(internalname)) {
@@ -86,23 +68,11 @@ public class DevInfoPane extends TextInfoPane {
}
}
- /*for(Map.Entry<String, JsonElement> entry : manager.getAuctionPricesJson().get("prices").getAsJsonObject().entrySet()) {
- if(!manager.getItemInformation().keySet().contains(entry.getKey())) {
- if(entry.getKey().contains("-")) {
- continue;
- }
- if(entry.getKey().startsWith("PERFECT")) continue;
- if(Item.itemRegistry.getObject(new ResourceLocation(entry.getKey().toLowerCase())) != null) {
- continue;
- }
- text += entry.getKey() + "\n";
- }
- }*/
+
return text;
}
//#region add vanilla items
-
AtomicBoolean running = new AtomicBoolean(false);
ScheduledExecutorService ses = Executors.newScheduledThreadPool(1);
@@ -555,7 +525,6 @@ public class DevInfoPane extends TextInfoPane {
if (stack.getItemDamage() != 0 && stack.getItemDamage() < 32000) {
stacki += "-" + stack.getItemDamage();
}
- //stacki += ":"+stack.stackSize;
stacki += ":1";
}
}
@@ -595,7 +564,6 @@ public class DevInfoPane extends TextInfoPane {
if (stack.getItemDamage() != 0 && stack.getItemDamage() < 32000) {
stacki += "-" + stack.getItemDamage();
}
- //stacki += ":"+stack.stackSize;
stacki += ":1";
}
}
@@ -645,7 +613,6 @@ public class DevInfoPane extends TextInfoPane {
if (stack.getItemDamage() != 0 && stack.getItemDamage() < 32000) {
stacki += "-" + stack.getItemDamage();
}
- //stacki += ":"+stack.stackSize;
stacki += ":1";
}
}
@@ -705,7 +672,6 @@ public class DevInfoPane extends TextInfoPane {
for (String bukkit : bukkitList) {
String internalname = bukkit.split("@")[0];
if (true || !manager.getItemInformation().containsKey(internalname)) {
- //System.out.println("adding vanilla: " + internalname);
String vanilla = internalname.toLowerCase().replace("_item", "");
if (bukkit.contains("@")) {
vanilla = bukkit.split("@")[1];
@@ -750,7 +716,6 @@ public class DevInfoPane extends TextInfoPane {
if (stack.getItemDamage() != 0 && stack.getItemDamage() < 32000) {
stacki += "-" + stack.getItemDamage();
}
- //stacki += ":"+stack.stackSize;
stacki += ":1";
}
}
@@ -801,7 +766,6 @@ public class DevInfoPane extends TextInfoPane {
if (stack.getItemDamage() != 0 && stack.getItemDamage() < 32000) {
stacki += "-" + stack.getItemDamage();
}
- //stacki += ":"+stack.stackSize;
stacki += ":1";
}
}
@@ -839,7 +803,6 @@ public class DevInfoPane extends TextInfoPane {
if (stack.getItemDamage() != 0 && stack.getItemDamage() < 32000) {
stacki += "-" + stack.getItemDamage();
}
- //stacki += ":"+stack.stackSize;
stacki += ":1";
}
}
@@ -887,7 +850,6 @@ public class DevInfoPane extends TextInfoPane {
if (stack.getItemDamage() != 0 && stack.getItemDamage() < 32000) {
stacki += "-" + stack.getItemDamage();
}
- //stacki += ":"+stack.stackSize;
stacki += ":1";
}
}
@@ -967,126 +929,7 @@ public class DevInfoPane extends TextInfoPane {
}
}
- //for(Map.Entry<String, JsonObject> item : manager.getItemInformation().entrySet()) {
- /*if(!item.getValue().has("infoType") || item.getValue().get("infoType").getAsString().isEmpty()) {
- if(item.getValue().has("info") && item.getValue().get("info").getAsJsonArray().size()>0) {
- item.getValue().addProperty("infoType", "WIKI_URL");
- try {
- manager.writeJsonDefaultDir(item.getValue(), item.getKey()+".json");
- } catch(IOException e){}
- manager.loadItem(item.getKey());
- }
- }*/
- /*if(item.getKey().startsWith("PET_ITEM_")) {
- item.getValue().addProperty("infoType", "WIKI_URL");
- JsonArray array = new JsonArray();
- array.add(new JsonPrimitive("https://hypixel-skyblock.fandom.com/wiki/Pet_Items"));
- item.getValue().add("info", array);
- try {
- manager.writeJsonDefaultDir(item.getValue(), item.getKey()+".json");
- } catch(IOException e){}
- manager.loadItem(item.getKey());
- }*/
- /*if(!item.getValue().has("infoType") || item.getValue().get("infoType").getAsString().isEmpty()) {
- //String prettyName =
-
- String itemS = item.getKey().split("-")[0].split(";")[0];
- StringBuilder prettyName = new StringBuilder();
- boolean capital = true;
- for(int i=0; i<itemS.length(); i++) {
- char c = itemS.charAt(i);
- if(capital) {
- prettyName.append(String.valueOf(c).toUpperCase());
- capital = false;
- } else {
- prettyName.append(String.valueOf(c).toLowerCase());
- }
- if(String.valueOf(c).equals("_")) {
- capital = true;
- }
- }
- String prettyNameS = prettyName.toString();
- File f = manager.getWebFile("https://hypixel-skyblock.fandom.com/wiki/"+prettyNameS);
- if(f == null) {
- continue;
- //#REDIRECT [[Armor of Magma]]
- }
- StringBuilder sb = new StringBuilder();
- try(BufferedReader br = new BufferedReader(new InputStreamReader(
- new FileInputStream(f), StandardCharsets.UTF_8))) {
- String l;
- while((l = br.readLine()) != null){
- sb.append(l).append("\n");
- }
- } catch(IOException e) {
- continue;
- }
- if(sb.toString().isEmpty()) {
- continue;
- }
- if(sb.toString().startsWith("#REDIRECT")) {
- prettyNameS = sb.toString().split("\\[\\[")[1].split("]]")[0].replaceAll(" ", "_");
- }
- item.getValue().addProperty("infoType", "WIKI_URL");
- JsonArray array = new JsonArray();
- array.add(new JsonPrimitive("https://hypixel-skyblock.fandom.com/wiki/"+prettyNameS));
- item.getValue().add("info", array);
- try {
- manager.writeJsonDefaultDir(item.getValue(), item.getKey()+".json");
- } catch(IOException e){}
- manager.loadItem(item.getKey());
- }*/
}
-
- /*if(running.get()) {
- List<String> add = new ArrayList<>();
- for(Map.Entry<String, JsonObject> item : manager.getItemInformation().entrySet()) {
- if(item.getValue().has("recipe")) {
- if(!item.getKey().contains("-") && !item.getKey().contains(";")) {
- add.add(item.getKey());
- }
- }
- }
- AtomicInteger index = new AtomicInteger(0);
-
- ses.schedule(new Runnable() {
- public void run() {
- if(!running.get()) return;
-
- int i = index.getAndIncrement();
- String item = add.get(i).split("-")[0].split(";")[0];
- Minecraft.getMinecraft().thePlayer.sendChatMessage("/viewrecipe " + item);
- ses.schedule(this, 1000L, TimeUnit.MILLISECONDS);
- }
- }, 1000L, TimeUnit.MILLISECONDS);
- }*/
- //}
- /*if(Keyboard.isKeyDown(Keyboard.KEY_J) && !running) {
- running = true;
- List<String> add = new ArrayList<>();
- for(Map.Entry<String, JsonElement> entry : manager.getAuctionPricesJson().get("prices").getAsJsonObject().entrySet()) {
- if(!manager.getItemInformation().keySet().contains(entry.getKey())) {
- if(entry.getKey().contains("-")) {
- continue;
- }
- if(entry.getKey().startsWith("PERFECT")) continue;
- if(Item.itemRegistry.getObject(new ResourceLocation(entry.getKey().toLowerCase())) != null) {
- continue;
- }
- add.add(entry.getKey());
- }
- }
- AtomicInteger index = new AtomicInteger(0);
-
- ses.schedule(new Runnable() {
- public void run() {
- int i = index.getAndIncrement();
- String item = add.get(i).split("-")[0].split(";")[0];
- Minecraft.getMinecraft().thePlayer.sendChatMessage("/viewrecipe " + item);
- ses.schedule(this, 1000L, TimeUnit.MILLISECONDS);
- }
- }, 1000L, TimeUnit.MILLISECONDS);
- }*/
return false;
}
//#endregion
diff --git a/src/main/java/io/github/moulberry/notenoughupdates/itemeditor/GuiElementTextField.java b/src/main/java/io/github/moulberry/notenoughupdates/itemeditor/GuiElementTextField.java
index 71c4d498..7cc96d42 100644
--- a/src/main/java/io/github/moulberry/notenoughupdates/itemeditor/GuiElementTextField.java
+++ b/src/main/java/io/github/moulberry/notenoughupdates/itemeditor/GuiElementTextField.java
@@ -557,8 +557,6 @@ public class GuiElementTextField extends GuiElement {
continue;
}
- //String c2 = bold ? EnumChatFormatting.BOLD.toString() : "" + c;
-
int len = Minecraft.getMinecraft().fontRendererObj.getStringWidth(String.valueOf(c));
if (bold) len++;
if (i >= leftIndex && i < rightIndex) {
diff --git a/src/main/java/io/github/moulberry/notenoughupdates/listener/ChatListener.java b/src/main/java/io/github/moulberry/notenoughupdates/listener/ChatListener.java
index f85c165a..0ad9fd99 100644
--- a/src/main/java/io/github/moulberry/notenoughupdates/listener/ChatListener.java
+++ b/src/main/java/io/github/moulberry/notenoughupdates/listener/ChatListener.java
@@ -242,7 +242,6 @@ public class ChatListener {
} else if (unformatted.startsWith(" RNG Meter")) {
RNGMeter = unformatted.substring(" RNG Meter - ".length());
} else if (matcher.matches()) {
- //matcher.group(1);
SlayerOverlay.slayerLVL = matcher.group(2);
if (!SlayerOverlay.slayerLVL.equals("9")) {
SlayerOverlay.slayerXp = matcher.group(3);
diff --git a/src/main/java/io/github/moulberry/notenoughupdates/miscgui/tutorials/NeuConfigTutorial.java b/src/main/java/io/github/moulberry/notenoughupdates/miscgui/tutorials/NeuConfigTutorial.java
deleted file mode 100644
index 6a2602f8..00000000
--- a/src/main/java/io/github/moulberry/notenoughupdates/miscgui/tutorials/NeuConfigTutorial.java
+++ /dev/null
@@ -1,26 +0,0 @@
-/*
- * Copyright (C) 2022 NotEnoughUpdates contributors
- *
- * This file is part of NotEnoughUpdates.
- *
- * NotEnoughUpdates is free software: you can redistribute it
- * and/or modify it under the terms of the GNU Lesser General Public
- * License as published by the Free Software Foundation, either
- * version 3 of the License, or (at your option) any later version.
- *
- * NotEnoughUpdates is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public License
- * along with NotEnoughUpdates. If not, see <https://www.gnu.org/licenses/>.
- */
-
-package io.github.moulberry.notenoughupdates.miscgui.tutorials;
-
-public class NeuConfigTutorial extends TutorialBase {
- static {
- title = "NEU Config Tutorial";
- }
-}
diff --git a/src/main/java/io/github/moulberry/notenoughupdates/miscgui/tutorials/NeuTutorial.java b/src/main/java/io/github/moulberry/notenoughupdates/miscgui/tutorials/NeuTutorial.java
deleted file mode 100644
index c0a5d8c8..00000000
--- a/src/main/java/io/github/moulberry/notenoughupdates/miscgui/tutorials/NeuTutorial.java
+++ /dev/null
@@ -1,168 +0,0 @@
-/*
- * Copyright (C) 2022 NotEnoughUpdates contributors
- *
- * This file is part of NotEnoughUpdates.
- *
- * NotEnoughUpdates is free software: you can redistribute it
- * and/or modify it under the terms of the GNU Lesser General Public
- * License as published by the Free Software Foundation, either
- * version 3 of the License, or (at your option) any later version.
- *
- * NotEnoughUpdates is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public License
- * along with NotEnoughUpdates. If not, see <https://www.gnu.org/licenses/>.
- */
-
-package io.github.moulberry.notenoughupdates.miscgui.tutorials;
-
-import net.minecraft.client.Minecraft;
-import net.minecraft.util.ResourceLocation;
-
-public class NeuTutorial extends TutorialBase {
- static {
- title = "NEU Tutorial";
- }
-
- @Override
- public void setWorldAndResolution(Minecraft mc, int width, int height) {
- super.setWorldAndResolution(mc, width, height);
- screenshots = new ResourceLocation[18];
- for (int i = 0; i <= 17; i++) {