Quest Quieting The Storm (10757).
Contributed by Stayway.
This commit is contained in:
parent
5d57da5f1b
commit
a579ce9ec2
1
trunk/dist/game/data/scripts.cfg
vendored
1
trunk/dist/game/data/scripts.cfg
vendored
@ -204,6 +204,7 @@ ai/individual/TomaJunior.java
|
||||
ai/individual/TrainingGolem.java
|
||||
ai/individual/TrainningSoldier.java
|
||||
ai/individual/Valakas.java
|
||||
ai/individual/WindVortex.java
|
||||
|
||||
# Village Master
|
||||
village_master/Clan/Clan.java
|
||||
|
56
trunk/dist/game/data/scripts/ai/individual/WindVortex.java
vendored
Normal file
56
trunk/dist/game/data/scripts/ai/individual/WindVortex.java
vendored
Normal file
@ -0,0 +1,56 @@
|
||||
/*
|
||||
* 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 ai.individual;
|
||||
|
||||
import com.l2jmobius.gameserver.model.actor.L2Npc;
|
||||
import com.l2jmobius.gameserver.model.actor.instance.L2MonsterInstance;
|
||||
import com.l2jmobius.gameserver.model.actor.instance.L2PcInstance;
|
||||
import com.l2jmobius.gameserver.network.NpcStringId;
|
||||
import com.l2jmobius.gameserver.network.serverpackets.ExShowScreenMessage;
|
||||
|
||||
import ai.npc.AbstractNpcAI;
|
||||
|
||||
/**
|
||||
* @author Stayway
|
||||
*/
|
||||
public final class WindVortex extends AbstractNpcAI
|
||||
{
|
||||
// NPCs
|
||||
private static final int WIND_VORTEX = 23417;
|
||||
private static final int GIANT_WINDIMA = 23419;
|
||||
private static final int IMMENSE_WINDIMA = 23420;
|
||||
|
||||
private WindVortex()
|
||||
{
|
||||
super(WindVortex.class.getSimpleName(), "ai/individual");
|
||||
addKillId(WIND_VORTEX);
|
||||
}
|
||||
|
||||
@Override
|
||||
public String onKill(L2Npc npc, L2PcInstance killer, boolean isSummon)
|
||||
{
|
||||
final L2Npc newSpawn = addSpawn(getRandomBoolean() ? IMMENSE_WINDIMA : GIANT_WINDIMA, npc.getLocation(), false, 300000); // 5 minute despawn time
|
||||
((L2MonsterInstance) newSpawn).addDamage(killer, 1, null);
|
||||
showOnScreenMsg(killer, NpcStringId.A_POWERFUL_MONSTER_HAS_COME_TO_FACE_YOU, ExShowScreenMessage.TOP_CENTER, 4500);
|
||||
return super.onKill(npc, killer, isSummon);
|
||||
}
|
||||
|
||||
public static void main(String[] args)
|
||||
{
|
||||
new WindVortex();
|
||||
}
|
||||
}
|
6
trunk/dist/game/data/scripts/quests/Q10757_QuietingTheStorm/33963-01.htm
vendored
Normal file
6
trunk/dist/game/data/scripts/quests/Q10757_QuietingTheStorm/33963-01.htm
vendored
Normal file
@ -0,0 +1,6 @@
|
||||
<html><body>Researcher Pio:<br>
|
||||
Oh! Pretty wing ears!<br1>
|
||||
Hehe. I have something to ask you.<br>
|
||||
Tilt you head this way!<br>
|
||||
<button align=LEFT icon=NORMAL action="bypass -h Quest Q10757_QuietingTheStorm 33963-02.htm">"Ouch!"</button>
|
||||
</body></html>
|
5
trunk/dist/game/data/scripts/quests/Q10757_QuietingTheStorm/33963-02.htm
vendored
Normal file
5
trunk/dist/game/data/scripts/quests/Q10757_QuietingTheStorm/33963-02.htm
vendored
Normal file
@ -0,0 +1,5 @@
|
||||
<html><body>Researcher Pio:<br>
|
||||
Oops! I needed Ertheia hair. The Unwordly Wind you got for me was not enough. Sorry about that.<br>
|
||||
I will be using your hair for my research, so don't worry!<br>
|
||||
<button align=LEFT icon=NORMAL action="bypass -h Quest Q10757_QuietingTheStorm 33963-03.htm">Thanks for asking, creepo.</button>
|
||||
</body></html>
|
5
trunk/dist/game/data/scripts/quests/Q10757_QuietingTheStorm/33963-03.htm
vendored
Normal file
5
trunk/dist/game/data/scripts/quests/Q10757_QuietingTheStorm/33963-03.htm
vendored
Normal file
@ -0,0 +1,5 @@
|
||||
<html><body>Researcher Pio:<br>
|
||||
Sorry! Stop being so cranky.<br>
|
||||
It's just a strand of hair. Not all Ertheia are uptight like you are, are they? Come on, ease up and listen to my story.<br>
|
||||
<button align=LEFT icon=NORMAL action="bypass -h Quest Q10757_QuietingTheStorm 33963-04.htm">"Story?"</button>
|
||||
</body></html>
|
6
trunk/dist/game/data/scripts/quests/Q10757_QuietingTheStorm/33963-04.htm
vendored
Normal file
6
trunk/dist/game/data/scripts/quests/Q10757_QuietingTheStorm/33963-04.htm
vendored
Normal file
@ -0,0 +1,6 @@
|
||||
<html><body>Researcher Pio:<br>
|
||||
Oh it's about the Windy Hill. It's where winds in different directions meet and make vortex. However, we couldn't see the vortex with our eyes in the past.<br>
|
||||
But recently, perhaps due to the energy from the Wind Realm, the vortex has gotten so big that it's visible. Leaving the vortex will eventually harm the towns nearby.<br>
|
||||
We can't do nothing knowing that it's going to do harm. Speaking of which, can you do me a favor?<br>
|
||||
<button align=LEFT icon=NORMAL action="bypass -h Quest Q10757_QuietingTheStorm 33963-05.htm">"I'm still offended, but okay."</button>
|
||||
</body></html>
|
6
trunk/dist/game/data/scripts/quests/Q10757_QuietingTheStorm/33963-05.htm
vendored
Normal file
6
trunk/dist/game/data/scripts/quests/Q10757_QuietingTheStorm/33963-05.htm
vendored
Normal file
@ -0,0 +1,6 @@
|
||||
<html><body>Researcher Pio:<br>
|
||||
Hehe. Did I hunt you yanking your hair out?<br1>
|
||||
Anyway, thank you for helping.<br>
|
||||
Now go to Windy Hill and remove <font color="LEVEL">Vortex Wind Storm</font>.<br>
|
||||
And on the hill <font color="LEVEL">Giant Windima and Immense Windima</font> come out. Kill them while you're at it.
|
||||
</body></html>
|
5
trunk/dist/game/data/scripts/quests/Q10757_QuietingTheStorm/33963-06.htm
vendored
Normal file
5
trunk/dist/game/data/scripts/quests/Q10757_QuietingTheStorm/33963-06.htm
vendored
Normal file
@ -0,0 +1,5 @@
|
||||
<html><body>Researcher Pio:<br>
|
||||
Oh! Pretty wing ears!<br>
|
||||
Did you find anything from the spirits? Can you give them to me?
|
||||
<Button ALIGN=LEFT ICON="NORMAL" action="bypass -h Quest Q10757_QuietingTheStorm 33963-07.html">"I got Unworldly Wind. I can feel the power of the Wind Spirit Realm in it."</Button>
|
||||
</body></html>
|
5
trunk/dist/game/data/scripts/quests/Q10757_QuietingTheStorm/33963-07.html
vendored
Normal file
5
trunk/dist/game/data/scripts/quests/Q10757_QuietingTheStorm/33963-07.html
vendored
Normal file
@ -0,0 +1,5 @@
|
||||
<html><body>Researcher Pio:<br>
|
||||
I knew it. There is something wrong with the Vortex! Not only did I not see it in the past, but there weren't any monsters either.<br>
|
||||
It must be the influence from the Wind Spirit Realm.<br>
|
||||
Thank you for helping. I will call you when I need you again. Don't worry, I won't yank your hair again. Hahaha!
|
||||
</body></html>
|
5
trunk/dist/game/data/scripts/quests/Q10757_QuietingTheStorm/33963-08.html
vendored
Normal file
5
trunk/dist/game/data/scripts/quests/Q10757_QuietingTheStorm/33963-08.html
vendored
Normal file
@ -0,0 +1,5 @@
|
||||
<html><body>Researcher Pio:<br>
|
||||
Thank you!<br>
|
||||
Now go to Windy Hill and remove <font color="LEVEL">Vortex Wind Storm</font>.<br>
|
||||
And on the hill <font color="LEVEL">Giant Windima and Immense Windima</font> come out. Kill them while you're at it.
|
||||
</body></html>
|
192
trunk/dist/game/data/scripts/quests/Q10757_QuietingTheStorm/Q10757_QuietingTheStorm.java
vendored
Normal file
192
trunk/dist/game/data/scripts/quests/Q10757_QuietingTheStorm/Q10757_QuietingTheStorm.java
vendored
Normal file
@ -0,0 +1,192 @@
|
||||
/*
|
||||
* 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.Q10757_QuietingTheStorm;
|
||||
|
||||
import java.util.HashMap;
|
||||
import java.util.Map;
|
||||
|
||||
import com.l2jmobius.gameserver.enums.Race;
|
||||
import com.l2jmobius.gameserver.model.actor.L2Npc;
|
||||
import com.l2jmobius.gameserver.model.actor.instance.L2PcInstance;
|
||||
import com.l2jmobius.gameserver.model.holders.ItemHolder;
|
||||
import com.l2jmobius.gameserver.model.quest.Quest;
|
||||
import com.l2jmobius.gameserver.model.quest.QuestState;
|
||||
import com.l2jmobius.gameserver.model.quest.State;
|
||||
import com.l2jmobius.gameserver.network.NpcStringId;
|
||||
import com.l2jmobius.gameserver.network.serverpackets.ExQuestNpcLogList;
|
||||
import com.l2jmobius.gameserver.util.Util;
|
||||
|
||||
/**
|
||||
* Quieting The Storm (10757)
|
||||
* @author Stayway
|
||||
*/
|
||||
public class Q10757_QuietingTheStorm extends Quest
|
||||
{
|
||||
// NPC
|
||||
private static final int PIO = 33963;
|
||||
// Monsters
|
||||
private static final int WIND_VORTEX = 23417;
|
||||
private static final int GIANT_WINDIMA = 23419;
|
||||
private static final int IMMENSE_WINDIMA = 23420;
|
||||
private static final Map<Integer, Integer> MOBS_REQUIRED = new HashMap<>();
|
||||
{
|
||||
MOBS_REQUIRED.put(WIND_VORTEX, 5);
|
||||
MOBS_REQUIRED.put(GIANT_WINDIMA, 1);
|
||||
}
|
||||
// Item
|
||||
private static final ItemHolder GUILD_COIN = new ItemHolder(37045, 7);
|
||||
// Rewards
|
||||
private static final int EXP_REWARD = 632051;
|
||||
private static final int SP_REWARD = 151;
|
||||
// Others
|
||||
private static final int MIN_LEVEL = 24;
|
||||
|
||||
public Q10757_QuietingTheStorm()
|
||||
{
|
||||
super(10757, Q10757_QuietingTheStorm.class.getSimpleName(), "Quieting The Storm");
|
||||
addStartNpc(PIO);
|
||||
addTalkId(PIO);
|
||||
addKillId(WIND_VORTEX, IMMENSE_WINDIMA, GIANT_WINDIMA);
|
||||
addCondMinLevel(MIN_LEVEL, "no_level.htm");
|
||||
}
|
||||
|
||||
@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 "33963-02.htm":
|
||||
case "33963-03.htm":
|
||||
case "33963-04.htm":
|
||||
case "33963-06.htm":
|
||||
{
|
||||
htmltext = event;
|
||||
break;
|
||||
}
|
||||
case "33963-05.htm": // start the quest
|
||||
{
|
||||
qs.startQuest();
|
||||
qs.set(Integer.toString(WIND_VORTEX), 0);
|
||||
qs.set(Integer.toString(GIANT_WINDIMA), 0);
|
||||
qs.set(Integer.toString(IMMENSE_WINDIMA), 0);
|
||||
htmltext = event;
|
||||
break;
|
||||
}
|
||||
case "33963-07.html":
|
||||
{
|
||||
if (qs.isCond(2))
|
||||
{
|
||||
giveItems(player, GUILD_COIN);
|
||||
addExpAndSp(player, EXP_REWARD, SP_REWARD);
|
||||
qs.unset(Integer.toString(WIND_VORTEX));
|
||||
qs.unset(Integer.toString(GIANT_WINDIMA));
|
||||
qs.exitQuest(false, 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.getRace() != Race.ERTHEIA)
|
||||
{
|
||||
htmltext = "noErtheia.html";
|
||||
}
|
||||
else
|
||||
{
|
||||
htmltext = "33963-01.htm";
|
||||
}
|
||||
break;
|
||||
}
|
||||
|
||||
case State.STARTED:
|
||||
{
|
||||
if (qs.isCond(1))
|
||||
{
|
||||
htmltext = "33963-08.html";
|
||||
}
|
||||
else if (qs.isCond(2))
|
||||
{
|
||||
htmltext = "33963-06.html";
|
||||
}
|
||||
break;
|
||||
}
|
||||
case State.COMPLETED:
|
||||
{
|
||||
htmltext = getAlreadyCompletedMsg(player);
|
||||
break;
|
||||
}
|
||||
}
|
||||
return htmltext;
|
||||
}
|
||||
|
||||
@Override
|
||||
public String onKill(L2Npc npc, L2PcInstance killer, boolean isSummon)
|
||||
{
|
||||
final QuestState qs = getRandomPartyMemberState(killer, -1, 3, npc);
|
||||
if ((qs != null) && qs.isStarted() && qs.isCond(1) && (Util.checkIfInRange(1500, npc, qs.getPlayer(), false)))
|
||||
{
|
||||
int kills = 0;
|
||||
switch (npc.getId())
|
||||
{
|
||||
case WIND_VORTEX:
|
||||
{
|
||||
kills = qs.getInt(Integer.toString(WIND_VORTEX));
|
||||
kills++;
|
||||
qs.set(Integer.toString(WIND_VORTEX), kills);
|
||||
break;
|
||||
}
|
||||
case IMMENSE_WINDIMA:
|
||||
case GIANT_WINDIMA:
|
||||
{
|
||||
kills = qs.getInt(Integer.toString(GIANT_WINDIMA));
|
||||
kills++;
|
||||
qs.set(Integer.toString(GIANT_WINDIMA), kills);
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
final ExQuestNpcLogList log = new ExQuestNpcLogList(getId());
|
||||
log.addNpc(WIND_VORTEX, qs.getInt(Integer.toString(WIND_VORTEX)));
|
||||
log.addNpcString(NpcStringId.IMMENSE_WINDIMA_OR_GIANT_WINDIMA, qs.getInt(Integer.toString(GIANT_WINDIMA)));
|
||||
killer.sendPacket(log);
|
||||
|
||||
if ((qs.getInt(Integer.toString(WIND_VORTEX)) >= MOBS_REQUIRED.get(WIND_VORTEX)) && (qs.getInt(Integer.toString(GIANT_WINDIMA)) >= MOBS_REQUIRED.get(GIANT_WINDIMA)))
|
||||
{
|
||||
qs.setCond(2);
|
||||
}
|
||||
}
|
||||
return super.onKill(npc, killer, isSummon);
|
||||
}
|
||||
}
|
3
trunk/dist/game/data/scripts/quests/Q10757_QuietingTheStorm/noErtheia.html
vendored
Normal file
3
trunk/dist/game/data/scripts/quests/Q10757_QuietingTheStorm/noErtheia.html
vendored
Normal file
@ -0,0 +1,3 @@
|
||||
<html><body>Research Pio:<br>
|
||||
You are not Ertheia, this quest is not for you.
|
||||
</body></html>
|
3
trunk/dist/game/data/scripts/quests/Q10757_QuietingTheStorm/no_level.htm
vendored
Normal file
3
trunk/dist/game/data/scripts/quests/Q10757_QuietingTheStorm/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>
|
@ -254,6 +254,7 @@ import quests.Q10745_TheSecretIngredients.Q10745_TheSecretIngredients;
|
||||
import quests.Q10746_SeeTheWorld.Q10746_SeeTheWorld;
|
||||
import quests.Q10755_LettersFromTheQueen_WindyHill.Q10755_LettersFromTheQueen_WindyHill;
|
||||
import quests.Q10756_AnInterdimensionalDraft.Q10756_AnInterdimensionalDraft;
|
||||
import quests.Q10757_QuietingTheStorm.Q10757_QuietingTheStorm;
|
||||
|
||||
/**
|
||||
* @author NosBit
|
||||
@ -498,7 +499,8 @@ public class QuestMasterHandler
|
||||
Q10745_TheSecretIngredients.class,
|
||||
Q10746_SeeTheWorld.class,
|
||||
Q10755_LettersFromTheQueen_WindyHill.class,
|
||||
Q10756_AnInterdimensionalDraft.class
|
||||
Q10756_AnInterdimensionalDraft.class,
|
||||
Q10757_QuietingTheStorm.class
|
||||
};
|
||||
|
||||
public static void main(String[] args)
|
||||
|
@ -494,6 +494,8 @@
|
||||
<acquire exp="956" sp="0" />
|
||||
<stats>
|
||||
<vitals hp="772" hpRegen="7.5" mp="1345.8" mpRegen="2.7" />
|
||||
<attack physical="52.11271" magical="33.26266" random="30" critical="4" accuracy="4.75" attackSpeed="253" type="SWORD" range="40" distance="80" width="120" />
|
||||
<defence physical="78.46427" magical="58.8748547991048" />
|
||||
<speed>
|
||||
<walk ground="50" />
|
||||
<run ground="120" />
|
||||
@ -598,6 +600,8 @@
|
||||
<acquire exp="2956" sp="0" />
|
||||
<stats>
|
||||
<vitals hp="4899" hpRegen="3.5" mp="402" mpRegen="1.5" />
|
||||
<attack physical="92.64226" magical="63.26266" random="30" critical="4" accuracy="4.75" attackSpeed="253" type="SWORD" range="40" distance="80" width="120" />
|
||||
<defence physical="118.46427" magical="78.8748547991048" />
|
||||
<speed>
|
||||
<walk ground="60" /> <!-- Need retail value -->
|
||||
<run ground="120" /> <!-- Need retail value -->
|
||||
|
Loading…
Reference in New Issue
Block a user