aboutsummaryrefslogtreecommitdiff
path: root/src/main/java/me/Danker/commands
diff options
context:
space:
mode:
authorbowser0000 <bowser0000@gmail.com>2021-04-29 01:06:57 -0400
committerbowser0000 <bowser0000@gmail.com>2021-04-29 01:06:57 -0400
commit01822bff56d23b98885227943bd1e042e4f9e946 (patch)
tree5931c2b8a3df8ca25a5747fdc273a06c6102fa48 /src/main/java/me/Danker/commands
parentb48dabaf8ab58773eb51a1c2077b880ee1f28675 (diff)
downloadSkyblockMod-01822bff56d23b98885227943bd1e042e4f9e946.tar.gz
SkyblockMod-01822bff56d23b98885227943bd1e042e4f9e946.tar.bz2
SkyblockMod-01822bff56d23b98885227943bd1e042e4f9e946.zip
Add giant hp display
Also make LocationButton easy to add
Diffstat (limited to 'src/main/java/me/Danker/commands')
-rw-r--r--src/main/java/me/Danker/commands/DankerGuiCommand.java1
-rw-r--r--src/main/java/me/Danker/commands/MoveCommand.java13
-rw-r--r--src/main/java/me/Danker/commands/ScaleCommand.java11
-rw-r--r--src/main/java/me/Danker/commands/ToggleCommand.java11
4 files changed, 30 insertions, 6 deletions
diff --git a/src/main/java/me/Danker/commands/DankerGuiCommand.java b/src/main/java/me/Danker/commands/DankerGuiCommand.java
index 6fede04..2cc706e 100644
--- a/src/main/java/me/Danker/commands/DankerGuiCommand.java
+++ b/src/main/java/me/Danker/commands/DankerGuiCommand.java
@@ -93,6 +93,7 @@ public class DankerGuiCommand extends CommandBase {
debug.append("[highlightarachne][").append(ToggleCommand.highlightArachne).append("]\n");
debug.append("[highlightskeletonmasters][").append(ToggleCommand.highlightSkeletonMasters).append("]\n");
debug.append("[teammatesinradius][").append(ToggleCommand.teammatesInRadius).append("]\n");
+ debug.append("[gianthp][").append(ToggleCommand.giantHP).append("]\n");
debug.append("[dungeonbossmusic][").append(ToggleCommand.dungeonBossMusic).append("]\n");
debug.append("[bloodroommusic][").append(ToggleCommand.bloodRoomMusic).append("]\n");
debug.append("[dungeonmusic][").append(ToggleCommand.dungeonMusic).append("]\n");
diff --git a/src/main/java/me/Danker/commands/MoveCommand.java b/src/main/java/me/Danker/commands/MoveCommand.java
index 33d1f78..b17794c 100644
--- a/src/main/java/me/Danker/commands/MoveCommand.java
+++ b/src/main/java/me/Danker/commands/MoveCommand.java
@@ -24,6 +24,7 @@ public class MoveCommand extends CommandBase {
public static int[] bonzoTimerXY = {0, 0};
public static int[] golemTimerXY = {0 ,0};
public static int[] teammatesInRadiusXY = {0, 0};
+ public static int[] giantHPXY = {0, 0};
@Override
public String getCommandName() {
@@ -32,7 +33,7 @@ public class MoveCommand extends CommandBase {
@Override
public String getCommandUsage(ICommandSender arg0) {
- return "/" + getCommandName() + " <coords/display/dungeontimer/skill50/lividhp/caketimer/skilltracker/wateranswer/bonzotimer/golemtimer/teammatesinradius> <x> <y>";
+ return "/" + getCommandName() + " <coords/display/dungeontimer/skill50/lividhp/caketimer/skilltracker/wateranswer/bonzotimer/golemtimer/teammatesinradius/gianthp> <x> <y>";
}
public static String usage(ICommandSender arg0) {
@@ -48,7 +49,8 @@ public class MoveCommand extends CommandBase {
public List<String> addTabCompletionOptions(ICommandSender sender, String[] args, BlockPos pos) {
if (args.length == 1) {
return getListOfStringsMatchingLastWord(args, "coords", "display", "dungeontimer", "skill50", "lividhp", "caketimer",
- "skilltracker", "wateranswer", "bonzotimer", "golemtimer", "teammatesinradius");
+ "skilltracker", "wateranswer", "bonzotimer", "golemtimer", "teammatesinradius",
+ "gianthp");
}
return null;
}
@@ -140,6 +142,13 @@ public class MoveCommand extends CommandBase {
ConfigHandler.writeIntConfig("locations", "teammatesInRadiusY", teammatesInRadiusXY[1]);
player.addChatMessage(new ChatComponentText(DankersSkyblockMod.MAIN_COLOUR + "Teammates in radius has been moved to " + DankersSkyblockMod.SECONDARY_COLOUR + arg1[1] + ", " + arg1[2]));
break;
+ case "gianthp":
+ giantHPXY[0] = Integer.parseInt(arg1[1]);
+ giantHPXY[1] = Integer.parseInt(arg1[2]);
+ ConfigHandler.writeIntConfig("locations", "giantHPX", giantHPXY[0]);
+ ConfigHandler.writeIntConfig("locations", "giantHPY", giantHPXY[1]);
+ player.addChatMessage(new ChatComponentText(DankersSkyblockMod.MAIN_COLOUR + "Giant HP has been moved to " + DankersSkyblockMod.SECONDARY_COLOUR + arg1[1] + ", " + arg1[2]));
+ break;
default:
player.addChatMessage(new ChatComponentText(DankersSkyblockMod.ERROR_COLOUR + "Usage: " + getCommandUsage(arg0)));
}
diff --git a/src/main/java/me/Danker/commands/ScaleCommand.java b/src/main/java/me/Danker/commands/ScaleCommand.java
index a95f1b1..def0e57 100644
--- a/src/main/java/me/Danker/commands/ScaleCommand.java
+++ b/src/main/java/me/Danker/commands/ScaleCommand.java
@@ -24,6 +24,7 @@ public class ScaleCommand extends CommandBase {
public static double bonzoTimerScale;
public static double golemTimerScale;
public static double teammatesInRadiusScale;
+ public static double giantHPScale;
@Override
public String getCommandName() {
@@ -32,7 +33,7 @@ public class ScaleCommand extends CommandBase {
@Override
public String getCommandUsage(ICommandSender arg0) {
- return "/" + getCommandName() + " <coords/display/dungeontimer/skill50/lividhp/caketimer/skilltracker/wateranswer/bonzotimer/golemtimer/teammatesinradius> <size (0.1 - 10)>";
+ return "/" + getCommandName() + " <coords/display/dungeontimer/skill50/lividhp/caketimer/skilltracker/wateranswer/bonzotimer/golemtimer/teammatesinradius/gianthp> <size (0.1 - 10)>";
}
public static String usage(ICommandSender arg0) {
@@ -48,7 +49,8 @@ public class ScaleCommand extends CommandBase {
public List<String> addTabCompletionOptions(ICommandSender sender, String[] args, BlockPos pos) {
if (args.length == 1) {
return getListOfStringsMatchingLastWord(args, "coords", "display", "dungeontimer", "skill50", "lividhp", "caketimer",
- "skilltracker", "wateranswer", "bonzotimer", "golemtimer", "teammatesinradius");
+ "skilltracker", "wateranswer", "bonzotimer", "golemtimer", "teammatesinradius",
+ "gianthp");
}
return null;
}
@@ -124,6 +126,11 @@ public class ScaleCommand extends CommandBase {
ConfigHandler.writeDoubleConfig("scales", "teammatesInRadiusScale", teammatesInRadiusScale);
player.addChatMessage(new ChatComponentText(DankersSkyblockMod.MAIN_COLOUR + "Teammates in radius has been scaled to " + DankersSkyblockMod.SECONDARY_COLOUR + teammatesInRadiusScale + "x"));
break;
+ case "gianthp":
+ giantHPScale = scaleAmount;
+ ConfigHandler.writeDoubleConfig("scales", "giantHPScale", giantHPScale);
+ player.addChatMessage(new ChatComponentText(DankersSkyblockMod.MAIN_COLOUR + "Giant hp has been scaled to " + DankersSkyblockMod.SECONDARY_COLOUR + giantHPScale + "x"));
+ break;
default:
player.addChatMessage(new ChatComponentText(DankersSkyblockMod.ERROR_COLOUR + "Usage: " + getCommandUsage(arg0)));
}
diff --git a/src/main/java/me/Danker/commands/ToggleCommand.java b/src/main/java/me/Danker/commands/ToggleCommand.java
index 0eb52fd..a9fe663 100644
--- a/src/main/java/me/Danker/commands/ToggleCommand.java
+++ b/src/main/java/me/Danker/commands/ToggleCommand.java
@@ -35,6 +35,7 @@ public class ToggleCommand extends CommandBase implements ICommand {
public static boolean highlightArachne;
public static boolean highlightSkeletonMasters;
public static boolean teammatesInRadius;
+ public static boolean giantHP;
// Chat Messages
public static boolean sceptreMessages;
public static boolean midasStaffMessages;
@@ -95,7 +96,7 @@ public class ToggleCommand extends CommandBase implements ICommand {
"startswithterminal/selectallterminal/clickinorderterminal/" +
"ultrasequencer/chronomatron/superpairs/hidetooltipsinaddons/pickblock/" +
"melodytooltips/highlightslayers/highlightarachne/highlightskeletonmasters/teammatesinradius/" +
- "dungeonbossmusic/bloodroommusic/dungeonmusic/list>";
+ "gianthp/dungeonbossmusic/bloodroommusic/dungeonmusic/list>";
}
public static String usage(ICommandSender arg0) {
@@ -124,7 +125,7 @@ public class ToggleCommand extends CommandBase implements ICommand {
"ultrasequencer", "chronomatron", "superpairs",
"hidetooltipsinaddons", "pickblock", "melodytooltips", "highlightslayers",
"highlightskeletonmasters", "dungeonbossmusic", "bloodroommusic", "dungeonmusic",
- "teammatesinradius", "list");
+ "teammatesinradius", "gianthp", "list");
}
return null;
}
@@ -410,6 +411,11 @@ public class ToggleCommand extends CommandBase implements ICommand {
ConfigHandler.writeBooleanConfig("toggles", "TeammatesInRadius", teammatesInRadius);
player.addChatMessage(new ChatComponentText(DankersSkyblockMod.MAIN_COLOUR + "Teammates in radius has been set to " + DankersSkyblockMod.SECONDARY_COLOUR + teammatesInRadius + DankersSkyblockMod.MAIN_COLOUR + "."));
break;
+ case "gianthp":
+ giantHP = !giantHP;
+ ConfigHandler.writeBooleanConfig("toggles", "GiantHP", giantHP);
+ player.addChatMessage(new ChatComponentText(DankersSkyblockMod.MAIN_COLOUR + "Giant HP display has been set to " + DankersSkyblockMod.SECONDARY_COLOUR + giantHP + DankersSkyblockMod.MAIN_COLOUR + "."));
+ break;
case "dungeonbossmusic":
dungeonBossMusic = !dungeonBossMusic;
CustomMusic.dungeonboss.stop();
@@ -475,6 +481,7 @@ public class ToggleCommand extends CommandBase implements ICommand {
DankersSkyblockMod.TYPE_COLOUR + " Highlight Arachne Boss: " + DankersSkyblockMod.VALUE_COLOUR + highlightArachne + "\n" +
DankersSkyblockMod.TYPE_COLOUR + " Highlight Skeleton Masters: " + DankersSkyblockMod.VALUE_COLOUR + highlightSkeletonMasters + "\n" +
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 + " 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