summaryrefslogtreecommitdiff
path: root/npc/012-1
diff options
context:
space:
mode:
authorJesusaves <cpntb1@ymail.com>2018-06-22 12:10:22 -0300
committerJesusaves <cpntb1@ymail.com>2018-06-22 12:10:22 -0300
commite14789728c21fa71438b7cdbd04de00de5e302df (patch)
tree6eece3c81781a8ad7e91ed5aeccc4a65004f995d /npc/012-1
parent7c929681ed5891f8f9614cae32838cdca2c8e64a (diff)
downloadserverdata-e14789728c21fa71438b7cdbd04de00de5e302df.tar.gz
serverdata-e14789728c21fa71438b7cdbd04de00de5e302df.tar.bz2
serverdata-e14789728c21fa71438b7cdbd04de00de5e302df.tar.xz
serverdata-e14789728c21fa71438b7cdbd04de00de5e302df.zip
ShoppaKep stock change
Diffstat (limited to 'npc/012-1')
-rw-r--r--npc/012-1/shoppakep.txt26
1 files changed, 17 insertions, 9 deletions
diff --git a/npc/012-1/shoppakep.txt b/npc/012-1/shoppakep.txt
index 6037576e7..b18dadc66 100644
--- a/npc/012-1/shoppakep.txt
+++ b/npc/012-1/shoppakep.txt
@@ -12,8 +12,18 @@
shop .name$;
close;
+ function ShoppaKepItem {
+ .@i=rand(0,100);
+ if (.@i > 70)
+ return Coal;
+ else if (.@i < 30)
+ return IronOre;
+ else
+ return HalfEggshell;
+ }
+
OnInit:
- .ThisRebootRand=rand(0,100);
+ .CurrentItem=ShoppaKepItem();
.ThisRebootAmou=rand(30,70);
.sex = G_FEMALE;
@@ -33,14 +43,12 @@ OnInit:
sellitem Chagashroom, -1, 3;
sellitem PiouFeathers, -1, .ThisRebootAmou;
- if (.ThisRebootRand > 70)
- sellitem Coal, -1, 1;
- else if (.ThisRebootRand < 30)
- sellitem IronOre, -1, 1;
+ sellitem .CurrentItem, -1, rand(1,4);
end;
OnClock1759:
+OnClock0546:
restoreshopitem LeatherShirt, 125000, 1;
restoreshopitem JeansShorts, 125000, 1;
restoreshopitem CottonSkirt, 100000, 1;
@@ -53,9 +61,9 @@ OnClock1759:
restoreshopitem Chagashroom, -1, 3;
restoreshopitem PiouFeathers, -1, .ThisRebootAmou;
- if (.ThisRebootRand > 70)
- restoreshopitem Coal, -1, 1;
- else if (.ThisRebootRand < 30)
- restoreshopitem IronOre, -1, 1;
+
+ stopselling(.CurrentItem);
+ .CurrentItem=ShoppaKepItem();
+ sellitem .CurrentItem, -1, rand(1,4);
end;
}