//===== rAthena Script =======================================
//= God Items Quest
//===== Description: =========================================
//= [Official Conversion]
//= God Item Hervor Creation script (WoE TE)
//===== Changelogs: ==========================================
//= 1.0 First Version. [Capuche]
//============================================================

te_prtcas01,204,204,3	script	Blacksmith Kai#tegod01	4_M_RACHMAN2,{
	if (checkweight(1201,1) == 0) {
		mes "You have too many items to proceed with the quest.";
		mes "Please lighten your load and try again.";
		close;
	}

	.@guild_id = getcastledata("te_prtcas01",1);
	.@economy  = getcastledata("te_prtcas01",2);
	.@npc_name$ = "Kai";

	mes "["+ .@npc_name$ +"]";
	if (.@guild_id != getcharid(2)) {
		mes "You... don't look familiar to me... ?";
		mes "Are you going to threaten me?";
		mes "No, right?";
		next;
		mes "["+ .@npc_name$ +"]";
		mes "I have my reasons.";
		mes "Please, pretend not to see me.";
		close;
	}
	if (WoeTETimeStart(14400) == 1 || agitcheck3() == 1) {// cannot start the quest 4 hours before and during WOE TE
		mes "From now on, I'll stay here quietly and not interrupt anyone until the siege ends.";
		mes "Don't worry about me.";
		close;
	}
	if (is_guild_leader() == false) {
		mes "I feel so grateful all the time about you letting me stay here.";
		mes "It's nothing special... but if you want, I'll make you tools that could be of use.";
		next;
		mes "["+ .@npc_name$ +"]";
		mes "I mean if the guild master wants it.";
		mes "I'm also a master who pursues the ultimate way.";
		mes "I hope I can find that way here.";
		close;
	}
	if ($2012_tegod_gloria == 0) {// event status
		mes "Ah... Master.";
		mes "I feel so thankful all the time.";
		mes "Since I owe you big time, I'll help you with anything anytime.";
		next;
		switch( select( "Make Hervor.","Fuse materials.","Relax." ) ) {
		case 1:
			if (.@economy > 29) {
				if (countitem(6595) > 1 && countitem(6596) > 0 && countitem(6594) > 3 && countitem(6597) > 2 && countitem(6602) > 0 && countitem(6605) > 0 && countitem(6604) > 0 && countitem(2115) > 0) {
					mes "^ff0000Valkyrja's Shield is needed in the process of making Hervor.";
					mes "You should not possess any other items except for Valkyrja's Shields in order to proceed with the quest.^ff0000";
					next;
					mes "^ff0000Even if the refinement level and cards have been applied, the process requires any one of the Valkyrja's Shields you may have.";
					mes "Please try again after organizing your possessions.^000000";
					next;
					if (select( "Organize possessions.","Continue as it is." ) == 1) {
						mes "You've decided to keep Valkyrja's Shields only.";
						close;
					}
					mes "["+ .@npc_name$ +"]";
					mes "I see that you've developed the fortress as you promised.";
					mes "Moreover, you've found Velund's items...";
					next;
					mes "["+ .@npc_name$ +"]";
					mes "... so..let's get the work done.";
					mes "Before the girls find us...";
					next;
					mes "[" + strcharinfo(0) + "]";
					mes "The girls... ?";
					next;
					mes "["+ .@npc_name$ +"]";
					mes "... yeah, there were some girls..";
					mes "I had to run away because of them...";
					donpcevent "#tequest_master_prt01::OnCommandOn";
					mapannounce "te_prtcas01","A girl's voice: Hey, were you talking about us? It's "+ .@npc_name$ +", right? I can't believe you ran away to a place like this.",bc_map,"0x00FF00",FW_BOLD,20,0,40;
					next;
					mes "["+ .@npc_name$ +"]";
					mes "Oh, no... !";
					mes "They're here..!!";
					next;
					mes "[" + strcharinfo(0) + "]";
					mes "Leave it to me.";
					next;
					mes "^4d4dff!- Instruction -!";
					mes "Soon, 7 girls that are after "+ .@npc_name$ +" will try to invade the fortress.";
					mes "You have to protect "+ .@npc_name$ +" for 1 hour.^000000";
					next;
					mes "^4d4dff!- Instruction -!";
					mes "When the actual attack starts, the doorway of Emperium region will be blocked up for protection.^000000";
					close;
				}
				mes "["+ .@npc_name$ +"]";
				mes "Hervor is a shield named after Hervor the Valkyrie.";
				mes "I didn't know this fortress would have the items that used to belong to Velund, a husband of Hervor...";
				next;
				mes "["+ .@npc_name$ +"]";
				mes "If we use them, we could make Hervor.";
				mes "It's like a dream come true for me... my hands are shaking.";
				next;
				mes "["+ .@npc_name$ +"]";
				mes "However, it seems like we need more materials.";
				mes "Could you check again? I'll give you the list of what we need.";
				callsub S_Material, .@npc_name$,1,"since it is a crystal of Velund's love.";
			}
			mes "["+ .@npc_name$ +"]";
			mes "However, would it be okay if I said something?";
			mes "Hervor is one of the most powerful battlegears I make and you deserve to receive something like that from me...";
			next;
			mes "["+ .@npc_name$ +"]";
			mes "but I would like you to have the minimum qualification at least.";
			mes "Manage this fortress well and raise ^4d4dffits commerce level by 30 or more^000000.";
			next;
			mes "["+ .@npc_name$ +"]";
			mes "With great power comes great responsibility and duty.";
			mes "I would like you to master the basics first.";
			next;
			mes "["+ .@npc_name$ +"]";
			mes "I'll make you Hervor afterward.";
			mes "Let me give you the list of materials if you want.";
			callsub S_Material, .@npc_name$,0,"since it is a crystal of Velund's love.";
		case 2:
			callsub S_Fuse, .@npc_name$, "Hervor";
		case 3:
			mes "["+ .@npc_name$ +"]";
			mes "That is so nice of you to say that.";
			mes "By the way, I wonder how my younger brother Cano is doing?";
			next;
			mes "["+ .@npc_name$ +"]";
			mes "I'm sure he's doing fine just like I am.";
			mes "... I hope things stay as peaceful as they are now.";
			close;
		}
	}
	if ($2012_tegod_gloria == 1) {// event started
		mes "Did you hear the news?";
		mes "The girls are coming.";
		mes "The merciless girls!!!";
		next;
		mes "["+ .@npc_name$ +"]";
		mes "They'll get here any minute since they've declared war already.";
		mes "I'm sure they're coming to get Hervor.";
		next;
		mes "["+ .@npc_name$ +"]";
		mes "Stop them. Please!";
		next;
		switch( select( "Leave it to me.","What do you mean 'the girls?'" ) ) {
		case 1:
			mes "["+ .@npc_name$ +"]";
			mes "Thank you...";
			mes "I'm sorry that I'm causing you troubles, but my hands are tied.";
			next;
			mes "["+ .@npc_name$ +"]";
			mes "Please, stop them for me!";
			close;
		case 2:
			mes "["+ .@npc_name$ +"]";
			mes "... They are the girls who want to be Valkyries...";
			mes "and they always go around in groups of seven.";
			next;
			mes "["+ .@npc_name$ +"]";
			mes "What they want is a powerful battlegear...";
			mes "They always threatened my younger brother Cano and me.";
			next;
			mes "["+ .@npc_name$ +"]";
			mes "They were satisfied with basic weapons at first, but";
			mes "soon they started threatening us saying that they need something more powerful in order to become Valkyries.";
			next;
			mes "["+ .@npc_name$ +"]";
			mes "I couldn't stand it, so I ran away... but they're here...";
			mes "You have to be careful since they found out that materials for Hervor are here.";
			close;
		}
	}
	if ($2012_tegod_gloria == 2) {// after 10 minutes delay
		mes "Ah stop following me around!";
		mes "If you could just get rid of them... Hervor, that's right! I'll make you Hervor!";
		next;
		mes "["+ .@npc_name$ +"]";
		mes "When will they ever stop following me...";
		mes "Now I'm scared of girls in general... and I'm too scared to do anything...";
		next;
		mes "He's babbling now.";
		mes "Just wait and he'll calm down.";
		mes "You have to get rid of those girls first.";
		close;
	}
	if ($2012_tegod_gloria == 3) {// event failed
		mes "... Although I managed to escape from them again...";
		mes "it's hard.";
		mes "life is... just so hard.";
		next;
		mes "["+ .@npc_name$ +"]";
		mes "I'm so exhausted that I can't do anything.";
		mes "... I don't think I can do anything for a while, whether it's producing or smithing or whatever it is.";
		mes "I'm sorry. I'll take a break.";
		close;
	}
	if ($2012_tegod_gloria == 4) {
		mes "I can finally breathe now.";
		mes "I'll start making Hervor as promised.";
		next;
		switch( select( "Make Hervor.","Fuse materials.","Not now." ) ) {
		case 1:
			if (countitem(6595) > 1 && countitem(6596) > 0 && countitem(6594) > 3 && countitem(6597) > 2 && countitem(6602) > 0 && countitem(6605) > 0 && countitem(6604) > 0 && countitem(2115) > 0) {
				mes "^ff0000Valkyrja's Shield is needed in the process of making Hervor.";
				mes "You should not possess any other items except for Valkyrja's Shields in order to proceed with the quest.^ff0000";
				next;
				mes "^ff0000Even if the refinement level and cards have been applied, the process requires any one of the Valkyrja's Shields you may have.";
				mes "Please try again after organizing your possessions.^000000";
				next;
				if (select( "Organize possessions.","Continue as it is." ) == 1) {
					mes "You've decided to keep Valkyrja's Shields only.";
					close;
				}
				mes "["+ .@npc_name$ +"]";
				mes "Oh... thank you.";
				mes "I can't believe I'm finally touching these materials myself...";
				next;
				mes "["+ .@npc_name$ +"]";
				mes "Here it is.";
				mes "Wasn't it fast although we had to go through many steps?";
				mes "I was so overwhelmed that it felt as short as a moment.";
				next;
				mes "Hervor, a shield that Blacksmith Velund made for his wife Hervor, is finally made";
				mes "at the hands of "+ .@npc_name$ +".";
				delitem 6595,2;// Hammer_Of_Velund
				delitem 6596,1;// Anvil_Of_Velund
				delitem 6594,4;// Magic_Bronze_Bullion
				delitem 6597,3;// Bracelet_Of_Velund
				delitem 6602,1;// Secret_Of_Rune
				delitem 6605,1;// Muspellium
				delitem 6604,1;// Essence_Of_Rune
				delitem 2115,1;// Valkyrja's_Shield
				$2012_tegod_gloria = 5;
				getitem 2181,1;// Hervor
				announce "Velund's gift [ Hervor ] is introduced to this world by ["+ strcharinfo(0) +"] of ["+ getguildname(.@guild_id) +"] Guild.",bc_all,"0x70dbdb",FW_NORMAL,12;
				if (.@economy > 20)
					setcastledata "te_prtcas01",2,(.@economy-20);
				else
					setcastledata "te_prtcas01",2,1;// min is 1 for WOE TE
				next;
				mes "["+ .@npc_name$ +"]";
				mes "Whew.. I don't think I can work for a while.";
				mes "I'm all exhausted. Hahaha...";
				close;
			}
			mes "["+ .@npc_name$ +"]";
			mes "However, it seems like we need more materials.";
			mes "Could you check again? I'll give you the list of what we need.";
			callsub S_Material, .@npc_name$,1;
		case 2:
			callsub S_Fuse, .@npc_name$, "Hervor";
		case 3:
			mes "["+ .@npc_name$ +"]";
			mes "Now is actually the right time to make it.";
			mes "By the time next Emperium appears, there won't be any chances left.";
			next;
			mes "["+ .@npc_name$ +"]";
			mes "Also, keep in mind the fact that I can only do this once a week.";
			close;
		}
	}
	if ($2012_tegod_gloria == 5) {
		mes "I'm tired a little bit.";
		mes "I think I should rest for a few days.";
		mes "I may look just fine, but I was mentally very tired.";
		close;
	}
	mes "It's strange.";
	mes "I can't tell how I feel.";
	mes "Am I having some kind of a health problem?";
	mes "Is it something uncurable?";
	close;

