diff --git a/Server/src/plugin/dialogue/AnjaDialoguePlugin.java b/Server/src/plugin/dialogue/AnjaDialoguePlugin.java
new file mode 100644
index 000000000..83b1819ad
--- /dev/null
+++ b/Server/src/plugin/dialogue/AnjaDialoguePlugin.java
@@ -0,0 +1,144 @@
+package plugin.dialogue;
+
+import org.crandor.game.content.dialogue.DialoguePlugin;
+import org.crandor.game.content.dialogue.FacialExpression;
+import org.crandor.game.node.entity.npc.NPC;
+import org.crandor.game.node.entity.player.Player;
+import org.crandor.game.node.item.Item;
+import org.crandor.game.world.map.RegionManager;
+import org.crandor.plugin.InitializablePlugin;
+import org.crandor.tools.RandomFunction;
+
+/**
+ * Represents the dialogue plugin used for the anja npc.
+ * @author jamix77
+ */
+@InitializablePlugin
+public final class AnjaDialoguePlugin extends DialoguePlugin {
+
+ /**
+ *
+ * Constructs a new @{Code AnjaDialoguePlugin} object.
+ */
+ public AnjaDialoguePlugin() {
+ /**
+ * empty.
+ */
+ }
+
+ /**
+ * Constructs a new {@code AjjatDialoguePlugin} {@code Object}.
+ * @param player the player.
+ */
+ public AnjaDialoguePlugin(Player player) {
+ super(player);
+ }
+
+ @Override
+ public DialoguePlugin newInstance(Player player) {
+ return new AnjaDialoguePlugin(player);
+ }
+
+ @Override
+ public boolean open(Object... args) {
+ npc = (NPC) args[0];
+ player("Hello.");
+ stage = 0;
+ return true;
+ }
+
+ @Override
+ public boolean handle(int interfaceId, int buttonId) {
+ switch (stage) {
+ case 0:
+ npc("Hello sir. What are you doing in my house?");
+ stage = 1;
+ break;
+ case 1:
+ interpreter.sendOptions("Select an Option", "I'm just wandering around.", "I was hoping you'd give me some free stuff.", "I've come to kill you.");
+ stage = 2;
+ break;
+ case 2:
+ if (buttonId == 1) {
+ player("I'm just wondering around.");
+ stage = 3;
+ } else if (buttonId == 2) {
+ player("I was hoping you'd give me some free stuff.");
+ stage = 10;
+ } else if (buttonId == 3) {
+ player("I've come to kill you.");
+ stage = 13;
+ }
+ break;
+ case 3:
+ npc("Oh dear are you lost?");
+ stage++;
+ break;
+ case 4:
+ interpreter.sendOptions("Select an Option.", "Yes, I'm lost.", "No, I know where I am.");
+ stage++;
+ break;
+ case 5:
+ switch (buttonId) {
+ case 1:
+ player("Yes, I'm lost.");
+ stage =6;
+ break;
+ case 2:
+ player("No I know where I am.");
+ stage = 8;
+ break;
+ }
+ break;
+ case 6:
+ npc("Okay, just walk north-east when you leave this house,","and soon you'll reach the big city of Falador.");
+ stage++;
+ break;
+ case 7:
+ player("Thanks a lot.");
+ stage = 605;
+ break;
+ case 8:
+ npc("Oh? Well, would you mind wandering somewhere else?", "This is my house.");
+ stage++;
+ break;
+ case 9:
+ player("Meh!");
+ stage = 605;
+ break;
+ case 10:
+ String[] dialogues = {"Do you REALLY need it","I don't have much on me...", "I don't know..."};
+ npc(dialogues[RandomFunction.random(0, 2)]);
+ stage++;
+ break;
+ case 11:
+ interpreter.sendDialogues(player, FacialExpression.ASKING, "I promise I'll stop bothering you!", "Pleeease!","Pwetty pleathe wiv thugar on top!");
+ stage++;
+ break;
+ case 12:
+ npc("Oh, alright. Here you go.");
+ player.getInventory().add(new Item(995,RandomFunction.random(1, 3)));
+ stage = 605;
+ break;
+ case 13:
+ npc.sendChat("Eeeek!");
+ for (NPC npc1 : RegionManager.getLocalNpcs(player)) {
+ if (npc1.getName().equalsIgnoreCase("Hengel")) {
+ npc1.sendChat("Aaaaarrgh!");
+ break;
+ }
+ }
+ end();
+ break;
+ case 605:
+ end();
+ break;
+ }
+ return true;
+ }
+
+ @Override
+ public int[] getIds() {
+ return new int[] { 2684 };
+ }
+}
diff --git a/Server/src/plugin/dialogue/GoblinVillageGuardDialogue.java b/Server/src/plugin/dialogue/GoblinVillageGuardDialogue.java
new file mode 100644
index 000000000..2b44206ec
--- /dev/null
+++ b/Server/src/plugin/dialogue/GoblinVillageGuardDialogue.java
@@ -0,0 +1,77 @@
+package plugin.dialogue;
+
+import org.crandor.game.content.dialogue.DialoguePlugin;
+import org.crandor.game.node.entity.npc.NPC;
+import org.crandor.game.node.entity.player.Player;
+import org.crandor.plugin.InitializablePlugin;
+
+/**
+ * Represents the dialogue plugin used for the goblin village guard npc.
+ * @author jamix77
+ */
+@InitializablePlugin
+public final class GoblinVillageGuardDialogue extends DialoguePlugin {
+
+ /**
+ *
+ * Constructs a new @{Code HengelDialoguePlugin} object.
+ */
+ public GoblinVillageGuardDialogue() {
+ /**
+ * empty.
+ */
+ }
+
+ /**
+ *
+ * Constructs a new @{Code GoblinVillageGuardDialogue} object.
+ * @param player
+ */
+ public GoblinVillageGuardDialogue(Player player) {
+ super(player);
+ }
+
+ @Override
+ public DialoguePlugin newInstance(Player player) {
+ return new GoblinVillageGuardDialogue(player);
+ }
+
+ @Override
+ public boolean open(Object... args) {
+ npc = (NPC) args[0];
+ player("You're a long way out from the city.");
+ stage = 0;
+ return true;
+ }
+
+ @Override
+ public boolean handle(int interfaceId, int buttonId) {
+ switch (stage) {
+ case 0:
+ npc("I know. We guards uaully stay by banks and shops,", "but I got sent all the way out here to keep an eye on","the brigands loitering just south of here.");
+ stage = 1;
+ break;
+ case 1:
+ player("Sounds more exciting than standing", "around guarding banks and shops.");
+ stage = 2;
+ break;
+ case 2:
+ npc("It's not too bad. At least I don't get attacked so often", "out here. Guards in the cities get killed all the time.");
+ stage++;
+ break;
+ case 3:
+ player("Honestly people these days just don't know how to behave!");
+ stage++;
+ break;
+ case 4:
+ end();
+ break;
+ }
+ return true;
+ }
+
+ @Override
+ public int[] getIds() {
+ return new int[] { 3241 };
+ }
+}
diff --git a/Server/src/plugin/dialogue/HengelDialoguePlugin.java b/Server/src/plugin/dialogue/HengelDialoguePlugin.java
new file mode 100644
index 000000000..3ac4ce64e
--- /dev/null
+++ b/Server/src/plugin/dialogue/HengelDialoguePlugin.java
@@ -0,0 +1,115 @@
+package plugin.dialogue;
+
+import org.crandor.game.content.dialogue.DialoguePlugin;
+import org.crandor.game.node.entity.npc.NPC;
+import org.crandor.game.node.entity.player.Player;
+import org.crandor.game.world.map.RegionManager;
+import org.crandor.plugin.InitializablePlugin;
+
+/**
+ * Represents the dialogue plugin used for the hengel npc.
+ * @author jamix77
+ */
+@InitializablePlugin
+public final class HengelDialoguePlugin extends DialoguePlugin {
+
+ /**
+ *
+ * Constructs a new @{Code HengelDialoguePlugin} object.
+ */
+ public HengelDialoguePlugin() {
+ /**
+ * empty.
+ */
+ }
+
+ /**
+ * Constructs a new {@code AjjatDialoguePlugin} {@code Object}.
+ * @param player the player.
+ */
+ public HengelDialoguePlugin(Player player) {
+ super(player);
+ }
+
+ @Override
+ public DialoguePlugin newInstance(Player player) {
+ return new HengelDialoguePlugin(player);
+ }
+
+ @Override
+ public boolean open(Object... args) {
+ npc = (NPC) args[0];
+ player("Hello.");
+ stage = 0;
+ return true;
+ }
+
+ @Override
+ public boolean handle(int interfaceId, int buttonId) {
+ switch (stage) {
+ case 0:
+ npc("What are you doing here?");
+ stage = 1;
+ break;
+ case 1:
+ interpreter.sendOptions("Select an Option", "I'm just wandering around.", "I was hoping you'd give me some free stuff.", "I've come to kill you.");
+ stage = 2;
+ break;
+ case 2:
+ if (buttonId == 1) {
+ player("I'm just wondering around.");
+ stage = 3;
+ } else if (buttonId == 2) {
+ player("I was hoping you'd give me some free stuff.");
+ stage = 7;
+ } else if (buttonId == 3) {
+ player("I've come to kill you.");
+ stage = 9;
+ }
+ break;
+ case 3:
+ npc("You do realise you're wandering around in my house?");
+ stage++;
+ break;
+ case 4:
+ player("Yep.");
+ stage++;
+ break;
+ case 5:
+ npc("Well please get out!");
+ stage++;
+ break;
+ case 6:
+ player("Sheesh, keep your wig on!");
+ stage = 605;
+ break;
+ case 7:
+ npc("No, I jolly well wouldn't!","Get out of my house");
+ stage++;
+ break;
+ case 8:
+ player("Meanie!");
+ stage = 605;
+ break;
+ case 9:
+ npc.sendChat("Aaaaarrgh!");
+ for (NPC npc1 : RegionManager.getLocalNpcs(player)) {
+ if (npc1.getName().equalsIgnoreCase("anja")) {
+ npc1.sendChat("Eeeek!");
+ break;
+ }
+ }
+ end();
+ break;
+ case 605:
+ end();
+ break;
+ }
+ return true;
+ }
+
+ @Override
+ public int[] getIds() {
+ return new int[] { 2683 };
+ }
+}
diff --git a/Server/src/plugin/dialogue/LeelaDialogue.java b/Server/src/plugin/dialogue/LeelaDialogue.java
index 95c8af6ae..9bccce231 100644
--- a/Server/src/plugin/dialogue/LeelaDialogue.java
+++ b/Server/src/plugin/dialogue/LeelaDialogue.java
@@ -305,7 +305,7 @@ public final class LeelaDialogue extends DialoguePlugin {
stage = 21;
break;
case 21:
- interpreter.sendDialogues(npc, null, "Get some soft clay and get her to sho you the key", "somehow. Then take the print, with bronze, to my", "father.");
+ interpreter.sendDialogues(npc, null, "Get some soft clay and get her to show you the key", "somehow. Then take the print, with bronze, to my", "father.");
stage = 22;
break;
case 22:
diff --git a/Server/src/plugin/dialogue/NarfsDialogue.java b/Server/src/plugin/dialogue/NarfsDialogue.java
index bc88e3d60..2effd8426 100644
--- a/Server/src/plugin/dialogue/NarfsDialogue.java
+++ b/Server/src/plugin/dialogue/NarfsDialogue.java
@@ -58,7 +58,7 @@ public class NarfsDialogue extends DialoguePlugin {
@Override
public boolean open(Object... args) {
npc = (NPC) args[0];
- interpreter.sendDialogues(npc, FacialExpression.HALF_GUILTY, "That's a funny name you've got.");
+ interpreter.sendDialogues(player, FacialExpression.HALF_GUILTY, "That's a funny name you've got.");
stage = 1;
return true;
}
diff --git a/Server/src/plugin/interaction/object/ReadSignPostPlugin.java b/Server/src/plugin/interaction/object/ReadSignPostPlugin.java
index 2ea0be403..82bd962bd 100644
--- a/Server/src/plugin/interaction/object/ReadSignPostPlugin.java
+++ b/Server/src/plugin/interaction/object/ReadSignPostPlugin.java
@@ -25,7 +25,7 @@ public class ReadSignPostPlugin extends OptionHandler {
* @author 'Vexia
*/
public enum Signs {
- NEAR_LUMBRIDGE(18493, "North to farms and
Varrock.", "The River Lum lies to
the south.", "West to
Lumbridge.", "East to Al
Kharid - toll
gate; bring some
money."), NEAR_VARROCK(24263, "Varrock", "Lumbridge", "Draynor Manor", "Dig Site");
+ NEAR_LUMBRIDGE(18493, "North to farms and
Varrock.", "The River Lum lies to
the south.", "West to
Lumbridge.", "East to Al
Kharid - toll
gate; bring some
money."), NEAR_VARROCK(24263, "Sheep lay this way.", "South through farms
to Al Kharid and
Lumbridge", "West to Champion's Guild
and Varrock south
gate.", "East to Al Kharid mine and
follow the path north to
Varrock east gate.");
public static Signs forId(int id) {
for (Signs sign : Signs.values()) {
@@ -76,10 +76,17 @@ public class ReadSignPostPlugin extends OptionHandler {
if (sign == null) {
return false;
}
- player.getPacketDispatch().sendString(sign.directions[0], 135, 3); // North
- player.getPacketDispatch().sendString(sign.directions[1], 135, 9); // South
- player.getPacketDispatch().sendString(sign.directions[2], 135, 12); // West
- player.getPacketDispatch().sendString(sign.directions[3], 135, 8); // East
+ String[] dirs = sign.directions;
+ if (object.getLocation().getX() == 3107 && object.getLocation().getY() == 3296) {
+ dirs[0] = "North to Draynor
Manor";
+ dirs[1] = "South to Draynor
Village";
+ dirs[2] = "West to Port
Sarim";
+ dirs[3] = "East to
Lumbridge";
+ }
+ player.getPacketDispatch().sendString(dirs[0], 135, 3); // North
+ player.getPacketDispatch().sendString(dirs[1], 135, 9); // South
+ player.getPacketDispatch().sendString(dirs[2], 135, 12); // West
+ player.getPacketDispatch().sendString(dirs[3], 135, 8); // East
return true;
}
diff --git a/Server/src/plugin/npc/other/GuardNPC.java b/Server/src/plugin/npc/other/GuardNPC.java
index 150d52a2b..c142f510b 100644
--- a/Server/src/plugin/npc/other/GuardNPC.java
+++ b/Server/src/plugin/npc/other/GuardNPC.java
@@ -22,6 +22,7 @@ public final class GuardNPC extends AbstractNPC {
*/
public GuardNPC() {
super(0, null, true);
+ this.setAggressive(false);
}
/**
@@ -31,6 +32,7 @@ public final class GuardNPC extends AbstractNPC {
*/
private GuardNPC(int id, Location location) {
super(id, location, true);
+ this.setAggressive(false);
}
@Override