blob: 272deda1a0d98eba0fd8e099b1233f3df87c0090 (
plain) (
blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
|
// Author:
// Saulc
// Jesusalva
003-1,45,80,0 script Well NPC_NO_SPRITE,{
.@COST_PER_BOTTLE = 50;
mes l("This well have a mechanism to fill water bottles. It costs @@ gp per bottle.", .@COST_PER_BOTTLE);
mes l("You need the bottle, too. Too bad, not even water is free in this world!");
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_OTHER;
.distance = 3;
end;
}
|