S_Material:
	.@npc_name$ = getarg(0);
	next;
	mes "["+ .@npc_name$ +"]";
	mes "^4d4dff2 of Velund's Hammer";
	mes "1 Velund's Anvil";
	mes "4 Bronze bars with magical power";
	mes "3 of Velund's Bracelet";
	mes "1 Rune characters' Secret";
	mes "1 Valkyrja's Shield";
	mes "1 Muspellium and Essence of Rune, respectively^000000";
	next;
	mes "["+ .@npc_name$ +"]";
	mes "We need as many materials as these.";
	mes getarg(2,"");
	mes "By the way, Muspellium and Essence of Rune need to be made separately with additional materials.";
	next;
	mes "["+ .@npc_name$ +"]";
	mes "In order to make Muspellium, you need to ^4d4dffcombine 50 Eluniums and 50 Oridecons^000000.";
	mes "For Essence of Rune, you need to ^4d4dffcombine 200 Ancient Rough Runestones and 100 Mystic Rough Runestones^000000.";
	next;
	mes "["+ .@npc_name$ +"]";
	mes "I'll make Muspellium and Essence of Rune anytime upon your request,";
	mes "and of course, I'll make Jormungand as soon as we gather all the materials needed.";
	next;
	mes "["+ .@npc_name$ +"]";
	if (getarg(1))
		mes "What I'm doing is never enough compared to what you've done for me.";
	else {
		mes "However, you won't be able to find Velund's items.";
		mes "... but people say they definitely appear to those who truly want it. I wish you all the luck.";
	}
	close;

