summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSaulc <lucashelaine14@gmail.com>2018-02-10 18:21:50 +0100
committerSaulc <lucashelaine14@gmail.com>2018-02-10 18:21:50 +0100
commit6eb3add1aad3d61e8e3ec0ffccb2d309ddb5e388 (patch)
tree324314c608aced01e759135ffe9f44b38487b42c
parent2d7f2cfce425ae263ce253098a50c7e3108c4a50 (diff)
parent5ba80cc8cf983b239ba80b4b0394459bb12794f8 (diff)
downloadserverdata-6eb3add1aad3d61e8e3ec0ffccb2d309ddb5e388.tar.gz
serverdata-6eb3add1aad3d61e8e3ec0ffccb2d309ddb5e388.tar.bz2
serverdata-6eb3add1aad3d61e8e3ec0ffccb2d309ddb5e388.tar.xz
serverdata-6eb3add1aad3d61e8e3ec0ffccb2d309ddb5e388.zip
Merge branch 'master' of gitlab.com:TMW2/serverdata
-rw-r--r--npc/003-1-2-2/_import.txt2
-rw-r--r--npc/003-1/mahoud.txt51
-rw-r--r--npc/003-1/well.txt46
3 files changed, 51 insertions, 48 deletions
diff --git a/npc/003-1-2-2/_import.txt b/npc/003-1-2-2/_import.txt
deleted file mode 100644
index b20297f59..000000000
--- a/npc/003-1-2-2/_import.txt
+++ /dev/null
@@ -1,2 +0,0 @@
-// Map 003-1-2-2: Tulimshar
-// This file is generated automatically. All manually added changes will be removed when running the Converter.
diff --git a/npc/003-1/mahoud.txt b/npc/003-1/mahoud.txt
index ae169bbe5..e14047929 100644
--- a/npc/003-1/mahoud.txt
+++ b/npc/003-1/mahoud.txt
@@ -1,13 +1,58 @@
// Author:
// Saulc
+// Jesusalva
-003-1,46,79,0 script Mahoud NPC_MONA,{
+003-1,46,79,0 script Mahoud NPC_PLAYER,{
+ .@COST_PER_BOTTLE = 50;
-hello;
+ mes l("I can fill your bottle with water for only @@ gp the bottle.", .@COST_PER_BOTTLE);
+ mes l("After all, I am the Well Master!");
+ input .@count;
+
+ if (.@count == 0)
+ close;
+ .@Cost = .@count * .@COST_PER_BOTTLE;
+ .@empty = countitem("EmptyBottle");
+
+ if (.@empty < .@count)
+ goto L_NotEnoughBottles;
+ if (Zeny < .@Cost)
+ goto L_NotEnoughMoney;
+ getinventorylist;
+ if (@inventorylist_count == 100
+ && countitem("BottleOfSweaWater") == 0
+ && .@empty > .@count)
+ goto L_NotEnoughSlots;
+
+ set Zeny, Zeny - .@Cost;
+ delitem "EmptyBottle", .@count;
+ getitem "BottleOfSweaWater", .@count; // TODO FIXME: "Swea" water? Also, this is not sea water...
+ close;
+
+L_NotEnoughBottles:
+ mes l("You don't have that many empty bottles!");
+ close;
+
+L_NotEnoughMoney:
+ mes l("You don't have enough gp! You need @@ gp.", .@Cost);
+ close;
+
+L_NotEnoughSlots:
+ mes l("You don't have room for these bottles!");
+ close;
OnInit:
.sex = G_MALE;
- .distance = 3;
+ .distance = 7;
+
+ .@npcId = getnpcid(0, "Mahoud");
+ // Check items.xml for info about this
+ setunitdata(.@npcId, UDT_HEADTOP, 2906);
+ setunitdata(.@npcId, UDT_HEADMIDDLE, 1304);
+ setunitdata(.@npcId, UDT_HEADBOTTOM, 2201);
+ setunitdata(.@npcId, UDT_HAIRSTYLE, 7);
+ setunitdata(.@npcId, UDT_HAIRCOLOR, 17);
+
end;
}
diff --git a/npc/003-1/well.txt b/npc/003-1/well.txt
index c7e272213..926a14dac 100644
--- a/npc/003-1/well.txt
+++ b/npc/003-1/well.txt
@@ -1,54 +1,14 @@
// Author:
// Saulc
+// Jesusalva
003-1,45,80,0 script Well NPC_NO_SPRITE,{
- .Item1 = IronOre; //7
- .GP = 8500;
- .ItemCreate = IronIngot;
-
- function quest_create {
- speech S_FIRST_BLANK_LINE | S_LAST_NEXT,
- l("How many ingots do you want to make?");
- input .amount;
-
- if (countitem("Iron Ore") >= .amount * 7 && Zeny >= 8500 * .amount)
- {
- delitem .Item1, .amount * 7;
- Zeny = Zeny - .amount * .GP;
- getitem .ItemCreate, .amount;
- close;
- }
- speech S_FIRST_BLANK_LINE | S_LAST_NEXT,
- l("You don't have enough ore.");
- close;
-
- }
-
- speech S_FIRST_BLANK_LINE | S_LAST_NEXT,
- l("Hello! Do you want to craft @@? For that I will need 7 @@, and @@ gp.", getitemlink(.ItemCreate),getitemlink(.Item1),.GP);
-
- do
- {
- .@karim = getq(Karim_Quest);
- select
- l("Yes"),
- menuaction(l("Quit"));
-
- switch (@menu)
- {
- case 1:
- quest_create;
- break;
- }
- } while (@menu != 2);
-
- closedialog;
- goodbye;
+ mes l("This well is too deep and you don't have a bucket.");
close;
OnInit:
- .sex = G_MALE;
+ .sex = G_OTHER;
.distance = 3;
end;
}