Sync with L2JServer Jan 28th 2015.

This commit is contained in:
mobius
2015-01-29 05:18:04 +00:00
parent 59e1db4a68
commit 2cb3a52ed2
224 changed files with 4690 additions and 835 deletions

View File

@@ -0,0 +1,5 @@
<html><body>Pantheon:<br>
Hmm? You came Gallint instead? Injured by falling book... How is he? He could not move away from the shock of the fall of the Island, but still continued to work... Even don `t know what to say... just restless... Hmm...<br>
Right. What Gallint asked me to tell me?<br>
<Button ALIGN=LEFT ICON="NORMAL" action="bypass -h Quest Q10326_RespectYourElders 32972-02.htm">"To say that the Ruins Esagira began to notice Suspicious Types."</button>
</body></html>

View File

@@ -0,0 +1,4 @@
<html><body>Pantheon:<br>
Suspicious Types... Now I remember that in recent times have also seen in the Museum of strange personalities. It seemed to me that they are looking for material on the Giants... Maybe they're one of those bands that were seen in the Ruins?<br><br>
They tried to steal a book called <font color="LEVEL">War of the Gods and the Giants </ font>. In this ancient manuscript contains information in the power of the Giants, the origin of their powers, monsters era Giants and the like. I am afraid that now, after the fall of the Island of Giants, this information can be used for evil purposes. It is necessary to rearrange the book elsewhere.
</body></html>

View File

@@ -0,0 +1,4 @@
<html><body>Pantheon:<br>
I worry about Gallint. When Ye Sagira dropped onto Talking Island, he was in Aden. He came back to find everything had been changed. He's struggling with adjusting. I can't say I blame him.<br>
(You have already completed this quest)
</body></html>

View File

@@ -0,0 +1,4 @@
<html><body>Gallint:<br>
Ah-ah! My back... Something I overworked these documents... Ah... I wanted to give something... How am I so... <br>
<Button ALIGN=LEFT ICON="NORMAL" action="bypass -h Quest Q10326_RespectYourElders 32980-02.htm">"Ask describe the problem in detail"</button>
</body></html>

View File

@@ -0,0 +1,6 @@
<html><body>Gallint:<br>
You know... Today I long for the first time, brought order to the documents. There were so many that had to move folders using magic.<br><br>
But these manuscripts was so much dust that I started sneezing. Distracted, and documents that are carried through the air, dropped over. Now sore lower back.<br><br>
For three days had passed on his feet I stood up, but moving all Yeshe hard. It was necessary to convey something of the Pantheon. Phew. <br>
<Button ALIGN=LEFT ICON="NORMAL" action="bypass -h Quest Q10326_RespectYourElders 32980-03.htm">"Offer Help"</button>
</body></html>

View File

@@ -0,0 +1,3 @@
<html><body>Gallint:<br>
You are so kind. <font color="LEVEL">Pantheon</font> <font color="LEVEL">is located at the Museum</font>. Tell him: <font color="LEVEL">"In Esagire caught suspicious characters"</ font>. And pass. I beg you.
</body></html>

View File

@@ -0,0 +1,4 @@
<html><body>Gallint:<br>
Come back... laster! Too much... pain, and you can't help Argh!<br>
(Only characters level 20 or above may take on this quest)
</body></html>

View File

@@ -0,0 +1,4 @@
<html><body>Gallint:<br>
Come back... laster! Too much... pain, and you can't help Argh!<br>
(Only characters under level 20 who have completed the Looking for New Power quest may take on this quest)
</body></html>

View File

@@ -0,0 +1,210 @@
/*
* Copyright (C) 2004-2015 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.Q10326_RespectYourElders;
import quests.Q10325_SearchingForNewPower.Q10325_SearchingForNewPower;
import com.l2jserver.gameserver.model.Location;
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.network.NpcStringId;
import com.l2jserver.gameserver.network.clientpackets.Say2;
import com.l2jserver.gameserver.network.serverpackets.ExRotation;
import com.l2jserver.gameserver.network.serverpackets.NpcSay;
import com.l2jserver.gameserver.util.Util;
/**
* Respect Your Elders (10326)
* @author Gladicek, St3eT, Neanrakyr
*/
public class Q10326_RespectYourElders extends Quest
{
// Npcs
private static final int GALLINT = 32980;
private static final int PANTHEON = 32972;
private static final int HANDERMONKEY = 32971;
// Misc
private static final int MAX_LEVEL = 20;
private static final Location HANDERMONKEY_SPAWN = new Location(-116617, 255497, -1432);
private final static Location[] HANDERMONKEY_LOC =
{
new Location(-116560, 255951, -1457),
new Location(-116688, 256597, -1472),
new Location(-116518, 257309, -1512),
new Location(-116418, 257746, -1512),
new Location(-115907, 257780, -1312),
new Location(-115449, 257782, -1136),
new Location(-114946, 257760, -1316),
new Location(-114637, 257349, -1142),
new Location(-114414, 257318, -1136),
};
public Q10326_RespectYourElders()
{
super(10326, Q10326_RespectYourElders.class.getSimpleName(), "Respect Your Elders");
addStartNpc(GALLINT);
addTalkId(GALLINT, PANTHEON);
addSpawnId(HANDERMONKEY);
addMoveFinishedId(HANDERMONKEY);
addCondMaxLevel(MAX_LEVEL, "32980-04.htm");
addCondCompletedQuest(Q10325_SearchingForNewPower.class.getSimpleName(), "32980-05.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 "32980-03.htm":
{
qs.startQuest();
htmltext = event;
final L2Npc handerMonkey = addSpawn(HANDERMONKEY, HANDERMONKEY_SPAWN, false, 300000);
startQuestTimer("MOVE_DELAY", 500, handerMonkey, player);
break;
}
case "32972-02.htm":
{
giveAdena(player, 140, true);
addExpAndSp(player, 6700, 5);
qs.exitQuest(false, true);
htmltext = event;
break;
}
case "32980-02.htm":
{
htmltext = event;
break;
}
case "CHECK_PLAYER":
{
final L2PcInstance owner = npc.getVariables().getObject("OWNER", L2PcInstance.class);
if (owner != null)
{
if (npc.calculateDistance(owner, false, false) < 120)
{
npc.getVariables().set("FAIL_COUNT", 0);
final int loc_index = npc.getVariables().getInt("MOVE_INDEX", -1) + 1;
if (loc_index > 0)
{
if (loc_index == 9)
{
npc.broadcastPacket(new NpcSay(npc.getObjectId(), Say2.NPC_ALL, npc.getTemplate().getDisplayId(), NpcStringId.GO_GO_GO_CREEK));
startQuestTimer("DELETE_NPC", 2000, npc, owner);
break;
}
npc.getVariables().set("MOVE_INDEX", loc_index);
addMoveToDesire(npc, HANDERMONKEY_LOC[loc_index], 0);
}
}
else
{
final int failCount = npc.getVariables().getInt("FAIL_COUNT", 0);
npc.getVariables().set("FAIL_COUNT", failCount + 1);
if (failCount >= 30)
{
npc.deleteMe();
break;
}
startQuestTimer("CHECK_PLAYER", 2000, npc, owner);
if (getRandom(100) < 10)
{
npc.broadcastPacket(new NpcSay(npc.getObjectId(), Say2.NPC_ALL, npc.getTemplate().getDisplayId(), NpcStringId.COME_ON_CREEK));
}
}
}
else
{
npc.deleteMe();
}
break;
}
case "MOVE_DELAY":
{
npc.getVariables().set("OWNER", player);
npc.setTitle(player.getName());
npc.setIsRunning(true);
npc.broadcastInfo();
addMoveToDesire(npc, HANDERMONKEY_LOC[0], 0);
npc.getVariables().set("MOVE_INDEX", 0);
break;
}
case "DELETE_NPC":
{
npc.deleteMe();
break;
}
}
return htmltext;
}
@Override
public void onMoveFinished(L2Npc npc)
{
npc.broadcastPacket(new NpcSay(npc.getObjectId(), Say2.NPC_ALL, npc.getTemplate().getDisplayId(), NpcStringId.COME_ON_CREEK));
final L2PcInstance owner = npc.getVariables().getObject("OWNER", L2PcInstance.class);
if (owner != null)
{
startQuestTimer("CHECK_PLAYER", 2000, npc, owner);
npc.setHeading(Util.calculateHeadingFrom(npc, owner));
npc.broadcastPacket(new ExRotation(npc.getObjectId(), npc.getHeading()));
}
}
@Override
public String onTalk(L2Npc npc, L2PcInstance player)
{
final QuestState qs = getQuestState(player, true);
String htmltext = null;
switch (qs.getState())
{
case State.CREATED:
{
htmltext = npc.getId() == GALLINT ? "32980-01.htm" : "32972-01a.htm";
break;
}
case State.STARTED:
{
htmltext = npc.getId() == GALLINT ? "32980-03.htm" : "32972-01.htm";
break;
}
case State.COMPLETED:
{
htmltext = npc.getId() == GALLINT ? "32980-04.htm" : "32972-03.htm";
break;
}
}
return htmltext;
}
}