S_Fuse:
	.@npc_name$ = getarg(0);
	mes "["+ .@npc_name$ +"]";
	mes "Which material do you want to make?";
	next;
	switch( select( "Muspellium","Essence of Rune","Forget it." ) ) {
	case 1:
		mes "["+ .@npc_name$ +"]";
		if (countitem(985) > 49 && countitem(984) > 49) {
			mes "I'll make Muspellium with the materials you've prepared.";
			next;
			mes "["+ .@npc_name$ +"]";
			mes "It shouldn't take long.";
			mes "Here it is.";
			mes "It is an essential material for making Hervor and Jormungand.";
			delitem 985,50;// Elunium
			delitem 984,50;// Oridecon
			getitem 6605,1;// Muspellium
			close;
		}
		mes "In order to make Muspellium,";
		mes "^4d4dffyou need 50 Eluniums and 50 Oridecons.^000000";
		next;
		mes "["+ .@npc_name$ +"]";
		mes "We should have all the materials ready, right?";
		close;
	case 2:
		mes "["+ .@npc_name$ +"]";
		if (countitem(12735) > 199 && countitem(12736) > 99) {
			mes "I'll make Essence of Rune with the materials you've prepared.";
			next;
			mes "["+ .@npc_name$ +"]";
			mes "It shouldn't take long.";
			mes "Here it is.";
			mes "It is an essential material for making Hervor and Jormungand.";
			delitem 12735,200;// Runstone_Ancient
			delitem 12736,100;// Runstone_Mystic
			getitem 6604,1;// Essence_Of_Rune
			close;
		}
		mes "For Essence of Rune,";
		mes "^4d4dffyou need 200 Ancient Rough Runestones and 100 Mystic Rough Runestones.^000000";
		next;
		mes "["+ .@npc_name$ +"]";
		mes "Surely, it takes a lot...";
		close;
	case 3:
		mes "["+ .@npc_name$ +"]";
		mes "Tell me whenever you need it.";
		mes "I'm glad I can at least do this for you.";
		next;
		mes "["+ .@npc_name$ +"]";
		mes "Also, a place where you can find materials for "+ getarg(1) +"...";
		mes "this is like a dream place for me, too.";
		close;
	}

OnInit:
	if ($2012_tegod_gloria == 3 || agitcheck3())// 3 -> quest failed
		disablenpc();
	else
		enablenpc();
	end;
}

te_prtcas01,190,2,0	script	#tequest_master_prt01	CLEAR_NPC,{
	mes "password?";
	next;
	if ( callfunc( "F_GM_NPC", 1854,0, 0,9999 ) < 1 ) {
		mes "Go away";
		close;
	}
	.@map$ = "te_prtcas01";
	mes "Current Status: " + $2012_tegod_gloria;
	mes "0: Able to proceed with the quest";
	mes "1: Proceed with the quest. 10-minute wait";
	mes "2: Quest in progress";
	mes "3: Quest failed";
	mes "4: Able to produce items , 5: Items produced successfully.";
	next;
	mes "Princess Status: " + $@2012_tegirls_prt01;
	mes "Current Commerce Level of the Fortress:" + getcastledata(.@map$,2);
	next;
	switch( select( "Do not proceed","Initialization","Raise Commerce Level","Lower Commerce Level" ) ) {
	case 1:
		end;
	case 2:
		mes "Initialize";
		donpcevent "#tequest_master_prt01::OnReset";
		close;
	case 3:
		.@economy = getcastledata(.@map$,2) +30;
		.@economy = .@economy > 100 ? 100 : .@economy;
		setcastledata .@map$,2,.@economy;
		mes "Raise Commerce Level by 30";
		mes "Modified Commerce Level:" + .@economy;
		close;
	case 4:
		.@economy1 = getcastledata(.@map$,2);
		.@economy2 = .@economy1 > 30 ? (.@economy1 -30) : 1;
		if (.@economy1 > 30) {
			mes "Lower Commerce Level by 30";
			setcastledata .@map$,2,.@economy2;
		}
		else {
			mes "Commerce Level gets decreased to 0 since current level is lower than 30.";
			setcastledata .@map$,2,1;// min is 1 for WOE TE
		}
		mes "Modified Commerce Level:" + .@economy2;
		close;
	}

OnReset:// gm Initialization
	callsub S_EventReset;// kill some quests mobs and stop timer of others npcs
	callsub S_EventOff;// clear setnpcdisplay
	$2012_tegod_gloria = 0;
	$@2012_tegirls_prt01 = 0;
	.npc_name$ = "";
	enablenpc "prtg-1-22_prtg-1-31#te";
	enablenpc "Blacksmith Kai#tegod01";
	stopnpctimer;
	end;

OnCommandOn:
	$2012_tegod_gloria = 1;
	.npc_name$ = strnpcinfo(0);// for script readability
	initnpctimer;
	end;

OnTimer10000:
	announce "Girls' voices: Kai~ We already know where you are. It's over!",bc_all,"0xFF0000",FW_NORMAL,10;
	end;
OnTimer15000:
	announce "Girls' Voices: We'll wait just 10 minutes. If you don't show up in the meantime, we'll storm the fortress!",bc_all,"0xFF0000",FW_NORMAL,10;
	end;
OnTimer595000:
	mapannounce "te_prtcas01", "A girl's voice: Kai! How dare you ignore our warning! So, you have company there, huh? But how long do you think they'll stay with you?!",bc_map,"0x00ff00",FW_NORMAL,12;
	end;
OnTimer598000:
	mapannounce "te_prtcas01", "You are forced out of the fortress by unknown power.",bc_map,"0x00ff00",FW_NORMAL,12;
	end;

