Merge branch 'master' into 'master'

Fix: Shops, Examines, Objects, misc janitor work

See merge request 2009scape/2009scape!88
This commit is contained in:
Ceikry
2021-07-02 04:32:22 +00:00
7 changed files with 21106 additions and 20997 deletions
+111 -10
View File
@@ -4486,6 +4486,23 @@
"range_level": "1", "range_level": "1",
"attack_level": "25" "attack_level": "25"
}, },
{
"examine": "An old motherly witch with a curious smile and a hooked nose.",
"melee_animation": "0",
"range_animation": "0",
"defence_animation": "0",
"magic_animation": "0",
"death_animation": "0",
"name": "Hetty",
"defence_level": "1",
"safespot": null,
"lifepoints": "10",
"strength_level": "1",
"id": "307",
"aggressive": "true",
"range_level": "1",
"attack_level": "1"
},
{ {
"examine": "The man in charge of the fishing guild.", "examine": "The man in charge of the fishing guild.",
"melee_animation": "0", "melee_animation": "0",
@@ -4502,6 +4519,23 @@
"range_level": "1", "range_level": "1",
"attack_level": "1" "attack_level": "1"
}, },
{
"examine": "He has a colourful personality.",
"melee_animation": "0",
"range_animation": "0",
"defence_animation": "0",
"magic_animation": "0",
"death_animation": "0",
"name": "Da Vinci",
"defence_level": "1",
"safespot": null,
"lifepoints": "10",
"strength_level": "1",
"id": "336",
"aggressive": "true",
"range_level": "1",
"attack_level": "1"
},
{ {
"examine": "He's ready for a bet.", "examine": "He's ready for a bet.",
"melee_animation": "0", "melee_animation": "0",
@@ -5662,7 +5696,7 @@
"respawn_delay": "60", "respawn_delay": "60",
"defence_animation": "0", "defence_animation": "0",
"magic_animation": "0", "magic_animation": "0",
"death_animation": "0", "death_animation": "836",
"name": "Jail guard", "name": "Jail guard",
"defence_level": "21", "defence_level": "21",
"safespot": null, "safespot": null,
@@ -5682,7 +5716,7 @@
"respawn_delay": "60", "respawn_delay": "60",
"defence_animation": "0", "defence_animation": "0",
"magic_animation": "0", "magic_animation": "0",
"death_animation": "0", "death_animation": "836",
"name": "Jail guard", "name": "Jail guard",
"defence_level": "21", "defence_level": "21",
"safespot": null, "safespot": null,
@@ -5702,7 +5736,7 @@
"respawn_delay": "60", "respawn_delay": "60",
"defence_animation": "0", "defence_animation": "0",
"magic_animation": "0", "magic_animation": "0",
"death_animation": "0", "death_animation": "836",
"name": "Jail guard", "name": "Jail guard",
"defence_level": "21", "defence_level": "21",
"safespot": null, "safespot": null,
@@ -6872,6 +6906,22 @@
"range_level": "1", "range_level": "1",
"attack_level": "1" "attack_level": "1"
}, },
{
"examine": "If crafting's your thing, he's your man!",
"melee_animation": "0",
"range_animation": "0",
"defence_animation": "0",
"magic_animation": "0",
"death_animation": "0",
"name": "Rommik",
"defence_level": "1",
"safespot": null,
"lifepoints": "10",
"strength_level": "1",
"id": "574",
"range_level": "1",
"attack_level": "1"
},
{ {
"examine": "He seems to sell tea.", "examine": "He seems to sell tea.",
"melee_animation": "0", "melee_animation": "0",
@@ -9467,7 +9517,7 @@
"respawn_delay": "60", "respawn_delay": "60",
"defence_animation": "0", "defence_animation": "0",
"magic_animation": "0", "magic_animation": "0",
"death_animation": "0", "death_animation": "836",
"name": "Jail guard", "name": "Jail guard",
"defence_level": "21", "defence_level": "21",
"safespot": null, "safespot": null,
@@ -12067,6 +12117,7 @@
"melee_animation": "6241", "melee_animation": "6241",
"range_animation": "6241", "range_animation": "6241",
"attack_speed": "4", "attack_speed": "4",
"poisonous": "true",
"magic_level": "150", "magic_level": "150",
"respawn_delay": "45", "respawn_delay": "45",
"defence_animation": "6232", "defence_animation": "6232",
@@ -19192,6 +19243,22 @@
"range_level": "1", "range_level": "1",
"attack_level": "1" "attack_level": "1"
}, },
{
"examine": "He sells ranging equipment.",
"melee_animation": "0",
"range_animation": "0",
"defence_animation": "0",
"magic_animation": "0",
"death_animation": "0",
"name": "Brian",
"defence_level": "1",
"safespot": null,
"lifepoints": "10",
"strength_level": "1",
"id": "1866",
"range_level": "1",
"attack_level": "1"
},
{ {
"examine": "Nemarti looks ready to teach you about ranged combat.", "examine": "Nemarti looks ready to teach you about ranged combat.",
"melee_animation": "0", "melee_animation": "0",
@@ -23082,6 +23149,22 @@
"range_level": "1", "range_level": "1",
"attack_level": "1" "attack_level": "1"
}, },
{
"examine": "Perhaps this gardener might look after your crops for you.",
"melee_animation": "0",
"range_animation": "0",
"defence_animation": "0",
"magic_animation": "0",
"death_animation": "0",
"name": "Taria",
"defence_level": "1",
"safespot": null,
"lifepoints": "10",
"strength_level": "1",
"id": "2336",
"range_level": "1",
"attack_level": "1"
},
{ {
"examine": "Perhaps this gardener might look after your crops for you.", "examine": "Perhaps this gardener might look after your crops for you.",
"melee_animation": "0", "melee_animation": "0",
@@ -24807,19 +24890,37 @@
"attack_level": "1" "attack_level": "1"
}, },
{ {
"death_animation": "836", "examine": "A citizen of Rimmington.",
"melee_animation": "0",
"range_animation": "0",
"defence_animation": "0",
"magic_animation": "0",
"death_animation": "0",
"name": "Hengel", "name": "Hengel",
"defence_level": "1", "defence_level": "1",
"safespot": null, "safespot": null,
"lifepoints": "7", "lifepoints": "10",
"melee_animation": "422",
"strength_level": "1", "strength_level": "1",
"id": "2683", "id": "2683",
"range_level": "1", "range_level": "1",
"respawn_delay": "60", "attack_level": "1"
"attack_level": "1",
"defence_animation": "425"
}, },
{
"examine": "A citizen of Rimmington.",
"melee_animation": "0",
"range_animation": "0",
"defence_animation": "0",
"magic_animation": "0",
"death_animation": "0",
"name": "Anja",
"defence_level": "1",
"safespot": null,
"lifepoints": "10",
"strength_level": "1",
"id": "2684",
"range_level": "1",
"attack_level": "1"
},
{ {
"examine": "An ugly smelly creature.", "examine": "An ugly smelly creature.",
"melee_animation": "164", "melee_animation": "164",
+1 -1
View File
@@ -1469,7 +1469,7 @@
}, },
{ {
"npc_id": "558", "npc_id": "558",
"loc_data": "{3013,3221,0,1,6}" "loc_data": "{3013,3225,0,1,1}"
}, },
{ {
"npc_id": "559", "npc_id": "559",
File diff suppressed because it is too large Load Diff
+31 -31
View File
@@ -357,7 +357,7 @@
"general_store": "true", "general_store": "true",
"id": "41", "id": "41",
"title": "Trader Stan's Trading Post", "title": "Trader Stan's Trading Post",
"stock": "{1931,5}-{1935,2}-{1735,2}-{1925,3}-{1923,2}-{1887,2}-{590,2}-{1755,2}-{2347,5}-{550,5}-{9003,5}-{954,2}-{946,2}-{2114,inf}-{1963,15}-{2108,10}-{4286,10}-{1785,15}-{1783,inf}-{401,inf}-{1781,10}-{301,20}-{307,20}-{1941,30}-{9629,25}-{3226,20}-{1025,5}" "stock": "{1931,5}-{1935,2}-{1735,2}-{1925,3}-{1923,2}-{1887,2}-{590,2}-{1755,2}-{2347,5}-{550,5}-{9003,5}-{954,2}-{946,2}-{2114,0}-{1963,15}-{2108,10}-{4286,10}-{1785,15}-{1783,inf}-{401,inf}-{1781,10}-{301,20}-{307,20}-{1941,30}-{9629,25}-{3226,20}-{1025,5}"
}, },
{ {
"npcs": "534", "npcs": "534",
@@ -397,12 +397,12 @@
}, },
{ {
"npcs": "1860", "npcs": "1860",
"high_alch": "0", "high_alch": "1",
"currency": "995", "currency": "995",
"general_store": "false", "general_store": "false",
"id": "46", "id": "46",
"title": "Brian's Archery Supplies", "title": "Brian's Archery Supplies",
"stock": "{886,100}-{888,30}-{890,0}-{843,10}-{849,10}-{853,10}" "stock": "{886,100}-{888,30}-{890,0}-{843,10}-{845,10}-{849,10}-{847,10}-{853,10}-{851,10}"
}, },
{ {
"npcs": "550", "npcs": "550",
@@ -478,12 +478,12 @@
}, },
{ {
"npcs": "559", "npcs": "559",
"high_alch": "0", "high_alch": "1",
"currency": "995", "currency": "995",
"general_store": "false", "general_store": "false",
"id": "55", "id": "55",
"title": "Brian's Battleaxe Bazaar", "title": "Brian's Battleaxe Bazaar",
"stock": "{1375,10}-{1363,10}-{1365,10}-{1367,10}-{1369,10}-{1371,10}" "stock": "{1375,4}-{1363,3}-{1365,2}-{1367,1}-{1369,1}-{1371,1}"
}, },
{ {
"npcs": "562", "npcs": "562",
@@ -510,7 +510,7 @@
"general_store": "false", "general_store": "false",
"id": "58", "id": "58",
"title": "Wayne's Chains", "title": "Wayne's Chains",
"stock": "{1103,10}-{1101,10}-{1105,10}-{1107,10}-{1109,10}-{1111,10}" "stock": "{1103,3}-{1101,2}-{1105,1}-{1107,1}-{1109,1}-{1111,1}"
}, },
{ {
"npcs": "554", "npcs": "554",
@@ -622,7 +622,7 @@
}, },
{ {
"npcs": "585", "npcs": "585",
"high_alch": "0", "high_alch": "1",
"currency": "995", "currency": "995",
"general_store": "false", "general_store": "false",
"id": "71", "id": "71",
@@ -658,12 +658,12 @@
}, },
{ {
"npcs": "2304", "npcs": "2304",
"high_alch": "0", "high_alch": "1",
"currency": "995", "currency": "995",
"general_store": "false", "general_store": "false",
"id": "75", "id": "75",
"title": "Sarah's Farming Shop", "title": "Sarah's Farming Shop",
"stock": "{5376,10}-{6032,300}-{5418,10}-{5376,10}-{6036,10}-{5354,100}-{5341,10}-{5329,10}-{5343,10}-{952,10}-{5325,10}-{1925,100}-{5331,30}-{12622,10}-{5996,0}-{6006,0}-{1965,0}-{5994,0}-{5931,0}-{6000,0}-{1957,0}-{5504,0}-{5986,0}-{1982,0}-{5982,0}-{6002,0}-{5998,0}" "stock": "{5376,10}-{6032,300}-{5418,10}-{6036,10}-{5354,100}-{5341,10}-{5329,10}-{5343,10}-{952,10}-{5325,10}-{1925,100}-{5331,30}-{12622,10}-{5996,0}-{6006,0}-{1965,0}-{5994,0}-{5931,0}-{6000,0}-{1957,0}-{5504,0}-{5986,0}-{1982,0}-{5982,0}-{6002,0}-{5998,0}"
}, },
{ {
"npcs": "1783", "npcs": "1783",
@@ -676,11 +676,11 @@
}, },
{ {
"npcs": "557", "npcs": "557",
"high_alch": "0", "high_alch": "1",
"currency": "995", "currency": "995",
"general_store": "false", "general_store": "false",
"id": "77", "id": "77",
"title": "Wydin's Consumables Store", "title": "Wydin's Food Store",
"stock": "{1933,500}-{2132,10}-{2138,10}-{1965,10}-{1963,0}-{1951,0}-{2309,10}-{1973,10}-{1985,10}-{1982,10}-{1550,10}" "stock": "{1933,500}-{2132,10}-{2138,10}-{1965,10}-{1963,0}-{1951,0}-{2309,10}-{1973,10}-{1985,10}-{1982,10}-{1550,10}"
}, },
{ {
@@ -748,11 +748,11 @@
}, },
{ {
"npcs": "4293", "npcs": "4293",
"high_alch": "0", "high_alch": "1",
"currency": "995", "currency": "995",
"general_store": "false", "general_store": "false",
"id": "85", "id": "85",
"title": "Warriors' Guild Consumables Shop", "title": "Warriors' Guild Food Shop",
"stock": "{333,10}-{365,10}-{2289,10}-{6705,10}-{2003,10}" "stock": "{333,10}-{365,10}-{2289,10}-{6705,10}-{2003,10}"
}, },
{ {
@@ -766,11 +766,11 @@
}, },
{ {
"npcs": "584", "npcs": "584",
"high_alch": "0", "high_alch": "1",
"currency": "995", "currency": "995",
"general_store": "false", "general_store": "false",
"id": "87", "id": "87",
"title": "Herquin's Gem", "title": "Herquin's Gems",
"stock": "{1623,0}-{1621,0}-{1619,0}-{1617,0}-{1607,0}-{1605,0}-{1603,0}-{1601,0}" "stock": "{1623,0}-{1621,0}-{1619,0}-{1617,0}-{1607,0}-{1605,0}-{1603,0}-{1601,0}"
}, },
{ {
@@ -932,8 +932,8 @@
"currency": "995", "currency": "995",
"general_store": "false", "general_store": "false",
"id": "106", "id": "106",
"title": "Jewellery Shop", "title": "Grum's Gold Exchange",
"stock": "{1635,0}-{1637,0}-{1639,0}-{1641,0}-{1643,0}-{1654,0}-{1656,0}-{1658,0}-{1660,0}-{1662,0}-{1673,0}-{1675,0}-{1696,0}-{1698,0}-{1700,0}-{11069,0}-{11072,0}-{11076,0}-{11085,0}-{11092,0}" "stock": "{1635,0}-{1637,0}-{1639,0}-{1641,0}-{1643,0}-{1654,0}-{1656,0}-{1658,0}-{1660,0}-{1662,0}-{1692,0}-{1694,0}-{1696,0}-{1698,0}-{1700,0}-{11069,0}-{11072,0}-{11076,0}-{11085,0}-{11092,0}"
}, },
{ {
"npcs": "1862", "npcs": "1862",
@@ -977,8 +977,8 @@
"currency": "995", "currency": "995",
"general_store": "false", "general_store": "false",
"id": "111", "id": "111",
"title": "Mace Shop", "title": "Flynn's Mace Market",
"stock": "{1422,10}-{1420,10}-{1424,10}-{1428,10}-{1430,10}" "stock": "{1422,5}-{1420,4}-{1424,4}-{1428,3}-{1430,2}"
}, },
{ {
"npcs": "1862", "npcs": "1862",
@@ -991,12 +991,12 @@
}, },
{ {
"npcs": "583", "npcs": "583",
"high_alch": "0", "high_alch": "1",
"currency": "995", "currency": "995",
"general_store": "false", "general_store": "false",
"id": "113", "id": "113",
"title": "Betty's Magic Emporium", "title": "Betty's Magic Emporium",
"stock": "{554,3000}-{555,3000}-{556,3000}-{557,3000}-{558,100}-{559,100}-{562,30}-{560,10}-{221,150}-{579,10}-{1017,10}" "stock": "{554,300}-{555,300}-{556,300}-{557,300}-{558,100}-{559,100}-{562,30}-{560,10}-{221,100}-{579,10}-{1017,10}"
}, },
{ {
"npcs": "553", "npcs": "553",
@@ -1207,12 +1207,12 @@
}, },
{ {
"npcs": "577", "npcs": "577",
"high_alch": "0", "high_alch": "1",
"currency": "995", "currency": "995",
"general_store": "false", "general_store": "false",
"id": "137", "id": "137",
"title": "Shield Shop", "title": "Cassie's Shield Shop",
"stock": "{1171,10}-{1173,10}-{1189,10}-{1175,10}-{1191,10}-{1177,10}-{1193,10}-{1181,10}" "stock": "{1171,5}-{1173,3}-{1189,3}-{1175,2}-{1191,0}-{1177,0}-{1193,0}-{1181,0}"
}, },
{ {
"npcs": "209", "npcs": "209",
@@ -1275,7 +1275,7 @@
"general_store": "false", "general_store": "false",
"id": "144", "id": "144",
"title": "Gerrant's Fishy Business", "title": "Gerrant's Fishy Business",
"stock": "{303,10}-{307,10}-{309,10}-{311,1000}-{301,10}-{313,1000}-{314,1000}-{317,0}-{327,10}-{345,0}-{321,0}-{335,0}-{349,0}-{331,0}-{359,0}-{377,0}-{371,0}" "stock": "{303,10}-{307,10}-{309,10}-{311,30}-{301,10}-{13431,10}-{313,1000}-{314,1000}-{317,0}-{327,10}-{345,0}-{321,0}-{335,0}-{349,0}-{331,0}-{359,0}-{377,0}-{371,0}"
}, },
{ {
"npcs": "576", "npcs": "576",
@@ -1284,7 +1284,7 @@
"general_store": "false", "general_store": "false",
"id": "145", "id": "145",
"title": "Harry's Fishing Shop", "title": "Harry's Fishing Shop",
"stock": "{303,10}-{307,10}-{311,1000}-{301,10}-{313,1000}-{305,10}-{317,0}-{327,0}-{345,0}-{353,0}-{341,0}-{321,0}-{359,0}-{377,0}-{363,0}-{371,0}-{383,0}-{7810,1000}" "stock": "{303,10}-{307,10}-{311,1000}-{301,10}-{313,100}-{305,10}-{317,0}-{327,0}-{345,0}-{353,0}-{341,0}-{321,0}-{359,0}-{377,0}-{363,0}-{371,0}-{383,0}-{7810,1000}"
}, },
{ {
"npcs": "5266", "npcs": "5266",
@@ -1882,12 +1882,12 @@
}, },
{ {
"npcs": "4251", "npcs": "4251",
"high_alch": "0", "high_alch": "1",
"currency": "995", "currency": "995",
"general_store": "false", "general_store": "false",
"id": "213", "id": "213",
"title": "The Garden Centre", "title": "The Garden Centre",
"stock": "{8417,1000}-{8419,1000}-{8421,1000}-{8423,1000}-{8425,1000}-{8427,1000}-{8429,1000}-{8431,1000}-{8433,1000}-{8435,1000}-{8451,1000}-{8453,1000}-{8455,1000}-{8457,1000}-{8459,1000}-{8461,1000}-{8437,1000}-{8439,1000}-{8441,1000}-{8443,1000}-{8445,1000}-{8447,1000}-{8449,1000}" "stock": "{8417,10}-{8419,10}-{8421,10}-{8423,10}-{8425,10}-{8427,10}-{8429,10}-{8431,1000}-{8433,10}-{8435,10}-{8451,10}-{8453,10}-{8455,10}-{8457,10}-{8459,10}-{8461,10}-{8437,10}-{8439,10}-{8441,10}-{8443,10}-{8445,10}-{8447,10}-{8449,10}"
}, },
{ {
"npcs": "1972", "npcs": "1972",
@@ -2079,13 +2079,13 @@
"stock": "{1917,10}-{3803,10}-{3711,10}" "stock": "{1917,10}-{3803,10}-{3711,10}"
}, },
{ {
"npcs": "4248", "npcs": "7420",
"high_alch": "0", "high_alch": "0",
"currency": "995", "currency": "995",
"general_store": "false", "general_store": "false",
"id": "235", "id": "235",
"title": "Keldagrim Stonemason", "title": "Gnomic Supplies",
"stock": "{3420,500}-{8786,30}-{8784,30}-{8788,30}" "stock": "{1931,inf}-{1929,inf}-{1937,inf}-{2313,inf}-{1887,inf}-{590,inf}-{1735,inf}-{1951,inf}-{1969,inf}-{1949,inf}"
}, },
{ {
"npcs": "4856", "npcs": "4856",
@@ -1,276 +1,276 @@
package core.game.content.dialogue; package core.game.content.dialogue;
import core.game.node.entity.npc.NPC; import core.game.node.entity.npc.NPC;
import core.game.node.entity.player.Player; import core.game.node.entity.player.Player;
import core.game.node.entity.player.link.diary.DiaryType; import core.game.node.entity.player.link.diary.DiaryType;
import core.game.node.item.GroundItem; import core.game.node.item.GroundItem;
import core.game.node.item.GroundItemManager; import core.game.node.item.GroundItemManager;
import core.plugin.Initializable; import core.plugin.Initializable;
import core.game.node.item.Item; import core.game.node.item.Item;
/** /**
* Represents the dialogue plugin used for the apothecary npc. * Represents the dialogue plugin used for the apothecary npc.
* @author 'Vexia * @author 'Vexia
* @version 1.0 * @version 1.0
*/ */
@Initializable @Initializable
public final class ApothecaryDialogue extends DialoguePlugin { public final class ApothecaryDialogue extends DialoguePlugin {
/** /**
* Represents the potion requirements. * Represents the potion requirements.
*/ */
private static final Item[] POTION_ITEMS = new Item[] { new Item(223), new Item(225), new Item(995, 5) }; private static final Item[] POTION_ITEMS = new Item[] { new Item(223), new Item(225), new Item(995, 5) };
/** /**
* Represents the potion item. * Represents the potion item.
*/ */
private static final Item POTION = new Item(115); private static final Item POTION = new Item(115);
/** /**
* Represents the unkown potion. * Represents the unkown potion.
*/ */
private static final Item UNKNOWN_POTION = new Item(195, 1); private static final Item UNKNOWN_POTION = new Item(195, 1);
/** /**
* Represents the cadava berries item. * Represents the cadava berries item.
*/ */
private static final Item CADAVA_BERRIES = new Item(753); private static final Item CADAVA_BERRIES = new Item(753);
/** /**
* Represents the cadava potion item. * Represents the cadava potion item.
*/ */
private static final Item CADAVA_POTION = new Item(756); private static final Item CADAVA_POTION = new Item(756);
/** /**
* Constructs a new {@code ApothecaryDialogue} {@code Object}. * Constructs a new {@code ApothecaryDialogue} {@code Object}.
*/ */
public ApothecaryDialogue() { public ApothecaryDialogue() {
/** /**
* empty. * empty.
*/ */
} }
/** /**
* Constructs a new {@code ApothecaryDialogue} {@code Object}. * Constructs a new {@code ApothecaryDialogue} {@code Object}.
* @param player the player. * @param player the player.
*/ */
public ApothecaryDialogue(Player player) { public ApothecaryDialogue(Player player) {
super(player); super(player);
} }
@Override @Override
public DialoguePlugin newInstance(Player player) { public DialoguePlugin newInstance(Player player) {
return new ApothecaryDialogue(player); return new ApothecaryDialogue(player);
} }
@Override @Override
public boolean open(Object... args) { public boolean open(Object... args) {
npc = (NPC) args[0]; npc = (NPC) args[0];
if (player.getQuestRepository().getQuest("Romeo & Juliet").getStage(player) == 40) { if (player.getQuestRepository().getQuest("Romeo & Juliet").getStage(player) == 40) {
interpreter.sendDialogues(player, null, "Apothecary. Father Lawrence sent me."); interpreter.sendDialogues(player, null, "Apothecary. Father Lawrence sent me.");
stage = 500; stage = 500;
return true; return true;
} }
if (player.getQuestRepository().getQuest("Romeo & Juliet").getStage(player) == 50) { if (player.getQuestRepository().getQuest("Romeo & Juliet").getStage(player) == 50) {
if (!player.getInventory().contains(753, 1)) { if (!player.getInventory().contains(753, 1)) {
npc("Keep searching for those Cadavaberries. They're needed", "for the potion."); npc("Keep searching for those Cadava berries. They're needed", "for the potion.");
stage = 507; stage = 507;
return true; return true;
} else { } else {
npc("Well done. You have the berries."); npc("Well done. You have the berries.");
stage = 637; stage = 637;
return true; return true;
} }
} }
if (player.getQuestRepository().getQuest("Romeo & Juliet").getStage(player) == 60) { if (player.getQuestRepository().getQuest("Romeo & Juliet").getStage(player) == 60) {
if (!player.getInventory().contains(756, 1) && !player.getBank().contains(756, 1)) { if (!player.getInventory().contains(756, 1) && !player.getBank().contains(756, 1)) {
if (player.getInventory().contains(753, 1)) { if (player.getInventory().contains(753, 1)) {
npc("Well done. You have the berries."); npc("Well done. You have the berries.");
stage = 637; stage = 637;
return true; return true;
} else { } else {
npc("Keep searching for those Cadavaberries. They're needed", "for the potion."); npc("Keep searching for those Cadava berries. They're needed", "for the potion.");
stage = 507; stage = 507;
return true; return true;
} }
} else { } else {
npc("I am the Apothecary. I brew potions.", "Do you need anything specific?"); npc("I am the Apothecary. I brew potions.", "Do you need anything specific?");
} }
} }
npc("I am the Apothecary. I brew potions.", "Do you need anything specific?"); npc("I am the Apothecary. I brew potions.", "Do you need anything specific?");
stage = 1; stage = 1;
return true; return true;
} }
@Override @Override
public boolean handle(int interfaceId, int buttonId) { public boolean handle(int interfaceId, int buttonId) {
switch (stage) { switch (stage) {
case 1: case 1:
options("Can you make a strength potion?", "Do you know a potion to mame hair fall out?", "Have you got any good potions to give away?", "Can you make a potion that makes it seem like I'm dead?"); options("Can you make a strength potion?", "Do you know a potion to make hair fall out?", "Have you got any good potions to give away?", "Can you make a potion that makes it seem like I'm dead?");
stage = 2; stage = 2;
break; break;
case 2: case 2:
switch (buttonId) { switch (buttonId) {
case 1: case 1:
player("Can you make a strength potion?"); player("Can you make a strength potion?");
stage = 10; stage = 10;
break; break;
case 2: case 2:
player("Do you know a potion to make hair fall out?"); player("Do you know a potion to make hair fall out?");
stage = 20; stage = 20;
break; break;
case 3: case 3:
player("Have you got any good potions to give away?"); player("Have you got any good potions to give away?");
stage = 140; stage = 140;
break; break;
case 4: case 4:
player("Can you make a potion that makes it seems like I'm dead?"); player("Can you make a potion that makes it seems like I'm dead?");
stage = 40; stage = 40;
break; break;
} }
break; break;
case 10: case 10:
if (player.getInventory().containItems(223, 225)) { if (player.getInventory().containItems(223, 225)) {
npc("Certainly, just hand over the ingredients and 5 coins."); npc("Certainly, just hand over the ingredients and 5 coins.");
stage = 50; stage = 50;
return true; return true;
} }
npc("Yes, but the ingredients are a little hard to find. If you", "ever get them I will make it for you, for a fee."); npc("Yes, but the ingredients are a little hard to find. If you", "ever get them I will make it for you, for a fee.");
stage = 11; stage = 11;
break; break;
case 50: case 50:
if (!player.getInventory().contains(995, 5)) { if (!player.getInventory().contains(995, 5)) {
end(); end();
player.getPacketDispatch().sendMessage("You need 5 gold coins to do that."); player.getPacketDispatch().sendMessage("You need 5 gold coins to do that.");
return true; return true;
} }
interpreter.sendDialogue("You hand over the ingredients and money."); interpreter.sendDialogue("You hand over the ingredients and money.");
stage = 51; stage = 51;
break; break;
case 51: case 51:
if (player.getInventory().remove(POTION_ITEMS)) { if (player.getInventory().remove(POTION_ITEMS)) {
player.getInventory().add(POTION); player.getInventory().add(POTION);
end(); end();
player.getAchievementDiaryManager().finishTask(player, DiaryType.VARROCK, 1, 0); player.getAchievementDiaryManager().finishTask(player, DiaryType.VARROCK, 1, 0);
} }
break; break;
case 11: case 11:
player("So what are the ingredients?"); player("So what are the ingredients?");
stage = 12; stage = 12;
break; break;
case 12: case 12:
npc("You'll need to find the eggs of the deadly red spider and a", "limpwurt root."); npc("You'll need to find the eggs of the deadly red spider and a", "limpwurt root.");
stage = 13; stage = 13;
break; break;
case 13: case 13:
npc("Oh and you'll have to pay me 5 coins."); npc("Oh and you'll have to pay me 5 coins.");
stage = 14; stage = 14;
break; break;
case 14: case 14:
player("Ok, I'll look out for them."); player("Ok, I'll look out for them.");
stage = 15; stage = 15;
break; break;
case 15: case 15:
end(); end();
break; break;
case 20: case 20:
npc("I do indeed. I gave it to my mother. That's why I now live", "alone."); npc("I do indeed. I gave it to my mother. That's why I now live", "alone.");
stage = 21; stage = 21;
break; break;
case 21: case 21:
end(); end();
break; break;
case 30: case 30:
npc("Ok then. Try this potion."); npc("Ok then. Try this potion.");
player.getInventory().add(UNKNOWN_POTION); player.getInventory().add(UNKNOWN_POTION);
stage = 31; stage = 31;
break; break;
case 31: case 31:
end(); end();
break; break;
case 40: case 40:
npc("What a strange and morbid request! I can as it happens.", "The berry of the cadava bush, prepared properly, will", "induce a coma so deep that you will seem to be dead. It's", "very dangerous."); npc("What a strange and morbid request! I can as it happens.", "The berry of the cadava bush, prepared properly, will", "induce a coma so deep that you will seem to be dead. It's", "very dangerous.");
stage = 41; stage = 41;
break; break;
case 41: case 41:
npc("I have the other ingredients, but I'll need you to bring me", "one bunch of cadava berries."); npc("I have the other ingredients, but I'll need you to bring me", "one bunch of cadava berries.");
stage = 42; stage = 42;
break; break;
case 42: case 42:
player("I'll bear that in mind."); player("I'll bear that in mind.");
stage = 43; stage = 43;
break; break;
case 43: case 43:
end(); end();
break; break;
case 140: case 140:
npc("Sorry, charity is not my strong point."); npc("Sorry, charity is not my strong point.");
stage = 141; stage = 141;
break; break;
case 141: case 141:
end(); end();
break; break;
case 500: case 500:
interpreter.sendDialogues(player, null, "I need a Cadava potion to help Romeo and Juliet."); interpreter.sendDialogues(player, null, "I need a Cadava potion to help Romeo and Juliet.");
stage = 501; stage = 501;
break; break;
case 501: case 501:
interpreter.sendDialogues(npc, null, "Cadava potion. It's pretty nasty. And hard to make."); interpreter.sendDialogues(npc, null, "Cadava potion. It's pretty nasty. And hard to make.");
stage = 502; stage = 502;
break; break;
case 502: case 502:
interpreter.sendDialogues(npc, null, "Wing of rat, tail of frog.", "Ear of snake and horn of dog."); interpreter.sendDialogues(npc, null, "Wing of rat, tail of frog.", "Ear of snake and horn of dog.");
stage = 503; stage = 503;
break; break;
case 503: case 503:
interpreter.sendDialogues(npc, null, "I have all that, but i need some Cadava berries."); interpreter.sendDialogues(npc, null, "I have all that, but I need some Cadava berries.");
stage = 504; stage = 504;
break; break;
case 504: case 504:
interpreter.sendDialogues(npc, null, "You will have to find them while I get the rest ready."); interpreter.sendDialogues(npc, null, "You will have to find them while I get the rest ready.");
stage = 505; stage = 505;
break; break;
case 505: case 505:
interpreter.sendDialogues(npc, null, "Bring them here when you have them. But be careful.", "They are nasty."); interpreter.sendDialogues(npc, null, "Bring them here when you have them. But be careful.", "They are nasty.");
stage = 506; stage = 506;
break; break;
case 506: case 506:
player.getQuestRepository().getQuest("Romeo & Juliet").setStage(player, 50); player.getQuestRepository().getQuest("Romeo & Juliet").setStage(player, 50);
interpreter.sendDialogues(player, null, "Ok, thanks."); interpreter.sendDialogues(player, null, "Ok, thanks.");
stage = 507; stage = 507;
break; break;
case 507: case 507:
end(); end();
break; break;
case 637: case 637:
interpreter.sendItemMessage(753, "You hand over the berries."); interpreter.sendItemMessage(753, "You hand over the berries.");
stage = 638; stage = 638;
break; break;
case 638: case 638:
if (player.getInventory().remove(CADAVA_BERRIES)) { if (player.getInventory().remove(CADAVA_BERRIES)) {
npc("Phew! Here is what you need."); npc("Phew! Here is what you need.");
} }
stage = 639; stage = 639;
break; break;
case 639: case 639:
if (!player.getInventory().add(CADAVA_POTION)) { if (!player.getInventory().add(CADAVA_POTION)) {
GroundItemManager.create(new GroundItem(CADAVA_POTION, player.getLocation(), player)); GroundItemManager.create(new GroundItem(CADAVA_POTION, player.getLocation(), player));
} }
interpreter.sendItemMessage(756, "The Apothecary gives you a Cavada potion."); interpreter.sendItemMessage(756, "The Apothecary gives you a Cadava potion.");
stage = 640; stage = 640;
break; break;
case 640: case 640:
player.getQuestRepository().getQuest("Romeo & Juliet").setStage(player, 60); player.getQuestRepository().getQuest("Romeo & Juliet").setStage(player, 60);
end(); end();
break; break;
} }
return true; return true;
} }
@Override @Override
public int[] getIds() { public int[] getIds() {
return new int[] { 638 }; return new int[] { 638 };
} }
} }
@@ -1,181 +1,181 @@
package core.game.content.dialogue; package core.game.content.dialogue;
import core.game.node.entity.npc.NPC; import core.game.node.entity.npc.NPC;
import core.game.node.entity.player.Player; import core.game.node.entity.player.Player;
import core.plugin.Initializable; import core.plugin.Initializable;
import core.game.node.entity.player.link.quest.Quest; import core.game.node.entity.player.link.quest.Quest;
/** /**
* Represents the father lawrence dialogue plugin. * Represents the father lawrence dialogue plugin.
* @author 'Vexia * @author 'Vexia
* @version 1.0 * @version 1.0
*/ */
@Initializable @Initializable
public final class FatherLawrenceDialogue extends DialoguePlugin { public final class FatherLawrenceDialogue extends DialoguePlugin {
/** /**
* Constructs a new {@code FatherLawrenceDialogue} {@code Object}. * Constructs a new {@code FatherLawrenceDialogue} {@code Object}.
*/ */
public FatherLawrenceDialogue() { public FatherLawrenceDialogue() {
/** /**
* empty. * empty.
*/ */
} }
/** /**
* Constructs a new {@code FatherLawrenceDialogu} {@code Object}. * Constructs a new {@code FatherLawrenceDialogu} {@code Object}.
* @param player the player. * @param player the player.
*/ */
public FatherLawrenceDialogue(Player player) { public FatherLawrenceDialogue(Player player) {
super(player); super(player);
} }
@Override @Override
public boolean open(Object... args) { public boolean open(Object... args) {
npc = (NPC) args[0]; npc = (NPC) args[0];
final Quest quest = player.getQuestRepository().getQuest("Romeo & Juliet"); final Quest quest = player.getQuestRepository().getQuest("Romeo & Juliet");
if (quest.getStage(player) < 30) { if (quest.getStage(player) < 30) {
interpreter.sendDialogues(npc, FacialExpression.HALF_GUILTY, "Oh to be a father in the times of whiskey."); interpreter.sendDialogues(npc, FacialExpression.HALF_GUILTY, "Oh to be a father in the times of whiskey.");
stage = 0; stage = 0;
} }
switch (quest.getStage(player)) { switch (quest.getStage(player)) {
case 30: case 30:
interpreter.sendDialogues(npc, null, "\"...and let Saradomin light the way for you... \"", "Urgh!"); interpreter.sendDialogues(npc, null, "\"...and let Saradomin light the way for you... \"", "Urgh!");
stage = 41; stage = 41;
break; break;
case 40: case 40:
interpreter.sendDialogues(npc, null, "Ah, have you found the Apothecary yet? Remember,", "Cadava potion, for Juliet."); interpreter.sendDialogues(npc, null, "Ah, have you found the Apothecary yet? Remember,", "Cadava potion, for Juliet.");
stage = 30; stage = 30;
break; break;
case 50: case 50:
interpreter.sendDialogues(npc, null, "Did you find the Apothecary?"); interpreter.sendDialogues(npc, null, "Did you find the Apothecary?");
stage = 820; stage = 820;
break; break;
case 60: case 60:
case 70: case 70:
interpreter.sendDialogues(npc, null, "Did you find the Apothecary?"); interpreter.sendDialogues(npc, null, "Did you find the Apothecary?");
stage = 820; stage = 820;
break; break;
case 100: case 100:
player("Hi again!"); player("Hi again!");
stage = 0; stage = 0;
break; break;
} }
return true; return true;
} }
@Override @Override
public boolean handle(int interfaceId, int buttonId) { public boolean handle(int interfaceId, int buttonId) {
final Quest quest = player.getQuestRepository().getQuest("Romeo & Juliet"); final Quest quest = player.getQuestRepository().getQuest("Romeo & Juliet");
switch (stage) { switch (stage) {
case 0: case 0:
interpreter.sendDialogues(npc, FacialExpression.HALF_GUILTY, "I sing and I drink and I wake up in gutters."); interpreter.sendDialogues(npc, FacialExpression.HALF_GUILTY, "I sing and I drink and I wake up in gutters.");
stage = 1; stage = 1;
break; break;
case 1: case 1:
interpreter.sendDialogues(npc, FacialExpression.HALF_GUILTY, "Top of the morning to you."); interpreter.sendDialogues(npc, FacialExpression.HALF_GUILTY, "Top of the morning to you.");
stage = 2; stage = 2;
break; break;
case 2: case 2:
end(); end();
break; break;
case 41: case 41:
interpreter.sendDialogues(npc, null, "Can't you see that I'm in the middle of a Sermon?!"); interpreter.sendDialogues(npc, null, "Can't you see that I'm in the middle of a sermon?!");
stage = 42; stage = 42;
break; break;
case 42: case 42:
interpreter.sendDialogues(player, null, "But Romeo sent me!"); interpreter.sendDialogues(player, null, "But Romeo sent me!");
stage = 43; stage = 43;
break; break;
case 43: case 43:
interpreter.sendDialogues(npc, null, "But I'm busy delivering a sermon to my congregation!"); interpreter.sendDialogues(npc, null, "But I'm busy delivering a sermon to my congregation!");
stage = 44; stage = 44;
break; break;
case 44: case 44:
interpreter.sendDialogues(player, null, "Yes well it certainly seems like you have a captive", "audience!"); interpreter.sendDialogues(player, null, "Yes well it certainly seems like you have a captive", "audience!");
stage = 45; stage = 45;
break; break;
case 45: case 45:
interpreter.sendDialogues(npc, null, "Ok, ok...what do you want so I can get rid of you and", "continue with my sermon?"); interpreter.sendDialogues(npc, null, "Ok, ok...what do you want so I can get rid of you and", "continue with my sermon?");
stage = 46; stage = 46;
break; break;
case 46: case 46:
interpreter.sendDialogues(player, null, "Romeo sent me. He says you may be able to help."); interpreter.sendDialogues(player, null, "Romeo sent me. He says you may be able to help.");
stage = 47; stage = 47;
break; break;
case 47: case 47:
interpreter.sendDialogues(npc, null, "Ah Romeo, yes. A fine lad, but a little bit confused."); interpreter.sendDialogues(npc, null, "Ah Romeo, yes. A fine lad, but a little bit confused.");
stage = 48; stage = 48;
break; break;
case 48: case 48:
interpreter.sendDialogues(player, null, "Yes, very confused...Anyway, Romeo wishes to be", "married to Juliet! She must be rescued from her", "father's control!"); interpreter.sendDialogues(player, null, "Yes, very confused...Anyway, Romeo wishes to be", "married to Juliet! She must be rescued from her", "father's control!");
stage = 49; stage = 49;
break; break;
case 49: case 49:
interpreter.sendDialogues(npc, null, "I agree, and I think I have an idea! A potion to make", "her appear dead..."); interpreter.sendDialogues(npc, null, "I agree, and I think I have an idea! A potion to make", "her appear dead...");
stage = 50; stage = 50;
break; break;
case 50: case 50:
interpreter.sendDialogues(player, null, "Dead! Sounds a bit creepy to me...but please, continue."); interpreter.sendDialogues(player, null, "Dead! Sounds a bit creepy to me...but please, continue.");
stage = 51; stage = 51;
break; break;
case 51: case 51:
interpreter.sendDialogues(npc, null, "The potion will only make Juliet 'appear' dead...then", "she'll be taken to the crypt..."); interpreter.sendDialogues(npc, null, "The potion will only make Juliet 'appear' dead...then", "she'll be taken to the crypt...");
stage = 52; stage = 52;
break; break;
case 52: case 52:
interpreter.sendDialogues(player, null, "Crypt! Again...very creepy! You must have some", "strange hobbies."); interpreter.sendDialogues(player, null, "Crypt! Again...very creepy! You must have some", "strange hobbies.");
stage = 53; stage = 53;
break; break;
case 53: case 53:
interpreter.sendDialogues(npc, null, "Then Romeo can collect her from the crypt! Go to the", "Apothercary, tell him I sent you and that you'll need a", "'Cadava' potion."); interpreter.sendDialogues(npc, null, "Then Romeo can collect her from the crypt! Go to the", "Apothercary, tell him I sent you and that you'll need a", "'Cadava' potion.");
stage = 54; stage = 54;
break; break;
case 54: case 54:
interpreter.sendDialogues(player, null, "Apart from the strong overtones of death, this is", "turning out to be a real love story."); interpreter.sendDialogues(player, null, "Apart from the strong overtones of death, this is", "turning out to be a real love story.");
stage = 55; stage = 55;
break; break;
case 55: case 55:
quest.setStage(player, 40); quest.setStage(player, 40);
end(); end();
break; break;
case 30: case 30:
end(); end();
break; break;
case 820: case 820:
interpreter.sendDialogues(player, null, "Yes I did. He's told me I must find some Cadava", "berries."); interpreter.sendDialogues(player, null, "Yes I did. He's told me I must find some Cadava", "berries.");
stage = 821; stage = 821;
break; break;
case 821: case 821:
interpreter.sendDialogues(npc, null, "Well, good luck with that...they're quite tricky to find."); interpreter.sendDialogues(npc, null, "Well, good luck with that...they're quite tricky to find.");
stage = 822; stage = 822;
break; break;
case 822: case 822:
interpreter.sendDialogues(player, null, "Any clues where I can start to look?"); interpreter.sendDialogues(player, null, "Any clues where I can start to look?");
stage = 823; stage = 823;
break; break;
case 823: case 823:
interpreter.sendDialogues(npc, null, "I heard some kids saying they saw some the other day.", "They were visiting the mining place to the south east", "Varrock."); interpreter.sendDialogues(npc, null, "I heard some kids saying they saw some the other day.", "They were visiting the mining place to the south east", "Varrock.");
stage = 824; stage = 824;
break; break;
case 824: case 824:
interpreter.sendDialogues(player, null, "Ok, that's as good a place to start looking as any."); interpreter.sendDialogues(player, null, "Ok, that's as good a place to start looking as any.");
stage = 825; stage = 825;
break; break;
case 825: case 825:
end(); end();
break; break;
} }
return true; return true;
} }
@Override @Override
public DialoguePlugin newInstance(Player player) { public DialoguePlugin newInstance(Player player) {
return new FatherLawrenceDialogue(player); return new FatherLawrenceDialogue(player);
} }
@Override @Override
public int[] getIds() { public int[] getIds() {
return new int[] { 640 }; return new int[] { 640 };
} }
} }
@@ -1,224 +1,224 @@
package core.game.content.dialogue; package core.game.content.dialogue;
import core.game.node.entity.player.Player; import core.game.node.entity.player.Player;
import core.game.node.entity.player.link.quest.Quest; import core.game.node.entity.player.link.quest.Quest;
import core.plugin.Initializable; import core.plugin.Initializable;
import core.game.node.item.Item; import core.game.node.item.Item;
/** /**
* Represents the dialogue plugin used for the hetty npc. * Represents the dialogue plugin used for the hetty npc.
* @author 'Vexia * @author 'Vexia
* @version 1.0 * @version 1.0
*/ */
@Initializable @Initializable
public final class HettyDialogue extends DialoguePlugin { public final class HettyDialogue extends DialoguePlugin {
/** /**
* Constructs a new {@code HettyDialogue} {@code Object}. * Constructs a new {@code HettyDialogue} {@code Object}.
*/ */
public HettyDialogue() { public HettyDialogue() {
/** /**
* empty. * empty.
*/ */
} }
/** /**
* Constructs a new {@code HettyDialogue} {@code Object}. * Constructs a new {@code HettyDialogue} {@code Object}.
* @param player the player. * @param player the player.
*/ */
public HettyDialogue(Player player) { public HettyDialogue(Player player) {
super(player); super(player);
} }
@Override @Override
public DialoguePlugin newInstance(Player player) { public DialoguePlugin newInstance(Player player) {
return new HettyDialogue(player); return new HettyDialogue(player);
} }
@Override @Override
public boolean open(Object... args) { public boolean open(Object... args) {
Quest quest = player.getQuestRepository().getQuest("Witch's Potion"); Quest quest = player.getQuestRepository().getQuest("Witch's Potion");
if (quest.isCompleted(player)) { if (quest.isCompleted(player)) {
interpreter.sendDialogues(307, FacialExpression.HALF_GUILTY, "How's your magic coming along?"); interpreter.sendDialogues(307, FacialExpression.HALF_GUILTY, "How's your magic coming along?");
stage = 0; stage = 0;
} }
switch (quest.getStage(player)) { switch (quest.getStage(player)) {
case 0: case 0:
interpreter.sendDialogues(307, FacialExpression.HALF_GUILTY, "What could you want with an old woman like me?"); interpreter.sendDialogues(307, FacialExpression.HALF_GUILTY, "What could you want with an old woman like me?");
stage = 11; stage = 11;
break; break;
case 20: case 20:
interpreter.sendDialogues(307, FacialExpression.HALF_GUILTY, "So have you found the things for the potion?"); interpreter.sendDialogues(307, FacialExpression.HALF_GUILTY, "So have you found the things for the potion?");
stage = 100; stage = 100;
break; break;
case 40: case 40:
if (args.length == 2) { if (args.length == 2) {
interpreter.sendDialogue("You drink from the cauldron, it tastes horrible! You feel yourself", "imbued with power."); interpreter.sendDialogue("You drink from the cauldron, it tastes horrible! You feel yourself", "imbued with power.");
stage = 41; stage = 41;
} else { } else {
interpreter.sendDialogues(307, FacialExpression.HALF_GUILTY, "Well are you going to drink the potion or not?"); interpreter.sendDialogues(307, FacialExpression.HALF_GUILTY, "Well are you going to drink the potion or not?");
stage = 500; stage = 500;
} }
break; break;
} }
return true; return true;
} }
@Override @Override
public boolean handle(int interfaceId, int buttonId) { public boolean handle(int interfaceId, int buttonId) {
Quest quest = player.getQuestRepository().getQuest("Witch's Potion"); Quest quest = player.getQuestRepository().getQuest("Witch's Potion");
switch (stage) { switch (stage) {
case 0: case 0:
interpreter.sendDialogues(player, FacialExpression.HALF_GUILTY, "I'm practicing and slowly getting better."); interpreter.sendDialogues(player, FacialExpression.HALF_GUILTY, "I'm practicing and slowly getting better.");
stage = 1; stage = 1;
break; break;
case 1: case 1:
interpreter.sendDialogues(307, FacialExpression.HALF_GUILTY, "Good, good."); interpreter.sendDialogues(307, FacialExpression.HALF_GUILTY, "Good, good.");
stage = 2; stage = 2;
break; break;
case 2: case 2:
end(); end();
break; break;
case 11: case 11:
interpreter.sendOptions("Select an Option", "I am in search of a quest.", "I've heard that you are a witch."); interpreter.sendOptions("Select an Option", "I am in search of a quest.", "I've heard that you are a witch.");
stage = 12; stage = 12;
break; break;
case 12: case 12:
switch (buttonId) { switch (buttonId) {
case 1: case 1:
interpreter.sendDialogues(player, FacialExpression.HALF_GUILTY, "I am in search of a quest."); interpreter.sendDialogues(player, FacialExpression.HALF_GUILTY, "I am in search of a quest.");
stage = 13; stage = 13;
break; break;
case 2: case 2:
interpreter.sendDialogues(player, FacialExpression.HALF_GUILTY, "I've heard that you are a witch."); interpreter.sendDialogues(player, FacialExpression.HALF_GUILTY, "I've heard that you are a witch.");
stage = 20; stage = 20;
break; break;
} }
break; break;
case 13: case 13:
interpreter.sendDialogues(307, FacialExpression.HALF_GUILTY, "Hmmm... Maybe I can think of something for you."); interpreter.sendDialogues(307, FacialExpression.HALF_GUILTY, "Hmmm... Maybe I can think of something for you.");
stage = 14; stage = 14;
break; break;
case 14: case 14:
interpreter.sendDialogues(307, FacialExpression.HALF_GUILTY, "Would you like to become more proficient in the dark", "arts?"); interpreter.sendDialogues(307, FacialExpression.HALF_GUILTY, "Would you like to become more proficient in the dark", "arts?");
stage = 15; stage = 15;
break; break;
case 15: case 15:
interpreter.sendOptions("Select an Option", "Yes help me become one with my darker side.", "No I have my prinicples and honour."); interpreter.sendOptions("Select an Option", "Yes help me become one with my darker side.", "No I have my prinicples and honour.");
stage = 16; stage = 16;
break; break;
case 16: case 16:
switch (buttonId) { switch (buttonId) {
case 1: case 1:
interpreter.sendDialogues(player, FacialExpression.HALF_GUILTY, "Yes help me become one with my darker side."); interpreter.sendDialogues(player, FacialExpression.HALF_GUILTY, "Yes help me become one with my darker side.");
stage = 30; stage = 30;
break; break;
case 2: case 2:
interpreter.sendDialogues(player, FacialExpression.HALF_GUILTY, "No I have m principles and honour."); interpreter.sendDialogues(player, FacialExpression.HALF_GUILTY, "No I have m principles and honour.");
stage = 17; stage = 17;
break; break;
} }
break; break;
case 17: case 17:
interpreter.sendDialogues(307, FacialExpression.HALF_GUILTY, "Suit yourself, but you're missing out."); interpreter.sendDialogues(307, FacialExpression.HALF_GUILTY, "Suit yourself, but you're missing out.");
stage = 18; stage = 18;
break; break;
case 18: case 18:
end(); end();
break; break;
case 20: case 20:
interpreter.sendDialogues(307, FacialExpression.HALF_GUILTY, "Yes it does seem to be getting fairly common", "knowledge."); interpreter.sendDialogues(307, FacialExpression.HALF_GUILTY, "Yes it does seem to be getting fairly common", "knowledge.");
stage = 21; stage = 21;
break; break;
case 21: case 21:
interpreter.sendDialogues(307, FacialExpression.HALF_GUILTY, "I fear I may get a visit from the witch hunter of", "Falador before long."); interpreter.sendDialogues(307, FacialExpression.HALF_GUILTY, "I fear I may get a visit from the witch hunter of", "Falador before long.");
stage = 22; stage = 22;
break; break;
case 22: case 22:
end(); end();
break; break;
case 30: case 30:
interpreter.sendDialogues(307, FacialExpression.HALF_GUILTY, "Ok I'm going to make a potion to help bring out your", "darker self."); interpreter.sendDialogues(307, FacialExpression.HALF_GUILTY, "Ok I'm going to make a potion to help bring out your", "darker self.");
stage = 31; stage = 31;
break; break;
case 31: case 31:
interpreter.sendDialogues(307, FacialExpression.HALF_GUILTY, "You will need certain ingredients."); interpreter.sendDialogues(307, FacialExpression.HALF_GUILTY, "You will need certain ingredients.");
stage = 32; stage = 32;
break; break;
case 32: case 32:
interpreter.sendDialogues(player, FacialExpression.HALF_GUILTY, "What do i need?"); interpreter.sendDialogues(player, FacialExpression.HALF_GUILTY, "What do I need?");
stage = 33; stage = 33;
break; break;
case 33: case 33:
interpreter.sendDialogues(307, FacialExpression.HALF_GUILTY, "You need an eye of newt, a rat's tail, and onion... Oh", "and a piece of burnt meat."); interpreter.sendDialogues(307, FacialExpression.HALF_GUILTY, "You need an eye of newt, a rat's tail, and onion... Oh", "and a piece of burnt meat.");
stage = 34; stage = 34;
break; break;
case 34: case 34:
interpreter.sendDialogues(player, FacialExpression.HALF_GUILTY, "Great, I'll go get them."); interpreter.sendDialogues(player, FacialExpression.HALF_GUILTY, "Great, I'll go get them.");
stage = 35; stage = 35;
break; break;
case 35: case 35:
quest.start(player); quest.start(player);
quest.setStage(player, 20); quest.setStage(player, 20);
end(); end();
break; break;
case 100: case 100:
// Her:Well I can't make the potion without them! // Her:Well I can't make the potion without them!
// Remember.../You // Remember.../You
// need an eye of newt, a rat's tail, an onion, and a/piece of // need an eye of newt, a rat's tail, an onion, and a/piece of
// burnt // burnt
// meat. Off you go dear! Me:end(); // meat. Off you go dear! Me:end();
if (!player.getInventory().containItems(1957, 300, 2146, 221)) { if (!player.getInventory().containItems(1957, 300, 2146, 221)) {
interpreter.sendDialogues(player, FacialExpression.HALF_GUILTY, "I'm afraid I don't have all of them yet."); interpreter.sendDialogues(player, FacialExpression.HALF_GUILTY, "I'm afraid I don't have all of them yet.");
stage = 101; stage = 101;
} else { } else {
interpreter.sendDialogues(player, FacialExpression.HALF_GUILTY, "Yes I have everything!"); interpreter.sendDialogues(player, FacialExpression.HALF_GUILTY, "Yes I have everything!");
stage = 110; stage = 110;
} }
break; break;
case 110: case 110:
interpreter.sendDialogues(307, FacialExpression.HALF_GUILTY, "Excellent, can I have them then?"); interpreter.sendDialogues(307, FacialExpression.HALF_GUILTY, "Excellent, can I have them then?");
stage = 111; stage = 111;
break; break;
case 111: case 111:
interpreter.sendDialogue("You pass the ingredients to Hetty and she puts them all into her", "cauldron. Hetty closes her eyes and begins to chant. The cauldron", "bubbles mysteriously."); interpreter.sendDialogue("You pass the ingredients to Hetty and she puts them all into her", "cauldron. Hetty closes her eyes and begins to chant. The cauldron", "bubbles mysteriously.");
stage = 112; stage = 112;
break; break;
case 112: case 112:
interpreter.sendDialogues(player, FacialExpression.HALF_GUILTY, "Well, is it ready?"); interpreter.sendDialogues(player, FacialExpression.HALF_GUILTY, "Well, is it ready?");
stage = 113; stage = 113;
break; break;
case 113: case 113:
if (player.getInventory().remove(new Item(1957), new Item(300), new Item(2146), new Item(221))) { if (player.getInventory().remove(new Item(1957), new Item(300), new Item(2146), new Item(221))) {
quest.setStage(player, 40); quest.setStage(player, 40);
interpreter.sendDialogues(307, FacialExpression.HALF_GUILTY, "Ok, now drink from the cauldron."); interpreter.sendDialogues(307, FacialExpression.HALF_GUILTY, "Ok, now drink from the cauldron.");
stage = 114; stage = 114;
} }
break; break;
case 114: case 114:
end(); end();
break; break;
case 101: case 101:
interpreter.sendDialogues(307, FacialExpression.HALF_GUILTY, "Well I can't make the potion without them! Remember...", "You need an eye of newt, a rat's tail, an onion, and a", "You need an eye of newt, a rat's tail, an onion, and a", "piece of burnt meat. Off you go dear!"); interpreter.sendDialogues(307, FacialExpression.HALF_GUILTY, "Well I can't make the potion without them! Remember...", "You need an eye of newt, a rat's tail, an onion, and a", "You need an eye of newt, a rat's tail, an onion, and a", "piece of burnt meat. Off you go dear!");
stage = 102; stage = 102;
break; break;
case 102: case 102:
end(); end();
break; break;
case 500: case 500:
end(); end();
break; break;
case 41: case 41:
end(); end();
quest.finish(player); quest.finish(player);
player.getQuestRepository().syncronizeTab(player); player.getQuestRepository().syncronizeTab(player);
break; break;
} }
return true; return true;
} }
@Override @Override
public int[] getIds() { public int[] getIds() {
return new int[] { 307 }; return new int[] { 307 };
} }
} }