//================= Hercules Script =======================================
//=       _   _                     _
//=      | | | |                   | |
//=      | |_| | ___ _ __ ___ _   _| | ___  ___
//=      |  _  |/ _ \ '__/ __| | | | |/ _ \/ __|
//=      | | | |  __/ | | (__| |_| | |  __/\__ \
//=      \_| |_/\___|_|  \___|\__,_|_|\___||___/
//================= License ===============================================
//= This file is part of Hercules.
//= http://herc.ws - http://github.com/HerculesWS/Hercules
//=
//= Copyright (C) 2012-2015  Hercules Dev Team
//= Copyright (C)  L0ne_W0lf
//= Copyright (C)  Lupus
//= Copyright (C)  kobra_k88
//=
//= Hercules is free software: you can redistribute it and/or modify
//= it under the terms of the GNU General Public License as published by
//= the Free Software Foundation, either version 3 of the License, or
//= (at your option) any later version.
//=
//= This program is distributed in the hope that it will be useful,
//= but WITHOUT ANY WARRANTY; without even the implied warranty of
//= MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
//= GNU General Public License for more details.
//=
//= You should have received a copy of the GNU General Public License
//= along with this program.  If not, see <http://www.gnu.org/licenses/>.
//=========================================================================
//= Doomed Swords Quest
//================= Description ===========================================
//= Doomed Swords Quest:
//= - Quest for Doomed Swords: Grimtooth, Mysteltain, Executioner.
//================= Current Version =======================================
//= 1.5
//================= Additional Comments ===================================
//= Although this quest is enabled on iRO, the Mysteltainn portion is NOT
//= completable as the item "Young Twig" does not drop.
//================= Variables Used ========================================
//= event_magum (max 6)
//= dmdswrd_Q2 (bits 1 - 32)
//=========================================================================

prt_in,162,11,2	script	Ghatu#magum	4_M_04,{
	if (event_magum == 0) {
		if (dmdswrd_Q2 & 1 || dmdswrd_Q2 & 2 || dmdswrd_Q2 & 4 || dmdswrd_Q2 & 8 || dmdswrd_Q2 & 16 || dmdswrd_Q2 & 32) {
			mes "[Ghatu]";
			mes "I've heard of a strange";
			mes "blacksmith who lives in";
			mes "seclusion deep in the";
			mes "Payon Forest. The man";
			mes "was once famous for his";
			mes "legendary smithing skill...";
			next;
			mes "[Ghatu]";
			mes "Rumor has it that he's";
			mes "hiding in the mountains";
			mes "since too many people want to use his talents for the wrong";
			mes "purposes. Apparently, there is a godly quality to his weapons...";
			event_magum = 1;
			close;
		}
		mes "[Ghatu]";
		mes "Remember that blacksmith";
		mes "I told you about last time? It";
		mes "seems that his weapons were";
		mes "in such great demand because";
		mes "he would enchant them with ";
		mes "tremendously powerful magic.";
		next;
		mes "[Ghatu]";
		mes "However, the man was forced";
		mes "by the power hungry and the";
		mes "oppressive to create weapons";
		mes "for selfish and immoral ends.";
		mes "It's no surprise that he went";
		mes "into hiding in the end...";
		next;
		mes "[Ghatu]";
		mes "It's sad, really.";
		mes "That smith used to be";
		mes "a pretty easy going guy";
		mes "until he was forced to work";
		mes "against his will. Slowly, he became gloomy and intimidating...";
		next;
		mes "[Ghatu]";
		mes "But I suppose blacksmiths";
		mes "can never really give up the";
		mes "hammer. If you can manage to";
		mes "find him, perhaps you can ask";
		mes "him to forge something for you?";
		event_magum = 5;
		close;

	}
	else if (event_magum == 1) {
		mes "[Ghatu]";
		mes "Remember that blacksmith";
		mes "I told you about last time? It";
		mes "seems that his weapons were";
		mes "in such great demand because";
		mes "he would enchant them with ";
		mes "tremendously powerful magic.";
		next;
		mes "[Ghatu]";
		mes "However, the man was forced";
		mes "by the power hungry and the";
		mes "oppressive to create weapons";
		mes "for selfish and immoral ends.";
		mes "It's no surprise that he went";
		mes "into hiding in the end...";
		next;
		mes "[Ghatu]";
		mes "It's sad, really.";
		mes "That smith used to be";
		mes "a pretty easy going guy";
		mes "until he was forced to work";
		mes "against his will. Slowly, he became gloomy and intimidating...";
		next;
		mes "[Ghatu]";
		mes "But I suppose blacksmiths";
		mes "can never really give up the";
		mes "hammer. If you can manage to";
		mes "find him, perhaps you can ask";
		mes "him to forge something for you?";
		event_magum = 5;
		close;
	}
	mes "[Ghatu]";
	mes "That mysterious blacksmith...";
	mes "I wonder how he made those";
	mes "enchanted weapons of his.";
	mes "I've heard that he might have";
	mes "been dabbling in the dark arts,";
	mes "but that doesn't seem right...";
	close;
}