OnTimer600000:
	$2012_tegod_gloria = 2;
	mapwarp "te_prtcas01", "te_prt_gld",159,211;
	donpcevent "Aira#fake01_prt01::OnCommandOn";
	donpcevent "Kuluna#fake01_prt01::OnCommandOn";
	donpcevent "Mallina#fake01_prt01::OnCommandOn";
	donpcevent "Ezella#fake01_prt01::OnCommandOn";
	donpcevent "Lune#fake01_prt01::OnCommandOn";
	donpcevent "Morin#fake01_prt01::OnCommandOn";
	donpcevent "Nasarin#fake01_prt01::OnCommandOn";

	disablenpc "prtg-1-22_prtg-1-31#te";// warp to emperium room
	end;

OnTimer602000:
	announce "Gaebolg in Gloria region is being attacked by a group of unidentified beings.",bc_all,"0xFF0000",FW_NORMAL,10;
	monster "te_prtcas01",0,0,"Raydric",1163,15, .npc_name$ +"::OnMyMobDead";
	monster "te_prtcas01",0,0,"Khalitzburg",1132,10, .npc_name$ +"::OnMyMobDead";
	monster "te_prtcas01",0,0,"Abysmal Knight",1219,5, .npc_name$ +"::OnMyMobDead";

	monster "te_prtcas01",197,197,"Dalongee",1272,1, .npc_name$ +"::OnMyMobDead";// DARK_LORD
	monster "te_prtcas01",197,197,"Summoned Reindeer",1251,1, .npc_name$ +"::OnMyMobDead";// KNIGHT_OF_WINDSTORM
	monster "te_prtcas01",197,197,"Summoned Wolf",1252,1, .npc_name$ +"::OnMyMobDead";// GARM

	monster "te_prtcas01",40,26,"Dalongee",1272,1, .npc_name$ +"::OnMyMobDead";// DARK_LORD
	monster "te_prtcas01",80,33,"Summoned Reindeer",1251,1, .npc_name$ +"::OnMyMobDead";// KNIGHT_OF_WINDSTORM
	monster "te_prtcas01",151,96,"Summoned Wolf",1252,1, .npc_name$ +"::OnMyMobDead";// GARM
	end;

OnTimer610000:
	monster "te_prtcas01",0,0,"Raydric",1163,15, .npc_name$ +"::OnMyMobDead";
	monster "te_prtcas01",0,0,"Khalitzburg",1132,10, .npc_name$ +"::OnMyMobDead";
	monster "te_prtcas01",0,0,"Abysmal Knight",1219,5, .npc_name$ +"::OnMyMobDead";
	monster "te_prtcas01",0,0,"Bloody Knight",1268,5, .npc_name$ +"::OnMyMobDead";
	end;

OnTimer1000000:
OnTimer1300000:
OnTimer1900000:
OnTimer2500000:
OnTimer3100000:
	callsub S_MobRedondant;
	end;
S_MobRedondant:
	monster "te_prtcas01",0,0,"Raydric",1163,10, .npc_name$ +"::OnMyMobDead";
	monster "te_prtcas01",0,0,"Khalitzburg",1132,10, .npc_name$ +"::OnMyMobDead";
	monster "te_prtcas01",0,0,"Abysmal Knight",1219,10, .npc_name$ +"::OnMyMobDead";
	monster "te_prtcas01",0,0,"High Orc",1213,10, .npc_name$ +"::OnMyMobDead";
	monster "te_prtcas01",0,0,"Bloody Knight",1268,5, .npc_name$ +"::OnMyMobDead";
	end;

OnTimer4200000:
	mapannounce "te_prtcas01", "Girls: ... how long do we have to wait?",bc_map,"0x00ff00",FW_NORMAL,12;
	end;
OnTimer4205000:
	mapannounce "te_prtcas01", "Girls: Hervor should be made for us!",bc_map,"0x00ff00",FW_NORMAL,12;
	end;
OnTimer4210000:
	mapannounce "te_prtcas01", "Girls: Come on, cut if off! You guys are so persistent!!",bc_map,"0x00ff00",FW_NORMAL,12;
	end;
OnTimer4220000:
	mapannounce "te_prtcas01", "Aira: Ah! I can't take it anymore! Girls, come here!",bc_map,"0x00ff00",FW_NORMAL,12;

	$2012_tegod_gloria = 3;// quest off until someone break the emp
	callsub S_EventReset;
	enablenpc "prtg-1-22_prtg-1-31#te";
	end;

OnTimer4225000:
	donpcevent "#eproom_girls_prt01::OnReset";
	donpcevent "#end_aira_prt01::OnCommandOn";
	donpcevent "#end_kuluna_prt01::OnCommandOn";
	donpcevent "#end_mallina_prt01::OnCommandOn";
	donpcevent "#end_ezella_prt01::OnCommandOn";
	donpcevent "#end_lune_prt01::OnCommandOn";
	donpcevent "#end_morin_prt01::OnCommandOn";
	donpcevent "#end_nasarin_prt01::OnCommandOn";
	end;

OnTimer4227000:
	npctalk "Kai: Oh... no! What are you going to do to me?!", "Blacksmith Kai#tegod01";
	end;
OnTimer4230000:
	npctalk "Aira: Mm? Hey Kai. You're going home.", "#end_aira_prt01";
	end;
OnTimer4233000:
	npctalk "Kuluna: Yup~ You have to fix my broken wand and make powerful weapons for me once you get back!", "#end_kuluna_prt01";
	end;
OnTimer4236000:
	npctalk "Ezella: Try to run away again. You'll be sorry, understand?", "#end_ezella_prt01";
	end;
OnTimer4237000:
	npctalk "Nasarin: ... Just take him. Why are you guys talking to him so much?", "#end_nasarin_prt01";
	end;
OnTimer4240000:
	npctalk "Aira: You're right! Alright then!", "#end_aira_prt01";
	npctalk "Kai: Oh... No... Noooo!!!!!", "Blacksmith Kai#tegod01";
	end;

OnTimer4243000:
	mapannounce "te_prtcas01", "You've failed to recapture the fortress. Kai is now gone.",bc_map,"0x00ff00",FW_NORMAL,12;
	disablenpc "Blacksmith Kai#tegod01";
	callsub S_EventOff;// clear setnpcdisplay
	.npc_name$ = "";
	stopnpctimer;
	end;

S_EventOff:
	donpcevent "#end_aira_prt01::OnCommandOff";
	donpcevent "#end_kuluna_prt01::OnCommandOff";
	donpcevent "#end_mallina_prt01::OnCommandOff";
	donpcevent "#end_ezella_prt01::OnCommandOff";
	donpcevent "#end_lune_prt01::OnCommandOff";
	donpcevent "#end_morin_prt01::OnCommandOff";
	donpcevent "#end_nasarin_prt01::OnCommandOff";
	return;

