Quest Duty of the Survivor (10490).
Contributed by Stayway.
This commit is contained in:
5
trunk/dist/game/data/scripts/quests/Q00490_DutyOfTheSurvivor/30137-01.htm
vendored
Normal file
5
trunk/dist/game/data/scripts/quests/Q00490_DutyOfTheSurvivor/30137-01.htm
vendored
Normal file
@ -0,0 +1,5 @@
|
||||
<html><body>Trader Vollodos:<br>
|
||||
Have you been to the Dark Elf Village?<br>
|
||||
Aha... I'm worried. Because of Shilen's resurrection, many of my brethren were killed and had no choice but to escape from the village. Also, the power of the epidemic came to cover the entire continent. Look! Don't you see the blackish red fog all over this area? At this rate, none of us will be safe.<br>
|
||||
<button align=LEFT icon=NORMAL action="bypass -h Quest Q00490_DutyOfTheSurvivor 30137-02.htm">Continue to listen</button>
|
||||
</body></html>
|
4
trunk/dist/game/data/scripts/quests/Q00490_DutyOfTheSurvivor/30137-02.htm
vendored
Normal file
4
trunk/dist/game/data/scripts/quests/Q00490_DutyOfTheSurvivor/30137-02.htm
vendored
Normal file
@ -0,0 +1,4 @@
|
||||
<html><body>Trader Vollodos:<br>The problem is that not everyone escaped to a safe place like Talking Island. Many people were unable to find a refuge. They got lost along the way, and they succumbed to the epidemic. Many people died like this in this area. The harm will only increase if we do nothing about it.<br>
|
||||
It is the duty of the living to help them. So, will you help me?<br>
|
||||
<button align=LEFT icon=NORMAL action="bypass -h Quest Q00490_DutyOfTheSurvivor 30137-03.htm">Listen to the story.</button>
|
||||
</body></html>
|
5
trunk/dist/game/data/scripts/quests/Q00490_DutyOfTheSurvivor/30137-03.htm
vendored
Normal file
5
trunk/dist/game/data/scripts/quests/Q00490_DutyOfTheSurvivor/30137-03.htm
vendored
Normal file
@ -0,0 +1,5 @@
|
||||
<html><body>Trader Vollodos:<br>
|
||||
I am actually working on an antidote for the epidemic along with several Dark Elves. But I'm not a scholar or a magician, so there aren't that many things I can do. All I can do is collect research ingredients from nearby monsters to help with the research.<br>
|
||||
But I'm not a warrior, so that's why I must ask adventurers like you for help.<br>
|
||||
<button align=LEFT icon=NORMAL action="bypass -h Quest Q00490_DutyOfTheSurvivor 30137-04.htm">Ask how you can help.</button>
|
||||
</body></html>
|
5
trunk/dist/game/data/scripts/quests/Q00490_DutyOfTheSurvivor/30137-04.htm
vendored
Normal file
5
trunk/dist/game/data/scripts/quests/Q00490_DutyOfTheSurvivor/30137-04.htm
vendored
Normal file
@ -0,0 +1,5 @@
|
||||
<html><body>Trader Vollodos:<br>
|
||||
Please collect the research ingredients from the monsters in the area. We need <font color="LEVEL">Putrefied Extract</font> from the <font color="LEVEL">Corpse Devourer, Corpse Absorber, Corpse Shredder, Plagueworm, Contaminated Rottenroot, and Decayed Spore</font>. We need <font color="LEVEL">Rotten Blood</font> from the <font color="LEVEL">Swamp Stalker, Swamp Assassin, Swamp Watcher, Corpse Collector, Delegate of Blood, and Blood Aide</font>. We need about <font color="LEVEL">20</font> each to continue the research.<br>
|
||||
Do you think you can handle it?<br>
|
||||
<button align=LEFT icon=NORMAL action="bypass -h Quest Q00490_DutyOfTheSurvivor 30137-05.htm">"I can do it on your own."</button>
|
||||
</body></html>
|
3
trunk/dist/game/data/scripts/quests/Q00490_DutyOfTheSurvivor/30137-05.htm
vendored
Normal file
3
trunk/dist/game/data/scripts/quests/Q00490_DutyOfTheSurvivor/30137-05.htm
vendored
Normal file
@ -0,0 +1,3 @@
|
||||
<html><body>Grocer Vollodos:<br>
|
||||
Ahh, thank goodness. Please bring me the research ingredients. If you do, I will certainly reward you for your trouble. Then, please be careful...
|
||||
</body></html>
|
5
trunk/dist/game/data/scripts/quests/Q00490_DutyOfTheSurvivor/30137-06.html
vendored
Normal file
5
trunk/dist/game/data/scripts/quests/Q00490_DutyOfTheSurvivor/30137-06.html
vendored
Normal file
@ -0,0 +1,5 @@
|
||||
<html><body>Grocer Vollodos:<br>
|
||||
Ahh. You collected all the research ingredients. Thank you! This will greatly help to advance my research.<br>
|
||||
I hope that no more people perish from this epidemic. We will do our best to successfully develop an antidote. Please continue to be careful as you travel in this area.<br>
|
||||
Oh! The antidote research will continue, so if you have time tomorrow, please stop by again.
|
||||
</body></html>
|
3
trunk/dist/game/data/scripts/quests/Q00490_DutyOfTheSurvivor/30137-07.html
vendored
Normal file
3
trunk/dist/game/data/scripts/quests/Q00490_DutyOfTheSurvivor/30137-07.html
vendored
Normal file
@ -0,0 +1,3 @@
|
||||
<html><body>Grocer Vollodos:<br>
|
||||
Please collect the research ingredients from the monsters in the area. We need <font color="LEVEL">Putrefied Extract</font> from the <font color="LEVEL">Corpse Devourer, Corpse Absorber, Corpse Shredder, Plagueworm, Contaminated Rottenroot, and Decayed Spore</font>... And <font color="LEVEL">Rotten Blood</font> from <font color="LEVEL">Swamp Tracker, Swamp Assassin, Swamp Watcher, Corpse Collector, Delegate of Blood, and Blood Aide</font>. We need about <font color="LEVEL">20</font> of each item to continue to the research.<br>Please bring me the ingredients. If you do, I will certainly reward you for your trouble. Then, please be careful...
|
||||
</body></html>
|
3
trunk/dist/game/data/scripts/quests/Q00490_DutyOfTheSurvivor/30137-08.html
vendored
Normal file
3
trunk/dist/game/data/scripts/quests/Q00490_DutyOfTheSurvivor/30137-08.html
vendored
Normal file
@ -0,0 +1,3 @@
|
||||
<html><body>Grocer Vollodos:<br>
|
||||
(You can do this quest once a day. It resets each day at 6.30am.)
|
||||
</body></html>
|
186
trunk/dist/game/data/scripts/quests/Q00490_DutyOfTheSurvivor/Q00490_DutyOfTheSurvivor.java
vendored
Normal file
186
trunk/dist/game/data/scripts/quests/Q00490_DutyOfTheSurvivor/Q00490_DutyOfTheSurvivor.java
vendored
Normal file
@ -0,0 +1,186 @@
|
||||
/*
|
||||
* 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.Q00490_DutyOfTheSurvivor;
|
||||
|
||||
import java.util.HashMap;
|
||||
import java.util.Map;
|
||||
|
||||
import com.l2jmobius.gameserver.enums.QuestType;
|
||||
import com.l2jmobius.gameserver.model.actor.L2Npc;
|
||||
import com.l2jmobius.gameserver.model.actor.instance.L2PcInstance;
|
||||
import com.l2jmobius.gameserver.model.holders.ItemChanceHolder;
|
||||
import com.l2jmobius.gameserver.model.quest.Quest;
|
||||
import com.l2jmobius.gameserver.model.quest.QuestState;
|
||||
import com.l2jmobius.gameserver.model.quest.State;
|
||||
|
||||
/**
|
||||
* Duty of the Survivor (10490)
|
||||
* @author Stayway
|
||||
*/
|
||||
public class Q00490_DutyOfTheSurvivor extends Quest
|
||||
{
|
||||
// NPC
|
||||
private static final int VOLLODOS = 30137;
|
||||
// Items
|
||||
private static final int PUTRIFIED_EXTRACT = 34059;
|
||||
private static final int ROTTEN_BLOOD = 34060;
|
||||
|
||||
private static final Map<Integer, ItemChanceHolder> MONSTERS = new HashMap<>();
|
||||
static
|
||||
{
|
||||
MONSTERS.put(23162, new ItemChanceHolder(PUTRIFIED_EXTRACT, 0.59, 1)); // Corpse Devourer
|
||||
MONSTERS.put(23163, new ItemChanceHolder(PUTRIFIED_EXTRACT, 0.59, 1)); // Corpse Absorber
|
||||
MONSTERS.put(23164, new ItemChanceHolder(PUTRIFIED_EXTRACT, 0.59, 1)); // Corpse Shredder
|
||||
MONSTERS.put(23165, new ItemChanceHolder(PUTRIFIED_EXTRACT, 0.70, 1)); // Plagueworm
|
||||
MONSTERS.put(23166, new ItemChanceHolder(PUTRIFIED_EXTRACT, 0.64, 1)); // Contaminated Rottenroot
|
||||
MONSTERS.put(23167, new ItemChanceHolder(PUTRIFIED_EXTRACT, 0.64, 1)); // Decayed Spore
|
||||
MONSTERS.put(23168, new ItemChanceHolder(ROTTEN_BLOOD, 0.70, 1)); // Swamp Tracker
|
||||
MONSTERS.put(23169, new ItemChanceHolder(ROTTEN_BLOOD, 0.70, 1)); // Swamp Assassin
|
||||
MONSTERS.put(23170, new ItemChanceHolder(ROTTEN_BLOOD, 0.70, 1)); // Swamp Watcher
|
||||
MONSTERS.put(23171, new ItemChanceHolder(ROTTEN_BLOOD, 0.54, 1)); // Corpse Collector
|
||||
MONSTERS.put(23172, new ItemChanceHolder(ROTTEN_BLOOD, 0.54, 1)); // Delegate of Blood
|
||||
MONSTERS.put(23173, new ItemChanceHolder(ROTTEN_BLOOD, 0.54, 1)); // Blood Aide
|
||||
}
|
||||
// Rewards
|
||||
private static final int EXP_REWARD = 145557000;
|
||||
private static final int SP_REWARD = 34933;
|
||||
// Others
|
||||
private static final int MIN_LEVEL = 85;
|
||||
private static final int MAX_LEVEL = 89;
|
||||
|
||||
public Q00490_DutyOfTheSurvivor()
|
||||
{
|
||||
super(490, Q00490_DutyOfTheSurvivor.class.getSimpleName(), "Duty Of The Survivor");
|
||||
addStartNpc(VOLLODOS);
|
||||
addTalkId(VOLLODOS);
|
||||
addKillId(MONSTERS.keySet());
|
||||
addCondLevel(MIN_LEVEL, MAX_LEVEL, "no_level.html");
|
||||
}
|
||||
|
||||
@Override
|
||||
public String onAdvEvent(String event, L2Npc npc, L2PcInstance player)
|
||||
{
|
||||
final QuestState qs = getQuestState(player, false);
|
||||
if (qs == null)
|
||||
{
|
||||
return null;
|
||||
}
|
||||
|
||||
String htmltext = null;
|
||||
switch (event)
|
||||
{
|
||||
case "30137-02.htm":
|
||||
case "30137-03.htm":
|
||||
case "30137-04.htm":
|
||||
{
|
||||
htmltext = event;
|
||||
break;
|
||||
}
|
||||
case "30137-05.htm": // start the quest
|
||||
{
|
||||
qs.startQuest();
|
||||
htmltext = event;
|
||||
break;
|
||||
}
|
||||
case "30137-06.html":
|
||||
{
|
||||
if (qs.isCond(2))
|
||||
{
|
||||
giveAdena(player, 505062, true);
|
||||
addExpAndSp(player, EXP_REWARD, SP_REWARD);
|
||||
qs.exitQuest(QuestType.DAILY, true);
|
||||
htmltext = event;
|
||||
}
|
||||
break;
|
||||
}
|
||||
}
|
||||
return htmltext;
|
||||
}
|
||||
|
||||
@Override
|
||||
public String onTalk(L2Npc npc, L2PcInstance player)
|
||||
{
|
||||
final QuestState qs = getQuestState(player, true);
|
||||
String htmltext = null;
|
||||
switch (qs.getState())
|
||||
{
|
||||
case State.CREATED:
|
||||
{
|
||||
if ((player.getLevel() < MIN_LEVEL) && (player.getLevel() > MAX_LEVEL))
|
||||
{
|
||||
htmltext = "no_level.html";
|
||||
}
|
||||
else
|
||||
{
|
||||
htmltext = "30137-01.htm";
|
||||
}
|
||||
break;
|
||||
}
|
||||
|
||||
case State.STARTED:
|
||||
{
|
||||
if (qs.isCond(1))
|
||||
{
|
||||
htmltext = "30137-07.html";
|
||||
}
|
||||
if (qs.isCond(2))
|
||||
{
|
||||
htmltext = "30137-06.html";
|
||||
giveAdena(player, 505062, true);
|
||||
addExpAndSp(player, EXP_REWARD, SP_REWARD);
|
||||
qs.exitQuest(QuestType.DAILY, true);
|
||||
}
|
||||
break;
|
||||
}
|
||||
case State.COMPLETED:
|
||||
{
|
||||
if ((player.getLevel() < MIN_LEVEL) && (player.getLevel() > MAX_LEVEL))
|
||||
{
|
||||
htmltext = "no_level.html";
|
||||
}
|
||||
else if (!qs.isNowAvailable())
|
||||
{
|
||||
htmltext = "30137-08.html";
|
||||
}
|
||||
else
|
||||
{
|
||||
qs.setState(State.CREATED);
|
||||
htmltext = "30137-01.htm";
|
||||
}
|
||||
break;
|
||||
}
|
||||
}
|
||||
return htmltext;
|
||||
}
|
||||
|
||||
@Override
|
||||
public String onKill(L2Npc npc, L2PcInstance killer, boolean isSummon)
|
||||
{
|
||||
final QuestState qs = getRandomPartyMemberState(killer, -1, 3, npc);
|
||||
if (qs != null)
|
||||
{
|
||||
final ItemChanceHolder item = MONSTERS.get(npc.getId());
|
||||
if (giveItemRandomly(qs.getPlayer(), npc, item.getId(), item.getCount(), 20, item.getChance(), true) //
|
||||
&& (getQuestItemsCount(qs.getPlayer(), PUTRIFIED_EXTRACT) >= 20) //
|
||||
&& (getQuestItemsCount(qs.getPlayer(), ROTTEN_BLOOD) >= 20))
|
||||
{
|
||||
qs.setCond(2, true);
|
||||
}
|
||||
}
|
||||
return super.onKill(npc, killer, isSummon);
|
||||
}
|
||||
}
|
3
trunk/dist/game/data/scripts/quests/Q00490_DutyOfTheSurvivor/no_level.htm
vendored
Normal file
3
trunk/dist/game/data/scripts/quests/Q00490_DutyOfTheSurvivor/no_level.htm
vendored
Normal file
@ -0,0 +1,3 @@
|
||||
<html><body>You don't meet level requirements<br>
|
||||
(Quest available from level 28 to level 40)
|
||||
</body></html>
|
@ -131,6 +131,7 @@ import quests.Q00464_Oath.Q00464_Oath;
|
||||
import quests.Q00471_BreakingThroughTheEmeraldSquare.Q00471_BreakingThroughTheEmeraldSquare;
|
||||
import quests.Q00472_ChallengeSteamCorridor.Q00472_ChallengeSteamCorridor;
|
||||
import quests.Q00473_InTheCoralGarden.Q00473_InTheCoralGarden;
|
||||
import quests.Q00490_DutyOfTheSurvivor.Q00490_DutyOfTheSurvivor;
|
||||
import quests.Q00494_IncarnationOfGreedZellakaGroup.Q00494_IncarnationOfGreedZellakaGroup;
|
||||
import quests.Q00495_IncarnationOfJealousyPellineGroup.Q00495_IncarnationOfJealousyPellineGroup;
|
||||
import quests.Q00496_IncarnationOfGluttonyKaliosGroup.Q00496_IncarnationOfGluttonyKaliosGroup;
|
||||
@ -411,6 +412,7 @@ final class QuestMasterHandler
|
||||
Q00471_BreakingThroughTheEmeraldSquare.class,
|
||||
Q00472_ChallengeSteamCorridor.class,
|
||||
Q00473_InTheCoralGarden.class,
|
||||
Q00490_DutyOfTheSurvivor.class,
|
||||
Q00494_IncarnationOfGreedZellakaGroup.class,
|
||||
Q00495_IncarnationOfJealousyPellineGroup.class,
|
||||
Q00496_IncarnationOfGluttonyKaliosGroup.class,
|
||||
|
Reference in New Issue
Block a user