summaryrefslogtreecommitdiff
path: root/npc/003-9
diff options
context:
space:
mode:
authorJesusaves <cpntb1@ymail.com>2022-10-23 21:44:22 -0300
committerJesusaves <cpntb1@ymail.com>2022-10-23 21:44:22 -0300
commita7c45a192268da2601cef47a4cdba987ae2327ca (patch)
treec5fb5b97db109fe7106496dd96498c475881046b /npc/003-9
downloadserverdata-a7c45a192268da2601cef47a4cdba987ae2327ca.tar.gz
serverdata-a7c45a192268da2601cef47a4cdba987ae2327ca.tar.bz2
serverdata-a7c45a192268da2601cef47a4cdba987ae2327ca.tar.xz
serverdata-a7c45a192268da2601cef47a4cdba987ae2327ca.zip
Initial commit (Moubootaur Legends fork)
Diffstat (limited to 'npc/003-9')
-rw-r--r--npc/003-9/_import.txt6
-rw-r--r--npc/003-9/_warps.txt14
-rw-r--r--npc/003-9/gambler.txt54
-rw-r--r--npc/003-9/recepcionist.txt64
-rw-r--r--npc/003-9/scripted.txt167
5 files changed, 305 insertions, 0 deletions
diff --git a/npc/003-9/_import.txt b/npc/003-9/_import.txt
new file mode 100644
index 0000000..49e21f7
--- /dev/null
+++ b/npc/003-9/_import.txt
@@ -0,0 +1,6 @@
+// Map 003-9: Tulimshar Inn
+// This file is generated automatically. All manually added changes will be removed when running the Converter.
+"npc/003-9/_warps.txt",
+"npc/003-9/gambler.txt",
+"npc/003-9/recepcionist.txt",
+"npc/003-9/scripted.txt",
diff --git a/npc/003-9/_warps.txt b/npc/003-9/_warps.txt
new file mode 100644
index 0000000..dd9e5a9
--- /dev/null
+++ b/npc/003-9/_warps.txt
@@ -0,0 +1,14 @@
+// This file is generated automatically. All manually added changes will be removed when running the Converter.
+// Map 003-9: Tulimshar Inn warps
+003-9,62,136,0 warp #003-9_62_136 0,0,003-1,70,138
+003-9,48,92,0 script #003-9_48_92 NPC_HIDDEN,1,0,{
+ end;
+OnTouch:
+ slide 47,56; end;
+}
+003-9,48,57,0 script #003-9_48_57 NPC_HIDDEN,1,0,{
+ end;
+OnTouch:
+ slide 48,93; end;
+}
+003-9,36,57,0 warp #003-9_36_57 0,0,003-1,64,131
diff --git a/npc/003-9/gambler.txt b/npc/003-9/gambler.txt
new file mode 100644
index 0000000..eacbc77
--- /dev/null
+++ b/npc/003-9/gambler.txt
@@ -0,0 +1,54 @@
+// TMW2 scripts.
+// Author:
+// Jesusalva
+// Description:
+// Tulimshar Inn Receptionist
+
+003-9,42,123,0 script Gambler Master NPC_LOF_NOBLEMAN,{
+ mesn;
+ mesq l("Hello! Welcome to the Inn! I am an Alliance officer, and I oversee gambling all over the world!");
+ next;
+ mesn;
+ mesq l("So how can I help you?");
+ do
+ {
+ next;
+ select
+ l("How does Gambling works?"),
+ l("How can I obtain casino coins?"),
+ l("Nothing, thanks.");
+ mes "";
+ switch (@menu) {
+ case 1:
+ mesn;
+ mesq l("You find a slot machine or another gambler, and make a bet!");
+ next;
+ mesn;
+ mesq l("If you're right, you'll gain more Casino Coins! And even other nice things!");
+ next;
+ mesn;
+ mesq l("But if you're wrong, you'll have to pay up! There's no refunds. This is gambling, if you lose you lose!");
+ next;
+ mesn;
+ mesq l("If you're afraid of losing everything, then DEFINITELY do not gamble. %%2");
+ break;
+ case 2:
+ mesn;
+ mesq l("I dunno. I don't think they're sold anywhere.");
+ next;
+ mesn;
+ mesq l("I know a few bandits stole a few, and Lava Slimes love to eat Casino Coins.");
+ next;
+ mesn;
+ mesq l("I've even heard of people whom dug Casino Coins out of the ground, but as I said, I don't know. But you'll certainly come across a few o your adventures!");
+ break;
+ }
+ } while (@menu != 3);
+ close;
+
+OnInit:
+ .sex = G_MALE;
+ .distance = 5;
+ end;
+}
+
diff --git a/npc/003-9/recepcionist.txt b/npc/003-9/recepcionist.txt
new file mode 100644
index 0000000..cb6a81c
--- /dev/null
+++ b/npc/003-9/recepcionist.txt
@@ -0,0 +1,64 @@
+// TMW2 scripts.
+// Author:
+// Jesusalva
+// Description:
+// Tulimshar Inn Recepcionist
+
+003-9,62,128,0 script Recepcionist#TInn NPC_LOF_BARKEEPER,{
+ // You're on Main Quest - total priority
+ if (LUA_ASKED_TO_SLEEP)
+ goto L_Cutscene;
+
+ // Otherwise, you cannot sleep here before finishing Lua's Quest
+ if (getq(General_Narrator) < 3) {
+ npctalk3 l("Hello, and welcome to Tulimshar Inn.");
+ emotion E_HAPPY;
+ end;
+ }
+
+ .@price=limit(400, 700+(BaseLevel*3)-getq(General_Narrator)*6, 1200);
+ .@price=limit(250, POL_AdjustPrice(.@price), 1200);
+
+ mesn;
+ mesq l("Good %s. Would you like to sleep here? It's only %d GP!", (is_night() ? l("evening") : l("day")), .@price);
+ mesc l("Sleeping will fully replenish your health.");
+ mesc l("It'll also boost your %s for %s.", b(l("MAX HP")), l("15 minutes."));
+ mesc l("Sleeping at night, the bonus will be stronger!");
+ next;
+ if (askyesno() == ASK_YES && Zeny > .@price) {
+ POL_PlayerMoney(.@price);
+ percentheal 100, 100;
+ .@buff=(is_night() ? 15 : 10);
+ SC_Bonus(900, SC_INCMHPRATE, .@buff, .@buff); // FIXME: We don't want stacking
+ closeclientdialog;
+ warp "003-9", 36, 47;
+ dispbottom l("You feel refreshed!");
+ }
+ close;
+
+L_Cutscene:
+ mesn strcharinfo(0);
+ mesq l("Hello, Lua told me she booked a room for me.");
+ next;
+ mesn;
+ mesq l("Ah, so you must be %s, the new guy! Yes, it is on the rooms upstairs. I'll bring you there, don't you worry a thing!", strcharinfo(0));
+ tutmes l("During cutscenes, you cannot move. If you do, you'll be forcibly pushed back."), l("Cutscenes");
+ next;
+ closeclientdialog;
+ .@mapn$="tinn@"+getcharid(0);
+ .@inst = instance_create("Tulim Inn "+getcharid(0), getcharid(3), IOT_CHAR);
+ instance_attachmap("003-9", .@inst, false, .@mapn$);
+ // Instance lasts 6 minutes
+ instance_set_timeout(360, 360, .@inst);
+ instance_init(.@inst);
+ warp .@mapn$, 36, 47;
+ setpcblock(PCBLOCK_HARD, true); // NOTE: No commands?! I'm not sure...
+ addtimer 1000, "#TulimInnStory::OnEvent1";
+ close;
+
+OnInit:
+ .sex = G_FEMALE;
+ .distance = 5;
+ end;
+}
+
diff --git a/npc/003-9/scripted.txt b/npc/003-9/scripted.txt
new file mode 100644
index 0000000..f8ad67b
--- /dev/null
+++ b/npc/003-9/scripted.txt
@@ -0,0 +1,167 @@
+// TMW2 scripts.
+// Author:
+// Jesusalva
+// Description:
+// Scripted functions (Lua)
+
+003-9,58,121,0 script #TInnClockPassage NPC_NO_SPRITE,{
+ dispbottom l("If I only could find another way in...");
+ close;
+
+OnInit:
+ .sex = G_OTHER;
+ .distance = 3;
+ end;
+}
+
+003-9,0,0,0 script #TulimInnStory NPC_HIDDEN,{
+ end;
+
+OnEvent1:
+ .@mapn$="tinn@"+getcharid(0);
+ @tinn_assa=monster(.@mapn$, 47, 56, "???", Assassin, 1);
+ @tinn_boss=monster(.@mapn$, 48, 56, "???", HoodedAssassin, 1);
+ unitwalk(@tinn_boss, 40, 47);
+ addtimer 400, .name$+"::OnEvent2";
+ end;
+
+OnEvent2:
+ .@mapn$="tinn@"+getcharid(0);
+ setunitdata(@tinn_boss, UDT_SPEED, 190); // So they walk at same pace
+ setunitdata(@tinn_assa, UDT_SPEED, 190); // So they walk at same pace
+ unitwalk(@tinn_assa, 40, 48);
+ addtimer 1860, .name$+"::OnEvent3"; // Roughly 9/11 tiles time
+ end;
+
+OnEvent3:
+ .@mapn$="tinn@"+getcharid(0);
+ //unitwarp(@tinn_boss, .@mapn$, 40, 47);
+ sc_start(SC_STUN, 17240, 1, 10000, SCFLAG_NOAVOID|SCFLAG_FIXEDTICK, @tinn_boss);
+ unittalk(@tinn_boss, l("*hurry up, your moron!*"));
+ addtimer 440, .name$+"::OnEvent4"; // Roughly 2/11 tiles time
+ end;
+
+OnEvent4:
+ .@mapn$="tinn@"+getcharid(0);
+ //unitwarp(@tinn_assa, .@mapn$, 40, 48);
+ sc_start(SC_STUN, 22000, 1, 10000, SCFLAG_NOAVOID|SCFLAG_FIXEDTICK, @tinn_assa);
+ unittalk(@tinn_assa, l("*sorry, boss!*"));
+ //atcommand("@refresh"); // Can't use @commands at block 255
+ addtimer 2000, .name$+"::OnEvent5";
+ end;
+
+OnEvent5:
+ .@mapn$="tinn@"+getcharid(0);
+ unittalk(@tinn_boss, l("*is everything ready?*"));
+ addtimer 2000, .name$+"::OnEvent6";
+ end;
+
+OnEvent6:
+ .@mapn$="tinn@"+getcharid(0);
+ unittalk(@tinn_assa, l("*Yes, boss!*"));
+ addtimer 1500, .name$+"::OnEvent7";
+ end;
+
+OnEvent7:
+ .@mapn$="tinn@"+getcharid(0);
+ unittalk(@tinn_boss, l("*Don't shout, you moron!*"));
+ addtimer 2000, .name$+"::OnEvent8";
+ end;
+
+OnEvent8:
+ .@mapn$="tinn@"+getcharid(0);
+ unittalk(@tinn_assa, l("*Yes, boss!*"));
+ addtimer 2000, .name$+"::OnEvent9";
+ end;
+
+OnEvent9:
+ .@mapn$="tinn@"+getcharid(0);
+ unittalk(@tinn_boss, l("*I'll give you two energy balls.*"));
+ addtimer 1000, .name$+"::OnEvent10";
+ end;
+
+OnEvent10:
+ .@mapn$="tinn@"+getcharid(0);
+ @tinn_ball=monster(.@mapn$, 41, 47, l("Energy Ball"), EnergyBall, 1);
+ @tinn_ba11=monster(.@mapn$, 41, 48, l("Energy Ball"), EnergyBall, 1);
+ sc_start(SC_STUN, 11500, 1, 10000, SCFLAG_NOAVOID|SCFLAG_FIXEDTICK, @tinn_ball);
+ sc_start(SC_STUN, 11500, 1, 10000, SCFLAG_NOAVOID|SCFLAG_FIXEDTICK, @tinn_ba11);
+ setunitdata(@tinn_ball, UDT_SPEED, 200); // So they walk at same pace
+ setunitdata(@tinn_ba11, UDT_SPEED, 200); // So they walk at same pace
+ addtimer 2000, .name$+"::OnEvent11";
+ end;
+
+OnEvent11:
+ .@mapn$="tinn@"+getcharid(0);
+ unittalk(@tinn_boss, l("*Don't fail me. If you do, ensure you're well past dead before.*"));
+ addtimer 2800, .name$+"::OnEvent12";
+ end;
+
+OnEvent12:
+ .@mapn$="tinn@"+getcharid(0);
+ unittalk(@tinn_assa, l("*Yes, boss!*"));
+ addtimer 1500, .name$+"::OnEvent13";
+ end;
+
+OnEvent13:
+ .@mapn$="tinn@"+getcharid(0);
+ unittalk(@tinn_boss, l("*I'll take my leave, then.*"));
+ unitwalk(@tinn_boss, 47, 56);
+ addtimer 2200, .name$+"::OnEvent14";
+ end;
+
+OnEvent14:
+ .@mapn$="tinn@"+getcharid(0);
+ unitwarp(@tinn_boss, "boss", 22, 22);
+ unitkill(@tinn_boss);
+ addtimer 200, .name$+"::OnEvent15";
+ end;
+
+OnEvent15:
+ .@mapn$="tinn@"+getcharid(0);
+ unittalk(@tinn_assa, l("*hehehe...*"));
+ addtimer 800, .name$+"::OnEvent16";
+ end;
+
+OnEvent16:
+ .@mapn$="tinn@"+getcharid(0);
+ unittalk(@tinn_assa, l("*The Professor will never know what got him...*"));
+ addtimer 2000, .name$+"::OnEvent17";
+ end;
+
+OnEvent17:
+ .@mapn$="tinn@"+getcharid(0);
+ unittalk(@tinn_assa, l("*hehehe...*"));
+ unitwalk(@tinn_assa, 47, 56);
+ addtimer 200, .name$+"::OnEvent18";
+ end;
+
+OnEvent18:
+ unitwalk(@tinn_ball, 47, 56);
+ unitwalk(@tinn_ba11, 48, 56);
+ addtimer 2000, .name$+"::OnEvent19";
+ end;
+
+OnEvent19:
+ .@mapn$="tinn@"+getcharid(0);
+ unitwarp(@tinn_assa, "boss", 22, 22);
+ unitwarp(@tinn_ball, "boss", 22, 22);
+ unitwarp(@tinn_ba11, "boss", 22, 22);
+ unitkill(@tinn_assa);
+ unitkill(@tinn_ball);
+ unitkill(@tinn_ba11);
+ addtimer 200, .name$+"::OnEvent20";
+ end;
+
+OnEvent20:
+ dispbottom l("*are they gone...?*");
+ addtimer 1000, .name$+"::OnEvent21";
+ end;
+
+OnEvent21:
+ setpcblock(PCBLOCK_HARD, false);
+ dispbottom l("I better report this to Lua!");
+ LUA_ASKED_TO_SLEEP=false;
+ end;
+}
+