summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJesusaves <cpntb1@ymail.com>2021-05-27 19:35:38 +0000
committerJesusaves <cpntb1@ymail.com>2021-05-27 19:35:38 +0000
commit519a365928311d0cf8558526b073a4cff69eed49 (patch)
tree6b62464ced2779d4068818ee2ac92e49e536cfc5
parent93fd0fff03385a7d7e2e9d72adbeddb219ad5146 (diff)
downloadserverdata-519a365928311d0cf8558526b073a4cff69eed49.tar.gz
serverdata-519a365928311d0cf8558526b073a4cff69eed49.tar.bz2
serverdata-519a365928311d0cf8558526b073a4cff69eed49.tar.xz
serverdata-519a365928311d0cf8558526b073a4cff69eed49.zip
Mirror Lake Quest - Cindy
-rw-r--r--conf/login/login-server.conf2
-rw-r--r--db/constants.conf10
-rw-r--r--npc/009-8/celestia.txt17
-rw-r--r--npc/013-2/notes.txt10
-rw-r--r--npc/013-2/wizard.txt76
-rw-r--r--npc/017-4/waric.txt7
-rw-r--r--npc/029-2/morgan.txt21
-rw-r--r--npc/031-1/angelaOutside.txt9
-rw-r--r--npc/031-2/angelaHouse.txt51
-rw-r--r--npc/031-4/cindyCave.txt10
-rw-r--r--npc/048-2/sageNikolai.txt109
-rw-r--r--npc/functions/bitwise.txt18
-rw-r--r--npc/functions/vault.txt6
13 files changed, 298 insertions, 48 deletions
diff --git a/conf/login/login-server.conf b/conf/login/login-server.conf
index da759180..da36d0aa 100644
--- a/conf/login/login-server.conf
+++ b/conf/login/login-server.conf
@@ -200,6 +200,6 @@ login_configuration: {
}
-update_server: "http://evol.gitlab.io/clientdata/"
+update_server: "http://updates.tmw2.org/messworld/"
import: "conf/import/login-server.conf"
diff --git a/db/constants.conf b/db/constants.conf
index 5d0e317e..b2e6b20d 100644
--- a/db/constants.conf
+++ b/db/constants.conf
@@ -3297,7 +3297,15 @@ more than one separator can be used in a row (so 12_3___456 is illegal).
comment__: "Misc settings"
CHEST_WAITTIME: 900 // 15 minutes
ROSSY_INSTIME: 1200 // 20 minutes
- WORLD_ID: 2 // Vault WID Identifier
+
+ comment__: "Mirror Lake settings"
+ WORLD_ID: 3 // Vault WID Identifier
+ MLP_MOUBOOTAUR: 1 // MLP code for Moubootaur Legends
+
+ comment__: "Mirror Lake Quest Constants"
+ MLP_TMW_CELESTIA: 1
+ MLP_TMW_YETIKING: 2
+ //MLP_................ 4
comment__: "Report Bug Flags"
RB_NONE: 0
diff --git a/npc/009-8/celestia.txt b/npc/009-8/celestia.txt
index 90889385..e4ef6f2d 100644
--- a/npc/009-8/celestia.txt
+++ b/npc/009-8/celestia.txt
@@ -43,6 +43,7 @@ L_MainMenu:
menu // else we just show a boring menu
"Party! Of course I came out for the party!", L_CameForParty,
"I'm sorry, life is much too serious for tea.", L_SrsBsns,
+ rif(get_nibble(##03_TMWQUEST, 0), l("Actually, have you ever heard of Yeti's kidnapping little girls?")), L_VaultQuest,
"(Walk away)", L_InstaClose;
L_EasyQuestMenu:
@@ -50,6 +51,7 @@ L_EasyQuestMenu:
"Party! Of course I came out for the party!", L_CameForParty,
"I'm sorry, life is much too serious for tea.", L_SrsBsns,
"Is there anything that I can do to help?", L_OfferHelp, // <= this will start the first quest
+ rif(get_nibble(##03_TMWQUEST, 0), l("Actually, have you ever heard of Yeti's kidnapping little girls?")), L_VaultQuest,
"(Walk away)", L_InstaClose;
L_AdvQuestMenu:
@@ -57,6 +59,7 @@ L_AdvQuestMenu:
"Party! Of course I came out for the party!", L_CameForParty,
"I'm sorry, life is much too serious for tea.", L_SrsBsns,
"I heard you were looking for help from experienced adventurers...", L_Scared, // <= this will start the adv quest
+ rif(get_nibble(##03_TMWQUEST, 0), l("Actually, have you ever heard of Yeti's kidnapping little girls?")), L_VaultQuest,
"(Walk away)", L_InstaClose;
L_CameForParty:
@@ -142,6 +145,16 @@ L_ThankYou:
next;
goto L_MainMenu;
+L_VaultQuest:
+ mesn;
+ mesq l("I've heard of Yetis %s little girls, and kidnapping them to eat immediately after.", b(l("eating")));
+ next;
+ mesn;
+ mesq l("If a Yeti kidnapped your friend and you had the time to come here tell me this, they're likely already gone.");
+ next;
+ mesc l("Thinking back, Cindy was in a cage. Something seems off.");
+ close;
+
L_Scared:
mes "Celestia takes a close look at you and seems to be satisfied.";
next;
@@ -194,8 +207,8 @@ L_YetiComplete:
L_AcceptTrinket:
mes "\"May our path cross again.\"";
mes;
- mes "["+getitemlink("HeartNecklace")+"]";
- getitem "HeartNecklace", 1;
+ mes l("%s", getitemlink("HeartNecklace"));
+ getitem HeartNecklace, 1;
QL_CELESTIA = 206;
close;
diff --git a/npc/013-2/notes.txt b/npc/013-2/notes.txt
index 92ded429..8c2cf9fa 100644
--- a/npc/013-2/notes.txt
+++ b/npc/013-2/notes.txt
@@ -12,6 +12,16 @@
013-2,38,20,0 script Saying#wiz NPC400,{
mes "The early bird catcheth the worm.";
+ if (!getvaultid()) close; // Close this mirror lake
+ if (get_nibble(##03_TMWQUEST, 0) < 2) close; // Not yet authorized
+ mesc l("Should we recite this backward to travel to a different world? If yes, thinking on what?");
+ select
+ l("Leave it be."),
+ rif(get_nibble(##03_TMWQUEST, 0) >= 2, l("Think on Mouboos and Cindy problems"));
+ mes "";
+ switch (@menu) {
+ case 2: MirrorLakeSendTo(MLP_MOUBOOTAUR, 0); break;
+ }
close;
}
diff --git a/npc/013-2/wizard.txt b/npc/013-2/wizard.txt
index 85704b5e..5bef35a4 100644
--- a/npc/013-2/wizard.txt
+++ b/npc/013-2/wizard.txt
@@ -24,6 +24,7 @@ L_Start:
menu
"Thanks, that's very kind of you!", L_Thanks,
"Can you teach me magic?", L_TeachRude,
+ rif(get_nibble(##03_TMWQUEST, 0), l("Actually, have you ever heard of Yeti's kidnapping little girls?")), L_VaultQuest,
"Oh, shut up!", L_ShutUp;
L_TeachRude:
@@ -136,6 +137,81 @@ L_Agree:
mes "\"Oh, and please don't take my apprentice too seriously. He still has a lot to learn.\"";
goto L_close;
+L_VaultQuest:
+ .@q = get_nibble(##03_TMWQUEST, 0);
+ mes "";
+ mesc l("%s raises an eyebrow at you.", strnpcinfo(1));
+ if (.@q == 1) {
+ mesn;
+ mesq l("Are you being serious?");
+ next;
+ //if (askyesno() == ASK_NO) close;
+ mesn;
+ mesq l("Have you at least asked Celestia about it? She is very knowledgeable about Yetis.");
+ next;
+ select
+ l("Who is Celestia?"),
+ l("Yes I did."),
+ l("No I didn't, I'll ask her.");
+ mes "";
+ switch (@menu) {
+ case 1:
+ mesn;
+ mesq l("Ah, Celestia... She is a good woman who lives in Hurnscald. Go find her, come back to me after.");
+ close;
+ case 3:
+ close;
+ }
+ mesn;
+ mesq l("And what did she say?");
+ next;
+ mesc l("You explain to the wizard about the situation.");
+ next;
+ mesn;
+ mesq l("If she said Yetis doesn't do it, then they doesn't do it... In this world, at least.");
+ if (!getvaultid()) close; // Duplicate code, for double safety
+ next;
+ select
+ l("\"this world\"?");
+ mes "";
+ mesn;
+ mesq l("Oh yes, there are worlds like this one where you can find even Yetis involved in politics. Really impressing.");
+ next;
+ set_nibble(##03_TMWQUEST, 0, 2);
+ .@q = 2;
+ }
+ if (.@q == 2) {
+ mesn;
+ mesq l("It was a long time since the last time I visited a different world... But you're young. Maybe you can do it. However, keep it a secret.");
+ next;
+ mesn;
+ mesq l("So, lemme think. There was this world, \"Moubootaur Lake\" or something, don't recall how they call themselves."); // Typo on purpose
+ next;
+ mesn;
+ mesq l("You could ask the %s of that world about it. Come back to me if she doesn't know anything, and I'll think on another world.", b("Celestia"));
+ next;
+ mesn;
+ mesq l("Now, %s. The worlds are all different. The one you're going to may be similar but is far from a carbon copy of this one.", b(l("pay attention")));
+ next;
+ mesn;
+ mesq l("That world's Celestia is %s but not necessarily on the same house, or with the exact same name, nor with the exact same clothes.", b(l("likely on the same town")));
+ next;
+ mesn;
+ mesq l("Now, if my memory serves me right, after visiting that world, you'll appear near a lake. %s, and then %s.",
+ b(l("Go south until you see a big road")),
+ b(l("Head east until you see the town")));
+ next;
+ mesn;
+ mesq l("If you know a native citizen of the world, all the better. Worlds tend to impose their own rules, after all.");
+ next;
+ mesn;
+ mesq col(l("*cough cough*"), 9)+" "+l("Anyway, I don't teach this spell to everyone. Near my bed is a saying. Recite it backwards, think on the world you want to go, and let it be.");
+ next;
+ }
+ mesn;
+ mesq l("Good luck, and come back to me if you need help.");
+ close;
+
L_close:
@has_magic = 0;
close;
diff --git a/npc/017-4/waric.txt b/npc/017-4/waric.txt
index 1ada69ff..f58eda6c 100644
--- a/npc/017-4/waric.txt
+++ b/npc/017-4/waric.txt
@@ -318,8 +318,15 @@ L_MoreMagic:
next;
menu
"Can you tell me the invocations for the spells you taught me again?", L_Next8,
+ rif(get_nibble(##03_TMWQUEST, 0), l("Actually, have you ever heard of Yeti's kidnapping little girls?")), L_VaultQuest,
"Thanks, master. I will come back later", L_close;
+L_VaultQuest:
+ mes "";
+ mesn;
+ mesq l("Sounds cool, but no. Besides, kidnapping is not my style.");
+ close;
+
L_Next8:
mesn;
mesq l("Yes, of course.");
diff --git a/npc/029-2/morgan.txt b/npc/029-2/morgan.txt
index 00128fd5..d5416802 100644
--- a/npc/029-2/morgan.txt
+++ b/npc/029-2/morgan.txt
@@ -61,7 +61,7 @@ L_Seen:
L_NotMagic:
mes "[Morgan]";
mes "\"Hrmm you don't appear to posses enough magical talent to teach.\"";
- goto L_close;
+ close;
L_Start:
mesn;
@@ -91,7 +91,7 @@ L_Start:
next;
mesn;
mesq l("Speak to me again once you've cast the spell.");
- goto L_close;
+ close;
L_Started:
mes "[Morgan]";
@@ -99,7 +99,7 @@ L_Started:
mes "\"Equip the wand and lets try out that spell.\"";
mes "\"To cast a spell open the chat window, type the invocation and press enter.\"";
mes "\"Speak to me again once you've cast the spell.\"";
- goto L_close;
+ close;
L_CastOnce:
mes "[Morgan]";
@@ -111,7 +111,7 @@ L_CastOnce:
next;
mes "\"I've taught you all I can for now. You should visit the Mana Seed north west of Hurnscald.\"";
QL_MORGAN = 4;
- goto L_close;
+ close;
L_LearningDone:
mes "[Morgan]";
@@ -120,7 +120,18 @@ L_LearningDone:
mes "\"To cast a spell open the chat window, type the invocation and press enter.\"";
mes "\"I've taught you all I can for now. You should visit the Mana Seed north west of Hurnscald.\"";
learnskill SKILL_CONFRINGO;
- goto L_close;
+ if (get_nibble(##03_TMWQUEST, 0) == 1) {
+ mes "";
+ select
+ l("Gotcha."),
+ l("Actually, have you ever heard of Yeti's kidnapping little girls?");
+ mes "";
+ if (@menu == 2) {
+ mesn;
+ mesq l("No, but maybe someone %s would know better?", b(l("old")));
+ }
+ }
+ close;
L_close:
close;
diff --git a/npc/031-1/angelaOutside.txt b/npc/031-1/angelaOutside.txt
index dbacd7c3..2cd05030 100644
--- a/npc/031-1/angelaOutside.txt
+++ b/npc/031-1/angelaOutside.txt
@@ -24,7 +24,7 @@ OnInit:
end;
}
-031-1,79,24,0 script Angela NPC195,15,15,{
+031-1,79,24,0 script Angela NPC195,{
.@q = getq(KaizeiQuest_Cindy);
if (.@q == 4) goto L_Please_Visit_Again;
if (.@q > 2 && .@q < 6) goto L_Please_Visit;
@@ -35,7 +35,7 @@ OnInit:
next;
mes "\"It's terrible, oh my dear child!\"";
next;
- if (countitem("ConcentrationPotion") > 0 && BaseLevel >= .minlevel && .@q == 1)
+ if (countitem("ConcentrationPotion") > 0 && BaseLevel >= .minLevel && .@q == 1)
goto L_Menu_Potion;
menu
@@ -63,7 +63,7 @@ L_Whining:
mes "She is crying and sobbing.";
next;
mes "It seems she is too upset to tell you anything helpful. If she would just calm down and concentrate a bit...";
- if(BaseLevel >= .minlevel) goto L_GetQuest;
+ if(BaseLevel >= .minLevel) goto L_GetQuest;
goto L_close;
L_GetQuest:
@@ -125,6 +125,7 @@ L_close:
close;
OnInit:
- .minlevel = 70;
+ .minLevel = 70;
end;
+//TODO OnTouch: if Level show emote
}
diff --git a/npc/031-2/angelaHouse.txt b/npc/031-2/angelaHouse.txt
index 55c2c7df..695e0e77 100644
--- a/npc/031-2/angelaHouse.txt
+++ b/npc/031-2/angelaHouse.txt
@@ -42,7 +42,7 @@ L_Hello_Again:
mes "\"Hello! Good to see you again. Please warm yourself.\"";
next;
menu
- "I just wanted to say hello.",L_close,
+ "I just wanted to say hello.",L_Hello,
"I have some yellow present boxes.",L_Yellow,
"I have some white present boxes.",L_White;
@@ -73,7 +73,7 @@ L_White:
callfunc "DailyQuest";
next;
if (@dq_return == 4)
- mes "\"You are a great help!\"";
+ mesq l("You are a great help!");
goto L_close;
L_close:
@@ -86,4 +86,51 @@ L_close:
@dq_exp = 0;
@dq_return = 0;
close;
+
+L_Hello:
+ if (getvaultid() && get_nibble(##03_TMWQUEST, 0) <= 3) goto L_VaultQuest;
+ closeclientdialog;
+ close;
+
+L_VaultQuest:
+ mes "";
+ mesn;
+ mesq l("Actually, there is one thing bugging me during this whole ordeal.");
+ next;
+ mesn;
+ mesq l("Yetis used to be very shy. Since the Great Quake, they became aggressive.");
+ next;
+ mesn;
+ mesq l("...So why would they kidnap Cindy?? %%i");
+ next;
+ mesn;
+ mesq l("I figured out, maybe one of the sages could help. Would you mind asking them?");
+ next;
+ select
+ l("I'll be back later."),
+ rif(get_nibble(##03_TMWQUEST, 0) == 0, l("Sure, I'll ask them.")),
+ rif(get_nibble(##03_TMWQUEST, 0) == 3, l("[Tell her the truth]")),
+ rif(get_nibble(##03_TMWQUEST, 0) == 3, l("[Make up an excuse]"));
+ mes "";
+ switch (@menu) {
+ case 2:
+ mesn;
+ mesq l("Wonderful! Please be careful out there.");
+ set_nibble(##03_TMWQUEST, 0, 1);
+ break;
+ case 3:
+ mesc l("%s faints.", strnpcinfo(1));
+ next;
+ // FALL-THROUGH
+ case 4:
+ mesn;
+ mesq l("Thanks for informing me. I'm sure Nikolai and the sages will do something about it, then.");
+ next;
+ mesn;
+ mesq l("I'm afraid I don't have anything of value to reward you with, but some %s which my husband was saving for a quest or other. You can have them. Cindy is more important than a quest.", getitemlink(TreasureKey));
+ set_nibble(##03_TMWQUEST, 0, 4);
+ getitem TreasureKey, rand2(15, 25);
+ break;
+ }
+ close;
}
diff --git a/npc/031-4/cindyCave.txt b/npc/031-4/cindyCave.txt
index 39ff62e4..284a58f8 100644
--- a/npc/031-4/cindyCave.txt
+++ b/npc/031-4/cindyCave.txt
@@ -49,7 +49,7 @@ L_Try_Cage:
$@FIGHT_YETI_WAVE = 0;
$@YETI_COUNT = 1;
$@FIGHT_YETI_PLAYER_COUNT = getmapusers("031-4");
- areamonster "031-4", 0, 0, 95, 91, "", 1072, 1, "Cindy::OnPetDeath";
+ areamonster "031-4", 0, 0, 95, 91, "Yeti", Yeti, 1, "Cindy::OnPetDeath";
initnpctimer;
goto L_close;
@@ -130,7 +130,7 @@ OnTimer5000:
L_Return_1:
$@FIGHT_YETI_PLAYER_COUNT = 0;
- areatimer 0, "031-4", 0, 0, 95, 91, 10, "Cindy::OnTick";
+ maptimer2 "031-4", 10, "Cindy::OnTick";
end;
L_CaveLogic:
@@ -140,7 +140,7 @@ L_CaveLogic:
if ($@FIGHT_YETI_PLAYER_COUNT <= 0)
goto L_CleanUp;
set $@FIGHT_YETI_ROUND_TIMER, $@FIGHT_YETI_ROUND_TIMER + 5; // Advance 5 seconds
- if (mobcount("031-4", "Cindy::OnPetDeath") < 0)
+ if (mobcount("031-4", "Cindy::OnPetDeath") <= 0)
goto L_NextWave;
if ($@FIGHT_YETI_ROUND_TIMER + $@FIGHT_YETI_ROUND_PEN >= 120)
goto L_NextWave;
@@ -156,13 +156,13 @@ L_NextWave:
&& $@FIGHT_YETI_WAVE < 22)
goto L_Return_1;
if ($@FIGHT_YETI_WAVE > 22)
- areamonster "031-4", 0, 0, 95, 91, "", 1072, $@FIGHT_YETI_WAVE*2 + $@FIGHT_YETI_PLAYER_COUNT*5, "Cindy::OnPetDeath";
+ areamonster "031-4", 0, 0, 95, 91, "Yeti", Yeti, $@FIGHT_YETI_WAVE*2 + $@FIGHT_YETI_PLAYER_COUNT*5, "Cindy::OnPetDeath";
if ($@FIGHT_YETI_WAVE > 22)
$@YETI_COUNT = $@YETI_COUNT + $@FIGHT_YETI_WAVE*2 + $@FIGHT_YETI_PLAYER_COUNT*5;
$@FIGHT_YETI_NUMBER = (5 + (1 * $@FIGHT_YETI_WAVE) + (2 * $@FIGHT_YETI_PLAYER_COUNT))/4;
$@YETI_COUNT = $@YETI_COUNT + $@FIGHT_YETI_NUMBER;
- areamonster "031-4", 0, 0, 95, 91, "", 1072, $@FIGHT_YETI_NUMBER, "Cindy::OnPetDeath";
+ areamonster "031-4", 0, 0, 95, 91, "Yeti", Yeti, $@FIGHT_YETI_NUMBER, "Cindy::OnPetDeath";
$@msg$ = $@FIGHT_YETI_MESSAGES$[$@FIGHT_YETI_WAVE];
if ($@msg$ == "")
diff --git a/npc/048-2/sageNikolai.txt b/npc/048-2/sageNikolai.txt
index d69cad46..25e360e1 100644
--- a/npc/048-2/sageNikolai.txt
+++ b/npc/048-2/sageNikolai.txt
@@ -25,7 +25,7 @@
goto L_Hints;
mes "You see a very reputable looking man who is going through some papers. He looks up as you approach.";
- mes "[Nikolai]";
+ mesn;
mes "\"Welcome to my mansion. I am Nikolai, member of the Sages of Kaizei.";
mes "I assume you came to see our famous library? As you can see, it isn't in very good shape due to some... misfortunes. I'm very sorry.\"";
if (BaseLevel < $@Q_BlueSageMinimumLevel)
@@ -38,7 +38,7 @@
goto L_close;
L_Hints:
- mes "[Nikolai]";
+ mesn;
mes "\"I heard you started to help out a bit. That's very kind.\"";
cleararray @choice_idx, 0, 10;
@@ -173,21 +173,21 @@ L_MenuChoice:
L_StartPagesAdvice:
// I heard the slimes ate most of the books...
- mes "[Nikolai]";
+ mesn;
mes "\"This is true. But while hunting the slimes we discovered that they occasionaly drop bookpages that are still legible.";
mes "Since we had several copies of nearly all the books, we might be able to recreate most of them if we can get at least one copy of each page.\"";
goto L_close;
L_PagesAdvice:
// I'm collecting lost bookpages.
- mes "[Nikolai]";
+ mesn;
mes "\"Excellent! This will save us a lot of time. Ensio coordinates the sorting of the pages.\"";
goto L_close;
L_StartMaterialAdvice:
// There were many valuable books in your library, right?
mes "He sighs.";
- mes "[Nikolai]";
+ mesn;
mes "\"Yes. There were some really old and rare pieces.\"";
next;
mes "\"We're going to recreate some of them, but I'm not sure if we have all the needed materials. If you'd like to help you could ask around if someone is missing something.\"";
@@ -195,31 +195,31 @@ L_StartMaterialAdvice:
L_MaterialAdvice:
// I brought some material to repair the books.
- mes "[Nikolai]";
+ mesn;
mes "\"That's very generous! Though I think not everyone has all they need yet.\"";
goto L_close;
L_StartSlimesAdvice:
// Those slimes really caused a mess!
- mes "[Nikolai]";
+ mesn;
mes "\"Indeed. My helpers did great work to clean the worst of it, but there are still some remaining slimes in the deeper parts of the library.\"";
goto L_close;
L_SlimesAdvice:
// I'm hunting the remaining slimes in the library.
- mes "[Nikolai]";
+ mesn;
mes "\"You're a great help! All helpers who would be capable of dealing with the slimes are occupied with other tasks.\"";
goto L_close;
L_StartInvAdvice:
// How did this all happen?
- mes "[Nikolai]";
+ mesn;
mes "\"We're not sure yet. The helper who was responsible for sealing away the slimes has been sent to his room until the situation calms down and we can start an investigation.\"";
goto L_close;
L_InvestigateAdvice:
// I'm trying to find out how that accident could've happened.
- mes "[Nikolai]";
+ mesn;
mes "\"I see. Well, we were too busy to start with that ourselves, but having someone unbiased looking at this case might be a good thing.\"";
next;
mes "\"It might be good if you talk to Elias at the reception. He usually has a very good overview of all the things going on and especially about visitors.\"";
@@ -227,14 +227,14 @@ L_InvestigateAdvice:
L_InvestigateAdvice2:
// I told Chief Oskari what I found out about the accident.
- mes "[Nikolai]";
+ mesn;
mes "\"Yes, he already let me know. Your investigations were very helpful! This is surely something we need to look into further.\"";
next;
mes "\"Did you already talk to Peetu? I'm sure he'll be glad to know about your results as well.\"";
goto L_close;
L_GrimoireReward:
- mes "[Nikolai]";
+ mesn;
mes "\"Ah, " + strcharinfo(0) + "! We're making excellent progress with our attempts to recover the important and valuable of the destroyed books, all thanks to you.\"";
next;
mes "\"I'd like you to have this as a reward for your help.\"";
@@ -249,7 +249,7 @@ L_GrimoireReward:
goto L_close;
L_SlimesReward:
- mes "[Nikolai]";
+ mesn;
mes "\"Ah, I heard you took care of the remaining slimes in the library!\"";
next;
mes "\"While looking through some old artifacts that we found during the cleaning, we found this sword. We don't really have a use for it.\"";
@@ -264,13 +264,90 @@ L_SlimesReward:
goto L_close;
L_Full_Inv:
- mes "[Nikolai]";
+ mesn;
mes "\"You have a very full backback. Please come back when you have more room available.\"";
goto L_close;
L_Done:
- mes "[Nikolai]";
- mes "\"Thanks for all of your help.\"";
+ mesn;
+ mesq l("Thanks for all of your help.");
+ if (get_nibble(##03_TMWQUEST, 0) == 2 &&
+ (##01_MLWORLD & MLP_TMW_YETIKING) &&
+ getvaultid()) goto L_VaultQuest;
+ goto L_close;
+
+L_VaultQuest:
+ mes "";
+ mesn strcharinfo(0);
+ select
+ l("Ask the Blue Sage about Cindy."),
+ l("Don't ask");
+ if (@menu == 2) close;
+ mes "";
+ mesn;
+ mesq l("Cindy? Never heard of.");
+ next;
+ mesn strcharinfo(0);
+ select
+ l("Press."),
+ l("Don't press.");
+ if (@menu == 2) close;
+ mes "";
+ mesn;
+ mesq l("Look, this is not Nivalis. This is Thermin. If I say I know nothing, I know nothing. Stop wasting my time.");
+ next;
+ mesn strcharinfo(0);
+ select
+ l("Press."),
+ l("Don't press.");
+ if (@menu == 2) close;
+ mes "";
+ mesn;
+ mesq l("Are you deaf?");
+ next;
+ mesn strcharinfo(0);
+ select
+ l("Press."),
+ l("Don't press.");
+ if (@menu == 2) close;
+ mes "";
+ mesn;
+ mesc l("*sigh*");
+ next;
+ mesn;
+ mesq l("Alright, alright, you win. But to make clear, this is NOT my fault. It's Santa's.");
+ next;
+ mesn;
+ mesq l("So, you know about the Sages of Kaizei, right? We used to be twelve, but then Balthasar left after fighting with Santa, and now we're only eleven.");
+ next;
+ mesn;
+ mesq l("Seems like Balthasar is bent on revenge. If you cannot harm a sage, aim at the things they hold dear, they say.");
+ next;
+ mesn;
+ mesq l("Christmas for Santa, the library for myself, and... Well, you guessed it: Cindy.");
+ next;
+ mesn;
+ mesq l("But please don't tell Angela this. She is already a worrywart, knowing Balthasar is after her husband will only makes things worse.");
+ next;
+ mesn;
+ mesq l("Listen, I'll give you either a Wizard Hat or a Wooden Staff for your silence. Do we have a deal?");
+ next;
+ select
+ l("I'll think on it later."),
+ l("Deal - Give me a Wizard Hat."),
+ l("Deal - Give me a Wooden Staff.");
+ mes "";
+ if (@menu == 1) close;
+ if (@menu == 2) .@it = any(2200, 2201, 2202, 2203, 2204, 2205, 2206, 2207, 2208, 2209);
+ if (@menu == 3) .@it = WoodenStaff;
+ inventoryplace .@it, 1;
+ getitem .@it, 1;
+ set_nibble(##03_TMWQUEST, 0, 3);
+ mesn;
+ mesq l("Here, take this %s. Tell Angela just that I've heard about it and I'll investigate, and she has nothing to worry about.", getitemlink(.@it));
+ next;
+ mesn;
+ mesq l("And thanks. I'll inform her father with telepathy as well.");
goto L_close;
L_close:
diff --git a/npc/functions/bitwise.txt b/npc/functions/bitwise.txt
index 7d0047e8..02360662 100644
--- a/npc/functions/bitwise.txt
+++ b/npc/functions/bitwise.txt
@@ -121,10 +121,10 @@ function script get_bitword {
/////////////////////////////////////////////////////////////////////////////////
// A Nibble can go up to 15. There are 7 nibbles.
-// set_nibble(VAR, VAL, NIBBLEID)
+// set_nibble(VAR, NIBBLEID, VAL)
function script set_nibble {
.@v=getarg(0);
- switch (getarg(2)) {
+ switch (getarg(1)) {
case 0:
.@s=0; .@m=0xF; break;
case 1:
@@ -140,17 +140,17 @@ function script set_nibble {
case 6:
.@s=24; .@m=0xF000000; break;
default:
- Exception("Invalid SNibble: "+getarg(2), RB_DEFAULT);
+ Exception("Invalid SNibble: "+getarg(1), RB_DEFAULT);
}
- return bitwise_set(.@v, .@m, .@s, getarg(1));
+ return bitwise_set(getarg(0), .@m, .@s, getarg(2));
}
// A Byte can go up to 255. There are 3 bytes. The forth can go up to 127.
-// set_nibble(VAR, VAL, BYTEID)
+// set_nibble(VAR, BYTEID, VAL)
function script set_byte {
.@v=getarg(0);
- switch (getarg(2)) {
+ switch (getarg(1)) {
case 0:
.@s=0; .@m=0xFF; break;
case 1:
@@ -160,10 +160,10 @@ function script set_byte {
case 3:
.@s=24; .@m=0x7F000000; break;
default:
- Exception("Invalid SByte: "+getarg(2), RB_DEFAULT);
+ Exception("Invalid SByte: "+getarg(1), RB_DEFAULT);
}
- return bitwise_set(.@v, .@m, .@s, getarg(1));
+ return bitwise_set(getarg(0), .@m, .@s, getarg(2));
}
// A Bitword can go up to 65535 and is fixed in position to handle Soul EXP.
@@ -171,6 +171,6 @@ function script set_byte {
function script set_bitword {
.@v=getarg(0);
- return bitwise_set(.@v, 0xFFFF, 0, getarg(1));
+ return bitwise_set(getarg(0), 0xFFFF, 0, getarg(1));
}
diff --git a/npc/functions/vault.txt b/npc/functions/vault.txt
index 15a969fb..b6d46a13 100644
--- a/npc/functions/vault.txt
+++ b/npc/functions/vault.txt
@@ -64,8 +64,8 @@ function script vaultOnLogin {
}
// Unset the target lake/world
- set_byte(##00_INFO, 0, 3);
- set_nibble(##00_INFO, 0, 5);
+ set_byte(##00_INFO, 3, 0);
+ set_nibble(##00_INFO, 5, 0);
} else if (.@gto) {
// Heading somewhere which is not here!
mesc l("WARNING: If you use any Mirror Lake feature on this world, the current Mirror Lake Quest will be marked as \"Failed\"."), 1;
@@ -85,7 +85,7 @@ function script vaultOnLogout {
.@api$=json_encode("UID", ##VAULT,
"GID", getcharid(3),
"VAR1N", "TMWQUEST",
- "VAR1V", ##02_TMWQUEST,
+ "VAR1V", ##03_TMWQUEST,
"VEXP", ##VAULT_EXP,
"GOTO", ##VAULT_GOTO,
"MLTO", ##VAULT_MLTO);