prontera,197,188,2	script	Veeyop#magum	1_M_04,{
	if (dmdswrd_Q2 & 1) {
		mes "[Veeyop]";
		mes "You know, talking";
		mes "about Mysteltainn and";
		mes "the death of Baldur just...";
		mes "It didn't occur to me until";
		mes "now just how morbid it all";
		mes "sounds. Yeah, yeah, I know.";
		close;
	}
	mes "[Veeyop]";
	mes "Have you heard the";
	mes "legend of Mysteltainn?";
	mes "It's a tree, known for being";
	mes "the only thing able to harm";
	mes "Baldur, god of light. In fact,";
	mes "just a twig from it killed him.";
	next;
	mes "[Veeyop]";
	mes "Now, I'm not sure if this";
	mes "is true, but I've heard that";
	mes "someone actually forged";
	mes "a sword so powerful, it's";
	mes "worthy of the name,";
	mes "''Mysteltainn.''";
	next;
	mes "[Veeyop]";
	mes "There's only one person";
	mes "in the world who can forge";
	mes "that Mysteltainn sword. I...";
	mes "I think he used to live in";
	mes "Prontera, but then he moved";
	mes "away for some weird reason.";
	if (event_magum == 1)
		event_magum = 5;
	dmdswrd_Q2 |= 1;
	close;
}

morocc,281,178,2	script	Cetsu#magum	4W_M_01,{
	if (dmdswrd_Q2 & 2) {
		mes "[Cetsu]";
		mes "I keep thinking about";
		mes "Grimtooth, and it occurred";
		mes "to me that the spell used to";
		mes "to endow that dagger with its";
		mes "strength probably isn't magic";
		mes "that we're familiar with.";
		next;
		mes "[Cetsu]";
		mes "There's all sorts of";
		mes "creepy stories going";
		mes "around. I even hear";
		mes "that the Grimtooth";
		mes "might have some";
		mes "sort of weird curse?";
		close;
	}
	mes "[Cetsu]";
	mes "You know, there are";
	mes "stories of an incredibly";
	mes "powerful dagger that's";
	mes "stronger than steel.";
	mes "I think it was made";
	mes "out of ogre teeth?";
	next;
	mes "[Cetsu]";
	mes "Anyway, it wasn't just";
	mes "the ogre teeth that gave";
	mes "the dagger its power. I think";
	mes "it had to be enchanted with";
	mes "a special spell or something.";
	next;
	mes "[Cetsu]";
	mes "This dagger, the Grimtooth,";
	mes "can only be made by one person";
	mes "in the entire world. This guy used to live in Prontera, but then he";
	mes "moved away for some reason.";
	next;
	mes "[Cetsu]";
	mes "I wonder...";
	mes "Did he go into";
	mes "hiding? His weapons";
	mes "did seem to be pretty";
	mes "high in demand back then...";
	if (event_magum == 1)
		event_magum = 5;
	dmdswrd_Q2 |= 2;
	close;
}

izlude_in,173,88,2	script	Nain#magum	8_F,{
	if (dmdswrd_Q2 == 4) {
		mes "[Nain]";
		mes "It doesn't matter how";
		mes "powerful the Executioner";
		mes "is: if it were to end up in";
		mes "my hands, I would get rid";
		mes "of it right away. I'd never risk losing my mind to that curse...";
		close;
	}
	mes "[Nain]";
	mes "Long ago, one sword";
	mes "was used to behead all";
	mes "the criminals that had been";
	mes "sentenced to death. That";
	mes "accursed blade is known";
	mes "as the Executioner.";
	next;
	mes "[Nain]";
	mes "As the Executioner slayed";
	mes "more criminals, the rage and";
	mes "bloodlust of its victims began";
	mes "to accumulate upon the blade.";
	mes "Although the sword gained great strength, it was tainted by evil.";
	next;
	mes "[Nain]";
	mes "The last person to wield";
	mes "the Executioner almost lost";
	mes "his mind to the sword. He saved himself by giving it to a talented";
	mes "blacksmith who would destroy it for him, thus saving his soul.";
	next;
	mes "[Nain]";
	mes "This mysterious blacksmith";
	mes "was never seen again in the";
	mes "city of Prontera, but rumor has";
	mes "it that if you can find him, he";
	mes "can forge that accursed";
	mes "Executioner anew...";
	if (event_magum == 1)
		event_magum = 5;
	dmdswrd_Q2 |= 4;
	close;
}