OnStop:// all girls have been defeated, kill remaining mobs and stop timer
	callsub S_EventReset;
	$@2012_tegirls_prt01 = 0;
	.npc_name$ = "";
	stopnpctimer;
	end;

S_EventReset:
	killmonster "te_prtcas01", .npc_name$ +"::OnMyMobDead";
	donpcevent "#eproom_girls_prt01::OnReset";
	donpcevent "Aira#fake01_prt01::OnReset";
	donpcevent "Kuluna#fake01_prt01::OnReset";
	donpcevent "Mallina#fake01_prt01::OnReset";
	donpcevent "Ezella#fake01_prt01::OnReset";
	donpcevent "Lune#fake01_prt01::OnReset";
	donpcevent "Morin#fake01_prt01::OnReset";
	donpcevent "Nasarin#fake01_prt01::OnReset";

	donpcevent "#aira_real_prt01::OnReset";
	donpcevent "#kuluna_real_prt01::OnReset";
	donpcevent "#mallina_real_prt01::OnReset";
	donpcevent "#ezella_real_prt01::OnReset";
	donpcevent "#lune_real_prt01::OnReset";
	donpcevent "#morin_real_prt01::OnReset";
	donpcevent "#nasarin_real_prt01::OnReset";
	return;

OnMyMobDead:
	end;

OnInit:
	$@2012_tegirls_prt01 = 0;// girls mobs killed count
	if ($2012_tegod_gloria < 3)
		$2012_tegod_gloria = 0;
	end;
}


te_prtcas01,64,20,3	script	Aira#fake01_prt01	CLEAR_NPC,{
	end;
OnCommandOn:
	enablenpc "Aira#fake01_prt01";
	setnpcdisplay "Aira#fake01_prt01",2443;// AIRA
	initnpctimer;
	end;

OnMyMobDead:
	if (mobcount( "te_prtcas01","Aira#fake01_prt01::OnMyMobDead" )) end;
	donpcevent "#aira_real_prt01::OnCommandOn";
	npctalk "Aira: My summon water balls! I'll get you! With my own hands!!";
OnReset:
	stopnpctimer;
	killmonster "te_prtcas01", "Aira#fake01_prt01::OnMyMobDead";
	setnpcdisplay "Aira#fake01_prt01",CLEAR_NPC;
OnInit:
	disablenpc "Aira#fake01_prt01";
	end;

OnTimer1000:
	monster "te_prtcas01",65,28,"Bodyguard",1213,5, "Aira#fake01_prt01::OnMyMobDead";// HIGH_ORC
	monster "te_prtcas01",65,28,"Bodyguard",1309,5, "Aira#fake01_prt01::OnMyMobDead";// GAJOMART
	end;
OnTimer2000:
	monster "te_prtcas01",65,28,"Bodyguard",1367,5, "Aira#fake01_prt01::OnMyMobDead";// BLAZZER
	monster "te_prtcas01",65,10,"Bodyguard",1837,5, "Aira#fake01_prt01::OnMyMobDead";// IMP
	end;
OnTimer3000:
	monster "te_prtcas01",65,10,"Bodyguard",1949,1, "Aira#fake01_prt01::OnMyMobDead";// B_S_GUARDIAN
	monster "te_prtcas01",65,28,"Bodyguard",1833,2, "Aira#fake01_prt01::OnMyMobDead";// KASA
	monster "te_prtcas01",65,28,"Bodyguard",1831,2, "Aira#fake01_prt01::OnMyMobDead";// SALAMANDER
	stopnpctimer;
	end;
}

te_prtcas01,50,54,3	script	Kuluna#fake01_prt01	CLEAR_NPC,{
	end;
OnCommandOn:
	enablenpc "Kuluna#fake01_prt01";
	setnpcdisplay "Kuluna#fake01_prt01",2444;// KULUNA
	initnpctimer;
	end;

OnMyMobDead:
	if (mobcount( "te_prtcas01","Kuluna#fake01_prt01::OnMyMobDead" )) end;
	donpcevent "#kuluna_real_prt01::OnCommandOn";
	npctalk "Kuluna: Hmm? So you're going to be that way? You'd better be ready!";
OnReset:
	stopnpctimer;
	killmonster "te_prtcas01", "Kuluna#fake01_prt01::OnMyMobDead";
	setnpcdisplay "Kuluna#fake01_prt01",CLEAR_NPC;
OnInit:
	disablenpc "Kuluna#fake01_prt01";
	end;

OnTimer1000:
	monster "te_prtcas01",54,61,"Guardian",1143,10, "Kuluna#fake01_prt01::OnMyMobDead";// MARIONETTE
	end;
OnTimer2000:
	monster "te_prtcas01",54,61,"Guardian",1693,10, "Kuluna#fake01_prt01::OnMyMobDead";// PLASMA_Y
	end;
OnTimer3000:
	monster "te_prtcas01",54,61,"Guardian",1869,5, "Kuluna#fake01_prt01::OnMyMobDead";// FLAME_SKULL
	monster "te_prtcas01",54,61,"Guardian",1704,1, "Kuluna#fake01_prt01::OnMyMobDead";// THA_ODIUM
	monster "te_prtcas01",54,61,"Guardian",1705,1, "Kuluna#fake01_prt01::OnMyMobDead";// THA_DESPERO
	monster "te_prtcas01",54,61,"Guardian",1706,1, "Kuluna#fake01_prt01::OnMyMobDead";// THA_MAERO
	monster "te_prtcas01",54,61,"Guardian",1707,1, "Kuluna#fake01_prt01::OnMyMobDead";// THA_DOLOR
	stopnpctimer;
	end;
}

te_prtcas01,175,92,3	script	Mallina#fake01_prt01	CLEAR_NPC,{
	end;
OnCommandOn:
	enablenpc "Mallina#fake01_prt01";
	setnpcdisplay "Mallina#fake01_prt01",2445;// MALLINA
	initnpctimer;
	end;

OnMyMobDead:
	if (mobcount( "te_prtcas01","Mallina#fake01_prt01::OnMyMobDead" )) end;
	donpcevent "#mallina_real_prt01::OnCommandOn";
	npctalk "Mallina: Stop it!! Stop bothering me!!";
OnReset:
	stopnpctimer;
	killmonster "te_prtcas01", "Mallina#fake01_prt01::OnMyMobDead";
	setnpcdisplay "Mallina#fake01_prt01",CLEAR_NPC;
OnInit:
	disablenpc "Mallina#fake01_prt01";
	end;

