Quest Winds of Fate: A Promise (10752).

Contributed by gigilo1968.
This commit is contained in:
MobiusDev
2016-05-02 10:05:03 +00:00
parent 1b52ef2637
commit 58b9307692
88 changed files with 1341 additions and 39 deletions

View File

@ -0,0 +1,4 @@
<html><body>Kain Van Halter:<br>
You're Ertheia. Child of the wind. Why would you try to kill Giselle all the way out here?<br>
<Button ALIGN=LEFT ICON="Normal" action="bypass -h Quest FortressOfTheDeadInstance 33979-02.html">"I didn't know that it was Giselle. She attacked first!"</button>
</body></html>

View File

@ -0,0 +1,5 @@
<html><body>Kain Van Halter:<br>
That's not a good reason. The fact that you came all the way here alone is suspicious.<br>
You were after Giselle's life in the first place!<br>
<Button ALIGN=LEFT ICON="Normal" action="bypass -h Quest FortressOfTheDeadInstance 33979-03.html">"I have Queen Navari's Mark."</button>
</body></html>

View File

@ -0,0 +1,6 @@
<html><body>Kain Van Halter:<br>
The Queen of Ertheia sent you?<br>
All right, then. Since Giselle became very aggressive after becoming a vampire, I will take your word on your dispute.<br>
But what brings you all the way here? Why were you looking for Giselle? I can't imagine Ertheia having business with her.<br>
<Button ALIGN=LEFT ICON="Normal" action="bypass -h Quest FortressOfTheDeadInstance 33979-04.html">"I was looking for you."</button>
</body></html>

View File

@ -0,0 +1,5 @@
<html><body>Kain Van Halter:<br>
Me?<br>
What do you want with a wanderer like me? And I don't see why I should even help you. You tried to harm my sister! Good thing I stopped by to check on her.<br>
<Button ALIGN=LEFT ICON="Normal" action="bypass -h Quest FortressOfTheDeadInstance 33979-05.html">"It's about the Prophecy Machine."</button>
</body></html>

View File

@ -0,0 +1,4 @@
<html><body>Kain Van Halter:<br>
Prophecy Machine?<br>What about the Prophecy Machine?<br>
<Button ALIGN=LEFT ICON="Normal" action="bypass -h Quest FortressOfTheDeadInstance 33979-06.html">"Here, take a look."</button>
</body></html>

View File

@ -0,0 +1,7 @@
<html><body>Kain Van Halter:<br>
<center><font color="LEVEL">A red river flows...hard frost upon the earth...<br1>
One of half-noble blood,<br1>descending with the winds to deliver from...<br1>
When joined by one...<br1>The path will open to the Grail.</font></center><br1>
So why are you showing me this?<br>
<Button ALIGN=LEFT ICON="Normal" action="bypass -h Quest FortressOfTheDeadInstance 33979-07.html">"I know that you're interested in the Grail."</button>
</body></html>

View File

@ -0,0 +1,4 @@
<html><body>Kain Van Halter:<br>
I see. Did Karla tell you? So she still remembers me mentioning the Grail that day.<br>
Check this out first.<br><Button ALIGN=LEFT ICON="Normal" action="bypass -h Quest FortressOfTheDeadInstance 33979-08.html">"This?"</button>
</body></html>

View File

@ -0,0 +1,6 @@
<html><body>Kain Van Halter:<br>
Surprised? I found it while passing Goddard Territory.<br>
This looks similar to the Prophecy Machine that you showed me. It's probably a part of the whole.<br>
And about what's written on your machine... I think I know what it's saying.<br>
<Button ALIGN=LEFT ICON="Normal" action="bypass -h Quest FortressOfTheDeadInstance 33979-09.html">"Do tell."</button>
</body></html>

View File

@ -0,0 +1,6 @@
<html><body>Kain Van Halter:<br>
<font color="LEVEL">A red river flows...Hm. I think I can see where this is going.</font><br>
It's talking about this continent. A red river flows...hard frost upon the earth. You see, <font color="LEVEL">Elmore</font> rules over a cold part of the land, which it once shared with Aden as Elmoreden. Now the whole continent is swarming with Shilen's bloody works.<br>
But this part is surprising. When joined by one...the path will open to the Grail. Truly?<br>
<Button ALIGN=LEFT ICON="Normal" action="bypass -h Quest FortressOfTheDeadInstance 33979-10.html">"Who is this one?"</button>
</body></html>

View File

@ -0,0 +1,7 @@
<html><body>Kain Van Halter:<br>
<font color="LEVEL">One of half-noble blood...</font><br>
Ha! Even the prophecy of Ertheia describes me so, huh? Well, it's right. My mother was a commoner. A tragic farce, to be loved by the king! So here I am, a prince only in name. And descending with the winds to deliver from...yes, that is me. I happened to save Faeron once. <font color="LEVEL">Kain</font> is your man!<br>
The <font color="LEVEL">Grail</font>...if it's the same <font color="LEVEL">Grail</font>, then...anyway, you can read the rest of the prophecy with the fragment that I found, right?<br>
Take it. Your village needs it more than I.<br>Hmm? Wait...<br>
<Button ALIGN=LEFT ICON="Normal" action="bypass -h Quest FortressOfTheDeadInstance 33979-11.html">"What?"</button>
</body></html>

