Addition of quest Protect At All Costs (10952).
Contributed by Elison.
This commit is contained in:
parent
4787447ab5
commit
29dd142760
@ -1,7 +1,5 @@
|
||||
<html><body>Newbie Guide:<br>
|
||||
Do you want to become stronger? Then listen to me carefully! I will give you a few pieces of advice.<br>
|
||||
<Button ALIGN=LEFT ICON="NORMAL" action="bypass -h Quest NewbieGuide 1">Ask for an advice</Button>
|
||||
<Button ALIGN=LEFT ICON="NORMAL" action="bypass -h Quest NpcLocationInfo">NPC Location Information.</Button>
|
||||
<Button ALIGN=LEFT ICON="NORMAL" action="bypass -h Link default/SupportMagic.htm">Receive help from beneficial magic.</Button>
|
||||
My name is Tanai. I am the keeper of our ancestors' legacy.<br>
|
||||
Do you want to become stronger? Then listen carefully! I will tell you everything you need to know.<br>
|
||||
<Button ALIGN=LEFT ICON="QUEST" action="bypass -h Quest">Quest</Button>
|
||||
</body></html>
|
@ -0,0 +1,8 @@
|
||||
<html><body>Guardian Tanai:<br>
|
||||
I am called the Guardian. Do you want to know what my duties are?<br>
|
||||
I preserve our ancestors' souls.<br>
|
||||
I must not let anyone disturb their burial places in the Valley of Heroes.<br>
|
||||
Also, I am to tell young Orcs what they must do to protect our legacy.<br>
|
||||
You should know that lately monsters in the Valley of Heroes have been digging our ancestors' graves, and it worries me greatly.<br>
|
||||
<Button ALIGN=LEFT ICON="Normal" action="bypass -h Quest Q10952_ProtectAtAllCosts 30602-02.htm">"It seems they must be killed."</Button>
|
||||
</body></html>
|
@ -0,0 +1,5 @@
|
||||
<html><body>Guardian Tanai:<br>
|
||||
Yes, these monsters must be killed, that is for certain.<br>
|
||||
However, my mission is not only to preserve our ancestors' graves, but also to guide young Orcs.<br>
|
||||
So I can't leave this place for too long and go monster hunting myself.<br>
|
||||
<Button ALIGN=LEFT ICON="NORMAL" action="bypass -h Quest Q10952_ProtectAtAllCosts 30602-03.htm">"Can someone else kill them?"</Button></body></html>
|
@ -0,0 +1,5 @@
|
||||
<html><body>Guardian Tanai:<br>
|
||||
I like the way you're thinking.<br>
|
||||
Well, young Orc, why don't you help me kill these monsters?<br>
|
||||
And in return I will tell you about <font color="LEVEL">the auto-hunting</font>.<br>
|
||||
<Button ALIGN=LEFT ICON="NORMAL" action="bypass -h Quest Q10952_ProtectAtAllCosts 30602-04.htm">"Auto-hunting? What is it?"</Button></body></html>
|
@ -0,0 +1,9 @@
|
||||
<html><body>Guardian Tanai:<br>
|
||||
The auto-hunting mode lets you find suitable targets and attack them without taking a break.<br>
|
||||
Like this, you can hunt more efficiently.<br>
|
||||
You can set up a distance to your target, loot pickup options, the manner mode, and so on.<br>
|
||||
Just drag your basic attack or a selected skill on the shortcut panel and press the right mouse button to activate it.<br>
|
||||
And now I will teleport you to<font color="LEVEL">the Valley of Heroes</font>. Kill monsters there using the auto-hunting mode.<br>
|
||||
There you will encounter <font color="LEVEL">Kasha Wolves, Kasha Forest Wolves, Goblin Tomb Raiders and Rakeclaw Imp Hunters</font>. Return to me when you kill <font color="LEVEL">20 of them</font><br>
|
||||
<Button ALIGN=LEFT ICON="TELEPORT" action="bypass -h Quest Q10952_ProtectAtAllCosts TELEPORT_TO_VALLEY_OF_HEROES">.Teleport to the Valley of Heroes</Button>
|
||||
</body></html>
|
@ -0,0 +1,4 @@
|
||||
<html><body>Guardian Tanai:<br>
|
||||
Have you dealt with monsters that desecrate our ancestors' graves in the Valley of Heroes?<br>
|
||||
<Button ALIGN=LEFT ICON="NORMAL" action="bypass -h Quest Q10952_ProtectAtAllCosts 30602-00.htm">Nod</Button>
|
||||
</body></html>
|
@ -0,0 +1,180 @@
|
||||
/*
|
||||
* 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 quests.Q10952_ProtectAtAllCosts;
|
||||
|
||||
import java.util.HashSet;
|
||||
import java.util.Set;
|
||||
|
||||
import org.l2jmobius.gameserver.enums.QuestSound;
|
||||
import org.l2jmobius.gameserver.model.actor.Npc;
|
||||
import org.l2jmobius.gameserver.model.actor.Player;
|
||||
import org.l2jmobius.gameserver.model.holders.ItemHolder;
|
||||
import org.l2jmobius.gameserver.model.holders.NpcLogListHolder;
|
||||
import org.l2jmobius.gameserver.model.quest.Quest;
|
||||
import org.l2jmobius.gameserver.model.quest.QuestState;
|
||||
import org.l2jmobius.gameserver.network.NpcStringId;
|
||||
import org.l2jmobius.gameserver.network.serverpackets.ExShowScreenMessage;
|
||||
|
||||
/**
|
||||
* Protect At All Costs (10952)
|
||||
* @author Ayurechko
|
||||
* @Notee: Based on NA server on March, 31 2022
|
||||
*/
|
||||
public class Q10952_ProtectAtAllCosts extends Quest
|
||||
{
|
||||
// NPC
|
||||
private static final int TANAI = 30602;
|
||||
// Monsters
|
||||
private static final int KASHA_WOLF = 20475;
|
||||
private static final int KASHA_TIMBER_WOLF = 20477; // NOTE: Kasha Forest Wolf in old client
|
||||
private static final int GOBLIN_TOMB_RAIDER = 20319;
|
||||
private static final int RAKECLAW_IMP_HUNTER = 20312;
|
||||
// Items
|
||||
private static final ItemHolder SOE_TO_TANAI = new ItemHolder(97230, 1);
|
||||
private static final ItemHolder SOE_NOVICE = new ItemHolder(10650, 10);
|
||||
private static final ItemHolder RING_NOVICE = new ItemHolder(49041, 2);
|
||||
private static final ItemHolder EARRING_NOVICE = new ItemHolder(49040, 2);
|
||||
private static final ItemHolder NECKLACE_NOVICE = new ItemHolder(49039, 1);
|
||||
// Misc
|
||||
private static final int MIN_LEVEL = 2;
|
||||
private static final int MAX_LEVEL = 15;
|
||||
private static final String KILL_COUNT_VAR = "KillCount";
|
||||
|
||||
public Q10952_ProtectAtAllCosts()
|
||||
{
|
||||
super(10952);
|
||||
addStartNpc(TANAI);
|
||||
addTalkId(TANAI);
|
||||
addKillId(KASHA_WOLF, KASHA_TIMBER_WOLF, GOBLIN_TOMB_RAIDER, RAKECLAW_IMP_HUNTER);
|
||||
addCondMinLevel(MIN_LEVEL, "no_lvl.htm");
|
||||
addCondMaxLevel(MAX_LEVEL, "no_lvl.htm");
|
||||
setQuestNameNpcStringId(NpcStringId.LV_2_15_PROTECT_AT_ALL_COSTS);
|
||||
}
|
||||
|
||||
@Override
|
||||
public String onAdvEvent(String event, Npc npc, Player player)
|
||||
{
|
||||
String htmltext = null;
|
||||
final QuestState qs = getQuestState(player, false);
|
||||
if (qs == null)
|
||||
{
|
||||
return htmltext;
|
||||
}
|
||||
|
||||
switch (event)
|
||||
{
|
||||
case "30602-01.htm":
|
||||
case "30602-02.htm":
|
||||
case "30602-03.htm":
|
||||
{
|
||||
htmltext = event;
|
||||
break;
|
||||
}
|
||||
case "30602-04.htm":
|
||||
{
|
||||
qs.startQuest();
|
||||
htmltext = event;
|
||||
break;
|
||||
}
|
||||
case "30602-00.htm":
|
||||
{
|
||||
if (qs.isStarted())
|
||||
{
|
||||
addExpAndSp(player, 260000, 6000);
|
||||
giveItems(player, SOE_NOVICE);
|
||||
giveItems(player, RING_NOVICE);
|
||||
giveItems(player, EARRING_NOVICE);
|
||||
giveItems(player, NECKLACE_NOVICE);
|
||||
qs.exitQuest(false, true);
|
||||
htmltext = event;
|
||||
break;
|
||||
}
|
||||
}
|
||||
case "TELEPORT_TO_VALLEY_OF_HEROES":
|
||||
{
|
||||
player.teleToLocation(-40897, -119022, -1912);
|
||||
break;
|
||||
}
|
||||
}
|
||||
return htmltext;
|
||||
}
|
||||
|
||||
@Override
|
||||
public String onTalk(Npc npc, Player player)
|
||||
{
|
||||
final QuestState qs = getQuestState(player, true);
|
||||
String htmltext = getNoQuestMsg(player);
|
||||
if (qs.isCreated())
|
||||
{
|
||||
htmltext = "30602-01.htm";
|
||||
}
|
||||
else if (qs.isStarted())
|
||||
{
|
||||
if (qs.isCond(1))
|
||||
{
|
||||
htmltext = "30602-04.htm";
|
||||
}
|
||||
else if (qs.isCond(2))
|
||||
{
|
||||
htmltext = "30602-05.htm";
|
||||
}
|
||||
}
|
||||
else if (qs.isCompleted())
|
||||
{
|
||||
htmltext = getAlreadyCompletedMsg(player);
|
||||
}
|
||||
return htmltext;
|
||||
}
|
||||
|
||||
@Override
|
||||
public String onKill(Npc npc, Player killer, boolean isSummon)
|
||||
{
|
||||
final QuestState qs = getQuestState(killer, false);
|
||||
if ((qs != null) && qs.isCond(1))
|
||||
{
|
||||
final int killCount = qs.getInt(KILL_COUNT_VAR) + 1;
|
||||
if (killCount < 20)
|
||||
{
|
||||
qs.set(KILL_COUNT_VAR, killCount);
|
||||
playSound(killer, QuestSound.ITEMSOUND_QUEST_ITEMGET);
|
||||
sendNpcLogList(killer);
|
||||
|
||||
}
|
||||
else
|
||||
{
|
||||
qs.setCond(2, true);
|
||||
qs.unset(KILL_COUNT_VAR);
|
||||
giveItems(killer, SOE_TO_TANAI);
|
||||
showOnScreenMsg(killer, NpcStringId.THE_TRAINING_IN_OVER_USE_A_SCROLL_OF_ESCAPE_IN_YOUR_INVENTORY_TO_GO_BACK_TO_TANAI, ExShowScreenMessage.TOP_CENTER, 10000);
|
||||
}
|
||||
}
|
||||
return super.onKill(npc, killer, isSummon);
|
||||
}
|
||||
|
||||
@Override
|
||||
public Set<NpcLogListHolder> getNpcLogList(Player player)
|
||||
{
|
||||
final QuestState qs = getQuestState(player, false);
|
||||
if ((qs != null) && qs.isCond(1))
|
||||
{
|
||||
final Set<NpcLogListHolder> holder = new HashSet<>();
|
||||
holder.add(new NpcLogListHolder(NpcStringId.SUBJUGATION_IN_THE_VALLEY_OF_HEROES.getId(), true, qs.getInt(KILL_COUNT_VAR)));
|
||||
return holder;
|
||||
}
|
||||
return super.getNpcLogList(player);
|
||||
}
|
||||
}
|
@ -0,0 +1,3 @@
|
||||
<html><body>Guardian Tanai:<br>
|
||||
You do not meet the requirements of the quest (Quest is only available to 2-15 levels).
|
||||
</body></html>
|
@ -37,6 +37,7 @@ import quests.Q10300_ExploringTheCrumaTower.Q10300_ExploringTheCrumaTower;
|
||||
import quests.Q10301_NotSoSilentValley.Q10301_NotSoSilentValley;
|
||||
import quests.Q10673_SagaOfLegend.Q10673_SagaOfLegend;
|
||||
import quests.Q10951_NewFlameOfOrcs.Q10951_NewFlameOfOrcs;
|
||||
import quests.Q10952_ProtectAtAllCosts.Q10952_ProtectAtAllCosts;
|
||||
import quests.Q10954_SayhaChildren.Q10954_SayhaChildren;
|
||||
import quests.Q10955_NewLifeLessons.Q10955_NewLifeLessons;
|
||||
import quests.Q10956_WeSylphs.Q10956_WeSylphs;
|
||||
@ -89,6 +90,7 @@ public class QuestMasterHandler
|
||||
Q10300_ExploringTheCrumaTower.class,
|
||||
Q10301_NotSoSilentValley.class,
|
||||
Q10951_NewFlameOfOrcs.class,
|
||||
Q10952_ProtectAtAllCosts.class,
|
||||
Q10954_SayhaChildren.class,
|
||||
Q10955_NewLifeLessons.class,
|
||||
Q10956_WeSylphs.class,
|
||||
|
22
L2J_Mobius_Essence_6.2_Vanguard/dist/game/data/stats/items/97200-97299.xml
vendored
Normal file
22
L2J_Mobius_Essence_6.2_Vanguard/dist/game/data/stats/items/97200-97299.xml
vendored
Normal file
@ -0,0 +1,22 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<list xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="../../xsd/items.xsd">
|
||||
<item id="97230" name="Scroll of Escape: Guardian Tanai" additionalName="Sealed" type="EtcItem">
|
||||
<!-- Teleports to Captain Bathis in Giran Castle. -->
|
||||
<set name="icon" val="icon.etc_scroll_of_return_i04" />
|
||||
<set name="default_action" val="SKILL_REDUCE" />
|
||||
<set name="material" val="PAPER" />
|
||||
<set name="price" val="35000" />
|
||||
<set name="is_stackable" val="true" />
|
||||
<set name="is_oly_restricted" val="true" />
|
||||
<set name="handler" val="ItemSkills" />
|
||||
<set name="commissionItemType" val="SCROLL_OTHER" />
|
||||
<set name="is_tradable" val="false" />
|
||||
<set name="is_dropable" val="false" />
|
||||
<cond addName="1" msgId="113">
|
||||
<player flyMounted="false" />
|
||||
</cond>
|
||||
<skills>
|
||||
<skill id="40412" level="1" /> <!-- Scroll of Escape: Guardian Tanai -->
|
||||
</skills>
|
||||
</item>
|
||||
</list>
|
@ -61,9 +61,30 @@
|
||||
<operateType>A1</operateType>
|
||||
</skill>
|
||||
<skill id="40412" toLevel="1" name="Scroll of Escape: Guardian Tanai">
|
||||
<!-- AUTO GENERATED SKILL TODO: FIX IT -->
|
||||
<icon>icon.skill0000</icon>
|
||||
<!-- A magical scroll that relocates you to the Guardian Tanai in Orc Village. Cannot be exchanged, dropped, or sold. Can be stored in a private warehouse. -->
|
||||
<hitTime>500</hitTime>
|
||||
<isMagic>2</isMagic> <!-- Static Skill -->
|
||||
<itemConsumeCount>1</itemConsumeCount>
|
||||
<itemConsumeId>91651</itemConsumeId>
|
||||
<magicLevel>1</magicLevel>
|
||||
<operateType>A1</operateType>
|
||||
<magicCriticalRate>5</magicCriticalRate>
|
||||
<targetType>SELF</targetType>
|
||||
<affectScope>SINGLE</affectScope>
|
||||
<conditions>
|
||||
<condition name="OpAlignment">
|
||||
<affectType>CASTER</affectType>
|
||||
<alignment>LAWFUL</alignment>
|
||||
</condition>
|
||||
<condition name="OpCanEscape" />
|
||||
</conditions>
|
||||
<effects>
|
||||
<effect name="Teleport">
|
||||
<x>-45079</x>
|
||||
<y>-113511</y>
|
||||
<z>-208</z>
|
||||
</effect>
|
||||
</effects>
|
||||
</skill>
|
||||
<skill id="40413" toLevel="1" name="Scroll of Escape: Gantaki Zu Urutu">
|
||||
<!-- AUTO GENERATED SKILL TODO: FIX IT -->
|
||||
|
Loading…
Reference in New Issue
Block a user