OnTimer1000:
	monster "te_prtcas01",182,92,"The Absolute",1993,10, "Mallina#fake01_prt01::OnMyMobDead";// NAGA
	end;
OnTimer3000:
	monster "te_prtcas01",182,92,"The Absolute",1695,10, "Mallina#fake01_prt01::OnMyMobDead";// PLASMA_G
	end;
OnTimer5000:
	monster "te_prtcas01",182,92,"The Absolute",1717,5, "Mallina#fake01_prt01::OnMyMobDead";// FERUS_
	monster "te_prtcas01",182,92,"The Absolute",1991,2, "Mallina#fake01_prt01::OnMyMobDead";// TENDRILRION
	monster "te_prtcas01",182,92,"The Absolute",1989,2, "Mallina#fake01_prt01::OnMyMobDead";// HILLSRION
	stopnpctimer;
	end;
}

te_prtcas01,159,113,3	script	Ezella#fake01_prt01	CLEAR_NPC,{
	end;
OnCommandOn:
	enablenpc "Ezella#fake01_prt01";
	setnpcdisplay "Ezella#fake01_prt01",2446;// EZELLA
	initnpctimer;
	end;

OnMyMobDead:
	if (mobcount( "te_prtcas01","Ezella#fake01_prt01::OnMyMobDead" )) end;
	donpcevent "#ezella_real_prt01::OnCommandOn";
	npctalk "Ezella: Ahh... This only makes both of us more tired...";
OnReset:
	stopnpctimer;
	killmonster "te_prtcas01", "Ezella#fake01_prt01::OnMyMobDead";
	setnpcdisplay "Ezella#fake01_prt01",CLEAR_NPC;
OnInit:
	disablenpc "Ezella#fake01_prt01";
	end;

OnTimer1000:
	monster "te_prtcas01",161,111,"Convoy",1692,10, "Ezella#fake01_prt01::OnMyMobDead";// BREEZE
	end;
OnTimer2000:
	monster "te_prtcas01",161,111,"Convoy",1627,2, "Ezella#fake01_prt01::OnMyMobDead";// ANOPHELES
	monster "te_prtcas01",161,111,"Convoy",1656,2, "Ezella#fake01_prt01::OnMyMobDead";// KAVAC
	monster "te_prtcas01",161,111,"Convoy",1315,6, "Ezella#fake01_prt01::OnMyMobDead";// ASSULTER
	end;
OnTimer3000:
	monster "te_prtcas01",161,111,"Convoy",1669,5, "Ezella#fake01_prt01::OnMyMobDead";// DIMIK
	monster "te_prtcas01",161,111,"Convoy",1259,2, "Ezella#fake01_prt01::OnMyMobDead";// GRYPHON
	monster "te_prtcas01",161,111,"Convoy",1783,1, "Ezella#fake01_prt01::OnMyMobDead";// GALION
	monster "te_prtcas01",161,111,"Convoy",1950,1, "Ezella#fake01_prt01::OnMyMobDead";// B_B_GUARDIAN
	stopnpctimer;
	end;
}

te_prtcas01,152,102,3	script	Lune#fake01_prt01	CLEAR_NPC,{
	end;
OnCommandOn:
	enablenpc "Lune#fake01_prt01";
	setnpcdisplay "Lune#fake01_prt01",2447;// LUNE
	initnpctimer;
	end;

OnMyMobDead:
	if (mobcount( "te_prtcas01","Lune#fake01_prt01::OnMyMobDead" )) end;
	donpcevent "#lune_real_prt01::OnCommandOn";
	npctalk "Lune: ..you want to be drowned in the deep sea? Huh?";
OnReset:
	stopnpctimer;
	killmonster "te_prtcas01", "Lune#fake01_prt01::OnMyMobDead";
	setnpcdisplay "Lune#fake01_prt01",CLEAR_NPC;
OnInit:
	disablenpc "Lune#fake01_prt01";
	end;

OnTimer1000:
	monster "te_prtcas01",144,97,"Bodyguard",1778,1, "Lune#fake01_prt01::OnMyMobDead";// GAZETI
	monster "te_prtcas01",145,97,"Bodyguard",1778,1, "Lune#fake01_prt01::OnMyMobDead";
	monster "te_prtcas01",146,97,"Bodyguard",1778,1, "Lune#fake01_prt01::OnMyMobDead";
	monster "te_prtcas01",147,97,"Bodyguard",1778,1, "Lune#fake01_prt01::OnMyMobDead";
	monster "te_prtcas01",148,97,"Bodyguard",1778,1, "Lune#fake01_prt01::OnMyMobDead";
	monster "te_prtcas01",149,97,"Bodyguard",1778,1, "Lune#fake01_prt01::OnMyMobDead";
	monster "te_prtcas01",150,97,"Bodyguard",1778,1, "Lune#fake01_prt01::OnMyMobDead";
	monster "te_prtcas01",151,97,"Bodyguard",1778,1, "Lune#fake01_prt01::OnMyMobDead";
	monster "te_prtcas01",152,97,"Bodyguard",1778,1, "Lune#fake01_prt01::OnMyMobDead";
	monster "te_prtcas01",153,97,"Bodyguard",1778,1, "Lune#fake01_prt01::OnMyMobDead";
	end;

OnTimer2000:
	monster "te_prtcas01",155,97,"Bodyguard",2016,1, "Lune#fake01_prt01::OnMyMobDead";// AQUA_ELEMENTAL
	monster "te_prtcas01",155,96,"Bodyguard",2016,1, "Lune#fake01_prt01::OnMyMobDead";
	monster "te_prtcas01",155,95,"Bodyguard",2016,1, "Lune#fake01_prt01::OnMyMobDead";
	monster "te_prtcas01",155,94,"Bodyguard",2016,1, "Lune#fake01_prt01::OnMyMobDead";
	monster "te_prtcas01",155,93,"Bodyguard",2016,1, "Lune#fake01_prt01::OnMyMobDead";
	monster "te_prtcas01",155,92,"Bodyguard",2016,1, "Lune#fake01_prt01::OnMyMobDead";
	monster "te_prtcas01",155,91,"Bodyguard",2016,1, "Lune#fake01_prt01::OnMyMobDead";
	monster "te_prtcas01",155,90,"Bodyguard",2016,1, "Lune#fake01_prt01::OnMyMobDead";
	monster "te_prtcas01",155,89,"Bodyguard",2016,1, "Lune#fake01_prt01::OnMyMobDead";
	monster "te_prtcas01",155,87,"Bodyguard",2016,1, "Lune#fake01_prt01::OnMyMobDead";
	end;