View File

@ -0,0 +1,3 @@
<html><body>Kain Van Halter:<br>
Who is that person standing there?
</body></html>

View File

@ -0,0 +1,5 @@
<html><body>Kain Van Halter:<br>
You trespass on the land of death. Who are you?<br1>
No matter. You threatened Giselle with harm, and you will answer to me!<br>
<Button ALIGN=LEFT ICON="QUEST" action="bypass -h Quest FortressOfTheDeadInstance">Quest</button>
</body></html>

View File

@ -0,0 +1,4 @@
<html><body>Mysterious Wizard:<br>
I was just worried about you.<br>I guess I was worried that a small Ertheia was led by the souls of the dead to somewhere. <br>
But it seems I picked the wrong time.<br><Button ALIGN=LEFT ICON="Normal" action="bypass -h Quest FortressOfTheDeadInstance exit_instance">"What do you mean?"</button>
</body></html>

View File

@ -0,0 +1,5 @@
<html><body>Mysterious Wizard:<br>
It seems nothing happened.<br>
Did you find the person you were looking for?<br>
<Button ALIGN=LEFT ICON="Normal" action="bypass -h Quest FortressOfTheDeadInstance">Why did you come here?"</button>
</body></html>

View File

@ -0,0 +1,232 @@
/*
* This file is part of the L2J Mobius project.
*
* This program 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/>.
*/
package instances.FortressOfTheDeadInstance;
import com.l2jmobius.gameserver.instancemanager.InstanceManager;
import com.l2jmobius.gameserver.model.Location;
import com.l2jmobius.gameserver.model.actor.L2Npc;
import com.l2jmobius.gameserver.model.actor.instance.L2PcInstance;
import com.l2jmobius.gameserver.model.instancezone.InstanceWorld;
import com.l2jmobius.gameserver.model.quest.QuestState;
import com.l2jmobius.gameserver.network.NpcStringId;
import com.l2jmobius.gameserver.network.serverpackets.ExQuestNpcLogList;
import com.l2jmobius.gameserver.network.serverpackets.ExShowScreenMessage;
import instances.AbstractInstance;
import quests.Q10752_WindsOfFateAPromise.Q10752_WindsOfFateAPromise;
/**
* Fortress of The Dead Instance Zone.
* @author Gigi
*/
public final class FortressOfTheDeadInstance extends AbstractInstance
{
// NPCs
private static final int KAIN_VAN_HALTER = 33979;
private static final int MYSTERIOUS_WIZARD_2 = 33980;
// Monsters
private static final int VON_HELLMANN = 19566;
private static final int VAMPIRIC_SOLDIER = 19567;
// Locations
private static final Location START_LOC = new Location(57972, -28955, 568);
private static final Location EXIT_LOC = new Location(52084, -51317, -3096);
// Misc
private static final int TEMPLATE_ID = 254;
private static final int KAINS_PROPHECY_MACHINE_FRAGMENT = 39538;
private static final int VAMPIRIC_SOLDIER_KILL = 4;
private static final int VON_HELLMANN_KILL = 1;
class FTODWorld extends InstanceWorld
{
}
public FortressOfTheDeadInstance()
{
super(FortressOfTheDeadInstance.class.getSimpleName());
addTalkId(KAIN_VAN_HALTER, MYSTERIOUS_WIZARD_2);
addFirstTalkId(KAIN_VAN_HALTER, MYSTERIOUS_WIZARD_2);
addKillId(VAMPIRIC_SOLDIER, VON_HELLMANN);
}
@Override
public String onAdvEvent(String event, L2Npc npc, L2PcInstance player)
{
final QuestState qs = player.getQuestState(Q10752_WindsOfFateAPromise.class.getSimpleName());
final InstanceWorld tmpworld = InstanceManager.getInstance().getPlayerWorld(player);
if (qs == null)
{
return null;
}
String htmltext = null;
switch (event)
{
case "33979-02.html":
case "33979-03.html":
case "33979-04.html":
case "33979-05.html":
case "33979-06.html":
case "33979-07.html":
case "33979-08.html":
case "33979-09.html":
case "33979-10.html":
{
htmltext = event;
break;
}
case "33979-11.html":
{
if (tmpworld instanceof FTODWorld)
{
final FTODWorld world = (FTODWorld) tmpworld;
showOnScreenMsg(player, NpcStringId.TALK_TO_THE_MYSTERIOUS_WIZARD, ExShowScreenMessage.TOP_CENTER, 10000);
L2Npc wizard = addSpawn(MYSTERIOUS_WIZARD_2, npc.getX() + getRandom(-50, 50), npc.getY() + getRandom(-50, 50), npc.getZ(), npc.getHeading(), true, 60000, false, world.getInstanceId());
wizard.setTitle(player.getName());
wizard.setIsRunning(false);
wizard.broadcastInfo();
npc.deleteMe();
}
htmltext = event;
break;
}
case "exit_instance":
{
npc.deleteMe();
player.showQuestMovie(111);
giveItems(player, KAINS_PROPHECY_MACHINE_FRAGMENT, 1);
qs.setCond(9, true);
startQuestTimer("TELEPORT", 27000, npc, player);
break;
}
case "enter_instance":
{
enterInstance(player, new FTODWorld(), "FortressOfTheDead.xml", TEMPLATE_ID);
qs.set(Integer.toString(VAMPIRIC_SOLDIER), 0);
break;
}
case "SPAWN_HELLMANN":
{
if (tmpworld instanceof FTODWorld)
{
final FTODWorld world = (FTODWorld) tmpworld;
L2Npc hellmann = addSpawn(VON_HELLMANN, 57963, -28676, 568, 49980, false, 300000, false, world.getInstanceId());
addAttackDesire(hellmann, player);
}
break;
}
case "SPAWN_KAIN_VAN_HALTER":
{
if (tmpworld instanceof FTODWorld)
{
final FTODWorld world = (FTODWorld) tmpworld;
addSpawn(KAIN_VAN_HALTER, 57963, -28676, 568, 49980, false, 300000, false, world.getInstanceId());
}
break;
}
case "TELEPORT":
{
tmpworld.removeAllowed(player.getObjectId());
teleportPlayer(player, EXIT_LOC, 0);
break;
}
}
return htmltext;
}
@Override
public final String onTalk(L2Npc npc, L2PcInstance player)
{
String htmltext = getNoQuestMsg(player);
switch (npc.getId())
{
case KAIN_VAN_HALTER:
{
htmltext = "33979-01.html";
break;
}
case MYSTERIOUS_WIZARD_2:
{
htmltext = "33980-01.html";
break;
}
}
return htmltext;
}
@Override
public String onFirstTalk(L2Npc npc, L2PcInstance player)
{
return npc.getId() + ".htm";
}
@Override
public String onKill(L2Npc npc, L2PcInstance player, boolean isSummon)
{
final QuestState qs = player.getQuestState(Q10752_WindsOfFateAPromise.class.getSimpleName());
if ((qs != null) && (qs.isCond(8)))
{
switch (npc.getId())
{
case VAMPIRIC_SOLDIER:
{
int kills = qs.getInt(Integer.toString(VAMPIRIC_SOLDIER));
if (kills < VAMPIRIC_SOLDIER_KILL)
{
kills++;
qs.set(Integer.toString(VAMPIRIC_SOLDIER), kills);
}
break;
}
case VON_HELLMANN:
{
int kills = qs.getInt(Integer.toString(VON_HELLMANN));
if (kills < VON_HELLMANN_KILL)
{
kills++;
qs.set(Integer.toString(VON_HELLMANN), kills);
}
break;
}
}
final ExQuestNpcLogList log = new ExQuestNpcLogList(getId());
log.addNpc(VAMPIRIC_SOLDIER, qs.getInt(Integer.toString(VAMPIRIC_SOLDIER)));
log.addNpc(VON_HELLMANN, qs.getInt(Integer.toString(VON_HELLMANN)));
if (qs.getInt(Integer.toString(VAMPIRIC_SOLDIER)) >= VAMPIRIC_SOLDIER_KILL)
{
qs.unset(Integer.toString(VAMPIRIC_SOLDIER));
startQuestTimer("SPAWN_HELLMANN", 8000, npc, player);
}
if (qs.getInt(Integer.toString(VON_HELLMANN)) >= VON_HELLMANN_KILL)
{
npc.deleteMe();
qs.unset(Integer.toString(VON_HELLMANN));
player.showQuestMovie(110);
startQuestTimer("SPAWN_KAIN_VAN_HALTER", 5000, npc, player);
}
}
return super.onKill(npc, player, isSummon);
}
@Override
public void onEnterInstance(L2PcInstance player, InstanceWorld world, boolean firstEntrance)
{
if (firstEntrance)
{
world.addAllowed(player.getObjectId());
}
teleportPlayer(player, START_LOC, world.getInstanceId());
}
}

View File

@ -33,6 +33,7 @@ import instances.ElcadiasTent.ElcadiasTent;
import instances.FaeronTrainingGrounds1.FaeronTrainingGrounds1;
import instances.FaeronTrainingGrounds2.FaeronTrainingGrounds2;
import instances.FinalEmperialTomb.FinalEmperialTomb;
import instances.FortressOfTheDeadInstance.FortressOfTheDeadInstance;
import instances.HarnakUndergroundRuins.HarnakUndergroundRuins;
import instances.HideoutOfTheDawn.HideoutOfTheDawn;
import instances.IceQueensCastle.IceQueensCastle;
@ -76,6 +77,7 @@ final class InstanceLoader
FaeronTrainingGrounds1.class,
FaeronTrainingGrounds2.class,
FinalEmperialTomb.class,
FortressOfTheDeadInstance.class,
HarnakUndergroundRuins.class,
HideoutOfTheDawn.class,
ChamberOfDelusionEast.class,