// TMW2/LoF scripts.
// Authors:
// TMW-LoF Team
// Jesusalva
// Description:
// Part from a bigger, very important quest for learning about the MOUBOOTAUR.
// Interacts with Sagratha (for uncursing).
//
// Quest Structure:
// HurnscaldQuest_InjuriedMouboo - STATUS - HPBAR
// Quest Status:
// 0 - First Met
// 1 - Examined (HP Bar stored on field 2)
// 2 - Healed (Curse not solved - ready for Sagratha Quest)
// 3 - Curse removed (Sagratha's Arc)
// 9 - KILLED YOUR MOUBOO. YOU EVIL MONSTER.
014-2,144,80,0 script Mouboo#0142injuried NPC_INJURIED_MOUBOO,{
.@q=getq(HurnscaldQuest_InjuriedMouboo);
if (.@q < 2) goto L_Begin;
if (.@q == 2) goto L_Healed;
if (.@q == 3) goto L_Uncursed;
if (.@q == 9) goto L_Killed;
goodbye;
end;
// Main Quest
L_Begin:
.@q=getq(HurnscaldQuest_InjuriedMouboo);
.@q2=getq2(HurnscaldQuest_InjuriedMouboo);
mesn l("Injuried Mouboo");
mesq l("Booo....");
mesc l("The Mouboo seems to be lying in pain.");
next;
select
l("Examine the Mouboo"),
rif(.@q == 1, l("Attempt to heal the Mouboo")),
rif(.@q == 1, l("Attempt to kill the Mouboo")),
l("Leave the Mouboo alone");
mes "";
switch (@menu) {
case 1:
mesc l("The Mouboo is lying down on the grass.");
mesc l("There doesn't seems to be any physical wound.");
mesc l("A closer inspection suggests this mouboo has been... CURSED.");
if (.@q == 0)
setq HurnscaldQuest_InjuriedMouboo, 1, 100;
next;
goto L_Begin;
case 2:
mes "##B" + l("Drag and drop a healing item from your inventory.") + "##b";
.@id = requestitem();
// If ID is invalid, there's not enough items, it is bound = Cannot bury
if (.@id < 1 || countitem(.@id) < 1 || checkbound(.@id) || getiteminfo(.@id, ITEMINFO_TYPE) != IT_HEALING) {
if (checkbound(.@id))
mesc l("You cannot part with this item!");
else if (.@id == MoubooFigurine)
mesc l("Haha, this wooden figurine won't do the job, sorry.");
else if (.@id == PlushMouboo)
mesc l("This seems like a good idea at first, but actually, it isn't.");
else if (.@id == MoubooPendant)
mesc l("Wise choice! But can you really part with it? Better think on something else!");
else if (.@id == MoubooHat || .@id == AlphaMoubooHat)
mesc l("...I don't think giving it this hat will really help...");
else if (getiteminfo(.@id, ITEMINFO_TYPE) != IT_HEALING)
mesc l("This is not a healing item.");
else
mesc l("You give up.");
close;
}
if (.@id == MoubooSteak) {
mesc l("Uhm, this seems like a bad idea.");
close;
} else if (.@id == DeathPenalty) {
mesc l("Uhm, that's an... @@. Do you... want to grow a tree on the mouboo or something? Can't you think on something else?", DeathPenalty);
close;
}
mesc l("Really give your @@ to the Mouboo?", getitemlink(.@id)), 1;
mesc l("The item will be lost forever.");
next;
if (askyesno() == ASK_YES) {
delitem .@id, 1;
itemeffect(.@id); // As a bonus, you'll be healed too, because I need to retrieve @max value
// You need about 9.000 HP-worth healing items, and you can't use Mouboo Steak
if (.@id == ElixirOfLife)
setq2 HurnscaldQuest_InjuriedMouboo, 9999;
else
setq2 HurnscaldQuest_InjuriedMouboo, .@q2+((@min+@max)/10);
if (.@q2 > 1000) {
mesc l("This will be remembered."), 6;
setq HurnscaldQuest_InjuriedMouboo, 2;
getexp 800, 0;
close;
}
}
break;
case 3:
mes "##B" + l("Drag and drop a weapon from your inventory.") + "##b";
.@id = requestitem();
// If ID is invalid, there's not enough items, it is bound = Cannot bury
if (.@id < 1 || countitem(.@id) < 1 || getiteminfo(.@id, ITEMINFO_TYPE) != IT_WEAPON) {
if (getiteminfo(.@id, ITEMINFO_TYPE) != IT_WEAPON)
mesc l("This is not a weapon. Wait, you don't want to explode it, right?!");
else
mesc l("You give up.");
close;
}
mesc l("Really attack the Mouboo with a(n) @@?", getitemlink(.@id)), 1;
mesc l("There will be consequences.");
next;
if (askyesno() == ASK_YES) {
.@atk=getiteminfo(.@id, ITEMINFO_ATK);
mesn l("Injuried Mouboo");
if (.@q2 < 20)
mesq l("Re-ref... Reflect.");
else
mesq l("Ma... Magical Re... Re-ref... Reflection.");
setq2 HurnscaldQuest_InjuriedMouboo, .@q2-(.@atk/10);
if (.@q2 > 1000) {
mesq l("The... Mou... Boo... Taur...");
mesq l("Is... Dan... Ger... Ous...");
mesq l("...Help... Me...");
setq HurnscaldQuest_InjuriedMouboo, 9;
getexp 800, 0;
next;
mesc l("This will be remembered."), 6;
heal -.@atk, -(.@atk/10);
close;
}
heal -.@atk, -(.@atk/10);
next;
}
break;
default:
close;
}
mes "";
goto L_Begin;
// Sagratha Arc
L_Healed:
.@q=getq(HurnscaldQuest_InjuriedMouboo);
.@q2=getq2(HurnscaldQuest_InjuriedMouboo);
mesn l("Injuried Mouboo");
mesq l("Zzzzzz....");
mesc l("The mouboo is sleeping soundly. The curse is still there.");
// TODO: HANDLE SAGRATHA
close;
// Final Results
L_Uncursed:
mesn;
mesq l("Hello, @@. Thanks for helping me.", strcharinfo(0));
next;
mesn;
mesq l("Don't challenge the Moubootaur. You saw what happened to me.");
close;
L_Killed:
mesc l("Did this Mouboo just blinked? No, I made sure to kill it. Must have been my imagination.");
close;
OnInit:
.sex=G_OTHER;
.distance=2;
end;
}