OnTimer3000:
	monster "te_prtcas01",149,97,"Bodyguard",1777,5, "Lune#fake01_prt01::OnMyMobDead";// ICE_TITAN
	monster "te_prtcas01",149,97,"Bodyguard",1681,1, "Lune#fake01_prt01::OnMyMobDead";// GEMINI
	monster "te_prtcas01",149,97,"Bodyguard",2021,1, "Lune#fake01_prt01::OnMyMobDead";// PHYLLA
	monster "te_prtcas01",149,97,"Bodyguard",2020,2, "Lune#fake01_prt01::OnMyMobDead";// RHYNCHO
	stopnpctimer;
	end;
}

te_prtcas01,99,180,3	script	Morin#fake01_prt01	CLEAR_NPC,{
	end;
OnCommandOn:
	enablenpc "Morin#fake01_prt01";
	setnpcdisplay "Morin#fake01_prt01",2448;// MORIN
	initnpctimer;
	end;

OnMyMobDead:
	if (mobcount( "te_prtcas01","Morin#fake01_prt01::OnMyMobDead" )) end;
	donpcevent "#morin_real_prt01::OnCommandOn";
	npctalk "Morin: ... . ...";
OnReset:
	stopnpctimer;
	killmonster "te_prtcas01", "Morin#fake01_prt01::OnMyMobDead";
	setnpcdisplay "Morin#fake01_prt01",CLEAR_NPC;
OnInit:
	disablenpc "Morin#fake01_prt01";
	end;

OnTimer1000:
	monster "te_prtcas01",99,176,"Nightmare Gang",1379,10, "Morin#fake01_prt01::OnMyMobDead";// NIGHTMARE_TERROR
	end;
OnTimer2000:
	monster "te_prtcas01",99,176,"Nightmare Gang",1701,5, "Morin#fake01_prt01::OnMyMobDead";// SHELTER
	monster "te_prtcas01",99,176,"Nightmare Gang",1753,5, "Morin#fake01_prt01::OnMyMobDead";// FRUS
	end;
OnTimer3000:
	monster "te_prtcas01",99,176,"Nightmare Gang",1752,5, "Morin#fake01_prt01::OnMyMobDead";// SKOGUL
	monster "te_prtcas01",99,176,"Nightmare Gang",1733,1, "Morin#fake01_prt01::OnMyMobDead";// KIEL
	monster "te_prtcas01",99,176,"Nightmare Gang",1205,1, "Morin#fake01_prt01::OnMyMobDead";// EXECUTIONER
	monster "te_prtcas01",99,176,"Nightmare Gang",2040,1, "Morin#fake01_prt01::OnMyMobDead";// TIRFING_R
	monster "te_prtcas01",99,176,"Nightmare Gang",1203,1, "Morin#fake01_prt01::OnMyMobDead";// MYSTELTAINN
	stopnpctimer;
	end;
}

te_prtcas01,120,174,3	script	Nasarin#fake01_prt01	CLEAR_NPC,{
	end;
OnCommandOn:
	enablenpc "Nasarin#fake01_prt01";
	setnpcdisplay "Nasarin#fake01_prt01",2449;// NASARIN
	initnpctimer;
	end;

OnMyMobDead:
	if (mobcount( "te_prtcas01","Nasarin#fake01_prt01::OnMyMobDead" )) end;
	donpcevent "#nasarin_real_prt01::OnCommandOn";
	npctalk "Nasarin: ..Ahh.. It's so hard to become a Valkyrie!";
OnReset:
	stopnpctimer;
	killmonster "te_prtcas01", "Nasarin#fake01_prt01::OnMyMobDead";
	setnpcdisplay "Nasarin#fake01_prt01",CLEAR_NPC;
OnInit:
	disablenpc "Nasarin#fake01_prt01";
	end;

OnTimer1000:
	monster "te_prtcas01",125,170,"Gang of Poison",1987,10, "Nasarin#fake01_prt01::OnMyMobDead";// CENTIPEDE
	end;
OnTimer2000:
	monster "te_prtcas01",125,170,"Gang of Poison",2015,10, "Nasarin#fake01_prt01::OnMyMobDead";// PINGUICULA_D
	end;
OnTimer3000:
	monster "te_prtcas01",125,170,"Gang of Poison",1618,3, "Nasarin#fake01_prt01::OnMyMobDead";// UNGOLIANT
	monster "te_prtcas01",125,170,"Khalitz",1949,1, "Nasarin#fake01_prt01::OnMyMobDead";// B_S_GUARDIAN
	stopnpctimer;
	end;
}

