From e1fa33b4ddc090047b29c3a2e90b6649e8edbb94 Mon Sep 17 00:00:00 2001 From: Skal Fate <13443576-SkalFate@users.noreply.gitlab.com> Date: Sat, 4 Feb 2023 09:14:47 +0000 Subject: [PATCH] Fixed Varrock sword shop shopkeeper and his assistant not being able to speak Catherby's Vannessa no longer double prompts players about what they want to buy Varrock sword shop staff and Catherby's Vannessa now have correct facial expressions --- .../catherby/dialogue/VanessaDialogue.java | 15 ++++----------- .../dialogue/VarrockSwordShopDialogue.java | 13 ++++++++----- 2 files changed, 12 insertions(+), 16 deletions(-) diff --git a/Server/src/main/content/region/kandarin/catherby/dialogue/VanessaDialogue.java b/Server/src/main/content/region/kandarin/catherby/dialogue/VanessaDialogue.java index 31472391b..f1ed25b7d 100644 --- a/Server/src/main/content/region/kandarin/catherby/dialogue/VanessaDialogue.java +++ b/Server/src/main/content/region/kandarin/catherby/dialogue/VanessaDialogue.java @@ -30,10 +30,6 @@ public class VanessaDialogue extends DialoguePlugin { public boolean handle(int interfaceId, int buttonId) { switch (stage) { case 0: - interpreter.sendOptions("Select an Option", "What are you selling?", "Can you give me any Farming advice?", "I'm okay, thank you."); - stage = 1; - break; - case 1: interpreter.sendOptions("Select an Option", "What are you selling?", "Can you give me any Farming advice?", "I'm okay, thank you."); stage = 10; break; @@ -44,11 +40,11 @@ public class VanessaDialogue extends DialoguePlugin { npc.openShop(player); break; case 2: - interpreter.sendDialogues(player, FacialExpression.HALF_GUILTY, "Can you give me any Farming advice?"); + interpreter.sendDialogues(player, FacialExpression.HALF_ASKING, "Can you give me any Farming advice?"); stage = 20; break; case 3: - interpreter.sendDialogues(player, FacialExpression.HALF_GUILTY, "I'm okay, thank you."); + interpreter.sendDialogues(player, FacialExpression.FRIENDLY, "I'm okay, thank you."); stage = 30; break; @@ -56,10 +52,7 @@ public class VanessaDialogue extends DialoguePlugin { break; case 20: interpreter.sendDialogues(npc, FacialExpression.HALF_GUILTY, "Yes - ask a gardener."); - stage = 21; - break; - case 21: - end(); + stage = 30; break; case 30: end(); @@ -77,7 +70,7 @@ public class VanessaDialogue extends DialoguePlugin { @Override public boolean open(Object... args) { npc = (NPC) args[0]; - interpreter.sendDialogues(npc, FacialExpression.HALF_GUILTY, "Hello. How can I help you?"); + interpreter.sendDialogues(npc, FacialExpression.HAPPY, "Hello. How can I help you?"); stage = 0; return true; } diff --git a/Server/src/main/content/region/misthalin/varrock/dialogue/VarrockSwordShopDialogue.java b/Server/src/main/content/region/misthalin/varrock/dialogue/VarrockSwordShopDialogue.java index 77258f13e..d0deef1e4 100644 --- a/Server/src/main/content/region/misthalin/varrock/dialogue/VarrockSwordShopDialogue.java +++ b/Server/src/main/content/region/misthalin/varrock/dialogue/VarrockSwordShopDialogue.java @@ -4,11 +4,14 @@ import core.game.dialogue.DialoguePlugin; import core.game.dialogue.FacialExpression; import core.game.node.entity.npc.NPC; import core.game.node.entity.player.Player; +import core.plugin.Initializable; /** * Handles the VarrockSwordShopDialogue dialogue. * @author 'Vexia */ + +@Initializable public class VarrockSwordShopDialogue extends DialoguePlugin { public VarrockSwordShopDialogue() { @@ -21,7 +24,7 @@ public class VarrockSwordShopDialogue extends DialoguePlugin { @Override public int[] getIds() { - return new int[] { 551 }; + return new int[] { 551, 552 }; } @Override @@ -36,11 +39,11 @@ public class VarrockSwordShopDialogue extends DialoguePlugin { switch (buttonId) { case 1: - interpreter.sendDialogues(player, FacialExpression.HALF_GUILTY, "Yes, please."); + interpreter.sendDialogues(player, FacialExpression.HAPPY, "Yes, please."); stage = 2; break; case 2: - interpreter.sendDialogues(player, FacialExpression.HALF_GUILTY, "No, I'm okay for swords right now."); + interpreter.sendDialogues(player, FacialExpression.FRIENDLY, "No, I'm okay for swords right now."); stage = 10; break; } @@ -51,7 +54,7 @@ public class VarrockSwordShopDialogue extends DialoguePlugin { npc.openShop(player); break; case 10: - interpreter.sendDialogues(npc, FacialExpression.HALF_GUILTY, "Come back if you need any."); + interpreter.sendDialogues(npc, FacialExpression.FRIENDLY, "Come back if you need any."); stage = 11; break; case 11: @@ -71,7 +74,7 @@ public class VarrockSwordShopDialogue extends DialoguePlugin { @Override public boolean open(Object... args) { npc = (NPC) args[0]; - interpreter.sendDialogues(npc, FacialExpression.HALF_GUILTY, "Hello, adventurer. Can I interest you in some swords?"); + interpreter.sendDialogues(npc, FacialExpression.HAPPY, "Hello, adventurer. Can I interest you in some swords?"); stage = 0; return true; }