summaryrefslogtreecommitdiff
path: root/npc/merchants
diff options
context:
space:
mode:
authorL0ne_W0lf <L0ne_W0lf@54d463be-8e91-2dee-dedb-b68131a5f0ec>2007-11-25 20:55:07 +0000
committerL0ne_W0lf <L0ne_W0lf@54d463be-8e91-2dee-dedb-b68131a5f0ec>2007-11-25 20:55:07 +0000
commit3f131f30d872f3a97ba13e67030d727c7a0c8702 (patch)
tree4210a97c7f29cb4f4b291e148043df727cac045b /npc/merchants
parentc723eb1e797490754cb061a129bf6db23873ecda (diff)
downloadhercules-3f131f30d872f3a97ba13e67030d727c7a0c8702.tar.gz
hercules-3f131f30d872f3a97ba13e67030d727c7a0c8702.tar.bz2
hercules-3f131f30d872f3a97ba13e67030d727c7a0c8702.tar.xz
hercules-3f131f30d872f3a97ba13e67030d727c7a0c8702.zip
git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@11801 54d463be-8e91-2dee-dedb-b68131a5f0ec
Diffstat (limited to 'npc/merchants')
-rw-r--r--npc/merchants/novice_exchange.txt473
1 files changed, 353 insertions, 120 deletions
diff --git a/npc/merchants/novice_exchange.txt b/npc/merchants/novice_exchange.txt
index 1d4b14012..ad87dc4ae 100644
--- a/npc/merchants/novice_exchange.txt
+++ b/npc/merchants/novice_exchange.txt
@@ -3,157 +3,390 @@
//===== By: ==================================================
//= ???, eAthena Team
//===== Current Version: =====================================
-//= 1.1a
+//= 1.2
//===== Compatible With: =====================================
//= eAthena 1.0+
//===== Description: =========================================
-//= Exchanges your cheap loot to Red Potions.
-//= Official NPC.
+//= [Aegis COnversion]
+//= Exchanges your Basic Monster drops for Red Potions.
//===== Additional Comments: =================================
-//= 1.1 Made it as a function. U can add your own Merchs [Lupus]
-//= 1.1a Fixed item select [KarLaeda]
+//= 1.2 Rescripted to Aegis 10.standards. [L0ne_W0lf[
+//= Made it easier to add new items to exhange list
+//= meaning only the exchange is done in a function now.
//============================================================
-function script F_NMerch {
- mes "["+getarg(0)+"]";
- if((Weight*100)/MaxWeight >= 90){
- mes "You will exceed your weight limit if you exchange for the Red Potions.";
+prontera,123,102,5 script Merchant#pron 85,{
+ set .@now_weight,MaxWeight-Weight;
+ if (.@now_weight < 6301) {
+ mes "[Merchant]";
+ mes "Haha!";
+ mes "What are you, superhuman?";
+ mes "You're carrying so much stuff!";
+ mes "You better put some of that";
+ mes "into Kafra Storage~";
close;
}
+ mes "[Merchant]";
mes "Good day!";
- mes "Do you have any collection items such as "+getitemname(getarg(1))+" or "+getitemname(getarg(3))+"?";
- if(getarg(5))
- mes "...how about "+getitemname(getarg(5))+"?..";
- mes "Oh, yeah, I need those for something.";
+ mes "Have you collected any";
+ mes "items like Shells or Fluff?";
+ mes "What about Jellopies? Oh yeah,";
+ mes "I need those for something.";
next;
- mes "["+getarg(0)+"]";
- mes "Of course I am not asking you to give those for free!";
- mes "How about... if I give you 1 Red";
- mes "Potion for "+getarg(2)+" "+getitemname(getarg(1))+" or "+getarg(4)+" "+getitemname(getarg(3))+"?";
- if(getarg(5))
- mes "Or "+getarg(6)+" "+getitemname(getarg(5))+"?";
+ mes "[Merchant]";
+ mes "Of course, I won't ask you";
+ mes "to give me that stuff for free. What about if I trade a Red Potion for 5 Shells, 10 Fluff,";
+ mes "or 10 Jellopies?";
next;
- switch (select("Sure!:Think you're ripping me off...:No, thanks")) {
+ switch(select("Sure!:I think it's a rip-off!:No, thanks.")) {
case 1:
- mes "["+getarg(0)+"]";
- mes "So which item do you bring me?";
- mes ""+getitemname(getarg(1))+"? "+getitemname(getarg(3))+"?";
- if(getarg(5))
- mes "Or "+getitemname(getarg(5))+"?";
+ mes "[Merchant]";
+ mes "So which item do";
+ mes "you want to bring me?";
+ mes "Shells, Fluffs, or Jellopies?";
next;
- if(getarg(5))
- set @i,select(""+getitemname(getarg(1))+"",""+getitemname(getarg(3))+"",""+getitemname(getarg(5))+"","Cancel");
- else
- set @i,select(""+getitemname(getarg(1))+"",""+getitemname(getarg(3))+"","Cancel");
- if(@i==4 || (@i==3 && !getarg(5))) {
- mes "["+getarg(0)+"]";
- mes "Sure, no problem.";
- close;
- }
- set @item,getarg(@i*2-1);
- set @amount,getarg(@i*2);
- set @have,countitem(@item);
- if(@have < @amount) {
- mes "["+getarg(0)+"]";
- mes "Hey, where are all those";
- mes getitemname(@item)+" you promised?";
+ switch(select("Shells:Jellopies:Fluff:Cancel")) {
+ case 1: callfunc "F_PotExchange",935,5;
+ case 2: callfunc "F_PotExchange",909,10;
+ case 3: callfunc "F_PotExchange",914,10;
+ case 4:
+ mes "[Merchant]";
+ mes "Sure~";
+ mes "No problem.";
close;
}
- mes "["+getarg(0)+"]";
- mes "Okay, let me take a look at the stuff you brought.";
- next;
- set @max,@have / @amount;
- mes "["+getarg(0)+"]";
- mes "You have total "+@have+" "+getitemname(@item)+"...";
- mes "I can give you";
- mes "total "+@max+" Red Potion for those.";
- next;
- mes "["+getarg(0)+"]";
- mes "What do you say? Deal?";
+ case 2:
+ mes "[Merchant]";
+ mes "A rip-off...?";
+ mes "If you check the market value";
+ mes "of the items being traded, I'm actually the one getting";
+ mes "ripped off here.";
+ close;
+ case 3:
+ mes "[Merchant]";
+ mes "Alright,";
+ mes "no problem.";
+ mes "But come back to me";
+ mes "if you change your mind.";
+ close;
+ }
+}
+
+morocc,180,259,3 script Merchant#morroc 85,{
+ set .@now_weight,MaxWeight-Weight;
+ if (.@now_weight < 6301) {
+ mes "[Merchant]";
+ mes "Haha!";
+ mes "What are you, superhuman?";
+ mes "You're carrying so much stuff!";
+ mes "You better put some of that";
+ mes "into Kafra Storage~";
+ close;
+ }
+ mes "[Merchant]";
+ mes "Good day!";
+ mes "Have you collected any";
+ mes "Shells or Feathers of Bird?";
+ mes "What about Jellopies? Oh yeah,";
+ mes "I need those for something.";
+ next;
+ mes "[Merchant]";
+ mes "Of course, I won't ask you";
+ mes "to give me that stuff for free. What about if I trade a Red Potion for 5 Shells, 7 Feathers of Bird";
+ mes "or 10 Jellopies?";
+ next;
+ switch(select("Sure!:I think it's a rip-off!:No, thanks.")) {
+ case 1:
+ mes "[Merchant]";
+ mes "So which item do";
+ mes "you want to bring me?";
+ mes "Shells, Feathers of Birds,";
+ mes "or Jellopies?";
next;
- if(select("Deal.:No deal.")==2) {
- mes "["+getarg(0)+"]";
- mes "Bah~ whatever.";
- mes "Bah!";
+ switch(select("Shells:Feathers of Birds:Jellopies:Cancel")) {
+ case 1: callfunc "F_PotExchange",935,5;
+ case 2: callfunc "F_PotExchange",916,7;
+ case 3: callfunc "F_PotExchange",909,10;
+ case 4:
+ mes "[Merchant]";
+ mes "Sure~";
+ mes "No problem.";
close;
}
- mes "["+getarg(0)+"]";
- mes "You know the exact number of Red Potions";
- mes "you can receive for "+getitemname(@item)+", don't you?";
+ case 2:
+ mes "[Merchant]";
+ mes "A rip-off...?";
+ mes "If you check the market value";
+ mes "of the items being traded, I'm actually the one getting";
+ mes "ripped off here.";
+ close;
+ case 3:
+ mes "[Merchant]";
+ mes "Alright,";
+ mes "no problem.";
+ mes "But come back to me";
+ mes "if you change your mind.";
+ close;
+ }
+}
+
+payon,200,134,5 script Merchant#pay 85,{
+ set .@now_weight,MaxWeight-Weight;
+ if (.@now_weight < 6301) {
+ mes "[Merchant]";
+ mes "Haha!";
+ mes "What are you, superhuman?";
+ mes "You're carrying so much stuff!";
+ mes "You better put some of that";
+ mes "into Kafra Storage~";
+ close;
+ }
+ mes "[Merchant]";
+ mes "Good day!";
+ mes "Have you collected";
+ mes "items like Tree Roots?";
+ mes "What about Jellopies? Oh yeah,";
+ mes "I need those for something.";
+ next;
+ mes "[Merchant]";
+ mes "Of course, I won't ask you";
+ mes "to give me that stuff for free. What about if I trade a Red Potion for 6 Tree Roots or 10 Jellopies?";
+ next;
+ switch(select("Sure!:I think it's a rip-off!:No, thanks.")) {
+ case 1:
+ mes "[Merchant]";
+ mes "So which item do";
+ mes "you want to bring me?";
+ mes "Tree Roots, or Jellopies?";
next;
- mes "["+getarg(0)+"]";
- mes "You can get Red Potions";
- mes "from minimum 1 to maximum 100 at once.";
- mes "If you change your mind, enter '0'";
- mes "to cancel.";
- while(1) {
- next;
- input @val;
- if(@val<0 || @val>100) {
- mes "["+getarg(0)+"]";
- mes "Uh oh, the number you entered";
- mes "seemed incorrect.";
- mes "You'd better check how many Red";
- mes "Potions you can get.";
- continue;
- }
- break;
- }
- mes "["+getarg(0)+"]";
- if(@val == 0) {
- mes "What...how the hell did you even";
- mes "bother to talk to me?";
- mes "Leave, I don't deal with whimsical";
- mes "people.";
+ switch(select("Tree Roots:Jellopies:Cancel")) {
+ case 1: callfunc "F_PotExchange",902,6;
+ case 2: callfunc "F_PotExchange",909,10;
+ case 3:
+ mes "[Merchant]";
+ mes "Sure~";
+ mes "No problem.";
close;
}
- if(@val > @max) {
- mes "Uh oh, the number you entered";
- mes "seemed incorrect.";
- mes "You'd better check how many Red";
- mes "Potions you can get.";
- close;
- }
- delitem @item,@amount*@val;
- getitem 501,@val;
- mes "There you go!";
- mes "Thanks, it was a good deal.";
- close;
case 2:
- mes "["+getarg(0)+"]";
- mes "Did you say I am ripping you off?!";
- mes "You got to know how ignorant that comment was!";
- next;
- mes "["+getarg(0)+"]";
- mes "When you check the price of each item,";
- mes "I am doing a losing business.";
- mes "If you don't want to do then, fine!";
+ mes "[Merchant]";
+ mes "A rip-off...?";
+ mes "If you check the market value";
+ mes "of the items being traded, I'm actually the one getting";
+ mes "ripped off here.";
close;
case 3:
- mes "["+getarg(0)+"]";
- mes "Hah, no problem.";
- mes "Bah!";
+ mes "[Merchant]";
+ mes "Alright,";
+ mes "no problem.";
+ mes "But come back to me";
+ mes "if you change your mind.";
close;
}
}
-prontera,123,102,5 script Merchant#1 85,{
- callfunc "F_NMerch","Merchant",935,5,914,10,909,10;
-}
-
-geffen,173,88,5 script Merchant#2 85,{
- callfunc "F_NMerch","Merchant",935,5,915,6,909,10;
+aldebaran,152,63,5 script Merchant#alde 85,{
+ set .@now_weight,MaxWeight-Weight;
+ if (.@now_weight < 6301) {
+ mes "[Merchant]";
+ mes "Haha!";
+ mes "What are you, superhuman?";
+ mes "You're carrying so much stuff!";
+ mes "You better put some of that";
+ mes "into Kafra Storage~";
+ close;
+ }
+ mes "[Merchant]";
+ mes "Good day!";
+ mes "Have you collected any";
+ mes "Worm Peelings or Feather of Birds?";
+ mes "How about Jellopies? Oh yeah,";
+ mes "I need those for something.";
+ next;
+ mes "[Merchant]";
+ mes "Of course, I won't ask you";
+ mes "to give me that stuff for free. What about if I trade a Red Potion for 1 Worm Peeling, 7 Feather of Birds, or 10 Jellopies?";
+ next;
+ switch(select("Sure!:I think it's a rip-off!:No, thanks.")) {
+ case 1:
+ mes "[Merchant]";
+ mes "So which item do";
+ mes "you want to bring me?";
+ mes "Feathers of Birds?";
+ mes "Worm Peelings?";
+ mes "Or Jellopies?";
+ next;
+ switch(select("Worm Peelings:Feathers of Birds:Jellopies:Cancel")) {
+ case 1: callfunc "F_PotExchange",955,1;
+ case 2: callfunc "F_PotExchange",916,7;
+ case 3: callfunc "F_PotExchange",909,10;
+ case 4:
+ mes "[Merchant]";
+ mes "Sure~";
+ mes "No problem.";
+ close;
+ }
+ case 2:
+ mes "[Merchant]";
+ mes "A rip-off...?";
+ mes "If you check the market value";
+ mes "of the items being traded, I'm actually the one getting";
+ mes "ripped off here.";
+ close;
+ case 3:
+ mes "[Merchant]";
+ mes "Alright,";
+ mes "no problem.";
+ mes "But come back to me";
+ mes "if you change your mind.";
+ close;
+ }
}
-morocc,180,259,3 script Merchant#3 85,{
- callfunc "F_NMerch","Merchant",935,5,916,7,909,10;
+geffen,173,88,5 script Merchant#geff 85,{
+ set .@now_weight,MaxWeight-Weight;
+ if (.@now_weight < 6301) {
+ mes "[Merchant]";
+ mes "Haha!";
+ mes "What are you, superhuman?";
+ mes "You're carrying so much stuff!";
+ mes "You better put some of that";
+ mes "into Kafra Storage~";
+ close;
+ }
+ mes "[Merchant]";
+ mes "Good day!";
+ mes "Have you collected any";
+ mes "items like Shells or Chrysalises?";
+ mes "What about Jellopies? Oh yeah,";
+ mes "I need those for something.";
+ next;
+ mes "[Merchant]";
+ mes "Of course, I won't ask you";
+ mes "to give me that stuff for free. What about if I trade a Red Potion for 5 Shells or 6 Chrysalises, or 10 Jellopies?";
+ next;
+ switch(select("Sure!:I think it's a rip-off!:No, thanks.")) {
+ case 1:
+ mes "[Merchant]";
+ mes "So which item do";
+ mes "you want to bring me?";
+ mes "Shells, Chrysalises, or Jellopies?";
+ next;
+ switch(select("Shells:Chrysalises:Jellopies:Cancel")) {
+ case 1: callfunc "F_PotExchange",935,5;
+ case 2: callfunc "F_PotExchange",915,6;
+ case 3: callfunc "F_PotExchange",909,10;
+ case 4:
+ mes "[Merchant]";
+ mes "Sure~";
+ mes "No problem.";
+ close;
+ }
+ case 2:
+ mes "[Merchant]";
+ mes "A rip-off...?";
+ mes "If you check the market value";
+ mes "of the items being traded, I'm actually the one getting";
+ mes "ripped off here.";
+ close;
+ case 3:
+ mes "[Merchant]";
+ mes "Alright,";
+ mes "no problem.";
+ mes "But come back to me";
+ mes "if you change your mind.";
+ close;
+ }
}
-aldebaran,152,63,5 script Merchant#4 85,{
- callfunc "F_NMerch","Merchant",955,1,916,7,909,10;
+function script F_PotExchange {
+ if (countitem(getarg(0)) < getarg(1)) {
+ mes "[Merchant]";
+ mes "Hey, where are";
+ mes "all those Shells";
+ mes "that you promised?";
+ mes "Give me "+getitemname(getarg(0))+"!";
+ close;
+ }
+ else {
+ mes "[Merchant]";
+ mes "Okay, let me check";
+ mes "how many Shells you";
+ mes "have on you. Hmm...";
+ next;
+ mes "[Merchant]";
+ mes "You have";
+ mes "a total of " + countitem(getarg(0)) + " "+getitemname(getarg(0))+".";
+ mes "I can give you a total";
+ mes "of " + (countitem(getarg(0))/getarg(1)) + " Red Potions for those.";
+ next;
+ mes "[Merchant]";
+ mes "What do you say?";
+ mes "Do we have a deal?";
+ next;
+ if (select("Deal.:No deal.") == 1) {
+ mes "[Merchant]";
+ mes "You know the exact";
+ mes "number of Red Potions";
+ mes "you want to receive for";
+ mes "those "+getitemname(getarg(0))+", don't you?";
+ next;
+ mes "[Merchant]";
+ mes "Now, I can trade you";
+ mes "a minimum of 1 Red Potion";
+ mes "and a maximum of 100 Red Potions";
+ mes "at one time. If you change your";
+ mes "mind, just enter '0' to cancel.";
+ next;
+ while(1) {
+ input .@input;
+ if (.@input == 0) {
+ mes "[Merchant]";
+ mes "What...?";
+ mes "Why the hell do you";
+ mes "even bother to talk to me?";
+ mes "Pretty indecisive, aren't you?";
+ close;
+ }
+ else if (.@input > 100) {
+ mes "[Merchant]";
+ mes "I can't give you more";
+ mes "than 100 Red Potions";
+ mes "at once. Let's try";
+ mes "this again.";
+ next;
+ }
+ else {
+ break;
+ }
+ }
+ set .@put_out_item,.@input * getarg(1);
+ if (countitem(getarg(0)) < .@put_out_item) {
+ mes "[Merchant]";
+ mes "Uh oh, the number you entered doesn't seem right. You better check the number of Red Potions that you can trade for again.";
+ close;
+ }
+ mes "[Merchant]";
+ mes "There you go!";
+ mes "Check how many Red Potions";
+ mes "I've given you, it should be good. Thanks, that was a good deal~";
+ delitem getarg(0),.@put_out_item; //Shell
+ getitem 501,.@input; //Red_Potion
+ close;
+ }
+ mes "[Merchant]";
+ mes "Huh~";
+ mes "Alright.";
+ mes "Though aren't";
+ mes "Red Potions more useful";
+ mes "to an adventurer like you?";
+ close;
+ }
}
-payon,200,134,5 script Merchant#5 85,{
- //we remove 3rd item, by adding 0,0
- callfunc "F_NMerch","Merchant",902,6,909,10,0,0;
-}
+//============================================================
+// Old changelog
+//============================================================
+//= 1.1 Made it as a function. U can add your own Merchs [Lupus]
+//= 1.1a Fixed item select [KarLaeda]
+//============================================================