-	script	real_prt01	-1,{
	end;
OnCommandOn:
	.@npc_name$ = strnpcinfo(0);
	if (.@npc_name$ == "#aira_real_prt01")
		monster "te_prtcas01",65,28,"Aira in a blaze",2443,1, .@npc_name$ +"::OnMyMobDead";
	else if (.@npc_name$ == "#kuluna_real_prt01")
		monster "te_prtcas01",54,61,"Passionate Kuluna",2444,1, .@npc_name$ +"::OnMyMobDead";
	else if (.@npc_name$ == "#mallina_real_prt01")
		monster "te_prtcas01",182,92,"Mallina of the Earth",2445,1, .@npc_name$ +"::OnMyMobDead";
	else if (.@npc_name$ == "#ezella_real_prt01")
		monster "te_prtcas01",161,111,"Ezella of Verdure",2446,1, .@npc_name$ +"::OnMyMobDead";
	else if (.@npc_name$ == "#lune_real_prt01")
		monster "te_prtcas01",149,97,"Lune of the Eternal Glacier",2447,1, .@npc_name$ +"::OnMyMobDead";
	else if (.@npc_name$ == "#morin_real_prt01")
		monster "te_prtcas01",99,176,"Morin of the Abyss",2448,1, .@npc_name$ +"::OnMyMobDead";
	else if (.@npc_name$ == "#nasarin_real_prt01")
		monster "te_prtcas01",125,170,"Fatal Nasarin",2449,1, .@npc_name$ +"::OnMyMobDead";
	end;

OnReset:
	stopnpctimer;
	killmonster "te_prtcas01", strnpcinfo(0) +"::OnMyMobDead";
	end;

OnMyMobDead:
	if (mobcount( "te_prtcas01",strnpcinfo(0) +"::OnMyMobDead" ) == 0)
		initnpctimer;
	end;

OnTimer1000:
	if (mobcount( "te_prtcas01",strnpcinfo(0) +"::OnMyMobDead" ) == 0) {
		$@2012_tegirls_prt01++;
		if ($@2012_tegirls_prt01 == 7) {
			mapannounce "te_prtcas01","Kai: aaahh!! The girls broke the shields and made their way into where Emperium is!!!!",bc_map,"0x00ff00",FW_NORMAL,12;
			donpcevent "#eproom_girls_prt01::OnCommandOn";
		}
		else {
			.@npc_name$ = strnpcinfo(0);
			if (.@npc_name$ == "#aira_real_prt01")
				mapannounce "te_prtcas01","Aira: You think I lost? You're wrong! We force our way to where Kai is!!",bc_map,"0x00ff00",FW_NORMAL,12;
			else if (.@npc_name$ == "#kuluna_real_prt01")
				mapannounce "te_prtcas01","Kuluna: ... This is called a strategic retreat.",bc_map,"0x00ff00",FW_NORMAL,12;
			else if (.@npc_name$ == "#mallina_real_prt01")
				mapannounce "te_prtcas01","Mallina: ... Why are you disturbing us so much? But victory will be ours in the end!!",bc_map,"0x00ff00",FW_NORMAL,12;
			else if (.@npc_name$ == "#ezella_real_prt01")
				mapannounce "te_prtcas01","Ezella: Oh you, a weakling that would just disappear like the wind... !!!",bc_map,"0x00ff00",FW_NORMAL,12;
			else if (.@npc_name$ == "#lune_real_prt01")
				mapannounce "te_prtcas01","Lune: ..Alright. Let the battle begin!",bc_map,"0x00ff00",FW_NORMAL,12;
			else if (.@npc_name$ == "#morin_real_prt01")
				mapannounce "te_prtcas01","Morin: It's not... interesting anymore.",bc_map,"0x00ff00",FW_NORMAL,12;
			else if (.@npc_name$ == "#nasarin_real_prt01")
				mapannounce "te_prtcas01","Nasarin: .. I wasted my time. Kai is in the center of this fortress?",bc_map,"0x00ff00",FW_NORMAL,12;
		}
	}
	stopnpctimer;
	end;
}
te_prtcas01,192,2,0	duplicate(real_prt01)	#aira_real_prt01	CLEAR_NPC
te_prtcas01,193,2,0	duplicate(real_prt01)	#kuluna_real_prt01	CLEAR_NPC
te_prtcas01,194,2,0	duplicate(real_prt01)	#mallina_real_prt01	CLEAR_NPC
te_prtcas01,194,2,0	duplicate(real_prt01)	#ezella_real_prt01	CLEAR_NPC
te_prtcas01,196,2,0	duplicate(real_prt01)	#lune_real_prt01	CLEAR_NPC
te_prtcas01,197,2,0	duplicate(real_prt01)	#morin_real_prt01	CLEAR_NPC
te_prtcas01,198,2,0	duplicate(real_prt01)	#nasarin_real_prt01	CLEAR_NPC


te_prtcas01,199,2,0	script	#eproom_girls_prt01	CLEAR_NPC,{
	end;
OnCommandOn:
	enablenpc "prtg-1-22_prtg-1-31#te";
	monster "te_prtcas01",184,188,"Fatal Nasarin",2449,1, "#eproom_girls_prt01::OnMyMobDead";
	monster "te_prtcas01",191,182,"Morin of the Abyss",2448,1, "#eproom_girls_prt01::OnMyMobDead";
	monster "te_prtcas01",183,183,"Lune of the Eternal Glacier",2447,1, "#eproom_girls_prt01::OnMyMobDead";
	monster "te_prtcas01",197,188,"Ezella of Verdure",2446,1, "#eproom_girls_prt01::OnMyMobDead";
	monster "te_prtcas01",202,190,"Mallina of the Earth",2445,1, "#eproom_girls_prt01::OnMyMobDead";
	monster "te_prtcas01",199,192,"Passionate Kuluna",2444,1, "#eproom_girls_prt01::OnMyMobDead";
	monster "te_prtcas01",200,195,"Aira in a blaze",2443,1, "#eproom_girls_prt01::OnMyMobDead";
	end;

OnReset:
	stopnpctimer;
	killmonster "te_prtcas01", "#eproom_girls_prt01::OnMyMobDead";
	end;

OnMyMobDead:
	if (mobcount( "te_prtcas01","#eproom_girls_prt01::OnMyMobDead" ) == 0)
		initnpctimer;
	end;

OnTimer3000:
	if (mobcount( "te_prtcas01","#eproom_girls_prt01::OnMyMobDead" ) == 0) {
		donpcevent "#tequest_master_prt01::OnStop";
		$2012_tegod_gloria = 4;
		mapannounce "te_prtcas01","You have defeated the girls and recaptured the fortress successfully.",bc_map,"0x00ff00",FW_NORMAL,12;
	}
	stopnpctimer;
	end;
}

te_prtcas01,203,204,5	script	#end_aira_prt01	CLEAR_NPC,{
	end;
OnCommandOn:
	.@npc_name$ = strnpcinfo(0);
	enablenpc .@npc_name$;
	if (compare(.@npc_name$,"aira")) setnpcdisplay .@npc_name$,2443;
	else if (compare(.@npc_name$,"kuluna")) setnpcdisplay .@npc_name$,2444;
	else if (compare(.@npc_name$,"mallina")) setnpcdisplay .@npc_name$,2445;
	else if (compare(.@npc_name$,"ezella")) setnpcdisplay .@npc_name$,2446;
	else if (compare(.@npc_name$,"lune")) setnpcdisplay .@npc_name$,2447;
	else if (compare(.@npc_name$,"morin")) setnpcdisplay .@npc_name$,2448;
	else if (compare(.@npc_name$,"nasarin")) setnpcdisplay .@npc_name$,2449;
	end;

OnCommandOff:
	setnpcdisplay strnpcinfo(0),CLEAR_NPC;
OnInit:
	disablenpc();
	end;
}
te_prtcas01,205,205,3	duplicate(#end_aira_prt01)	#end_kuluna_prt01	CLEAR_NPC
te_prtcas01,204,203,7	duplicate(#end_aira_prt01)	#end_mallina_prt01	CLEAR_NPC
te_prtcas01,203,205,5	duplicate(#end_aira_prt01)	#end_ezella_prt01	CLEAR_NPC
te_prtcas01,205,204,3	duplicate(#end_aira_prt01)	#end_lune_prt01	CLEAR_NPC
te_prtcas01,204,205,4	duplicate(#end_aira_prt01)	#end_morin_prt01	CLEAR_NPC
te_prtcas01,205,203,1	duplicate(#end_aira_prt01)	#end_nasarin_prt01	CLEAR_NPC
