This commit is contained in:
4
trunk/dist/game/data/scripts/quests/Q00608_SlayTheEnemyCommanderKetra/31370-01.htm
vendored
Normal file
4
trunk/dist/game/data/scripts/quests/Q00608_SlayTheEnemyCommanderKetra/31370-01.htm
vendored
Normal file
@@ -0,0 +1,4 @@
|
||||
<html><body>Kadun Zu Ketra:<br>
|
||||
The time has come for our revenge! Let's slay the commander of the enemy forces and put an end to our long war with the Varka! Will you join our cause?<br>
|
||||
<a action="bypass -h Quest Q00608_SlayTheEnemyCommanderKetra 31370-04.htm">"I'll do it."</a>
|
||||
</body></html>
|
||||
4
trunk/dist/game/data/scripts/quests/Q00608_SlayTheEnemyCommanderKetra/31370-02.htm
vendored
Normal file
4
trunk/dist/game/data/scripts/quests/Q00608_SlayTheEnemyCommanderKetra/31370-02.htm
vendored
Normal file
@@ -0,0 +1,4 @@
|
||||
<html><body>Kadun Zu Ketra:<br>
|
||||
You're not up to this mission. If we're to achieve victory, we must be patient. A good general waits patiently for the right time to strike!<br>
|
||||
(Only a character who possesses Ketra's friend - 4th level can undertake this quest.)
|
||||
</body></html>
|
||||
4
trunk/dist/game/data/scripts/quests/Q00608_SlayTheEnemyCommanderKetra/31370-03.htm
vendored
Normal file
4
trunk/dist/game/data/scripts/quests/Q00608_SlayTheEnemyCommanderKetra/31370-03.htm
vendored
Normal file
@@ -0,0 +1,4 @@
|
||||
<html><body>Kadun Zu Ketra:<br>
|
||||
You're not ready for this mission yet. Practice!<br>
|
||||
(Only a character of level 75 or above may undertake this quest.)
|
||||
</body></html>
|
||||
4
trunk/dist/game/data/scripts/quests/Q00608_SlayTheEnemyCommanderKetra/31370-04.htm
vendored
Normal file
4
trunk/dist/game/data/scripts/quests/Q00608_SlayTheEnemyCommanderKetra/31370-04.htm
vendored
Normal file
@@ -0,0 +1,4 @@
|
||||
<html><body>Kadun Zu Ketra:<br>
|
||||
Excellent! This mission is critical to the war effort. I need you to go to the garrison of the Varka Silenos and kill their commander! He's known as Mos, and he's the best swordsman in the entire tribe! Although you're an excellent fighter, don't even think of taking him on alone! Gather your most reliable comrades together, and track down and kill Mos!<br>
|
||||
The glorious flames of Pa'agrio will light your path forever!
|
||||
</body></html>
|
||||
4
trunk/dist/game/data/scripts/quests/Q00608_SlayTheEnemyCommanderKetra/31370-05.html
vendored
Normal file
4
trunk/dist/game/data/scripts/quests/Q00608_SlayTheEnemyCommanderKetra/31370-05.html
vendored
Normal file
@@ -0,0 +1,4 @@
|
||||
<html><body>Kadun Zu Ketra:<br>
|
||||
Have you brought the head of the commander of the Varka Silenos?<br>
|
||||
<a action="bypass -h Quest Q00608_SlayTheEnemyCommanderKetra 31370-07.html">"Here's the Head of Mos."</a>
|
||||
</body></html>
|
||||
3
trunk/dist/game/data/scripts/quests/Q00608_SlayTheEnemyCommanderKetra/31370-06.html
vendored
Normal file
3
trunk/dist/game/data/scripts/quests/Q00608_SlayTheEnemyCommanderKetra/31370-06.html
vendored
Normal file
@@ -0,0 +1,3 @@
|
||||
<html><body>Kadun Zu Ketra:<br>
|
||||
Arise, Orcs! The time has come! Kill Mos, the Varka commander, cut off his head and bring it to me!
|
||||
</body></html>
|
||||
3
trunk/dist/game/data/scripts/quests/Q00608_SlayTheEnemyCommanderKetra/31370-07.html
vendored
Normal file
3
trunk/dist/game/data/scripts/quests/Q00608_SlayTheEnemyCommanderKetra/31370-07.html
vendored
Normal file
@@ -0,0 +1,3 @@
|
||||
<html><body>Kadun Zu Ketra:<br>
|
||||
Ha! Excellent! This is outstanding! Our war with the Varka Silenos has entered its final stage! The loss of their commander means that they can no longer resist our powerful forces! Good job! Please accept this totem of strategy as an acknowledgement of your service to the Ketra Orcs!
|
||||
</body></html>
|
||||
@@ -0,0 +1,127 @@
|
||||
/*
|
||||
* Copyright (C) 2004-2014 L2J DataPack
|
||||
*
|
||||
* This file is part of L2J DataPack.
|
||||
*
|
||||
* L2J DataPack 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.
|
||||
*
|
||||
* L2J DataPack 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 quests.Q00608_SlayTheEnemyCommanderKetra;
|
||||
|
||||
import com.l2jserver.gameserver.model.actor.L2Npc;
|
||||
import com.l2jserver.gameserver.model.actor.instance.L2PcInstance;
|
||||
import com.l2jserver.gameserver.model.quest.Quest;
|
||||
import com.l2jserver.gameserver.model.quest.QuestState;
|
||||
import com.l2jserver.gameserver.model.quest.State;
|
||||
import com.l2jserver.gameserver.util.Util;
|
||||
|
||||
/**
|
||||
* Slay the Enemy Commander! (Ketra) (608)
|
||||
* @author malyelfik
|
||||
*/
|
||||
public class Q00608_SlayTheEnemyCommanderKetra extends Quest
|
||||
{
|
||||
// NPC
|
||||
private static final int KADUN = 31370;
|
||||
// Monster
|
||||
private static final int MOS = 25312;
|
||||
// Items
|
||||
private static final int MOS_HEAD = 7236;
|
||||
private static final int WISDOM_TOTEM = 7220;
|
||||
private static final int KETRA_ALLIANCE_FOUR = 7214;
|
||||
// Misc
|
||||
private static final int MIN_LEVEL = 75;
|
||||
|
||||
public Q00608_SlayTheEnemyCommanderKetra()
|
||||
{
|
||||
super(608, Q00608_SlayTheEnemyCommanderKetra.class.getSimpleName(), "Slay the Enemy Commander! (Ketra)");
|
||||
addStartNpc(KADUN);
|
||||
addTalkId(KADUN);
|
||||
addKillId(MOS);
|
||||
registerQuestItems(MOS_HEAD);
|
||||
}
|
||||
|
||||
@Override
|
||||
public void actionForEachPlayer(L2PcInstance player, L2Npc npc, boolean isSummon)
|
||||
{
|
||||
final QuestState st = getQuestState(player, false);
|
||||
if ((st != null) && st.isCond(1) && Util.checkIfInRange(1500, npc, player, false))
|
||||
{
|
||||
st.giveItems(MOS_HEAD, 1);
|
||||
st.setCond(2, true);
|
||||
}
|
||||
}
|
||||
|
||||
@Override
|
||||
public String onAdvEvent(String event, L2Npc npc, L2PcInstance player)
|
||||
{
|
||||
final QuestState st = getQuestState(player, false);
|
||||
if (st == null)
|
||||
{
|
||||
return null;
|
||||
}
|
||||
|
||||
String htmltext = event;
|
||||
switch (event)
|
||||
{
|
||||
case "31370-04.htm":
|
||||
st.startQuest();
|
||||
break;
|
||||
case "31370-07.html":
|
||||
if (st.hasQuestItems(MOS_HEAD) && st.isCond(2))
|
||||
{
|
||||
st.giveItems(WISDOM_TOTEM, 1);
|
||||
st.addExpAndSp(10000, 0);
|
||||
st.exitQuest(true, true);
|
||||
}
|
||||
else
|
||||
{
|
||||
htmltext = getNoQuestMsg(player);
|
||||
}
|
||||
break;
|
||||
default:
|
||||
htmltext = null;
|
||||
break;
|
||||
}
|
||||
return htmltext;
|
||||
}
|
||||
|
||||
@Override
|
||||
public String onKill(L2Npc npc, L2PcInstance killer, boolean isSummon)
|
||||
{
|
||||
executeForEachPlayer(killer, npc, isSummon, true, false);
|
||||
return super.onKill(npc, killer, isSummon);
|
||||
}
|
||||
|
||||
@Override
|
||||
public String onTalk(L2Npc npc, L2PcInstance player)
|
||||
{
|
||||
String htmltext = getNoQuestMsg(player);
|
||||
final QuestState st = getQuestState(player, true);
|
||||
if (st == null)
|
||||
{
|
||||
return htmltext;
|
||||
}
|
||||
|
||||
switch (st.getState())
|
||||
{
|
||||
case State.CREATED:
|
||||
htmltext = (player.getLevel() >= MIN_LEVEL) ? (st.hasQuestItems(KETRA_ALLIANCE_FOUR)) ? "31370-01.htm" : "31370-02.htm" : "31370-03.htm";
|
||||
break;
|
||||
case State.STARTED:
|
||||
htmltext = (st.isCond(2) && st.hasQuestItems(MOS_HEAD)) ? "31370-05.html" : "31370-06.html";
|
||||
break;
|
||||
}
|
||||
return htmltext;
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user