summaryrefslogtreecommitdiff
path: root/npc
diff options
context:
space:
mode:
authorJesusaves <cpntb1@ymail.com>2019-03-07 16:37:00 -0300
committerJesusaves <cpntb1@ymail.com>2019-03-07 16:37:00 -0300
commit62818a6f6312793dd20eb47f4ab817e0ae53f0ef (patch)
tree6b06a654465deaec668f39eb49bf97ef740dfba1 /npc
parentcf3db467c470144cbe9919895d8296d892cdc271 (diff)
downloadserverdata-62818a6f6312793dd20eb47f4ab817e0ae53f0ef.tar.gz
serverdata-62818a6f6312793dd20eb47f4ab817e0ae53f0ef.tar.bz2
serverdata-62818a6f6312793dd20eb47f4ab817e0ae53f0ef.tar.xz
serverdata-62818a6f6312793dd20eb47f4ab817e0ae53f0ef.zip
Regenerate maps now that 013-1 is fixed. Add the [Red Plush Wine] barrel.
Diffstat (limited to 'npc')
-rw-r--r--npc/003-2/_import.txt2
-rw-r--r--npc/013-1/_import.txt4
-rw-r--r--npc/013-1/_mobs.txt4
-rw-r--r--npc/013-1/_warps.txt3
-rw-r--r--npc/017-3/_import.txt1
-rw-r--r--npc/017-3/chagashroom.txt156
-rw-r--r--npc/_import.txt1
7 files changed, 170 insertions, 1 deletions
diff --git a/npc/003-2/_import.txt b/npc/003-2/_import.txt
index fffe69267..f6711989e 100644
--- a/npc/003-2/_import.txt
+++ b/npc/003-2/_import.txt
@@ -1,4 +1,4 @@
-// Map 003-2: Tulimshar Guild
+// Map 003-2: Tulimshar Guild
// This file is generated automatically. All manually added changes will be removed when running the Converter.
"npc/003-2/_warps.txt",
"npc/003-2/eistein.txt",
diff --git a/npc/013-1/_import.txt b/npc/013-1/_import.txt
new file mode 100644
index 000000000..f9269149b
--- /dev/null
+++ b/npc/013-1/_import.txt
@@ -0,0 +1,4 @@
+// Map 013-1: Woodlands Central Plateau
+// This file is generated automatically. All manually added changes will be removed when running the Converter.
+"npc/013-1/_mobs.txt",
+"npc/013-1/_warps.txt",
diff --git a/npc/013-1/_mobs.txt b/npc/013-1/_mobs.txt
new file mode 100644
index 000000000..0727c3e45
--- /dev/null
+++ b/npc/013-1/_mobs.txt
@@ -0,0 +1,4 @@
+// This file is generated automatically. All manually added changes will be removed when running the Converter.
+// Map 013-1: Woodlands Central Plateau mobs
+013-1,69,83,31,14 monster Pinkie 1132,9,30000,50000
+013-1,76,82,49,21 monster Mauve Plant 1135,4,90000,90000
diff --git a/npc/013-1/_warps.txt b/npc/013-1/_warps.txt
new file mode 100644
index 000000000..84ad4e25d
--- /dev/null
+++ b/npc/013-1/_warps.txt
@@ -0,0 +1,3 @@
+// This file is generated automatically. All manually added changes will be removed when running the Converter.
+// Map 013-1: Woodlands Central Plateau warps
+013-1,118,27,0 warp #013-1_118_27 0,0,015-3,172,195
diff --git a/npc/017-3/_import.txt b/npc/017-3/_import.txt
index 0d514e54a..6d9b59e77 100644
--- a/npc/017-3/_import.txt
+++ b/npc/017-3/_import.txt
@@ -1,6 +1,7 @@
// Map 017-3: Dimond's Cove
// This file is generated automatically. All manually added changes will be removed when running the Converter.
"npc/017-3/_warps.txt",
+"npc/017-3/chagashroom.txt",
"npc/017-3/chef.txt",
"npc/017-3/dimonds.txt",
"npc/017-3/doctor.txt",
diff --git a/npc/017-3/chagashroom.txt b/npc/017-3/chagashroom.txt
new file mode 100644
index 000000000..12bc44429
--- /dev/null
+++ b/npc/017-3/chagashroom.txt
@@ -0,0 +1,156 @@
+// TMW2 Scripts
+// Author:
+// Jesusalva
+// Description:
+// Chagashroom → Red Plush Wine
+// Variables:
+// REDWINE_DATE = When the wine started being done
+// REDWINE_DONE = When the wine will be ready
+// REDWINE_AMMO = How much Wine you're trying to make
+// Success Rate is based on how much you're trying to do and how long ago that was
+
+017-3,25,78,0 script Wine Making Barrel NPC_NO_SPRITE,{
+ goto L_Main;
+ // redwine_chance()
+ // Returns chance (0~10,000) to successfully obtain wine
+ // REDWINE_DONE/REDWINE_DATE is taken in account
+ function redwine_chance {
+ .@max=10000;
+ .@base=REDWINE_DATE;//-(REDWINE_DONE-REDWINE_DATE);
+ // .@c = how much time is left until completion
+ // .@d = original amount of time required
+ // .@e = Current time
+ .@c=REDWINE_DONE-.@base; //-gettimetick(2);
+ .@d=REDWINE_DATE-.@base; //-REDWINE_DONE;
+ .@e=gettimetick(2)-.@base;
+ debugmes "%d - %d - %d", .@d, .@e, .@c;
+ debugmes "Start - Now - Finish";
+ if (.@c == 0)
+ return .@max;
+ debugmes "Ratio: %d/%d = %d", .@e, .@c, (.@e*.@max)/.@c;
+ return min(10000, (.@e*.@max)/.@c);
+ }
+
+L_Main:
+ if (!REDWINE_DATE) {
+ mesn;
+ mesc l("Do you want to make wine?");
+ next;
+ select
+ l("Information"),
+ l("Yes"),
+ l("No");
+ mes "";
+
+ switch (@menu) {
+ case 1:
+ mesc l("Produced item:");
+ mesc l("@@", getitemlink(RedPlushWine));
+ mes "";
+ mesc l("Cost per two glass:");
+ mesc l("* @@/@@ @@", countitem(SeaDrops), 1, getitemlink(SeaDrops));
+ mesc l("* @@/@@ @@", countitem(Plushroom), 1, getitemlink(Plushroom));
+ mesc l("* @@/@@ @@", countitem(Chagashroom), 30, getitemlink(Chagashroom));
+ mesc l("* @@ Water Bottle", 1);
+ next;
+ break;
+ case 2:
+ mesc l("How many batches do you want to produce? (max. 5)");
+ input .@glass_count;
+ if (.@glass_count < 1 ||
+ .@glass_count > 5 ||
+ countitem(SeaDrops) < .@glass_count ||
+ countitem(Plushroom) < .@glass_count ||
+ countitem(Chagashroom) < .@glass_count*30
+ ) {
+ mesc l("Not enough ingredients or invalid amount."), 1;
+ break;
+ }
+ mesc l("Which water will you use?");
+ mesc l("The bottom-most the water, the better the bonus.");
+ menuint
+ l("Cancel"), -1,
+ rif(countitem(BottleOfSewerWater) > .@glass_count, l("Sewer Water")), 0,
+ rif(countitem(BottleOfSeaWater) > .@glass_count, l("Sea Water")), 3600,
+ rif(countitem(BottleOfTonoriWater) > .@glass_count, l("Tonori Water")), 11760,
+ rif(countitem(BottleOfWoodlandWater) > .@glass_count, l("Woodland Water")), 12000,
+ rif(countitem(BottleOfDivineWater) > .@glass_count, l("Divine Water")), 21600;
+ mes "";
+ if (@menuret < 0)
+ break;
+ switch (@menuret) {
+ case 0:
+ .@bonus=@menuret;
+ .@water=BottleOfSewerWater;
+ break;
+ case 3600:
+ .@bonus=@menuret;
+ .@water=BottleOfSeaWater;
+ break;
+ case 11760:
+ .@bonus=@menuret;
+ .@water=BottleOfTonoriWater;
+ break;
+ case 12000:
+ .@bonus=@menuret;
+ .@water=BottleOfWoodlandWater;
+ break;
+ case 21600:
+ .@bonus=@menuret;
+ .@water=BottleOfDivineWater;
+ break;
+ default:
+ mesc l("Error, invalid return code, blame Saulc"), 1;
+ mes "==== SCRIPT ABORTED";
+ close;
+ }
+
+ // Save data
+ delitem SeaDrops, .@glass_count;
+ delitem Plushroom, .@glass_count;
+ delitem Chagashroom, .@glass_count*30;
+ delitem .@water, .@glass_count;
+ REDWINE_AMMO=.@glass_count;
+ REDWINE_DATE=gettimetick(2);
+ REDWINE_DONE=gettimetick(2)-.@bonus+.mintime;
+ REDWINE_DONE+=.cuptime*REDWINE_AMMO;
+ break;
+ case 3:
+ close;
+ break;
+ }
+ goto L_Main;
+ } else {
+ mesn;
+ mesc l("Your request for @@ @@ are being fermented for @@.", REDWINE_AMMO, getitemlink(RedPlushWine), FuzzyTime(REDWINE_DATE));
+ next;
+ inventoryplace RedPlushWine, REDWINE_AMMO;
+ mesn;
+ mes l("Trying to retrieve it now will have @@ % chance to be successful.", redwine_chance()/100);
+ mes l("Attempt to retrieve it now?");
+ next;
+ if (askyesno() == ASK_YES) {
+ if (rand(1000,10000) < redwine_chance()) {
+ mesc l("Success!"), 3;
+ getitem RedPlushWine, REDWINE_AMMO*2;
+ } else {
+ mesc l("The wine wasn't ready yet and you lost it..."), 1;
+ }
+ REDWINE_DATE=0;
+ REDWINE_AMMO=0;
+ }
+ }
+ close;
+
+OnInit:
+ .sex = G_OTHER;
+ .distance = 4;
+
+ // Time to make each batch
+ .cuptime=(60*60*6);
+ // Base time to make any amount of cups
+ .mintime=(60*60*24);
+ end;
+
+}
+
diff --git a/npc/_import.txt b/npc/_import.txt
index 94ecf1c6a..cf02e351b 100644
--- a/npc/_import.txt
+++ b/npc/_import.txt
@@ -74,6 +74,7 @@
@include "npc/012-6/_import.txt"
@include "npc/012-7/_import.txt"
@include "npc/012-8/_import.txt"
+@include "npc/013-1/_import.txt"
@include "npc/014-1/_import.txt"
@include "npc/014-2-1/_import.txt"
@include "npc/014-2/_import.txt"