aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorbowser0000 <bowser0000@gmail.com>2020-12-10 15:07:49 -0500
committerbowser0000 <bowser0000@gmail.com>2020-12-10 15:07:49 -0500
commit82afdeaa57625b554850c9e0a9b06ab06bb8097d (patch)
treeb6c5438349cdba0a9942c7216d794512983db20a /src
parent0c8bda1714891bb26979f723f40db299896b1cce (diff)
downloadSkyblockMod-82afdeaa57625b554850c9e0a9b06ab06bb8097d.tar.gz
SkyblockMod-82afdeaa57625b554850c9e0a9b06ab06bb8097d.tar.bz2
SkyblockMod-82afdeaa57625b554850c9e0a9b06ab06bb8097d.zip
Add pet colors to config
Diffstat (limited to 'src')
-rw-r--r--src/main/java/me/Danker/DankersSkyblockMod.java35
-rw-r--r--src/main/java/me/Danker/handlers/ConfigHandler.java22
2 files changed, 45 insertions, 12 deletions
diff --git a/src/main/java/me/Danker/DankersSkyblockMod.java b/src/main/java/me/Danker/DankersSkyblockMod.java
index e7bc30d..3fe283c 100644
--- a/src/main/java/me/Danker/DankersSkyblockMod.java
+++ b/src/main/java/me/Danker/DankersSkyblockMod.java
@@ -166,6 +166,17 @@ public class DankersSkyblockMod
public static String TRIVIA_WRONG_ANSWER_COLOUR;
public static int LOWEST_BLAZE_COLOUR;
public static int HIGHEST_BLAZE_COLOUR;
+ public static int PET_1_TO_9;
+ public static int PET_10_TO_19;
+ public static int PET_20_TO_29;
+ public static int PET_30_TO_39;
+ public static int PET_40_TO_49;
+ public static int PET_50_TO_59;
+ public static int PET_60_TO_69;
+ public static int PET_70_TO_79;
+ public static int PET_80_TO_89;
+ public static int PET_90_TO_99;
+ public static int PET_100;
@EventHandler
public void init(FMLInitializationEvent event) {
@@ -3091,29 +3102,29 @@ public class DankersSkyblockMod
int colour;
int petLevel = Integer.parseInt(item.getDisplayName().substring(item.getDisplayName().indexOf(" ") + 1, item.getDisplayName().indexOf("]")));
if (petLevel == 100) {
- colour = 0xBFF2D249; // Gold
+ colour = PET_100;
} else if (petLevel >= 90) {
- colour = 0xBF9E794E; // Brown
+ colour = PET_90_TO_99;
} else if (petLevel >= 80) {
- colour = 0xBF5C1F35; // idk weird magenta
+ colour = PET_80_TO_89;
} else if (petLevel >= 70) {
- colour = 0xBFD64FC8; // Pink
+ colour = PET_70_TO_79;
} else if (petLevel >= 60) {
- colour = 0xBF7E4FC6; // Purple
+ colour = PET_60_TO_69;
} else if (petLevel >= 50) {
- colour = 0xBF008AD8; // Light Blue
+ colour = PET_50_TO_59;
} else if (petLevel >= 40) {
- colour = 0xBF0EAC35; // Green
+ colour = PET_40_TO_49;
} else if (petLevel >= 30) {
- colour = 0xBFFFC400; // Yellow
+ colour = PET_30_TO_39;
} else if (petLevel >= 20) {
- colour = 0xBFEF5230; // Orange
+ colour = PET_20_TO_29;
} else if (petLevel >= 10) {
- colour = 0xBFD62440; // Red
+ colour = PET_10_TO_19;
} else {
- colour = 0xBF999999; // Gray
+ colour = PET_1_TO_9;
}
- Utils.drawOnSlot(chestSize, slot.xDisplayPosition, slot.yDisplayPosition, colour);
+ Utils.drawOnSlot(chestSize, slot.xDisplayPosition, slot.yDisplayPosition, colour + 0xBF000000);
}
}
}
diff --git a/src/main/java/me/Danker/handlers/ConfigHandler.java b/src/main/java/me/Danker/handlers/ConfigHandler.java
index 23bd6c4..b2880a9 100644
--- a/src/main/java/me/Danker/handlers/ConfigHandler.java
+++ b/src/main/java/me/Danker/handlers/ConfigHandler.java
@@ -417,6 +417,17 @@ public class ConfigHandler {
if (!hasKey("colors", "triviaWrongAnswer")) writeStringConfig("colors", "triviaWrongAnswer", EnumChatFormatting.RED.toString());
if (!hasKey("colors", "blazeLowest")) writeIntConfig("colors", "blazeLowest", 0xFF0000);
if (!hasKey("colors", "blazeHighest")) writeIntConfig("colors", "blazeHighest", 0x40FF40);
+ if (!hasKey("colors", "pet1To9")) writeIntConfig("colors", "pet1To9", 0x999999); // Gray
+ if (!hasKey("colors", "pet10To19")) writeIntConfig("colors", "pet10To19", 0xD62440); // Red
+ if (!hasKey("colors", "pet20To29")) writeIntConfig("colors", "pet20To29", 0xEF5230); // Orange
+ if (!hasKey("colors", "pet30To39")) writeIntConfig("colors", "pet30To39", 0xFFC400); // Yellow
+ if (!hasKey("colors", "pet40To49")) writeIntConfig("colors", "pet40To49", 0x0EAC35); // Green
+ if (!hasKey("colors", "pet50To59")) writeIntConfig("colors", "pet50To59", 0x008AD8); // Light Blue
+ if (!hasKey("colors", "pet60To69")) writeIntConfig("colors", "pet60To69", 0x7E4FC6); // Purple
+ if (!hasKey("colors", "pet70To79")) writeIntConfig("colors", "pet70To79", 0xD64FC8); // Pink
+ if (!hasKey("colors", "pet80To89")) writeIntConfig("colors", "pet80To89", 0x5C1F35); // idk weird magenta
+ if (!hasKey("colors", "pet90To99")) writeIntConfig("colors", "pet90To99", 0x9E794E); // Brown
+ if (!hasKey("colors", "pet100")) writeIntConfig("colors", "pet100", 0xF2D249); // Gold
ToggleCommand.gpartyToggled = getBoolean("toggles", "GParty");
ToggleCommand.coordsToggled = getBoolean("toggles", "Coords");
@@ -670,6 +681,17 @@ public class ConfigHandler {
DankersSkyblockMod.TRIVIA_WRONG_ANSWER_COLOUR = getString("colors", "triviaWrongAnswer");
DankersSkyblockMod.LOWEST_BLAZE_COLOUR = getInt("colors", "blazeLowest");
DankersSkyblockMod.HIGHEST_BLAZE_COLOUR = getInt("colors", "blazeHighest");
+ DankersSkyblockMod.PET_1_TO_9 = getInt("colors", "pet1To9");
+ DankersSkyblockMod.PET_10_TO_19 = getInt("colors", "pet10To19");
+ DankersSkyblockMod.PET_20_TO_29 = getInt("colors", "pet20To29");
+ DankersSkyblockMod.PET_30_TO_39 = getInt("colors", "pet30To39");
+ DankersSkyblockMod.PET_40_TO_49 = getInt("colors", "pet40To49");
+ DankersSkyblockMod.PET_50_TO_59 = getInt("colors", "pet50To59");
+ DankersSkyblockMod.PET_60_TO_69 = getInt("colors", "pet60To69");
+ DankersSkyblockMod.PET_70_TO_79 = getInt("colors", "pet70To79");
+ DankersSkyblockMod.PET_80_TO_89 = getInt("colors", "pet80To89");
+ DankersSkyblockMod.PET_90_TO_99 = getInt("colors", "pet90To99");
+ DankersSkyblockMod.PET_100 = getInt("colors", "pet100");
}
}