From 07a7541a2661a2c61b6f2146799e43539ade4728 Mon Sep 17 00:00:00 2001 From: Avi Weinstock Date: Fri, 10 Sep 2021 21:02:52 -0400 Subject: [PATCH] More TDs fixes: - Increase TDs aggro range - Add proper music for the Ancient Guthix Temple. - Add a kill counter for TDs, and replace Bork with it in `::stats`. --- Server/data/configs/music_configs.json | 12 ++++++++++++ .../core/game/content/global/BossKillCounter.java | 7 ++++++- .../node/entity/npc/bosses/TormentedDemonNPC.java | 10 ++++++++++ .../node/entity/player/info/stats/StatsCommandSet.kt | 4 ++-- 4 files changed, 30 insertions(+), 3 deletions(-) diff --git a/Server/data/configs/music_configs.json b/Server/data/configs/music_configs.json index 0a66a3f51..078efa2cc 100644 --- a/Server/data/configs/music_configs.json +++ b/Server/data/configs/music_configs.json @@ -2278,5 +2278,17 @@ "name": "Volcanic Vikings", "indexId": "440", "borders": "{2304,3785,2635,3818}" + }, + { + "id": "584", + "name": "Temple Desecrated", + "indexId": "628", + "borders": "{2580,5763,2620,5700}" + }, + { + "id": "589", + "name": "The Sound of Guthix", + "indexId": "626", + "borders": "{2500,5766,2620,5810}" } ] diff --git a/Server/src/main/java/core/game/content/global/BossKillCounter.java b/Server/src/main/java/core/game/content/global/BossKillCounter.java index 49acae21f..319b0dcdb 100644 --- a/Server/src/main/java/core/game/content/global/BossKillCounter.java +++ b/Server/src/main/java/core/game/content/global/BossKillCounter.java @@ -25,6 +25,11 @@ public enum BossKillCounter { JAD(new int[] { 2745 }, "Tz-Tok Jad", 14828), KALPHITE_QUEEN(new int[] { 1160 }, "Kalphite Queen", 14650), CORPOREAL_BEAST(new int[] { 8133 }, "Corporeal Beast", 14653), + TORMENTED_DEMONS(new int[] { + 8349, 8350, 8351, 8352, 8353, 8354, + 8355, 8356, 8357, 8358, 8359, 8360, + 8361, 8362, 8363, 8364, 8365, 8366, + }, "Tormented demon", -1), CALLISTO(new int[] { 8610 }, "Callisto", 14658), SCORPIA(new int[] { 8611 }, "Scorpia", 14661), VENENATIS(new int[] { 8612 }, "Venenatis", 14657), @@ -169,4 +174,4 @@ public enum BossKillCounter { player.getPacketDispatch().sendMessage("Your Barrows chest count is: " + player.getSavedData().getGlobalData().getBarrowsLoots() + "."); } -} \ No newline at end of file +} diff --git a/Server/src/main/java/core/game/node/entity/npc/bosses/TormentedDemonNPC.java b/Server/src/main/java/core/game/node/entity/npc/bosses/TormentedDemonNPC.java index 0273d6559..c1652870c 100644 --- a/Server/src/main/java/core/game/node/entity/npc/bosses/TormentedDemonNPC.java +++ b/Server/src/main/java/core/game/node/entity/npc/bosses/TormentedDemonNPC.java @@ -2,6 +2,7 @@ package core.game.node.entity.npc.bosses; import java.util.concurrent.TimeUnit; +import core.game.content.global.BossKillCounter; import core.game.node.entity.Entity; import core.game.node.entity.combat.BattleState; import core.game.node.entity.combat.CombatStyle; @@ -63,6 +64,14 @@ public class TormentedDemonNPC extends AbstractNPC { */ private final int[] damageLog = new int[3]; + @Override + public void init() { + super.init(); + getAggressiveHandler().setChanceRatio(10); + getAggressiveHandler().setRadius(64); + getAggressiveHandler().setAllowTolerance(false); + } + /** * Constructs a new {@Code TormentedDemonNPC} {@Code Object} */ @@ -162,6 +171,7 @@ public class TormentedDemonNPC extends AbstractNPC { super.finalizeDeath(killer); reTransform(); fireShield = true; + BossKillCounter.addtoKillcount((Player) killer, this.getId()); } @Override diff --git a/Server/src/main/kotlin/rs09/game/node/entity/player/info/stats/StatsCommandSet.kt b/Server/src/main/kotlin/rs09/game/node/entity/player/info/stats/StatsCommandSet.kt index 50756dac3..8ea7c07ec 100644 --- a/Server/src/main/kotlin/rs09/game/node/entity/player/info/stats/StatsCommandSet.kt +++ b/Server/src/main/kotlin/rs09/game/node/entity/player/info/stats/StatsCommandSet.kt @@ -57,7 +57,7 @@ class StatsCommandSet : CommandSet(Command.Privilege.STANDARD) { //Boss KC 82 -> sendLine(player, "KBD KC: ${globalData.bossCounters.get(BossKillCounter.KING_BLACK_DRAGON.ordinal)}",i) - 83 -> sendLine(player, "Bork KC: ${globalData.bossCounters.get(BossKillCounter.BORK.ordinal)}",i) + 83 -> sendLine(player, "TDs KC: ${globalData.bossCounters.get(BossKillCounter.TORMENTED_DEMONS.ordinal)}",i) 84 -> sendLine(player, "Supreme KC: ${globalData.bossCounters.get(BossKillCounter.DAGANNOTH_SUPREME.ordinal)}",i) 85 -> sendLine(player, "Rex KC: ${globalData.bossCounters.get(BossKillCounter.DAGANNOTH_REX.ordinal)}",i) 86 -> sendLine(player, "Prime KC: ${globalData.bossCounters.get(BossKillCounter.DAGANNOTH_PRIME.ordinal)}",i) @@ -88,4 +88,4 @@ class StatsCommandSet : CommandSet(Command.Privilege.STANDARD) { player.packetDispatch.sendInterfaceConfig(26,66,true) player.packetDispatch.sendString(other.username + "'s Stats",26,101) } -} \ No newline at end of file +}