Zamorak robe top and bottom now count as Zamorak god items

Zamorak robe top and bottom now allowed into Entrana
Implemented the right-click take-boat options for the monks of Entrana
Fixed some silly typos in the Monk-of-Entrana dialogue
Removed unused god item definitions
This commit is contained in:
Player Name
2025-02-16 10:23:21 +00:00
committed by Ryan
parent 4f97dbef8c
commit 2d1a626df0
5 changed files with 72 additions and 16 deletions
@@ -41,6 +41,11 @@ public final class MonkOfEntranaDialogue extends DialoguePlugin {
return new MonkOfEntranaDialogue(player);
}
public void sail(Player player, Ships ship) {
ship.sail(player);
playJingle(player, 172);
}
@Override
public boolean open(Object... args) {
npc = (NPC) args[0];
@@ -98,7 +103,7 @@ public final class MonkOfEntranaDialogue extends DialoguePlugin {
stage = 25;
break;
case 23:
interpreter.sendDialogues(npc, null, "Do not try and decieve us again. Come back when you", "have liad down your Zamorakian instruments of death.");
interpreter.sendDialogues(npc, null, "Do not try to deceive us again. Come back when you", "have laid down your Zamorakian instruments of death.");
stage = 24;
break;
case 24:
@@ -106,8 +111,7 @@ public final class MonkOfEntranaDialogue extends DialoguePlugin {
break;
case 25:
end();
Ships.PORT_SARIM_TO_ENTRANA.sail(player);
playJingle(player, 172);
sail(player, Ships.PORT_SARIM_TO_ENTRANA);
if (!player.getAchievementDiaryManager().getDiary(DiaryType.FALADOR).isComplete(0, 14)) {
player.getAchievementDiaryManager().getDiary(DiaryType.FALADOR).updateTask(player, 0, 14, true);
}
@@ -133,9 +137,7 @@ public final class MonkOfEntranaDialogue extends DialoguePlugin {
stage = 511;
break;
case 511:
end();
Ships.ENTRANA_TO_PORT_SARIM.sail(player);
playJingle(player, 172);
sail(player, Ships.ENTRANA_TO_PORT_SARIM);
break;
case 520:
end();
@@ -0,0 +1,56 @@
package content.region.misc.entrana.handlers
import content.global.travel.ship.Ships
import core.api.*
import core.cache.def.impl.ItemDefinition
import core.game.dialogue.DialogueFile
import core.game.interaction.IntType
import core.game.interaction.InteractionListener
import core.game.node.entity.npc.NPC
import core.game.node.entity.player.Player
import core.game.node.entity.player.link.diary.DiaryType
import core.tools.END_DIALOGUE
import org.rs09.consts.NPCs
/**
* Listeners for the Entrana monks' fast-travel option
* @author Player Name
*/
fun sail(player: Player?, ship: Ships) {
ship.sail(player)
playJingle(player!!, 172)
}
class EntranaListeners : InteractionListener {
override fun defineListeners() {
for (npc in arrayOf(NPCs.MONK_OF_ENTRANA_2730, NPCs.MONK_OF_ENTRANA_658, NPCs.MONK_OF_ENTRANA_2731)) {
on(npc, IntType.NPC, "take-boat") { player, _ ->
sail(player, Ships.ENTRANA_TO_PORT_SARIM)
return@on true
}
}
for (npc in arrayOf(NPCs.MONK_OF_ENTRANA_2728, NPCs.MONK_OF_ENTRANA_657, NPCs.MONK_OF_ENTRANA_2729)) {
on(npc, IntType.NPC, "take-boat") { player, _ ->
if (!ItemDefinition.canEnterEntrana(player)) {
openDialogue(player, object : DialogueFile() {
override fun handle(componentID: Int, buttonID: Int) {
this.npc = NPC(npc)
when (stage) {
0 -> npc("NO WEAPONS OR ARMOUR are permitted on holy", "Entrana AT ALL. We will not allow you to travel there", "in breach of mighty Saradomin's edict.").also { stage++ }
1 -> npc("Do not try to deceive us again. Come back when you", "have laid down your Zamorakian instruments of death.").also { stage = END_DIALOGUE }
}
}
})
return@on true
}
sail(player, Ships.PORT_SARIM_TO_ENTRANA)
if (!player.achievementDiaryManager.getDiary(DiaryType.FALADOR).isComplete(0, 14)) {
player.achievementDiaryManager.getDiary(DiaryType.FALADOR).updateTask(player, 0, 14, true)
}
return@on true
}
}
}
}