Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- NpcTalk("Hey i have heard you are looking for woad leaves");
- int choice = showMenu(new String[] {"Well yes I am. Can you get some?", "Who told you that?"});
- if(choice == 0) {
- yaiam();
- } else if(choice == 1) {
- whotold();
- }
- }
- private void yaiam() {
- NpcTalk("Yes I have some somewhere");
- PlayerTalk("Can I buy one please?");
- NpcTalk("How much are you willing to pay?");
- int choice = showMenu(new String[] {"How about 5 coins?", "How about 10 coins?", "How about 15 coins?", "How about 20 coins?"});
- if(choice == 0) {
- five();
- } else if(choice == 1) {
- ten();
- } else if(choice == 1) {
- fifteen();
- } else if(choice == 1) {
- twenty();
- }
- }
- private void five() {
- NpcTalk("No no that's far too little. Woad leaves are hard to get you know");
- NpcTalk("I used to have plenty but someone kept stealing them off me");
- } else {
- PlayerTalk("I don't have enough coins to buy the leaves. I'll come back later");
- }
- }
- private void ten() {
- NpcTalk("No no that's far too little. Woad leaves are hard to get you know");
- NpcTalk("I used to have plenty but someone kept stealing them off me");
- } else {
- PlayerTalk("I don't have enough coins to buy the leaves. I'll come back later");
- }
- }
- private void fifteen() {
- NpcTalk("Mmmm ok that sounds fair.");
- SendMessage("You give wyson 15 coins");
- RemoveItem(10, 15);
- SendMessage("Wyson the gardener gives you some woad leaves");
- AddItem(281, 1); // 1 woad leaf
- } else {
- PlayerTalk("I don't have enough coins to buy the leaves. I'll come back later");
- }
- }
- private void twenty() {
- NpcTalk("Ok that's more than fair.");
- SendMessage("You give wyson 20 coins");
- RemoveItem(10, 20);
- SendMessage("Wyson the gardener gives you some woad leaves");
- AddItem(281, 1);
- NpcTalk("Here have some more you're a generous person");
- SendMessage("Wyson the gardener gives you some woad leaves");
- AddItem(281, 1);
- } else {
- PlayerTalk("I don't have enough coins to buy the leaves. I'll come back later");
- }
- }
- private void whotold() {
- NpcTalk("I can't remember now. Someone who visits this park");
- NpcTalk("I happen to have some woad leaves lying around");
- NpcTalk("Would you like to buy some?");
- int choice = showMenu(new String[] {"Oh yes please", "No thanks not right now"});
- if(choice == 0) {
- yesplz();
- } else if(choice == 1) {
- notnow();
- }
- }
- private void yesplz() {
- NpcTalk("How much are you willing to pay?");
- int choice = showMenu(new String[] {"How about 5 coins?", "How about 10 coins?", "How about 15 coins?", "How about 20 coins?"});
- if(choice == 0) {
- five();
- } else if(choice == 1) {
- ten();
- } else if(choice == 1) {
- fifteen();
- } else if(choice == 1) {
- twenty();
- }
- }
- private void notnow() {
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment