From ef4074c6f9166c330ee9d02214ac463477fae027 Mon Sep 17 00:00:00 2001 From: Kyleeld <48519776+Kyleeld@users.noreply.github.com> Date: Sun, 28 Jul 2019 22:41:10 +0100 Subject: [PATCH] Impling: crystal impling (#1139) * Impling: add crystal impling Impling: add crystal impling * Update Impling.java * Update ImplingsConfig.java * Update ImplingsPlugin.java * Update Impling.java * Update Impling.java --- .../client/plugins/implings/Impling.java | 21 ++++++++++ .../client/plugins/implings/ImplingType.java | 1 + .../plugins/implings/ImplingsConfig.java | 38 +++++++++++++++---- .../plugins/implings/ImplingsPlugin.java | 8 ++++ 4 files changed, 60 insertions(+), 8 deletions(-) diff --git a/runelite-client/src/main/java/net/runelite/client/plugins/implings/Impling.java b/runelite-client/src/main/java/net/runelite/client/plugins/implings/Impling.java index 473fad2c23..968a50c869 100644 --- a/runelite-client/src/main/java/net/runelite/client/plugins/implings/Impling.java +++ b/runelite-client/src/main/java/net/runelite/client/plugins/implings/Impling.java @@ -60,12 +60,33 @@ enum Impling NINJA(ImplingType.NINJA, NpcID.NINJA_IMPLING), NINJA_2(ImplingType.NINJA, NpcID.NINJA_IMPLING_1653), + + CRYSTAL(ImplingType.CRYSTAL, NpcID.CRYSTAL_IMPLING), + CRYSTAL_2(ImplingType.CRYSTAL, NpcID.CRYSTAL_IMPLING_8742), + CRYSTAL_3(ImplingType.CRYSTAL, NpcID.CRYSTAL_IMPLING_8743), + CRYSTAL_4(ImplingType.CRYSTAL, NpcID.CRYSTAL_IMPLING_8744), + CRYSTAL_5(ImplingType.CRYSTAL, NpcID.CRYSTAL_IMPLING_8745), + CRYSTAL_6(ImplingType.CRYSTAL, NpcID.CRYSTAL_IMPLING_8746), + CRYSTAL_7(ImplingType.CRYSTAL, NpcID.CRYSTAL_IMPLING_8747), + CRYSTAL_8(ImplingType.CRYSTAL, NpcID.CRYSTAL_IMPLING_8748), + CRYSTAL_9(ImplingType.CRYSTAL, NpcID.CRYSTAL_IMPLING_8749), + CRYSTAL_10(ImplingType.CRYSTAL, NpcID.CRYSTAL_IMPLING_8750), + CRYSTAL_11(ImplingType.CRYSTAL, NpcID.CRYSTAL_IMPLING_8751), + CRYSTAL_12(ImplingType.CRYSTAL, NpcID.CRYSTAL_IMPLING_8752), + CRYSTAL_13(ImplingType.CRYSTAL, NpcID.CRYSTAL_IMPLING_8753), + CRYSTAL_14(ImplingType.CRYSTAL, NpcID.CRYSTAL_IMPLING_8754), + CRYSTAL_15(ImplingType.CRYSTAL, NpcID.CRYSTAL_IMPLING_8755), + CRYSTAL_16(ImplingType.CRYSTAL, NpcID.CRYSTAL_IMPLING_8756), + CRYSTAL_17(ImplingType.CRYSTAL, NpcID.CRYSTAL_IMPLING_8757), + DRAGON(ImplingType.DRAGON, NpcID.DRAGON_IMPLING), DRAGON_2(ImplingType.DRAGON, NpcID.DRAGON_IMPLING_1654), LUCKY(ImplingType.LUCKY, NpcID.LUCKY_IMPLING), LUCKY_2(ImplingType.LUCKY, NpcID.LUCKY_IMPLING_7302); + + private ImplingType implingType; private final int npcId; diff --git a/runelite-client/src/main/java/net/runelite/client/plugins/implings/ImplingType.java b/runelite-client/src/main/java/net/runelite/client/plugins/implings/ImplingType.java index 787adcc46a..8a98bd7186 100644 --- a/runelite-client/src/main/java/net/runelite/client/plugins/implings/ImplingType.java +++ b/runelite-client/src/main/java/net/runelite/client/plugins/implings/ImplingType.java @@ -41,6 +41,7 @@ enum ImplingType NATURE("Nature"), MAGPIE("Magpie"), NINJA("Ninja"), + CRYSTAL("Crystal"), DRAGON("Dragon"), LUCKY("Lucky"); diff --git a/runelite-client/src/main/java/net/runelite/client/plugins/implings/ImplingsConfig.java b/runelite-client/src/main/java/net/runelite/client/plugins/implings/ImplingsConfig.java index 386284a874..d538509825 100644 --- a/runelite-client/src/main/java/net/runelite/client/plugins/implings/ImplingsConfig.java +++ b/runelite-client/src/main/java/net/runelite/client/plugins/implings/ImplingsConfig.java @@ -232,9 +232,31 @@ public interface ImplingsConfig extends Config { return new Color(71, 70, 75); } - + @ConfigItem( position = 19, + keyName = "showcrystal", + name = "Show Crystal implings", + description = "Configures whether or not Crystal impling tags are displayed" + ) + default boolean showCrystal() + { + return false; + } + + @ConfigItem( + position = 20, + keyName = "crystalColor", + name = "Crystal impling color", + description = "Text color for Crystal implings" + ) + default Color getCrystalColor() + { + return new Color(2, 255, 251); + } + + @ConfigItem( + position = 21, keyName = "showdragon", name = "Show Dragon implings", description = "Configures whether or not Dragon impling tags are displayed" @@ -245,7 +267,7 @@ public interface ImplingsConfig extends Config } @ConfigItem( - position = 20, + position = 22, keyName = "dragonColor", name = "Dragon impling color", description = "Text color for Dragon implings" @@ -256,7 +278,7 @@ public interface ImplingsConfig extends Config } @ConfigItem( - position = 21, + position = 23, keyName = "showlucky", name = "Show Lucky implings", description = "Configures whether or not Lucky impling tags are displayed" @@ -267,7 +289,7 @@ public interface ImplingsConfig extends Config } @ConfigItem( - position = 22, + position = 24, keyName = "luckyColor", name = "Lucky impling color", description = "Text color for Lucky implings" @@ -278,7 +300,7 @@ public interface ImplingsConfig extends Config } @ConfigItem( - position = 23, + position = 25, keyName = "showspawn", name = "Show Spawn locations", description = "Configures whether or not spawn locations are displayed in Puro Puro" @@ -289,7 +311,7 @@ public interface ImplingsConfig extends Config } @ConfigItem( - position = 24, + position = 26, keyName = "spawnColor", name = "Impling spawn color", description = "Text color for impling spawns in Puro Puro" @@ -300,7 +322,7 @@ public interface ImplingsConfig extends Config } @ConfigItem( - position = 25, + position = 27, keyName = "showname", name = "Show name on minimap", description = "Configures whether or not impling names are displayed on minimap" @@ -311,7 +333,7 @@ public interface ImplingsConfig extends Config } @ConfigItem( - position = 26, + position = 28, keyName = "spawnColorDynamic", name = "Impling dynamic spawn color", description = "Text color for dynamic impling spawns in Puro Puro" diff --git a/runelite-client/src/main/java/net/runelite/client/plugins/implings/ImplingsPlugin.java b/runelite-client/src/main/java/net/runelite/client/plugins/implings/ImplingsPlugin.java index d005a30af3..7c1f3077de 100644 --- a/runelite-client/src/main/java/net/runelite/client/plugins/implings/ImplingsPlugin.java +++ b/runelite-client/src/main/java/net/runelite/client/plugins/implings/ImplingsPlugin.java @@ -105,6 +105,8 @@ public class ImplingsPlugin extends Plugin private Color getMagpieColor; private boolean showNinja; private Color getNinjaColor; + private boolean showCrystal; + private Color getCrystalColor; private boolean showDragon; private Color getDragonColor; private boolean showLucky; @@ -260,6 +262,8 @@ public class ImplingsPlugin extends Plugin return this.showMagpie; case NINJA: return this.showNinja; + case CRYSTAL: + return this.showCrystal; case DRAGON: return this.showDragon; case LUCKY: @@ -303,6 +307,8 @@ public class ImplingsPlugin extends Plugin return this.getMagpieColor; case NINJA: return this.getNinjaColor; + case CRYSTAL: + return this.getCrystalColor; case DRAGON: return this.getDragonColor; case LUCKY: @@ -342,6 +348,8 @@ public class ImplingsPlugin extends Plugin this.getMagpieColor = config.getMagpieColor(); this.showNinja = config.showNinja(); this.getNinjaColor = config.getNinjaColor(); + this.showCrystal = config.showCrystal(); + this.getCrystalColor = config.getCrystalColor(); this.showDragon = config.showDragon(); this.getDragonColor = config.getDragonColor(); this.showLucky = config.showLucky();