aboutsummaryrefslogtreecommitdiff
path: root/src/main/java
diff options
context:
space:
mode:
Diffstat (limited to 'src/main/java')
-rw-r--r--src/main/java/me/Danker/DankersSkyblockMod.java15
-rw-r--r--src/main/java/me/Danker/commands/DHelpCommand.java11
-rw-r--r--src/main/java/me/Danker/commands/DungeonsCommand.java152
-rw-r--r--src/main/java/me/Danker/commands/SetAngleCommand.java40
-rw-r--r--src/main/java/me/Danker/commands/ToggleCommand.java13
-rw-r--r--src/main/java/me/Danker/commands/warp/Crypt.java47
-rw-r--r--src/main/java/me/Danker/commands/warp/DarkAuction.java48
-rw-r--r--src/main/java/me/Danker/commands/warp/Dragon.java48
-rw-r--r--src/main/java/me/Danker/commands/warp/DungeonHub.java48
-rw-r--r--src/main/java/me/Danker/commands/warp/HowlingCave.java47
-rw-r--r--src/main/java/me/Danker/commands/warp/Magma.java47
-rw-r--r--src/main/java/me/Danker/commands/warp/SpidersNest.java47
-rw-r--r--src/main/java/me/Danker/features/HighlightCommissions.java37
-rw-r--r--src/main/java/me/Danker/features/SpamHider.java2
-rw-r--r--src/main/java/me/Danker/gui/DankerGui.java8
-rw-r--r--src/main/java/me/Danker/handlers/ConfigHandler.java1
16 files changed, 452 insertions, 159 deletions
diff --git a/src/main/java/me/Danker/DankersSkyblockMod.java b/src/main/java/me/Danker/DankersSkyblockMod.java
index f176bbe..fe31d96 100644
--- a/src/main/java/me/Danker/DankersSkyblockMod.java
+++ b/src/main/java/me/Danker/DankersSkyblockMod.java
@@ -2,6 +2,7 @@ package me.Danker;
import com.google.gson.JsonObject;
import me.Danker.commands.*;
+import me.Danker.commands.warp.*;
import me.Danker.events.ChestSlotClickedEvent;
import me.Danker.events.GuiChestBackgroundDrawnEvent;
import me.Danker.events.RenderOverlay;
@@ -140,6 +141,8 @@ public class DankersSkyblockMod {
MinecraftForge.EVENT_BUS.register(new WatcherReadyAlert());
MinecraftForge.EVENT_BUS.register(new WaterSolver());
+ MinecraftForge.EVENT_BUS.register(new HighlightCommissions());
+
ConfigHandler.reloadConfig();
GoldenEnchants.init();
TriviaSolver.init();
@@ -167,7 +170,6 @@ public class DankersSkyblockMod {
ClientCommandHandler.instance.registerCommand(new DHelpCommand());
ClientCommandHandler.instance.registerCommand(new DankerGuiCommand());
ClientCommandHandler.instance.registerCommand(new DisplayCommand());
- ClientCommandHandler.instance.registerCommand(new DungeonsCommand());
ClientCommandHandler.instance.registerCommand(new FairySoulsCommand());
ClientCommandHandler.instance.registerCommand(new GetkeyCommand());
ClientCommandHandler.instance.registerCommand(new GuildOfCommand());
@@ -187,6 +189,15 @@ public class DankersSkyblockMod {
ClientCommandHandler.instance.registerCommand(new SkyblockPlayersCommand());
ClientCommandHandler.instance.registerCommand(new SlayerCommand());
ClientCommandHandler.instance.registerCommand(new ToggleCommand());
+ ClientCommandHandler.instance.registerCommand(new SetAngleCommand());
+
+ ClientCommandHandler.instance.registerCommand(new Crypt());
+ ClientCommandHandler.instance.registerCommand(new DarkAuction());
+ ClientCommandHandler.instance.registerCommand(new Dragon());
+ ClientCommandHandler.instance.registerCommand(new DungeonHub());
+ ClientCommandHandler.instance.registerCommand(new HowlingCave());
+ ClientCommandHandler.instance.registerCommand(new Magma());
+ ClientCommandHandler.instance.registerCommand(new SpidersNest());
configDirectory = event.getModConfigurationDirectory().toString();
}
@@ -393,7 +404,7 @@ public class DankersSkyblockMod {
@SubscribeEvent
public void onGuiRender(GuiScreenEvent.BackgroundDrawnEvent event) {
- if (!Utils.inSkyblock) return;
+ //if (!Utils.inSkyblock) return;
if (event.gui instanceof GuiChest) {
GuiChest inventory = (GuiChest) event.gui;
Container containerChest = inventory.inventorySlots;
diff --git a/src/main/java/me/Danker/commands/DHelpCommand.java b/src/main/java/me/Danker/commands/DHelpCommand.java
index 4d595e5..f12d0ee 100644
--- a/src/main/java/me/Danker/commands/DHelpCommand.java
+++ b/src/main/java/me/Danker/commands/DHelpCommand.java
@@ -1,6 +1,7 @@
package me.Danker.commands;
import me.Danker.DankersSkyblockMod;
+import me.Danker.commands.warp.*;
import net.minecraft.command.CommandBase;
import net.minecraft.command.CommandException;
import net.minecraft.command.ICommandSender;
@@ -49,7 +50,7 @@ public class DHelpCommand extends CommandBase {
EnumChatFormatting.GOLD + PetsCommand.usage(arg0) + EnumChatFormatting.AQUA + " - Uses API to get pets of a person. If no name is provided, it checks yours.\n" +
EnumChatFormatting.GOLD + BankCommand.usage(arg0) + EnumChatFormatting.AQUA + " - Uses API to get bank and purse coins of a person. If no name is provided, it checks yours.\n" +
EnumChatFormatting.GOLD + ArmourCommand.usage(arg0) + EnumChatFormatting.AQUA + " - Uses API to get armour of a person. If no name is provided, it checks yours.\n" +
- EnumChatFormatting.GOLD + DungeonsCommand.usage(arg0) + EnumChatFormatting.AQUA + " - Uses API to get dungeon levels of a person. If no name is provided, it checks yours.\n" +
+ EnumChatFormatting.GOLD + DungeonHub.usage(arg0) + EnumChatFormatting.AQUA + " - Uses API to get dungeon levels of a person. If no name is provided, it checks yours.\n" +
EnumChatFormatting.GOLD + ImportFishingCommand.usage(arg0) + EnumChatFormatting.AQUA + " - Imports your fishing stats from your latest profile to your fishing tracker using the API.\n" +
EnumChatFormatting.GOLD + SkyblockPlayersCommand.usage(arg0) + EnumChatFormatting.AQUA + " - Uses API to find how many players are on each Skyblock island.\n" +
EnumChatFormatting.GOLD + SkillTrackerCommand.usage(arg0) + EnumChatFormatting.AQUA + " - Text display for skill xp/hour.\n" +
@@ -57,6 +58,14 @@ public class DHelpCommand extends CommandBase {
EnumChatFormatting.GOLD + RepartyCommand.usage(arg0) + EnumChatFormatting.AQUA + " - Disbands and reparties all members in the party.\n" +
EnumChatFormatting.GOLD + CustomMusicCommand.usage(arg0) + EnumChatFormatting.AQUA + " - Stops or reloads the custom music.\n" +
EnumChatFormatting.GOLD + PlayerCommand.usage(arg0) + EnumChatFormatting.AQUA + " - Uses API to find skills, slayers, coins and weight of a player.\n" +
+ EnumChatFormatting.GOLD + Crypt.usage(arg0) + EnumChatFormatting.AQUA + " - Warps you to the Crypt in the Hub. \n" +
+ EnumChatFormatting.GOLD + DarkAuction.usage(arg0) + EnumChatFormatting.AQUA + " - Warps you to the Dark Auction in the Hub. \n" +
+ EnumChatFormatting.GOLD + Dragon.usage(arg0) + EnumChatFormatting.AQUA + " - Warps you to the Dragons Nest in the End. \n" +
+ EnumChatFormatting.GOLD + DungeonHub.usage(arg0) + EnumChatFormatting.AQUA + " - Warps you to the Dungeon Hub. \n" +
+ EnumChatFormatting.GOLD + HowlingCave.usage(arg0) + EnumChatFormatting.AQUA + " - Warps you to the Howling Cave in the Park. \n" +
+ EnumChatFormatting.GOLD + Magma.usage(arg0) + EnumChatFormatting.AQUA + " - Warps you to the Magma Fields in the Blazing Fortress. \n" +
+ EnumChatFormatting.GOLD + SpidersNest.usage(arg0) + EnumChatFormatting.AQUA + " - Warps you to the Top of the Spider's Nest in the Spider's Den. \n" +
+ EnumChatFormatting.GOLD + SetAngleCommand.usage(arg0) + EnumChatFormatting.AQUA + " - Sets your yaw and pitch. \n" +
EnumChatFormatting.GREEN + " Open Maddox Menu" + EnumChatFormatting.AQUA + " - M by default.\n" +
EnumChatFormatting.GREEN + " Start/Stop Skill Tracker" + EnumChatFormatting.AQUA + " - Numpad 5 by default.\n"));
}
diff --git a/src/main/java/me/Danker/commands/DungeonsCommand.java b/src/main/java/me/Danker/commands/DungeonsCommand.java
deleted file mode 100644
index 92779dc..0000000
--- a/src/main/java/me/Danker/commands/DungeonsCommand.java
+++ /dev/null
@@ -1,152 +0,0 @@
-package me.Danker.commands;
-
-import com.google.gson.JsonObject;
-import me.Danker.DankersSkyblockMod;
-import me.Danker.handlers.APIHandler;
-import me.Danker.handlers.ConfigHandler;
-import me.Danker.utils.Utils;
-import net.minecraft.command.CommandBase;
-import net.minecraft.command.CommandException;
-import net.minecraft.command.ICommandSender;
-import net.minecraft.entity.player.EntityPlayer;
-import net.minecraft.event.HoverEvent;
-import net.minecraft.util.BlockPos;
-import net.minecraft.util.ChatComponentText;
-import net.minecraft.util.EnumChatFormatting;
-
-import java.util.List;
-
-public class DungeonsCommand extends CommandBase {
-
- @Override
- public String getCommandName() {
- return "dungeons";
- }
-
- @Override
- public String getCommandUsage(ICommandSender arg0) {
- return "/" + getCommandName() + " [name]";
- }
-
- public static String usage(ICommandSender arg0) {
- return new DungeonsCommand().getCommandUsage(arg0);
- }
-
- @Override
- public int getRequiredPermissionLevel() {
- return 0;
- }
-
- @Override
- public List<String> addTabCompletionOptions(ICommandSender sender, String[] args, BlockPos pos) {
- if (args.length == 1) {
- return Utils.getMatchingPlayers(args[0]);
- }
- return null;
- }
-
- @Override
- public void processCommand(ICommandSender arg0, String[] arg1) throws CommandException {
- // MULTI THREAD DRIFTING
- new Thread(() -> {
- EntityPlayer player = (EntityPlayer) arg0;
-
- // Check key
- String key = ConfigHandler.getString("api", "APIKey");
- if (key.equals("")) {
- player.addChatMessage(new ChatComponentText(DankersSkyblockMod.ERROR_COLOUR + "API key not set. Use /setkey."));
- }
-
- // Get UUID for Hypixel API requests
- String username;
- String uuid;
- if (arg1.length == 0) {
- username = player.getName();
- uuid = player.getUniqueID().toString().replaceAll("[\\-]", "");
- player.addChatMessage(new ChatComponentText(DankersSkyblockMod.MAIN_COLOUR + "Checking dungeon stats of " + DankersSkyblockMod.SECONDARY_COLOUR + username));
- } else {
- username = arg1[0];
- player.addChatMessage(new ChatComponentText(DankersSkyblockMod.MAIN_COLOUR + "Checking dungeon stats of " + DankersSkyblockMod.SECONDARY_COLOUR + username));
- uuid = APIHandler.getUUID(username);
- }
-
- // Find stats of latest profile
- String latestProfile = APIHandler.getLatestProfileID(uuid, key);
- if (latestProfile == null) return;
-
- String profileURL = "https://api.hypixel.net/skyblock/profile?profile=" + latestProfile + "&key=" + key;
- System.out.println("Fetching profile...");
- JsonObject profileResponse = APIHandler.getResponse(profileURL);
- if (!profileResponse.get("success").getAsBoolean()) {
- String reason = profileResponse.get("cause").getAsString();
- player.addChatMessage(new ChatComponentText(DankersSkyblockMod.ERROR_COLOUR + "Failed with reason: " + reason));
- return;
- }
-
- String playerURL = "https://api.hypixel.net/player?uuid=" + uuid + "&key=" + key;
- System.out.println("Fetching player data...");
- JsonObject playerResponse = APIHandler.getResponse(playerURL);
- if(!playerResponse.get("success").getAsBoolean()){
- String reason = playerResponse.get("cause").getAsString();
- player.addChatMessage(new ChatComponentText(DankersSkyblockMod.ERROR_COLOUR + "This player has not played on Hypixel."));
- }
-
- System.out.println("Fetching dungeon stats...");
- JsonObject dungeonsObject = profileResponse.get("profile").getAsJsonObject().get("members").getAsJsonObject().get(uuid).getAsJsonObject().get("dungeons").getAsJsonObject();
- if (!dungeonsObject.get("dungeon_types").getAsJsonObject().get("catacombs").getAsJsonObject().has("experience")) {
- player.addChatMessage(new ChatComponentText(DankersSkyblockMod.ERROR_COLOUR + "This player has not played dungeons."));
- return;
- }
-
- JsonObject catacombsObject = dungeonsObject.get("dungeon_types").getAsJsonObject().get("catacombs").getAsJsonObject();
- double catacombs = Utils.xpToDungeonsLevel(catacombsObject.get("experience").getAsDouble());
- double healer = Utils.xpToDungeonsLevel(dungeonsObject.get("player_classes").getAsJsonObject().get("healer").getAsJsonObject().get("experience").getAsDouble());
- double mage = Utils.xpToDungeonsLevel(dungeonsObject.get("player_classes").getAsJsonObject().get("mage").getAsJsonObject().get("experience").getAsDouble());
- double berserk = Utils.xpToDungeonsLevel(dungeonsObject.get("player_classes").getAsJsonObject().get("berserk").getAsJsonObject().get("experience").getAsDouble());
- double archer = Utils.xpToDungeonsLevel(dungeonsObject.get("player_classes").getAsJsonObject().get("archer").getAsJsonObject().get("experience").getAsDouble());
- double tank = Utils.xpToDungeonsLevel(dungeonsObject.get("player_classes").getAsJsonObject().get("tank").getAsJsonObject().get("experience").getAsDouble());
- String selectedClass = Utils.capitalizeString(dungeonsObject.get("selected_dungeon_class").getAsString());
- int secrets = playerResponse.get("player").getAsJsonObject().get("achievements").getAsJsonObject().get("skyblock_treasure_hunter").getAsInt();
-
- int highestFloor = catacombsObject.get("highest_tier_completed").getAsInt();
- JsonObject completionObj = catacombsObject.get("tier_completions").getAsJsonObject();
-
- String delimiter = DankersSkyblockMod.DELIMITER_COLOUR + "" + EnumChatFormatting.BOLD + "-------------------";
-
- ChatComponentText classLevels = new ChatComponentText(
- EnumChatFormatting.GOLD + " Selected Class: " + selectedClass + "\n\n" +
- EnumChatFormatting.RED + " Catacombs Level: " + catacombs + "\n" +
- EnumChatFormatting.YELLOW + " Healer Level: " + healer + "\n" +
- EnumChatFormatting.LIGHT_PURPLE + " Mage Level: " + mage + "\n" +
- EnumChatFormatting.RED + " Berserk Level: " + berserk + "\n" +
- EnumChatFormatting.GREEN + " Archer Level: " + archer + "\n" +
- EnumChatFormatting.BLUE + " Tank Level: " + tank + "\n\n" +
- EnumChatFormatting.WHITE + " Secrets Found: " + secrets + "\n\n");
-
- StringBuilder completionsHoverString = new StringBuilder();
-
- for (int i = 0; i <= highestFloor; i++) {
- completionsHoverString
- .append(EnumChatFormatting.GOLD)
- .append(i == 0 ? "Entrance: " : "Floor " + i + ": ")
- .append(EnumChatFormatting.RESET)
- .append(completionObj.get(String.valueOf(i)).getAsInt())
- .append(i < highestFloor ? "\n": "");
- }
-
- ChatComponentText completions = new ChatComponentText(EnumChatFormatting.GOLD + " Highest Floor Completed: " + highestFloor);
-
- completions.setChatStyle(completions.getChatStyle().setChatHoverEvent(new HoverEvent(HoverEvent.Action.SHOW_TEXT, new ChatComponentText(completionsHoverString.toString()))));
-
-
- player.addChatMessage(
- new ChatComponentText(delimiter)
- .appendText("\n")
- .appendSibling(classLevels)
- .appendSibling(completions)
- .appendText("\n")
- .appendSibling(new ChatComponentText(delimiter))
- );
- }).start();
- }
-}
diff --git a/src/main/java/me/Danker/commands/SetAngleCommand.java b/src/main/java/me/Danker/commands/SetAngleCommand.java
new file mode 100644
index 0000000..6061621
--- /dev/null
+++ b/src/main/java/me/Danker/commands/SetAngleCommand.java
@@ -0,0 +1,40 @@
+package me.Danker.commands;
+
+import me.Danker.DankersSkyblockMod;
+import net.minecraft.client.Minecraft;
+import net.minecraft.command.CommandBase;
+import net.minecraft.command.CommandException;
+import net.minecraft.command.ICommandSender;
+import net.minecraft.util.ChatComponentText;
+
+
+public class SetAngleCommand extends CommandBase {
+
+ @Override
+ public String getCommandName() {
+ return "setangle";
+ }
+
+ @Override
+ public String getCommandUsage(ICommandSender sender) {
+ return "/" + getCommandName() + " [yaw] [pitch]";
+ }
+
+ public static String usage(ICommandSender arg0) {
+ return new SetAngleCommand().getCommandUsage(arg0);
+ }
+
+ @Override
+ public int getRequiredPermissionLevel() {
+ return 0;
+ }
+
+ @Override
+ public void processCommand(ICommandSender sender, String[] args) throws CommandException {
+ if (args.length < 2) return;
+
+ Minecraft.getMinecraft().thePlayer.rotationPitch = Float.parseFloat(args[1]);
+ Minecraft.getMinecraft().thePlayer.rotationYaw = Float.parseFloat(args[0]);
+ sender.addChatMessage(new ChatComponentText(DankersSkyblockMod.MAIN_COLOUR + "Set your rotation to yaw=" + DankersSkyblockMod.SECONDARY_COLOUR + args[0] + DankersSkyblockMod.MAIN_COLOUR + ", pitch=" + DankersSkyblockMod.SECONDARY_COLOUR +args[1]));
+ }
+}
diff --git a/src/main/java/me/Danker/commands/ToggleCommand.java b/src/main/java/me/Danker/commands/ToggleCommand.java
index 27167b6..c04e0a8 100644
--- a/src/main/java/me/Danker/commands/ToggleCommand.java
+++ b/src/main/java/me/Danker/commands/ToggleCommand.java
@@ -37,6 +37,7 @@ public class ToggleCommand extends CommandBase implements ICommand {
public static boolean teammatesInRadius;
public static boolean giantHP;
public static boolean hidePetCandy;
+ public static boolean highlightCommissions;
// Chat Messages
public static boolean sceptreMessages;
public static boolean midasStaffMessages;
@@ -80,7 +81,7 @@ public class ToggleCommand extends CommandBase implements ICommand {
public static boolean bloodRoomMusic;
public static boolean dungeonMusic;
- @Override
+ @Override
public String getCommandName() {
return "toggle";
}
@@ -97,7 +98,7 @@ public class ToggleCommand extends CommandBase implements ICommand {
"startswithterminal/selectallterminal/clickinorderterminal/" +
"ultrasequencer/chronomatron/superpairs/hidetooltipsinaddons/pickblock/" +
"melodytooltips/highlightslayers/highlightarachne/highlightskeletonmasters/teammatesinradius/" +
- "gianthp/hidepetcandy/dungeonbossmusic/bloodroommusic/dungeonmusic/list>";
+ "gianthp/hidepetcandy/dungeonbossmusic/bloodroommusic/dungeonmusic/highlightcommissions/list>";
}
public static String usage(ICommandSender arg0) {
@@ -126,7 +127,7 @@ public class ToggleCommand extends CommandBase implements ICommand {
"ultrasequencer", "chronomatron", "superpairs",
"hidetooltipsinaddons", "pickblock", "melodytooltips", "highlightslayers",
"highlightskeletonmasters", "dungeonbossmusic", "bloodroommusic", "dungeonmusic",
- "teammatesinradius", "gianthp", "hidepetcandy", "list");
+ "teammatesinradius", "gianthp", "hidepetcandy", "highlightcommissions", "list");
}
return null;
}
@@ -422,6 +423,11 @@ public class ToggleCommand extends CommandBase implements ICommand {
ConfigHandler.writeBooleanConfig("toggles", "HidePetCandy", hidePetCandy);
player.addChatMessage(new ChatComponentText(DankersSkyblockMod.MAIN_COLOUR + "Hide pet candy has been set to " + DankersSkyblockMod.SECONDARY_COLOUR + hidePetCandy + DankersSkyblockMod.MAIN_COLOUR + "."));
break;
+ case "highlightcommissions":
+ highlightCommissions = !highlightCommissions;
+ ConfigHandler.writeBooleanConfig("toggles", "HighlightCommissions", highlightCommissions);
+ player.addChatMessage(new ChatComponentText(DankersSkyblockMod.MAIN_COLOUR + "Highlight Commissions has been set to " + DankersSkyblockMod.SECONDARY_COLOUR + highlightCommissions + DankersSkyblockMod.MAIN_COLOUR + "."));
+ break;
case "dungeonbossmusic":
dungeonBossMusic = !dungeonBossMusic;
CustomMusic.dungeonboss.stop();
@@ -489,6 +495,7 @@ public class ToggleCommand extends CommandBase implements ICommand {
DankersSkyblockMod.TYPE_COLOUR + " Teammates in radius: " + DankersSkyblockMod.VALUE_COLOUR + teammatesInRadius + "\n" +
DankersSkyblockMod.TYPE_COLOUR + " Giant HP display: " + DankersSkyblockMod.VALUE_COLOUR + giantHP + "\n" +
DankersSkyblockMod.TYPE_COLOUR + " Hide pet candy: " + DankersSkyblockMod.VALUE_COLOUR + hidePetCandy + "\n" +
+ DankersSkyblockMod.TYPE_COLOUR + " Highlight commissions: " + DankersSkyblockMod.VALUE_COLOUR + highlightCommissions + "\n" +
DankersSkyblockMod.TYPE_COLOUR + " Custom dungeon boss music: " + DankersSkyblockMod.VALUE_COLOUR + dungeonBossMusic + "\n" +
DankersSkyblockMod.TYPE_COLOUR + " Custom blood room music: " + DankersSkyblockMod.VALUE_COLOUR + bloodRoomMusic + "\n" +
DankersSkyblockMod.TYPE_COLOUR + " Custom dungeon music: " + DankersSkyblockMod.VALUE_COLOUR + dungeonMusic
diff --git a/src/main/java/me/Danker/commands/warp/Crypt.java b/src/main/java/me/Danker/commands/warp/Crypt.java
new file mode 100644
index 0000000..88f286b
--- /dev/null
+++ b/src/main/java/me/Danker/commands/warp/Crypt.java
@@ -0,0 +1,47 @@
+package me.Danker.commands.warp;
+
+import me.Danker.utils.Utils;
+import net.minecraft.client.Minecraft;
+import net.minecraft.command.CommandBase;
+import net.minecraft.command.CommandException;
+import net.minecraft.command.ICommandSender;
+import net.minecraft.entity.player.EntityPlayer;
+import net.minecraft.util.BlockPos;
+
+import java.util.List;
+
+public class Crypt extends CommandBase {
+ @Override
+ public String getCommandName() {
+ return "crypt";
+ }
+
+ @Override
+ public String getCommandUsage(ICommandSender sender) {
+ return "/" + getCommandName();
+ }
+
+ public static String usage(ICommandSender arg0) {
+ return new me.Danker.commands.warp.Crypt().getCommandUsage(arg0);
+ }
+
+ @Override
+ public int getRequiredPermissionLevel() {
+ return 0;
+ }
+
+ @Override
+ public List<String> addTabCompletionOptions(ICommandSender sender, String[] args, BlockPos pos) {
+ return null;
+ }
+
+ @Override
+ public void processCommand(ICommandSender sender, String[] args) throws CommandException {
+ if (!Utils.inSkyblock) return;
+ EntityPlayer player = ((EntityPlayer) sender);
+ // MULTI THREAD DRIFTING
+ new Thread(() -> {
+ Minecraft.getMinecraft().thePlayer.sendChatMessage("/warp crypt");
+ }).start();
+ }
+}
diff --git a/src/main/java/me/Danker/commands/warp/DarkAuction.java b/src/main/java/me/Danker/commands/warp/DarkAuction.java
new file mode 100644
index 0000000..40218d8
--- /dev/null
+++ b/src/main/java/me/Danker/commands/warp/DarkAuction.java
@@ -0,0 +1,48 @@
+package me.Danker.commands.warp;
+
+import me.Danker.DankersSkyblockMod;
+import me.Danker.utils.Utils;
+import net.minecraft.client.Minecraft;
+import net.minecraft.command.CommandBase;
+import net.minecraft.command.CommandException;
+import net.minecraft.command.ICommandSender;
+import net.minecraft.entity.player.EntityPlayer;
+import net.minecraft.util.BlockPos;
+
+import java.util.List;
+
+public class DarkAuction extends CommandBase {
+ @Override
+ public String getCommandName() {
+ return "da";
+ }
+
+ @Override
+ public String getCommandUsage(ICommandSender sender) {
+ return "/" + getCommandName();
+ }
+
+ public static String usage(ICommandSender arg0) {
+ return new me.Danker.commands.warp.DarkAuction().getCommandUsage(arg0);
+ }
+
+ @Override
+ public int getRequiredPermissionLevel() {
+ return 0;
+ }
+
+ @Override
+ public List<String> addTabCompletionOptions(ICommandSender sender, String[] args, BlockPos pos) {
+ return null;
+ }
+
+ @Override
+ public void processCommand(ICommandSender sender, String[] args) throws CommandException {
+ if (!Utils.inSkyblock) return;
+ EntityPlayer player = ((EntityPlayer) sender);
+ // MULTI THREAD DRIFTING
+ new Thread(() -> {
+ Minecraft.getMinecraft().thePlayer.sendChatMessage("/warp da");
+ }).start();
+ }
+}
diff --git a/src/main/java/me/Danker/commands/warp/Dragon.java b/src/main/java/me/Danker/commands/warp/Dragon.java
new file mode 100644
index 0000000..f36bef1
--- /dev/null
+++ b/src/main/java/me/Danker/commands/warp/Dragon.java
@@ -0,0 +1,48 @@
+package me.Danker.commands.warp;
+
+import me.Danker.DankersSkyblockMod;
+import me.Danker.utils.Utils;
+import net.minecraft.client.Minecraft;
+import net.minecraft.command.CommandBase;
+import net.minecraft.command.CommandException;
+import net.minecraft.command.ICommandSender;
+import net.minecraft.entity.player.EntityPlayer;
+import net.minecraft.util.BlockPos;
+
+import java.util.List;
+
+public class Dragon extends CommandBase {
+ @Override
+ public String getCommandName() {
+ return "drag";
+ }
+
+ @Override
+ public String getCommandUsage(ICommandSender sender) {
+ return "/" + getCommandName();
+ }
+
+ public static String usage(ICommandSender arg0) {
+ return new me.Danker.commands.warp.DarkAuction().getCommandUsage(arg0);
+ }
+
+ @Override
+ public int getRequiredPermissionLevel() {
+ return 0;
+ }
+
+ @Override
+ public List<String> addTabCompletionOptions(ICommandSender sender, String[] args, BlockPos pos) {
+ return null;
+ }
+
+ @Override
+ public void processCommand(ICommandSender sender, String[] args) throws CommandException {
+ if (!Utils.inSkyblock) return;
+ EntityPlayer player = ((EntityPlayer) sender);
+ // MULTI THREAD DRIFTING
+ new Thread(() -> {
+ Minecraft.getMinecraft().thePlayer.sendChatMessage("/warp drag");
+ }).start();
+ }
+}
diff --git a/src/main/java/me/Danker/commands/warp/DungeonHub.java b/src/main/java/me/Danker/commands/warp/DungeonHub.java
new file mode 100644
index 0000000..cc1c082
--- /dev/null
+++ b/src/main/java/me/Danker/commands/warp/DungeonHub.java
@@ -0,0 +1,48 @@
+package me.Danker.commands.warp;
+
+import me.Danker.DankersSkyblockMod;
+import me.Danker.utils.Utils;
+import net.minecraft.client.Minecraft;
+import net.minecraft.command.CommandBase;
+import net.minecraft.command.CommandException;
+import net.minecraft.command.ICommandSender;
+import net.minecraft.entity.player.EntityPlayer;
+import net.minecraft.util.BlockPos;
+
+import java.util.List;
+
+public class DungeonHub extends CommandBase {
+ @Override
+ public String getCommandName() {
+ return "dun";
+ }
+
+ @Override
+ public String getCommandUsage(ICommandSender sender) {
+ return "/" + getCommandName();
+ }
+
+ public static String usage(ICommandSender arg0) {
+ return new me.Danker.commands.warp.DungeonHub().getCommandUsage(arg0);
+ }
+
+ @Override
+ public int getRequiredPermissionLevel() {
+ return 0;
+ }
+
+ @Override
+ public List<String> addTabCompletionOptions(ICommandSender sender, String[] args, BlockPos pos) {
+ return null;
+ }
+
+ @Override
+ public void processCommand(ICommandSender sender, String[] args) throws CommandException {
+ if (!Utils.inSkyblock) return;
+ EntityPlayer player = ((EntityPlayer) sender);
+ // MULTI THREAD DRIFTING
+ new Thread(() -> {
+ Minecraft.getMinecraft().thePlayer.sendChatMessage("/warp dungeon_hub");
+ }).start();
+ }
+}
diff --git a/src/main/java/me/Danker/commands/warp/HowlingCave.java b/src/main/java/me/Danker/commands/warp/HowlingCave.java
new file mode 100644
index 0000000..4cdcf97
--- /dev/null
+++ b/src/main/java/me/Danker/commands/warp/HowlingCave.java
@@ -0,0 +1,47 @@
+package me.Danker.commands.warp;
+
+import me.Danker.utils.Utils;
+import net.minecraft.client.Minecraft;
+import net.minecraft.command.CommandBase;
+import net.minecraft.command.CommandException;
+import net.minecraft.command.ICommandSender;
+import net.minecraft.entity.player.EntityPlayer;
+import net.minecraft.util.BlockPos;
+
+import java.util.List;
+
+public class HowlingCave extends CommandBase {
+ @Override
+ public String getCommandName() {
+ return "howl";
+ }
+
+ @Override
+ public String getCommandUsage(ICommandSender sender) {
+ return "/" + getCommandName();
+ }
+
+ public static String usage(ICommandSender arg0) {
+ return new me.Danker.commands.warp.HowlingCave().getCommandUsage(arg0);
+ }
+
+ @Override
+ public int getRequiredPermissionLevel() {
+ return 0;
+ }
+
+ @Override
+ public List<String> addTabCompletionOptions(ICommandSender sender, String[] args, BlockPos pos) {
+ return null;
+ }
+
+ @Override
+ public void processCommand(ICommandSender sender, String[] args) throws CommandException {
+ if (!Utils.inSkyblock) return;
+ EntityPlayer player = ((EntityPlayer) sender);
+ // MULTI THREAD DRIFTING
+ new Thread(() -> {
+ Minecraft.getMinecraft().thePlayer.sendChatMessage("/warp howl");
+ }).start();
+ }
+}
diff --git a/src/main/java/me/Danker/commands/warp/Magma.java b/src/main/java/me/Danker/commands/warp/Magma.java
new file mode 100644
index 0000000..96ead00
--- /dev/null
+++ b/src/main/java/me/Danker/commands/warp/Magma.java
@@ -0,0 +1,47 @@
+package me.Danker.commands.warp;
+
+import me.Danker.utils.Utils;
+import net.minecraft.client.Minecraft;
+import net.minecraft.command.CommandBase;
+import net.minecraft.command.CommandException;
+import net.minecraft.command.ICommandSender;
+import net.minecraft.entity.player.EntityPlayer;
+import net.minecraft.util.BlockPos;
+
+import java.util.List;
+
+public class Magma extends CommandBase {
+ @Override
+ public String getCommandName() {
+ return "magma";
+ }
+
+ @Override
+ public String getCommandUsage(ICommandSender sender) {
+ return "/" + getCommandName();
+ }
+
+ public static String usage(ICommandSender arg0) {
+ return new me.Danker.commands.warp.Magma().getCommandUsage(arg0);
+ }
+
+ @Override
+ public int getRequiredPermissionLevel() {
+ return 0;
+ }
+
+ @Override
+ public List<String> addTabCompletionOptions(ICommandSender sender, String[] args, BlockPos pos) {
+ return null;
+ }
+
+ @Override
+ public void processCommand(ICommandSender sender, String[] args) throws CommandException {
+ if (!Utils.inSkyblock) return;
+ EntityPlayer player = ((EntityPlayer) sender);
+ // MULTI THREAD DRIFTING
+ new Thread(() -> {
+ Minecraft.getMinecraft().thePlayer.sendChatMessage("/warp magma");
+ }).start();
+ }
+}
diff --git a/src/main/java/me/Danker/commands/warp/SpidersNest.java b/src/main/java/me/Danker/commands/warp/SpidersNest.java
new file mode 100644
index 0000000..2f091ad
--- /dev/null
+++ b/src/main/java/me/Danker/commands/warp/SpidersNest.java
@@ -0,0 +1,47 @@
+package me.Danker.commands.warp;
+
+import me.Danker.utils.Utils;
+import net.minecraft.client.Minecraft;
+import net.minecraft.command.CommandBase;
+import net.minecraft.command.CommandException;
+import net.minecraft.command.ICommandSender;
+import net.minecraft.entity.player.EntityPlayer;
+import net.minecraft.util.BlockPos;
+
+import java.util.List;
+
+public class SpidersNest extends CommandBase {
+ @Override
+ public String getCommandName() {
+ return "nest";
+ }
+
+ @Override
+ public String getCommandUsage(ICommandSender sender) {
+ return "/" + getCommandName();
+ }
+
+ public static String usage(ICommandSender arg0) {
+ return new me.Danker.commands.warp.SpidersNest().getCommandUsage(arg0);
+ }
+
+ @Override
+ public int getRequiredPermissionLevel() {
+ return 0;
+ }
+
+ @Override
+ public List<String> addTabCompletionOptions(ICommandSender sender, String[] args, BlockPos pos) {
+ return null;
+ }
+
+ @Override
+ public void processCommand(ICommandSender sender, String[] args) throws CommandException {
+ if (!Utils.inSkyblock) return;
+ EntityPlayer player = ((EntityPlayer) sender);
+ // MULTI THREAD DRIFTING
+ new Thread(() -> {
+ Minecraft.getMinecraft().thePlayer.sendChatMessage("/warp nest");
+ }).start();
+ }
+}
diff --git a/src/main/java/me/Danker/features/HighlightCommissions.java b/src/main/java/me/Danker/features/HighlightCommissions.java
new file mode 100644
index 0000000..ae262c3
--- /dev/null
+++ b/src/main/java/me/Danker/features/HighlightCommissions.java
@@ -0,0 +1,37 @@
+package me.Danker.features;
+
+import me.Danker.commands.ToggleCommand;
+import me.Danker.events.GuiChestBackgroundDrawnEvent;
+import me.Danker.handlers.ConfigHandler;
+import me.Danker.utils.Utils;
+import net.minecraft.inventory.Slot;
+import net.minecraftforge.fml.common.eventhandler.SubscribeEvent;
+import net.minecraft.item.ItemWritableBook;
+
+import org.lwjgl.util.Color;
+import java.util.List;
+
+public class HighlightCommissions {
+
+ @SubscribeEvent
+ public void onGuiRender(GuiChestBackgroundDrawnEvent event) {
+ if(!Utils.inSkyblock) return;
+ if(!ToggleCommand.highlightCommissions) return;
+ List<Slot> slots = event.slots;
+ if (!event.displayName.equals("Commissions")) return;
+
+ for (Slot slot : slots) {
+ if (slot != null && slot.getStack() == null) continue;
+ if (slot.getStack().getItem() instanceof ItemWritableBook) {
+ for (String line : Utils.getItemLore(slot.getStack())) {
+ if (line.contains("COMPLETED")) {
+ Utils.drawOnSlot(event.chestSize, slot.xDisplayPosition, slot.yDisplayPosition, 0x51FF51 + 0xD7000000);
+ break;
+ }
+ }
+
+ }
+ }
+ }
+
+}
diff --git a/src/main/java/me/Danker/features/SpamHider.java b/src/main/java/me/Danker/features/SpamHider.java
index a88d9e5..f1a40c9 100644
--- a/src/main/java/me/Danker/features/SpamHider.java
+++ b/src/main/java/me/Danker/features/SpamHider.java
@@ -49,7 +49,7 @@ public class SpamHider {
}
// Kill Combo
if (!ToggleCommand.killComboMessages) {
- if ((message.contains("+") && message.contains(" Kill Combo ")) || message.contains("Your Kill Combo has expired!")) {
+ if ((message.contains("+") && message.contains(" Kill Combo")) || message.contains("Your Kill Combo has expired!")) {
event.setCanceled(true);
}
}
diff --git a/src/main/java/me/Danker/gui/DankerGui.java b/src/main/java/me/Danker/gui/DankerGui.java
index 16e0640..11e8bfa 100644
--- a/src/main/java/me/Danker/gui/DankerGui.java
+++ b/src/main/java/me/Danker/gui/DankerGui.java
@@ -12,6 +12,7 @@ import net.minecraft.client.gui.GuiScreen;
import net.minecraft.client.gui.GuiTextField;
import net.minecraft.client.gui.ScaledResolution;
import net.minecraft.util.EnumChatFormatting;
+import net.minecraft.client.gui.*;
import net.minecraft.util.StringUtils;
import java.awt.*;
@@ -66,6 +67,7 @@ public class DankerGui extends GuiScreen {
private GuiButton teammatesInRadius;
private GuiButton giantHP;
private GuiButton hidePetCandy;
+ private GuiButton highlightCommissions;
// Chat Messages
private GuiButton sceptreMessages;
private GuiButton midasStaffMessages;
@@ -153,6 +155,7 @@ public class DankerGui extends GuiScreen {
teammatesInRadius = new FeatureButton("Display Players in 30 Block Radius: " + Utils.getColouredBoolean(ToggleCommand.teammatesInRadius), "Displays dungeon teammates in 30 block radius for tether and diversion.");
giantHP = new FeatureButton("Display Giant HP: " + Utils.getColouredBoolean(ToggleCommand.giantHP), "Displays health of Sadan's giants during F6 bossfight and F7 blood room.");
hidePetCandy = new FeatureButton("Hide Pet Candy: " + Utils.getColouredBoolean(ToggleCommand.hidePetCandy), "Hide pet candy in pet tooltips.");
+ highlightCommissions = new FeatureButton("Highlight Commissions: " + Utils.getColouredBoolean(ToggleCommand.highlightCommissions), "Show which commissions are completed.");
allButtons.clear();
allButtons.add(changeDisplay);
@@ -198,6 +201,7 @@ public class DankerGui extends GuiScreen {
allButtons.add(teammatesInRadius);
allButtons.add(giantHP);
allButtons.add(hidePetCandy);
+ allButtons.add(highlightCommissions);
search.setText(initSearchText);
search.setVisible(true);
@@ -440,6 +444,10 @@ public class DankerGui extends GuiScreen {
ToggleCommand.hidePetCandy = !ToggleCommand.hidePetCandy;
ConfigHandler.writeBooleanConfig("toggles", "HidePetCandy", ToggleCommand.hidePetCandy);
hidePetCandy.displayString = "Hide Pet Candy: " + Utils.getColouredBoolean(ToggleCommand.hidePetCandy);
+ } else if (button == highlightCommissions) {
+ ToggleCommand.highlightCommissions = !ToggleCommand.highlightCommissions;
+ ConfigHandler.writeBooleanConfig("toggles", "HighlightCommissions", ToggleCommand.highlightCommissions);
+ highlightCommissions.displayString = "Highlight Commissions: " + Utils.getColouredBoolean(ToggleCommand.highlightCommissions);
}
}
diff --git a/src/main/java/me/Danker/handlers/ConfigHandler.java b/src/main/java/me/Danker/handlers/ConfigHandler.java
index db33cb2..ecd15f3 100644
--- a/src/main/java/me/Danker/handlers/ConfigHandler.java
+++ b/src/main/java/me/Danker/handlers/ConfigHandler.java
@@ -210,6 +210,7 @@ public class ConfigHandler {
ToggleCommand.melodyTooltips = initBoolean("toggles", "MelodyTooltips", false);
ToggleCommand.highlightSlayers = initBoolean("toggles", "HighlightSlayers", false);
ToggleCommand.highlightArachne = initBoolean("toggles", "HighlightArachne", false);
+ ToggleCommand.highlightCommissions = initBoolean("toggles", "HighlightCommissions", false);
ToggleCommand.highlightSkeletonMasters = initBoolean("toggles", "HighlightSkeletonMasters", false);
ToggleCommand.teammatesInRadius = initBoolean("toggles", "TeammatesInRadius", false);
ToggleCommand.giantHP = initBoolean("toggles", "GiantHP", false);