pay_fild08,218,283,2	script	Mysterious Man#magum	4_M_ORIENT02,{
	if (checkweight(Knife,1) == 0) {
		mes "[Mysterious Man]";
		mes "Hold it.";
		mes "You're carrying";
		mes "far too many items";
		mes "with you. Speak to me";
		mes "after you've placed your";
		mes "goods into Kafra Storage.";
		close;
	}
	if (event_magum == 0) {
		if (dmdswrd_Q2 & 1 || dmdswrd_Q2 & 2 || dmdswrd_Q2 & 4 || dmdswrd_Q2 & 8 || dmdswrd_Q2 & 16 || dmdswrd_Q2 & 32) {
			mes "[Mysterious Man]";
			mes "Well...?";
			mes "What the hell";
			mes "are you looking at?";
			next;
			if (select("Have you heard of the Doomed Swords?", "I... I...") == 1) {
				mes "[Mysterious Man]";
				mes "...!";
				mes "How the hell would";
				mes "I know about that?";
				mes "Leave me alone!";
				close;
			}
			mes "[Mysterious Man]";
			mes "...";
			next;
			mes "[Mysterious Man]";
			mes "...";
			mes "......";
			next;
			mes "[Mysterious Man]";
			mes "Get lost.";
			close;
		}
		else {
			mes "[Mysterious Man]";
			mes "Well...?";
			mes "What the hell";
			mes "are you looking at?";
			next;
			if (select("Um, er...", "Nothing, sir.") == 1) {
				mes "[Mysterious Man]";
				mes "What...?!";
				next;
				mes "^3355FFThis guy is";
				mes "really intimidating!^000000";
				close;
			}
			mes "[Mysterious Man]";
			mes "Nothing, huh?";
			mes "Well, right now, I'm";
			mes "looking at a bothersome";
			mes "adventurer! Get outta here";
			mes "and leave me the hell alone!";
			close;
		}
	}
	else if (event_magum == 1) {
		mes "[Mysterious Man]";
		mes "Well...?";
		mes "What the hell";
		mes "are you looking at?";
		next;
		if (select("Do you happen to be a blacksmith?", "No-Nothing!") == 1) {
			mes "[Mysterious Blacksmith]";
			mes "Hmpf. So you're not";
			mes "a total fool after all. Yes,";
			mes "I used to do smithing, but";
			mes "I don't do the simple work";
			mes "that most Blacksmiths";
			mes "can do nowadays...";
			close;
		}
		mes "[Mysterious Blacksmith]";
		mes "...";
		mes "......";
		next;
		mes "[Mysterious Blacksmith]";
		mes "Get outta my sight.";
		close;
	}
	else if (event_magum == 5) {
		mes "[Mysterious Blacksmith]";
		mes "Well...?";
		mes "What the hell";
		mes "are you looking at?";
		next;
		if (select("I want you to make me a Doomed Sword.", "Er, nothing!") == 1) {
			mes "[Mysterious Blacksmith]";
			mes "Hm. I don't know where";
			mes "the hell you may have heard";
			mes "of me, but I guess one of you";
			mes "adventurers would find me soon";
			mes "enough. Now, which doomed";
			mes "sword did you wish to possess?";
			next;
			switch(select("Mysteltainn.", "Grimtooth.", "Executioner.", "I ch-changed my mind!")) {
			case 1:
				if (dmdswrd_Q2 & 1) {
					mes "[Mysterious Blacksmith]";
					mes "You want...";
					mes "that sword?";
					mes "Don't speak its";
					mes "name so lightly!";
					next;
					mes "[Mysterious Blacksmith]";
					mes "Do you understand the curse";
					mes "on that sword? The Mysteltainn";
					mes "derives its dark power from the";
					mes "twig that was used to kill Baldur, god of light. Let me relate the";
					mes "story as briefly as I can...";
					next;
					mes "[Mysterious Blacksmith]";
					mes "In the era of the gods,";
					mes "the beautiful, pure and";
					mes "joyful Baldur was loved by";
					mes "all living creatures, save for";
					mes "one: Loki, the god of trickery.";
					next;
					mes "[Mysterious Blacksmith]";
					mes "When Loki, out of jealousy,";
					mes "decided to kill Baldur, the";
					mes "goddess Freyja had a dream";
					mes "about Baldur's death. Fearing";
					mes "the realization of her dream,";
					mes "she counseled with the gods.";
					next;
					mes "[Mysterious Blacksmith]";
					mes "To protect Baldur, the gods";
					mes "decided to extract an oath";
					mes "to never harm Baldur from";
					mes "every creature, object and";
					mes "natural force. All who were";
					mes "asked agreed to make this oath.";
					next;
					mes "[Mysterious Blacksmith]";
					mes "Of all the beings and objects";
					mes "in the universe, Freya only";
					mes "neglected to ask one tree to";
					mes "make this oath: the Mysteltainn. Freyja believed it was far too";
					mes "small and insignificant to ask.";
					next;
					mes "[Mysterious Blacksmith]";
					mes "Believing that everything";
					mes "in the universe had sworn";
					mes "not to harm Baldur, the gods";
					mes "made it their new pastime to";
					mes "throw daggers and knives at";
					mes "the now nigh invincible god.";
					next;
					mes "[Mysterious Blacksmith]";
					mes "However, Loki was determined";
					mes "to kill Baldur and, disguising";
					mes "himself, politely asked Freyja";
					mes "if there was any object in the";
					mes "world that did not take the";
					mes "oath to not harm Baldur.";
					next;
					mes "[Mysterious Blacksmith]";
					mes "Freyja suspected nothing and";
					mes "told Loki about the secret of";
					mes "Mysteltainn. The next time the gods played their game of throwing";
					mes "objects at Baldur, Loki was there with a small Mysteltainn twig.";
					next;
					mes "[Mysterious Blacksmith]";
					mes "Then, to compound his";
					mes "treachery, Loki tricked";
					mes "Hod, Baldur's blind twin";
					mes "brother, into throwing the";
					mes "twig into Baldur's heart. And";
					mes "so, the god of light was slain.";
					next;
					mes "[Mysterious Blacksmith]";
					mes "Over the years,";
					mes "Mysteltainn has been";
					mes "fashioned into the sword";
					mes "that you may be familiar";
					mes "with today. Its power is";
					mes "strictly forbidden by the gods.";
					next;
					mes "[Mysterious Blacksmith]";
					mes "However, if you're willing";
					mes "to risk that sword's curse";
					mes "for the sake of its power,";
					mes "I will forge it for you if you";
					mes "can bring me the following";
					mes "items. They'll make sense...";
					next;
					mes "[Mysterious Blacksmith]";
					mes "^0099FF1 Young Twig^000000,";
					mes "^0099FF1 Emperium^000000,";
					mes "^0099FF1 Loki's Whispers^000000,";
					mes "^0099FF1 Mother's Nightmare^000000 and";
					mes "^0099FF1 Foolishness of the Blind^000000.";
					mes "That is what I need.";
					next;
					mes "[Mysterious Blacksmith]";
					mes "I'm not asking for much.";
					mes "You are only bringing the raw";
					mes "materials to forge the sword,";
					mes "and an Emperium to prove your";
					mes "worthiness to me. I will wait";
					mes "for your return, adventurer.";
					dmdswrd_Q2 |= 8;
					event_magum = 6;
					close;
				}
				mes "[Mysterious Blacksmith]";
				mes "Just by looking at you,";
				mes "I can tell that you don't know";
				mes "enough about the Mysteltainn";
				mes "to fully understand all of the";
				mes "risks that come with wielding that sword. Yes, you're too green.";
				next;
				mes "[Mysterious Blacksmith]";
				mes "I can't take the risk";
				mes "of creating that accursed";
				mes "sword for you if you haven't";
				mes "learned enough about it to";
				mes "be fully prepared for any of";
				mes "the consequences...";
				close;
			case 2:
				if (dmdswrd_Q2 & 2) {
					mes "[Mysterious Blacksmith]";
					mes "Ah, yes. You must be";
					mes "wondering how such a small";
					mes "dagger can contain such power.";
					mes "It's simple. I cast forbidden";
					mes "curse magic to inbue the dagger with its awesome destructiveness.";
					next;
					mes "[Mysterious Blacksmith]";
					mes "The curse I cast is so";
					mes "powerful that if I use it on";
					mes "a metal dagger, it would";
					mes "immediately melt down. Ogre";
					mes "tooth is the only material that";
					mes "can withstand the curse magic.";
					next;
					mes "[Mysterious Blacksmith]";
					mes "Of course, it's only";
					mes "fair to warn you that";
					mes "the power of the curse";
					mes "is such that the more you";
					mes "use the Grimtooth, the more it burns away at your very soul...";
					next;
					mes "[Mysterious Blacksmith]";
					mes "I am willing to forge";
					mes "the Grimtooth if you can";
					mes "prove worthy to wield its";
					mes "power and provide all of the";
					mes "materials I need to create it.";
					next;
					mes "[Mysterious Blacksmith]";
					mes "I will need...";
					mes "^0099FF1 Emperium^000000,";
					mes "^0099FF100 Ogre Teeth^000000,";
					mes "^0099FF10 Blades of Darkness^000000,";
					mes "^0099FF5 Cursed Rubies^000000 and";
					mes "^0099FF1 Broken Sword Handle^000000.";
					next;
					mes "[Mysterious Blacksmith]";
					mes "I don't need the";
					mes "Emperium to create";
					mes "the accursed sword, but I do";
					mes "require you to prove that you";
					mes "are worthy of the Grimtooth's";
					mes "power. Can you truly handle it?";
					dmdswrd_Q2 |= 16;
					event_magum = 6;
					close;
				}
				mes "[Mysterious Blacksmith]";
				mes "Hmpf. You don't really";
				mes "know what you're asking";
				mes "for, do you? I won't create";
				mes "that kind of weapon for any";
				mes "ignorant fool. Learn more about";
				mes "Grimtooth before you ask again!";
				close;
			case 3:
				if (dmdswrd_Q2 & 4) {
					mes "[Mysterious Blacksmith]";
					mes "So you're telling me that";
					mes "you want a sword that's been";
					mes "cursed by all the souls that've";
					mes "died from the thousands of death sentences it has carried out?";
					mes "Ha ha ha! Very interesting!";
					next;
					mes "[Mysterious Blacksmith]";
					mes "Yes... Each time this";
					mes "sword cut down a guilty";
					mes "criminal, the blade was";
					mes "cursed by the rage and";
					mes "regret of the slain.";
					next;
					mes "[Mysterious Blacksmith]";
					mes "Over time, the Executioner";
					mes "accumulated a truly dreadful";
					mes "power from the hatred of those";
					mes "it had killed. However, he who";
					mes "uses this sword risks becoming consumed by insanity and hatred.";
					next;
					mes "[Mysterious Blacksmith]";
					mes "The last person for whom";
					mes "I created this sword asked";
					mes "me to destroy it, fearing that";
					mes "it would corrupt his mind with";
					mes "its bloodlust. But if you think you can endure, I may forge it...";
					next;
					mes "[Mysterious Blacksmith]";
					mes "Just bring me...";
					mes "^0099FF50 Amulets^000000,";
					mes "^0099FF1 Emperium^000000,";
					mes "^0099FF2 Executioner's Gloves^000000,";
					mes "^0099FF10 Bloody Edges^000000 and";
					mes "^0099FF3 Necklaces of Oblivion^000000.";
					next;
					mes "[Mysterious Blacksmith]";
					mes "Those are the items I need";
					mes "to create a sword imbued with";
					mes "evil power. As for the Emperium, consider it my test to see if you";
					mes "are truly capable of wielding";
					mes "the accursed Executioner...";
					dmdswrd_Q2 |= 32;
					event_magum = 6;
					close;
				}
				mes "[Mysterious Blacksmith]";
				mes "Do you even know what";
				mes "you are asking of me...?";
				mes "Fool! Go and learn more";
				mes "about the Executioner! Then,";
				mes "maybe you'll understand how";
				mes "dangerous that sword truly is!";
				close;
			case 4:
				mes "[Mysterious Blacksmith]";
				mes "Hmm...?";
				mes "That a fact?";
				close;
			}
		}
		close;
	}
	else if (event_magum == 6) {
		mes "[Mysterious Blacksmith]";
		mes "Hmmm...";
		mes "Have you brought";
		mes "the required items?";
		mes "Or did you forget what";
		mes "you needed to bring to me?";
		next;
		switch(select("Er, what were the items again?", "Yes, I brought all the required items.", "Oh! Um, never mind!")) {
		case 1:
			mes "[Mysterious Blacksmith]";
			mes "Hmpf. I thought so.";
			mes "Now, which sword did";
			mes "you want me to forge?";
			next;
			switch(select("Mysteltainn.", "Grimtooth.", "Executioner.", "Wait! I just remembered!")) {
			case 1:
				if (dmdswrd_Q2 & 1 || dmdswrd_Q2 & 8) {
					mes "[Mysterious Blacksmith]";
					mes "^0099FF1 Young Twig^000000,";
					mes "^0099FF1 Emperium^000000,";
					mes "^0099FF1 Loki's Whispers^000000,";
					mes "^0099FF1 Mother's Nightmare^000000 and";
					mes "^0099FF1 Foolishness of the Blind^000000.";
					mes "That is what I need.";
					close;
				}
				mes "[Mysterious Blacksmith]";
				mes "Hmm. You don't understand";
				mes "enough about Mysteltainn for";
				mes "me to risk forging that sword";
				mes "for you. Think again: which";
				mes "sword did you ask me to create?";
				close;
			case 2:
				if (dmdswrd_Q2 & 2 || dmdswrd_Q2 & 16) {
					mes "[Mysterious Blacksmith]";
					mes "I will need...";
					mes "^0099FF1 Emperium^000000,";
					mes "^0099FF100 Ogre Teeth^000000,";
					mes "^0099FF10 Blades of Darkness^000000,";
					mes "^0099FF5 Cursed Rubies^000000 and";
					mes "^0099FF1 Broken Sword Handle^000000.";
					close;
				}
				mes "[Mysterious Blacksmith]";
				mes "Hmm. You don't know enough";
				mes "about the Grimtooth for me to";
				mes "risk forging it for you. Learn";
				mes "more about that dagger if you";
				mes "really want to possess it...";
				close;
			case 3:
				if (dmdswrd_Q2 & 4 || dmdswrd_Q2 & 32) {
					mes "[Mysterious Blacksmith]";
					mes "Just bring me...";
					mes "^0099FF50 Amulets^000000,";
					mes "^0099FF1 Emperium^000000,";
					mes "^0099FF2 Executioner's Gloves^000000,";
					mes "^0099FF10 Bloody Edges^000000 and";
					mes "^0099FF3 Necklaces of Oblivion^000000.";
					close;
				}
				mes "[Mysterious Blacksmith]";
				mes "You don't know anything";
				mes "about the Executioner. Learn";
				mes "more about that sword before";
				mes "you consider asking me to";
				mes "forge that monstrocity.";
				close;
			case 4:
				mes "[Mysterious Blacksmith]";
				mes "Fine.";
				mes "Then bring all";
				mes "the items I require";
				mes "when you are ready.";
				close;
			}
		case 2:
			mes "[Mysterious Blacksmith]";
			mes "So you think you're";
			mes "ready. Now, which sword";
			mes "did you want me to craft?";
			next;
			switch(select("Mysteltainn", "Grimtooth", "Executioner", "I ch-changed my mind!")) {
			case 1:
				if (dmdswrd_Q2 & 8) {
					mes "[Mysterious Blacksmith]";
					mes "Mysteltainn. Hm.";
					mes "Let me make sure";
					mes "that you brought";
					mes "everything I need to";
					mes "create this sword...";
					next;
					if (countitem(Young_Twig) < 1) {
						mes "[Mysterious Blacksmith]";
						mes "Well, well.";
						mes "You've forgotten";
						mes "to bring ^0099FF1 Young Twig^000000,";
						mes "the embodiment of the";
						mes "Mysteltainn twig used to kill Baldur. Hurry and bring it...";
						close;
					}
					if (countitem(Lokis_Whispers) < 1) {
						mes "[Mysterious Blacksmith]";
						mes "Hm. You forgot to bring";
						mes "^0099FF1 Loki's Whispers^000000. We need";
						mes "that to imbue the sword with";
						mes "immense, evil power. Go and";
						mes "find that as quickly as you can! ";
						close;
					}
					if (countitem(Mothers_Nightmare) < 1) {
						mes "[Mysterious Blacksmith]";
						mes "Hm, you still need to";
						mes "bring ^0099FF1 Mother's Nightmare^000000";
						mes "to instill the power of misery";
						mes "and grave portent to this blade... ";
						close;
					}
					if (countitem(Foolishness_Of_Blind) < 1) {
						mes "[Mysterious Blacksmith]";
						mes "Hm, you still need to";
						mes "bring ^0099FF1 Foolishness";
						mes "of the Blind^000000 to instill the";
						mes "energy of tragic regret into";
						mes "the curse imbued into the blade... ";
						close;
					}
					if (countitem(Emperium) < 1) {
						mes "[Mysterious Blacksmith]";
						mes "You have everything";
						mes "I require to forge the";
						mes "Mysteltainn, but you must";
						mes "still prove yourself capable";
						mes "of wielding it. Bring ^0099FF1 Emperium^000000 and I will recognize your worth.";
						close;
					}
					if (countitem(Young_Twig) > 0 && countitem(Lokis_Whispers) > 0 && countitem(Mothers_Nightmare) > 0 && countitem(Foolishness_Of_Blind) > 0 && countitem(Emperium) > 0) {
						mes "[Mysterious Blacksmith]";
						mes "Well done, adventurer.";
						mes "All seems to be in readiness.";
						mes "Give me a minute to summon";
						mes "the dark power to forge the";
						mes "forbidden sword, Mysteltainn.";
						next;
						mes "[Mysterious Blacksmith]";
						mes "I... I never thought";
						mes "I would ever see this";
						mes "sword again. Take it,";
						mes "quickly! I d-don't want";
						mes "to touch it if I can avoid it.";
						delitem Young_Twig,1;
						delitem Lokis_Whispers,1;
						delitem Mothers_Nightmare,1;
						delitem Foolishness_Of_Blind,1;
						delitem Emperium,1;
						getitem Mysteltainn_,1;
						next;
						mes "[Mysterious Blacksmith]";
						mes "Be very careful.";
						mes "Don't let yourself";
						mes "be consumed by the";
						mes "power of that sword!";
						mes "By all means, resist";
						mes "Mysteltainn's tragic curse!";
						close;
					}
				}
				else if (dmdswrd_Q2 & 1) {
					mes "[Mysterious Blacksmith]";
					mes "You want...";
					mes "that sword?";
					mes "Don't speak its";
					mes "name so lightly!";
					next;
					mes "[Mysterious Blacksmith]";
					mes "Do you understand the curse";
					mes "on that sword? The Mysteltainn";
					mes "derives its dark power from the";
					mes "twig that was used to kill Baldur, god of light. Let me relate the";
					mes "story as briefly as I can...";
					next;
					mes "[Mysterious Blacksmith]";
					mes "In the era of the gods,";
					mes "the beautiful, pure and";
					mes "joyful Baldur was loved by";
					mes "all living creatures, save for";
					mes "one: Loki, the god of trickery.";
					next;
					mes "[Mysterious Blacksmith]";
					mes "When Loki, out of jealousy,";
					mes "decided to kill Baldur, the";
					mes "goddess Freyja had a dream";
					mes "about Baldur's death. Fearing";
					mes "the realization of her dream,";
					mes "she counseled with the gods.";
					next;
					mes "[Mysterious Blacksmith]";
					mes "To protect Baldur, the gods";
					mes "decided to extract an oath";
					mes "to never harm Baldur from";
					mes "every creature, object and";
					mes "natural force. All who were";
					mes "asked agreed to make this oath.";
					next;
					mes "[Mysterious Blacksmith]";
					mes "Of all the beings and objects";
					mes "in the universe, Freya only";
					mes "neglected to ask one tree to";
					mes "make this oath: the Mysteltainn. Freyja believed it was far too";
					mes "small and insignificant to ask.";
					next;
					mes "[Mysterious Blacksmith]";
					mes "Believing that everything";
					mes "in the universe had sworn";
					mes "not to harm Baldur, the gods";
					mes "made it their new pastime to";
					mes "throw daggers and knives at";
					mes "the now nigh invincible god.";
					next;
					mes "[Mysterious Blacksmith]";
					mes "However, Loki was determined";
					mes "to kill Baldur and, disguising";
					mes "himself, politely asked Freyja";
					mes "if there was any object in the";
					mes "world that did not take the";
					mes "oath to not harm Baldur.";
					next;
					mes "[Mysterious Blacksmith]";
					mes "Freyja suspected nothing and";
					mes "told Loki about the secret of";
					mes "Mysteltainn. The next time the gods played their game of throwing";
					mes "objects at Baldur, Loki was there with a small Mysteltainn twig.";
					next;
					mes "[Mysterious Blacksmith]";
					mes "Then, to compound his";
					mes "treachery, Loki tricked";
					mes "Hod, Baldur's blind twin";
					mes "brother, into throwing the";
					mes "twig into Baldur's heart. And";
					mes "so, the god of light was slain.";
					next;
					mes "[Mysterious Blacksmith]";
					mes "Over the years,";
					mes "Mysteltainn has been";
					mes "fashioned into the sword";
					mes "that you may be familiar";
					mes "with today. Its power is";
					mes "strictly forbidden by the gods.";
					next;
					mes "[Mysterious Blacksmith]";
					mes "However, if you're willing";
					mes "to risk that sword's curse";
					mes "for the sake of its power,";
					mes "I will forge it for you if you";
					mes "can bring me the following";
					mes "items. They'll make sense...";
					next;
					mes "[Mysterious Blacksmith]";
					mes "^0099FF1 Young Twig^000000,";
					mes "^0099FF1 Emperium^000000,";
					mes "^0099FF1 Loki's Whispers^000000,";
					mes "^0099FF1 Mother's Nightmare^000000 and";
					mes "^0099FF1 Foolishness of the Blind^000000.";
					mes "That is what I need.";
					next;
					mes "[Mysterious Blacksmith]";
					mes "I'm not asking for much.";
					mes "You are only bringing the raw";
					mes "materials to forge the sword,";
					mes "and an Emperium to prove your";
					mes "worthiness to me. I will wait";
					mes "for your return, adventurer.";
					dmdswrd_Q2 |= 8;
					close;
				}
				mes "[Mysterious Blacksmith]";
				mes "Hm. If you truly want";
				mes "Mysteltainn, I advise you";
				mes "to learn more about it. You";
				mes "must know the risks involved";
				mes "in wielding that sort of power... ";
				close;
			case 2:
				if (dmdswrd_Q2 & 16) {
					mes "[Mysterious Blacksmith]";
					mes "You want to me";
					mes "to forge Grimtooth.";
					mes "First, let me check";
					mes "if you brought all";
					mes "the items I require.";
					next;
					if (countitem(Ogre_Tooth) < 100) {
						mes "[Mysterious Blacksmith]";
						mes "Hm. I still need";
						mes "^0099FF100 Ogre Teeth^000000 to";
						mes "create a blade that can";
						mes "withstand the might of the";
						mes "Grimtooth's curse magic.";
						mes "Go and bring them soon.";
						close;
					}
					if (countitem(Cardinal_Jewel_) < 5) {
						mes "[Mysterious Blacksmith]";
						mes "In order to place";
						mes "the curse that grants";
						mes "the Grimtooth its immense";
						mes "power, I need you to bring";
						mes "^0099FF5 Cursed Rubies^000000. Hurry";
						mes "and bring them to me soon.";
						close;
					}
					if (countitem(Blade_Lost_In_Darkness) < 10) {
						mes "[Mysterious Blacksmith]";
						mes "Hm. I still need";
						mes "^0099FF10 Blades of Darkness^000000";
						mes "in order to for me to forge";
						mes "the Grimtooth. Bring those";
						mes "here as soon as you can.";
						close;
					}
					if (countitem(Old_Hilt) < 1) {
						mes "[Mysterious Blacksmith]";
						mes "Hm. You almost have";
						mes "everything ready, but";
						mes "I'll need ^0099FF1 Broken Sword";
						mes "Handle^000000 in order to forge";
						mes "the Grimtooth. Hurry and";
						mes "bring me one of those...";
						close;
					}
					if (countitem(Emperium) < 1) {
						mes "[Mysterious Blacksmith]";
						mes "You have everything I need";
						mes "to create the sword, but I won't forge it until you prove that you";
						mes "are capable of controlling its";
						mes "power. Bring me 1 Emperium";
						mes "as proof of your worthiness.";
						close;
					}
					if (countitem(Ogre_Tooth) > 99 && countitem(Cardinal_Jewel_) > 4 && countitem(Blade_Lost_In_Darkness) > 9 && countitem(Old_Hilt) > 0 && countitem(Emperium) > 0) {
						mes "[Mysterious Blacksmith]";
						mes "I see that you have";
						mes "come fully prepared.";
						mes "Perhaps you have grave";
						mes "need of Grimtooth's power.";
						mes "Give me a moment as I forge";
						mes "this accursed sword for you...";
						next;
						mes "[Mysterious Blacksmith]";
						mes "There, it's finished!";
						mes "Now hurry and take it!";
						mes "I, I don't want to handle";
						mes "the Grimtooth longer than";
						mes "I have to! You'll understand";
						mes "soon enough once you use it...";
						delitem Ogre_Tooth,100;
						delitem Cardinal_Jewel_,5;
						delitem Blade_Lost_In_Darkness,10;
						delitem Old_Hilt,1;
						delitem Emperium,1;
						getitem Grimtooth_,1;
						next;
						mes "[Mysterious Blacksmith]";
						mes "I know that you might";
						mes "have good intentions for";
						mes "Grimtooth's power, but do";
						mes "not overestimate yourself!";
						mes "Always be wary of Grimtooth,";
						mes "and don't let it eat your soul!";
						close;
					}
				}
				else if (dmdswrd_Q2 & 2) {
					mes "[Mysterious Blacksmith]";
					mes "Ah, yes. You must be";
					mes "wondering how such a small";
					mes "dagger can contain such power.";
					mes "It's simple. I cast forbidden";
					mes "curse magic to inbue the dagger with its awesome destructiveness.";
					next;
					mes "[Mysterious Blacksmith]";
					mes "The curse I cast is so";
					mes "powerful that if I use it on";
					mes "a metal dagger, it would";
					mes "immediately melt down. Ogre";
					mes "tooth is the only material that";
					mes "can withstand the curse magic.";
					next;
					mes "[Mysterious Blacksmith]";
					mes "Of course, it's only";
					mes "fair to warn you that";
					mes "the power of the curse";
					mes "is such that the more you";
					mes "use the Grimtooth, the more it burns away at your very soul...";
					next;
					mes "[Mysterious Blacksmith]";
					mes "I am willing to forge";
					mes "the Grimtooth if you can";
					mes "prove worthy to wield its";
					mes "power and provide all of the";
					mes "materials I need to create it.";
					next;
					mes "[Mysterious Blacksmith]";
					mes "I will need...";
					mes "^0099FF1 Emperium^000000,";
					mes "^0099FF100 Ogre Teeth^000000,";
					mes "^0099FF10 Blades of Darkness^000000,";
					mes "^0099FF5 Cursed Rubies^000000 and";
					mes "^0099FF1 Broken Sword Handle^000000.";
					next;
					mes "[Mysterious Blacksmith]";
					mes "I don't need the";
					mes "Emperium to create";
					mes "the accursed sword, but I do";
					mes "require you to prove that you";
					mes "are worthy of the Grimtooth's";
					mes "power. Can you truly handle it?";
					dmdswrd_Q2 |= 16;
					close;
				}
				mes "[Mysterious Blacksmith]";
				mes "Hm. I can't even consider";
				mes "forging Grimtooth for you";
				mes "when you know so very little";
				mes "about it. You better learn more";
				mes "about that sword before you";
				mes "ask me about it again.";
				close;
			case 3:
				if (dmdswrd_Q2 & 32) {
					mes "[Mysterious Blacksmith]";
					mes "The Executioner sword.";
					mes "Let me see if you've come";
					mes "prepared to wield that blade";
					mes "with your own two hands...";
					next;
					if (countitem(Executioners_Mitten) < 2) {
						mes "[Mysterious Blacksmith]";
						mes "Hm. In order for me";
						mes "to forge the Executioner,";
						mes "I need you to bring me";
						mes "^0099FF2 Executioner's Gloves^000000.";
						close;
					}
					if (countitem(Bloody_Edge) < 10) {
						mes "[Mysterious Blacksmith]";
						mes "In order to craft the";
						mes "blade, I need at least";
						mes "^0099FF10 Bloody Edges^000000. Find";
						mes "those as quickly as you";
						mes "can and bring them to me.";
						close;
					}
					if (countitem(Frozen_Heart) < 3) {
						mes "[Mysterious Blacksmith]";
						mes "In order to enchant";
						mes "the Executioner with";
						mes "its dark power, I will";
						mes "need you to bring me";
						mes "^0099FF3 Necklaces of Oblivion^000000.";
						mes "Go, hurry and get them!";
						close;
					}
					if (countitem(Amulet) < 50) {
						mes "[Mysterious Blacksmith]";
						mes "Hm. You've forgotten to";
						mes "bring me ^0099FF50 Amulets^000000. I need";
						mes "those in order to imbue the";
						mes "incredible energies that";
						mes "give the Executioner its";
						mes "monstrous strength...";
						close;
					}
					if (countitem(Emperium) < 1) {
						mes "[Mysterious Blacksmith]";
						mes "You have everything I need";
						mes "to forge the Executioner, but";
						mes "I'm still unsure of whether you";
						mes "are capable of handling its";
						mes "power. My fears will be allayed";
						mes "if you bring ^0099FF1 Emperium^000000.";
						close;
					}
					if (countitem(Executioners_Mitten) > 1 && countitem(Bloody_Edge) > 9 && countitem(Frozen_Heart) > 2 && countitem(Amulet) > 49 && countitem(Emperium) > 0) {
						mes "[Mysterious Blacksmith]";
						mes "Great, I see that you've";
						mes "prepared everything that";
						mes "I asked. Give me a moment";
						mes "while I summon the dark";
						mes "forces required to forge";
						mes "the Executioner...";
						next;
						mes "[Mysterious Blacksmith]";
						mes "It's been a long time";
						mes "since I've seen this";
						mes "terrifying sword. Now";
						mes "take it! Be wary, and don't";
						mes "let its bloodlust consume you!";
						delitem Executioners_Mitten,2;
						delitem Bloody_Edge,10;
						delitem Frozen_Heart,3;
						delitem Amulet,50;
						getitem Executioner_,1;
						close;
					}
				}
				else if (dmdswrd_Q2 & 4) {
					mes "[Mysterious Blacksmith]";
					mes "So you're telling me that";
					mes "you want a sword that's been";
					mes "cursed by all the souls that've";
					mes "died from the thousands of death sentences it has carried out?";
					mes "Ha ha ha! Very interesting!";
					next;
					mes "[Mysterious Blacksmith]";
					mes "Yes... Each time this";
					mes "sword cut down a guilty";
					mes "criminal, the blade was";
					mes "cursed by the rage and";
					mes "regret of the slain.";
					next;
					mes "[Mysterious Blacksmith]";
					mes "Over time, the Executioner";
					mes "accumulated a truly dreadful";
					mes "power from the hatred of those";
					mes "it had killed. However, he who";
					mes "uses this sword risks becoming consumed by insanity and hatred.";
					next;
					mes "[Mysterious Blacksmith]";
					mes "The last person for whom";
					mes "I created this sword asked";
					mes "me to destroy it, fearing that";
					mes "it would corrupt his mind with";
					mes "its bloodlust. But if you think you can endure, I may forge it...";
					next;
					mes "[Mysterious Blacksmith]";
					mes "Just bring me...";
					mes "^0099FF50 Amulets^000000,";
					mes "^0099FF1 Emperium^000000,";
					mes "^0099FF2 Executioner's Gloves^000000,";
					mes "^0099FF10 Bloody Edges^000000 and";
					mes "^0099FF3 Necklaces of Oblivion^000000.";
					next;
					mes "[Mysterious Blacksmith]";
					mes "Those are the items I need";
					mes "to create a sword imbued with";
					mes "evil power. As for the Emperium, consider it my test to see if you";
					mes "are truly capable of wielding";
					mes "the accursed Executioner...";
					dmdswrd_Q2 |= 4;
					close;
				}
				mes "[Mysterious Blacksmith]";
				mes "Hmpf. I don't think";
				mes "you understand enough";
				mes "about the Executioner to";
				mes "ask me to forge it. You better";
				mes "learn more about that accursed";
				mes "sword if you really want it...";
				close;
			case 4:
				mes "[Mysterious Blacksmith]";
				mes "Hmm...?";
				mes "That a fact?";
				close;
			}
		case 3:
			mes "[Mysterious Blacksmith]";
			mes "Hmpf...";
			mes "Well then, come";
			mes "back when you know";
			mes "exactly what you want";
			mes "from me, adventurer.";
			close;
		}
	}
}
