This commit is contained in:
4
trunk/dist/game/data/scripts/quests/Q00605_AllianceWithKetraOrcs/31371-01.htm
vendored
Normal file
4
trunk/dist/game/data/scripts/quests/Q00605_AllianceWithKetraOrcs/31371-01.htm
vendored
Normal file
@@ -0,0 +1,4 @@
|
||||
<html><body>Ketra's Messenger Wahkan:<br>
|
||||
Greetings, stranger! Are you a mercenary? Excellent! Will you fight for the Ketra Orcs?<br>
|
||||
<a action="bypass -h Quest Q00605_AllianceWithKetraOrcs 31371-04.htm">"I'll do it!"</a>
|
||||
</body></html>
|
4
trunk/dist/game/data/scripts/quests/Q00605_AllianceWithKetraOrcs/31371-02.htm
vendored
Normal file
4
trunk/dist/game/data/scripts/quests/Q00605_AllianceWithKetraOrcs/31371-02.htm
vendored
Normal file
@@ -0,0 +1,4 @@
|
||||
<html><body>Ketra's Messenger Wahkan:<br>
|
||||
Do you actually think a weakling like you can stand up to the mighty Ketra Orcs? Ha! I can't believe you've lasted this long! Scram, pencilneck!<br>
|
||||
(Only a character of level 74 or above may undertake this quest.)
|
||||
</body></html>
|
3
trunk/dist/game/data/scripts/quests/Q00605_AllianceWithKetraOrcs/31371-03.htm
vendored
Normal file
3
trunk/dist/game/data/scripts/quests/Q00605_AllianceWithKetraOrcs/31371-03.htm
vendored
Normal file
@@ -0,0 +1,3 @@
|
||||
<html><body>Ketra's Messenger Wahkan:<br>
|
||||
You're nothing but a filthy maggot! A dog of the Varka Silenos! Did you enjoy licking their vile boots?! Get out of my sight! You sicken me!
|
||||
</body></html>
|
5
trunk/dist/game/data/scripts/quests/Q00605_AllianceWithKetraOrcs/31371-04.htm
vendored
Normal file
5
trunk/dist/game/data/scripts/quests/Q00605_AllianceWithKetraOrcs/31371-04.htm
vendored
Normal file
@@ -0,0 +1,5 @@
|
||||
<html><body>Ketra's Messenger Wahkan:<br>
|
||||
Well, I suppose I'll give you a chance... If you can gain my trust, the Ketras will trust you as well. Your test is simple. Annihilate those filthy Varka Silenos! Kill as many as you can! As proof, bring back <font color="LEVEL">100 badges of Varka Soldiers</font>.<br>
|
||||
Get the badges by slaying Varka Silenos <font color="LEVEL">Recruits, Footmen, Scouts, Hunters and Shamans</font>. This will build trust with our tribe.<br>
|
||||
Now get going!
|
||||
</body></html>
|
7
trunk/dist/game/data/scripts/quests/Q00605_AllianceWithKetraOrcs/31371-05.htm
vendored
Normal file
7
trunk/dist/game/data/scripts/quests/Q00605_AllianceWithKetraOrcs/31371-05.htm
vendored
Normal file
@@ -0,0 +1,7 @@
|
||||
<html><body>Ketra's Messenger Wahkan:<br>
|
||||
There are several phases of friendship:<br>
|
||||
Fight bravely for the Ketra, and the Ketra will take care of you.<br>
|
||||
You must kill not only the henchmen but also the commander to win the war against the Varka Silenos Village. Kill every goatee you can find! Keep killing them! The war isn't over until all the filthy Varka are wiped off the earth!<br>
|
||||
I will give more confidence and trust to those who bring the insignia of the Wahkan Varka Rank - 200 soldiers with the insignia of the Varka Rank - 100 Non-Commissioned Officers. The insignia of the Varka Rank - Non-Commissioned Officer can be obtained when you kill <font color="LEVEL">the Priest of Varka Silenos, a Warrior, a Spiritual Medium, a Non-Commissioned Officer, a Chief Officiating Priest, a Commander of an Army Corps and an Elite Military Escort</font>. Go forward, friends of Ketra!<br>
|
||||
<font color="LEVEL">Remember not to lay a finger on our Ketra Orc tribe! This would destroy our alliance!</font>
|
||||
</body></html>
|
6
trunk/dist/game/data/scripts/quests/Q00605_AllianceWithKetraOrcs/31371-06.htm
vendored
Normal file
6
trunk/dist/game/data/scripts/quests/Q00605_AllianceWithKetraOrcs/31371-06.htm
vendored
Normal file
@@ -0,0 +1,6 @@
|
||||
<html><body>Ketra's Messenger Wahkan:<br>
|
||||
You're the best friend the Ketra ever had! The more you fight for the Ketra, the more we will trust you.<br>
|
||||
Our war against the Varka Orcs continues. We must drive those revolting goat beards from the face of the earth! Kill <font color="LEVEL">Varka Silenos great mystics, captains, grand seers, prophets, prophet's disciples, prophet's royal guards, chief magi and chief escorts</font>. Kill them all and take their badges as proof.<br>
|
||||
Bring back <font color="LEVEL">300 badges of grunts, 200 badges of officers and 100 badges of captains</font>. Good luck, my friend!<br>
|
||||
<font color="LEVEL">However, if you laid a hand on our Ketra Orcs in the middle, our confidence in you will fade away and our alliance with you will be destroyed!!</font>
|
||||
</body></html>
|
5
trunk/dist/game/data/scripts/quests/Q00605_AllianceWithKetraOrcs/31371-07.htm
vendored
Normal file
5
trunk/dist/game/data/scripts/quests/Q00605_AllianceWithKetraOrcs/31371-07.htm
vendored
Normal file
@@ -0,0 +1,5 @@
|
||||
<html><body>Ketra's Messenger Wahkan:<br>
|
||||
Ha ha ha! I'll bet those filthy goat beards peed all over themselves! Such is the pleasure of an overwhelming victory! Our job isn't finished yet, however. This war won't be over until every single Varka lies dead!<br>
|
||||
Your excellent reputation is spreading like wildfire among the Ketras! However, it is said that there are several steps in friendship. You're now in the middle. If you want to raise our esteem for you even further, attack the Varka Silenos again and bring us <font color="LEVEL">300 badges of grunts, 300 badges of officers, 200 badges of captains and a Totem of Valor</font>. You are fully qualified. Show your real power. The stronger someone is, the more he will be loved by Ketras! You can get the totem by successfully finishing the <font color="LEVEL">Prove Your Courage!</font> quest assigned by Hierarch Kadun Zu Ketra.<br>
|
||||
<font color="LEVEL">However, if you laid a hand on our Ketra Orcs in the middle, our confidence in you will fade away and our alliance with you will be destroyed!!</font>
|
||||
</body></html>
|
4
trunk/dist/game/data/scripts/quests/Q00605_AllianceWithKetraOrcs/31371-08.htm
vendored
Normal file
4
trunk/dist/game/data/scripts/quests/Q00605_AllianceWithKetraOrcs/31371-08.htm
vendored
Normal file
@@ -0,0 +1,4 @@
|
||||
<html><body>Ketra's Messenger Wahkan:<br>
|
||||
This mission will earn you the Ketra's highest level of trust. This task will not be very difficult for the strong one like you. You must kill the Varka Silenos and bring us <font color="LEVEL">400 badges of grunts, 400 badges of officers and 200 badges of captains</font> as well as the <font color="LEVEL">Totem of Wisdom</font>. The Totem of Wisdom can be obtained by killing Mos, the commander of the Varkas, longtime scourge of the Ketras. However, you must speak with <font color="LEVEL">Hierarch Kadun Zu Ketra</font> for more details on the quest, known as <font color="LEVEL">Slay the Enemy Commander</font> before killing Mos! Go ahead! I have no doubt that you will prevail!<br>
|
||||
<font color="LEVEL">However, if you laid a hand on our Ketra Orcs in the middle, our confidence in you will fade away and our alliance with you will be destroyed!!</font>
|
||||
</body></html>
|
5
trunk/dist/game/data/scripts/quests/Q00605_AllianceWithKetraOrcs/31371-09.htm
vendored
Normal file
5
trunk/dist/game/data/scripts/quests/Q00605_AllianceWithKetraOrcs/31371-09.htm
vendored
Normal file
@@ -0,0 +1,5 @@
|
||||
<html><body>Ketra's Messenger Wahkan:<br>
|
||||
Ha! Hello, friend! What can the Ketras do for you today? You are truly our dearest friend!<br>
|
||||
But don't forget, Ketras live in the moment, and our memories are short... Once a friend leaves us, it is as if they were never here. What's past is past.<br>
|
||||
<a action="bypass -h Quest Q00605_AllianceWithKetraOrcs 31371-25.html">"I want to quit."</a>
|
||||
</body></html>
|
3
trunk/dist/game/data/scripts/quests/Q00605_AllianceWithKetraOrcs/31371-10.html
vendored
Normal file
3
trunk/dist/game/data/scripts/quests/Q00605_AllianceWithKetraOrcs/31371-10.html
vendored
Normal file
@@ -0,0 +1,3 @@
|
||||
<html><body>Ketra's Messenger Wahkan:<br>
|
||||
Yo, stranger! Will you join our struggle against the filthy Varka Silenos? I, for one, can't wait to taste their blood! Quickly, go to the battlefield and kill Varka Silenos! As proof, bring back <font color="LEVEL">100 badges of grunts</font>! Then you shall surely become a friend of the Ketra Orcs.
|
||||
</body></html>
|
4
trunk/dist/game/data/scripts/quests/Q00605_AllianceWithKetraOrcs/31371-11.html
vendored
Normal file
4
trunk/dist/game/data/scripts/quests/Q00605_AllianceWithKetraOrcs/31371-11.html
vendored
Normal file
@@ -0,0 +1,4 @@
|
||||
<html><body>Ketra's Messenger Wahkan:<br>
|
||||
Have you brought the badges of the goat beards? How many did you kill?<br>
|
||||
<a action="bypass -h Quest Q00605_AllianceWithKetraOrcs 31371-12.html">"Here are the badges."</a>
|
||||
</body></html>
|
3
trunk/dist/game/data/scripts/quests/Q00605_AllianceWithKetraOrcs/31371-12.html
vendored
Normal file
3
trunk/dist/game/data/scripts/quests/Q00605_AllianceWithKetraOrcs/31371-12.html
vendored
Normal file
@@ -0,0 +1,3 @@
|
||||
<html><body>Ketra's Messenger Wahkan:<br>
|
||||
You've formed a friendship with the Ketra forged in blood and fire! Take this <font color="LEVEL">Mark of Ketra's Alliance - Level 1</font>. We only award them to those we consider our true friends. Congratulations!
|
||||
</body></html>
|
3
trunk/dist/game/data/scripts/quests/Q00605_AllianceWithKetraOrcs/31371-12a.html
vendored
Normal file
3
trunk/dist/game/data/scripts/quests/Q00605_AllianceWithKetraOrcs/31371-12a.html
vendored
Normal file
@@ -0,0 +1,3 @@
|
||||
<html><body>Ketra's Messenger Wahkan:<br>
|
||||
We'll reward our true friends. Help us in battle!
|
||||
</body></html>
|
3
trunk/dist/game/data/scripts/quests/Q00605_AllianceWithKetraOrcs/31371-12b.html
vendored
Normal file
3
trunk/dist/game/data/scripts/quests/Q00605_AllianceWithKetraOrcs/31371-12b.html
vendored
Normal file
@@ -0,0 +1,3 @@
|
||||
<html><body>Ketra's Messenger Wahkan:<br>
|
||||
Fellow Ketra soldier, we value your friendship!
|
||||
</body></html>
|
6
trunk/dist/game/data/scripts/quests/Q00605_AllianceWithKetraOrcs/31371-13.html
vendored
Normal file
6
trunk/dist/game/data/scripts/quests/Q00605_AllianceWithKetraOrcs/31371-13.html
vendored
Normal file
@@ -0,0 +1,6 @@
|
||||
<html><body>Ketra's Messenger Wahkan:<br>
|
||||
Have you massacred the Varka Silenos yet? Remember, you promised to bring back <font color="LEVEL">200 badges of grunts and 100 badges of officers</font> as proof!<br>
|
||||
We treat our friends very well, you're not thinking about changing your mind, are you?<br>
|
||||
<a action="bypass -h Quest Q00605_AllianceWithKetraOrcs 31371-12a.html">"I'll vanquish the enemy!"</a><br>
|
||||
<a action="bypass -h Quest Q00605_AllianceWithKetraOrcs 31371-25.html">"I want to quit."</a>
|
||||
</body></html>
|
4
trunk/dist/game/data/scripts/quests/Q00605_AllianceWithKetraOrcs/31371-14.html
vendored
Normal file
4
trunk/dist/game/data/scripts/quests/Q00605_AllianceWithKetraOrcs/31371-14.html
vendored
Normal file
@@ -0,0 +1,4 @@
|
||||
<html><body>Ketra's Messenger Wahkan:<br>
|
||||
Friend, how did you repay us for the trust we've shown you? Where's the proof?<br>
|
||||
<a action="bypass -h Quest Q00605_AllianceWithKetraOrcs 31371-15.html">"Here are the badges."</a>
|
||||
</body></html>
|
3
trunk/dist/game/data/scripts/quests/Q00605_AllianceWithKetraOrcs/31371-15.html
vendored
Normal file
3
trunk/dist/game/data/scripts/quests/Q00605_AllianceWithKetraOrcs/31371-15.html
vendored
Normal file
@@ -0,0 +1,3 @@
|
||||
<html><body>Ketra's Messenger Wahkan:<br>
|
||||
Good job, friend! We thank you for your strong friendship. Please accept this <font color="LEVEL">Mark of Ketra's Alliance - Level 2</font>. Warehouse Keeper Jaff will let you use the warehouse now! Congratulations!
|
||||
</body></html>
|
5
trunk/dist/game/data/scripts/quests/Q00605_AllianceWithKetraOrcs/31371-16.html
vendored
Normal file
5
trunk/dist/game/data/scripts/quests/Q00605_AllianceWithKetraOrcs/31371-16.html
vendored
Normal file
@@ -0,0 +1,5 @@
|
||||
<html><body>Ketra's Messenger Wahkan:<br>
|
||||
Where are the <font color="LEVEL">300 badges of grunts, 200 badges of officers and 100 badges of captains</font> you promised to bring back from the Varka Silenos? Surely this isn't too hard for you?! Do you want to back out of our agreement?<br>
|
||||
<a action="bypass -h Quest Q00605_AllianceWithKetraOrcs 31371-12a.html">"I'll destroy the enemy!"</a><br>
|
||||
<a action="bypass -h Quest Q00605_AllianceWithKetraOrcs 31371-25.html">"I want to quit."</a>
|
||||
</body></html>
|
4
trunk/dist/game/data/scripts/quests/Q00605_AllianceWithKetraOrcs/31371-17.html
vendored
Normal file
4
trunk/dist/game/data/scripts/quests/Q00605_AllianceWithKetraOrcs/31371-17.html
vendored
Normal file
@@ -0,0 +1,4 @@
|
||||
<html><body>Ketra's Messenger Wahkan:<br>
|
||||
Friend, show those goat beards the power of Pa'agrio's fire! This fight isn't over until every single Varka Silenos is dead! How many have you killed?<br>
|
||||
<a action="bypass -h Quest Q00605_AllianceWithKetraOrcs 31371-18.html">"Here are the badges."</a>
|
||||
</body></html>
|
3
trunk/dist/game/data/scripts/quests/Q00605_AllianceWithKetraOrcs/31371-18.html
vendored
Normal file
3
trunk/dist/game/data/scripts/quests/Q00605_AllianceWithKetraOrcs/31371-18.html
vendored
Normal file
@@ -0,0 +1,3 @@
|
||||
<html><body>Ketra's Messenger Wahkan:<br>
|
||||
Excellent, brave comrade! I won't be satisfied until I've ground the bones of every one of those filthy goat beards into dust! Please accept this <font color="LEVEL">Mark of Ketra's Alliance - Level 3</font>. You're now permitted to obtain specialty items from Trader Jumara and to receive the blessing of Asefa, guide of dead souls! Good job!
|
||||
</body></html>
|
5
trunk/dist/game/data/scripts/quests/Q00605_AllianceWithKetraOrcs/31371-19.html
vendored
Normal file
5
trunk/dist/game/data/scripts/quests/Q00605_AllianceWithKetraOrcs/31371-19.html
vendored
Normal file
@@ -0,0 +1,5 @@
|
||||
<html><body>Ketra's Messenger Wahkan:<br>
|
||||
What are you doing, dear comrade? Please, attack the Varka Silenos and bring us <font color="LEVEL">300 badges of grunts, 300 badges of officers, 200 badges of captains and the Totem of Valor</font>! This totem can be obtained by fulfilling the <font color="LEVEL">Prove your Courage</font> quest, a mission assigned by Hierarch Kadun Zu Ketra. You don't want to quit, do you?<br>
|
||||
<a action="bypass -h Quest Q00605_AllianceWithKetraOrcs 31371-12a.html">"I'll destroy the enemy!"</a><br>
|
||||
<a action="bypass -h Quest Q00605_AllianceWithKetraOrcs 31371-25.html">"I want to quit."</a>
|
||||
</body></html>
|
4
trunk/dist/game/data/scripts/quests/Q00605_AllianceWithKetraOrcs/31371-20.html
vendored
Normal file
4
trunk/dist/game/data/scripts/quests/Q00605_AllianceWithKetraOrcs/31371-20.html
vendored
Normal file
@@ -0,0 +1,4 @@
|
||||
<html><body>Ketra's Messenger Wahkan:<br>
|
||||
Ha! That's wonderful! Those arrogant Varka Silenos have tasted Orcish Steel! Ha! Keep up the good work!<br>
|
||||
<a action="bypass -h Quest Q00605_AllianceWithKetraOrcs 31371-21.html">"Here are the badges."</a>
|
||||
</body></html>
|
4
trunk/dist/game/data/scripts/quests/Q00605_AllianceWithKetraOrcs/31371-21.html
vendored
Normal file
4
trunk/dist/game/data/scripts/quests/Q00605_AllianceWithKetraOrcs/31371-21.html
vendored
Normal file
@@ -0,0 +1,4 @@
|
||||
<html><body>Ketra's Messenger Wahkan:<br>
|
||||
You're a most noble Warrior, friend of the Ketra! A true hero to our people! Please accept this <font color="LEVEL">Mark of Ketra's Alliance - Level 4</font>! Now Gatekeeper Kurfa will teleport you to nearby villages!<br>
|
||||
There is but one level of trust left for you to attain!
|
||||
</body></html>
|
5
trunk/dist/game/data/scripts/quests/Q00605_AllianceWithKetraOrcs/31371-22.html
vendored
Normal file
5
trunk/dist/game/data/scripts/quests/Q00605_AllianceWithKetraOrcs/31371-22.html
vendored
Normal file
@@ -0,0 +1,5 @@
|
||||
<html><body>Ketra's Messenger Wahkan:<br>
|
||||
The Varka Silenos are doomed, just fight a little longer! You must try harder! Attack them and bring back <font color="LEVEL">400 badges of grunts, 400 badges of officers and 200 badges of captains</font>, as well as a <font color="LEVEL">Totem of Wisdom</font>. The Totem of Wisdom can be obtained by fulfilling the <font color="LEVEL">Slay the Enemy Commander</font> quest, a mission assigned by <font color="LEVEL">Hierarch Kadun Zu Ketra</font>. We have faith in you!<br>
|
||||
<a action="bypass -h Quest Q00605_AllianceWithKetraOrcs 31371-12a.html">"I'll destroy the enemy!"</a><br>
|
||||
<a action="bypass -h Quest Q00605_AllianceWithKetraOrcs 31371-25.html">"I want to quit."</a>
|
||||
</body></html>
|
3
trunk/dist/game/data/scripts/quests/Q00605_AllianceWithKetraOrcs/31371-23.html
vendored
Normal file
3
trunk/dist/game/data/scripts/quests/Q00605_AllianceWithKetraOrcs/31371-23.html
vendored
Normal file
@@ -0,0 +1,3 @@
|
||||
<html><body>Ketra's Messenger Wahkan:<br>
|
||||
Excellent work! Please accept this <font color="LEVEL">Mark of Ketra's Alliance - Level 5</font>! This is the highest honor of trust that we Ketra bestow! You are now allowed to purchase specialty items and teleport directly to the nearest battlefield with the assistance of Gatekeeper Kurfa. Congratulations!
|
||||
</body></html>
|
5
trunk/dist/game/data/scripts/quests/Q00605_AllianceWithKetraOrcs/31371-24.html
vendored
Normal file
5
trunk/dist/game/data/scripts/quests/Q00605_AllianceWithKetraOrcs/31371-24.html
vendored
Normal file
@@ -0,0 +1,5 @@
|
||||
<html><body>Ketra's Messenger Wahkan:<br>
|
||||
You're the best friend the Ketra ever had! There is no higher honor we can bestow upon you! What are you thinking, my friend?<br>
|
||||
<a action="bypass -h Quest Q00605_AllianceWithKetraOrcs 31371-12b.html">"I'll keep my friendship with the Ketra!"</a><br>
|
||||
<a action="bypass -h Quest Q00605_AllianceWithKetraOrcs 31371-25.html">"I quit."</a>
|
||||
</body></html>
|
4
trunk/dist/game/data/scripts/quests/Q00605_AllianceWithKetraOrcs/31371-25.html
vendored
Normal file
4
trunk/dist/game/data/scripts/quests/Q00605_AllianceWithKetraOrcs/31371-25.html
vendored
Normal file
@@ -0,0 +1,4 @@
|
||||
<html><body>Ketra's Messenger Wahkan:<br>
|
||||
How can you leave us like this?! Don't be a fool! You would sever our relationship, after all we've been through?! Are you a fool? Think carefully, my friend! Such decisions are irreversible!<br>
|
||||
<a action="bypass -h Quest Q00605_AllianceWithKetraOrcs 31371-26.html">"I truly quit."</a>
|
||||
</body></html>
|
3
trunk/dist/game/data/scripts/quests/Q00605_AllianceWithKetraOrcs/31371-26.html
vendored
Normal file
3
trunk/dist/game/data/scripts/quests/Q00605_AllianceWithKetraOrcs/31371-26.html
vendored
Normal file
@@ -0,0 +1,3 @@
|
||||
<html><body>Ketra's Messenger Wahkan:<br>
|
||||
You are no longer our friend! Get out of my sight!
|
||||
</body></html>
|
333
trunk/dist/game/data/scripts/quests/Q00605_AllianceWithKetraOrcs/Q00605_AllianceWithKetraOrcs.java
vendored
Normal file
333
trunk/dist/game/data/scripts/quests/Q00605_AllianceWithKetraOrcs/Q00605_AllianceWithKetraOrcs.java
vendored
Normal file
@@ -0,0 +1,333 @@
|
||||
/*
|
||||
* 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.Q00605_AllianceWithKetraOrcs;
|
||||
|
||||
import java.util.HashMap;
|
||||
import java.util.Map;
|
||||
|
||||
import com.l2jserver.gameserver.enums.QuestSound;
|
||||
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;
|
||||
|
||||
/**
|
||||
* Alliance with Ketra Orcs (605)
|
||||
* @author malyelfik
|
||||
*/
|
||||
public class Q00605_AllianceWithKetraOrcs extends Quest
|
||||
{
|
||||
private static class DropInfo
|
||||
{
|
||||
private final int _chance;
|
||||
private final int _minCond;
|
||||
private final int _itemId;
|
||||
|
||||
public DropInfo(int chance, int minCond)
|
||||
{
|
||||
_chance = chance;
|
||||
_minCond = minCond;
|
||||
switch (_minCond)
|
||||
{
|
||||
case 1:
|
||||
_itemId = VARKA_BADGE_SOLDIER;
|
||||
break;
|
||||
case 2:
|
||||
_itemId = VARKA_BADGE_OFFICER;
|
||||
break;
|
||||
default:
|
||||
_itemId = VARKA_BADGE_CAPTAIN;
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
public int getMinCond()
|
||||
{
|
||||
return _minCond;
|
||||
}
|
||||
|
||||
public int getChance()
|
||||
{
|
||||
return _chance;
|
||||
}
|
||||
|
||||
public int getItemId()
|
||||
{
|
||||
return _itemId;
|
||||
}
|
||||
}
|
||||
|
||||
// NPC
|
||||
private static final int WAHKAN = 31371;
|
||||
// Monsters
|
||||
private static final Map<Integer, DropInfo> MOBS = new HashMap<>();
|
||||
static
|
||||
{
|
||||
MOBS.put(21350, new DropInfo(500, 1)); // Varka Silenos Recruit
|
||||
MOBS.put(21351, new DropInfo(500, 1)); // Varka Silenos Footman
|
||||
MOBS.put(21353, new DropInfo(509, 1)); // Varka Silenos Scout
|
||||
MOBS.put(21354, new DropInfo(521, 1)); // Varka Silenos Hunter
|
||||
MOBS.put(21355, new DropInfo(519, 1)); // Varka Silenos Shaman
|
||||
MOBS.put(21357, new DropInfo(500, 2)); // Varka Silenos Priest
|
||||
MOBS.put(21358, new DropInfo(500, 2)); // Varka Silenos Warrior
|
||||
MOBS.put(21360, new DropInfo(509, 2)); // Varka Silenos Medium
|
||||
MOBS.put(21361, new DropInfo(518, 2)); // Varka Silenos Magus
|
||||
MOBS.put(21362, new DropInfo(518, 2)); // Varka Silenos Officer
|
||||
MOBS.put(21364, new DropInfo(527, 2)); // Varka Silenos Seer
|
||||
MOBS.put(21365, new DropInfo(500, 3)); // Varka Silenos Great Magus
|
||||
MOBS.put(21366, new DropInfo(500, 3)); // Varka Silenos General
|
||||
MOBS.put(21368, new DropInfo(508, 3)); // Varka Silenos Great Seer
|
||||
MOBS.put(21369, new DropInfo(628, 2)); // Varka's Commander
|
||||
MOBS.put(21370, new DropInfo(604, 2)); // Varka's Elite Guard
|
||||
MOBS.put(21371, new DropInfo(627, 3)); // Varka's Head Magus
|
||||
MOBS.put(21372, new DropInfo(604, 3)); // Varka's Head Guard
|
||||
MOBS.put(21373, new DropInfo(649, 3)); // Varka's Prophet
|
||||
MOBS.put(21374, new DropInfo(626, 3)); // Prophet's Guard
|
||||
MOBS.put(21375, new DropInfo(626, 3)); // Disciple of Prophet
|
||||
}
|
||||
// Items
|
||||
private static final int VARKA_BADGE_SOLDIER = 7216;
|
||||
private static final int VARKA_BADGE_OFFICER = 7217;
|
||||
private static final int VARKA_BADGE_CAPTAIN = 7218;
|
||||
private static final int VALOR_TOTEM = 7219;
|
||||
private static final int WISDOM_TOTEM = 7220;
|
||||
private static final int[] KETRA_MARKS =
|
||||
{
|
||||
7211, // Mark of Ketra's Alliance - Level 1
|
||||
7212, // Mark of Ketra's Alliance - Level 2
|
||||
7213, // Mark of Ketra's Alliance - Level 3
|
||||
7214, // Mark of Ketra's Alliance - Level 4
|
||||
7215, // Mark of Ketra's Alliance - Level 5
|
||||
};
|
||||
private static final int[] VARKA_MARKS =
|
||||
{
|
||||
7221, // Mark of Varka's Alliance - Level 1
|
||||
7222, // Mark of Varka's Alliance - Level 2
|
||||
7223, // Mark of Varka's Alliance - Level 3
|
||||
7224, // Mark of Varka's Alliance - Level 4
|
||||
7225, // Mark of Varka's Alliance - Level 5
|
||||
};
|
||||
// Misc
|
||||
private static final int MIN_LEVEL = 74;
|
||||
private static final int[] SOLDIER_BADGE_COUNT =
|
||||
{
|
||||
100, // cond 1
|
||||
200, // cond 2
|
||||
300, // cond 3
|
||||
300, // cond 4
|
||||
400, // cond 5
|
||||
};
|
||||
private static final int[] OFFICER_BADGE_COUNT =
|
||||
{
|
||||
0, // cond 1
|
||||
100, // cond 2
|
||||
200, // cond 3
|
||||
300, // cond 4
|
||||
400, // cond 5
|
||||
};
|
||||
private static final int[] CAPTAIN_BADGE_COUNT =
|
||||
{
|
||||
0, // cond 1
|
||||
0, // cond 2
|
||||
100, // cond 3
|
||||
200, // cond 4
|
||||
200, // cond 5
|
||||
};
|
||||
|
||||
public Q00605_AllianceWithKetraOrcs()
|
||||
{
|
||||
super(605, Q00605_AllianceWithKetraOrcs.class.getSimpleName(), "Alliance with Ketra Orcs");
|
||||
addStartNpc(WAHKAN);
|
||||
addTalkId(WAHKAN);
|
||||
addKillId(MOBS.keySet());
|
||||
registerQuestItems(VARKA_BADGE_SOLDIER, VARKA_BADGE_OFFICER, VARKA_BADGE_CAPTAIN);
|
||||
}
|
||||
|
||||
private boolean canGetItem(QuestState st, int itemId)
|
||||
{
|
||||
int count = 0;
|
||||
switch (itemId)
|
||||
{
|
||||
case VARKA_BADGE_SOLDIER:
|
||||
count = SOLDIER_BADGE_COUNT[st.getCond() - 1];
|
||||
break;
|
||||
case VARKA_BADGE_OFFICER:
|
||||
count = OFFICER_BADGE_COUNT[st.getCond() - 1];
|
||||
break;
|
||||
case VARKA_BADGE_CAPTAIN:
|
||||
count = CAPTAIN_BADGE_COUNT[st.getCond() - 1];
|
||||
break;
|
||||
}
|
||||
if (st.getQuestItemsCount(itemId) < count)
|
||||
{
|
||||
return true;
|
||||
}
|
||||
return false;
|
||||
}
|
||||
|
||||
@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 "31371-12a.html":
|
||||
case "31371-12b.html":
|
||||
case "31371-25.html":
|
||||
break;
|
||||
case "31371-04.htm":
|
||||
if (hasAtLeastOneQuestItem(player, VARKA_MARKS))
|
||||
{
|
||||
return "31371-03.htm";
|
||||
}
|
||||
st.setState(State.STARTED);
|
||||
st.playSound(QuestSound.ITEMSOUND_QUEST_ACCEPT);
|
||||
for (int i = 0; i < KETRA_MARKS.length; i++)
|
||||
{
|
||||
if (st.hasQuestItems(KETRA_MARKS[i]))
|
||||
{
|
||||
st.setCond(i + 2);
|
||||
return "31371-0" + (i + 5) + ".htm";
|
||||
}
|
||||
}
|
||||
st.setCond(1);
|
||||
break;
|
||||
case "31371-12.html":
|
||||
if (st.getQuestItemsCount(VARKA_BADGE_SOLDIER) < SOLDIER_BADGE_COUNT[0])
|
||||
{
|
||||
return getNoQuestMsg(player);
|
||||
}
|
||||
st.takeItems(VARKA_BADGE_SOLDIER, -1);
|
||||
st.giveItems(KETRA_MARKS[0], 1);
|
||||
st.setCond(2, true);
|
||||
break;
|
||||
case "31371-15.html":
|
||||
if ((st.getQuestItemsCount(VARKA_BADGE_SOLDIER) < SOLDIER_BADGE_COUNT[1]) || (st.getQuestItemsCount(VARKA_BADGE_OFFICER) < OFFICER_BADGE_COUNT[1]))
|
||||
{
|
||||
return getNoQuestMsg(player);
|
||||
}
|
||||
takeItems(player, -1, VARKA_BADGE_SOLDIER, VARKA_BADGE_OFFICER, KETRA_MARKS[0]);
|
||||
st.giveItems(KETRA_MARKS[1], 1);
|
||||
st.setCond(3, true);
|
||||
break;
|
||||
case "31371-18.html":
|
||||
if ((st.getQuestItemsCount(VARKA_BADGE_SOLDIER) < SOLDIER_BADGE_COUNT[2]) || (st.getQuestItemsCount(VARKA_BADGE_OFFICER) < OFFICER_BADGE_COUNT[2]) || (st.getQuestItemsCount(VARKA_BADGE_CAPTAIN) < CAPTAIN_BADGE_COUNT[2]))
|
||||
{
|
||||
return getNoQuestMsg(player);
|
||||
}
|
||||
takeItems(player, -1, VARKA_BADGE_SOLDIER, VARKA_BADGE_OFFICER, VARKA_BADGE_CAPTAIN, KETRA_MARKS[1]);
|
||||
st.giveItems(KETRA_MARKS[2], 1);
|
||||
st.setCond(4, true);
|
||||
break;
|
||||
case "31371-21.html":
|
||||
if (!st.hasQuestItems(VALOR_TOTEM) || (st.getQuestItemsCount(VARKA_BADGE_SOLDIER) < SOLDIER_BADGE_COUNT[3]) || (st.getQuestItemsCount(VARKA_BADGE_OFFICER) < OFFICER_BADGE_COUNT[3]) || (st.getQuestItemsCount(VARKA_BADGE_CAPTAIN) < CAPTAIN_BADGE_COUNT[3]))
|
||||
{
|
||||
return getNoQuestMsg(player);
|
||||
}
|
||||
takeItems(player, -1, VARKA_BADGE_SOLDIER, VARKA_BADGE_OFFICER, VARKA_BADGE_CAPTAIN, VALOR_TOTEM, KETRA_MARKS[2]);
|
||||
st.giveItems(KETRA_MARKS[3], 1);
|
||||
st.setCond(5, true);
|
||||
break;
|
||||
case "31371-26.html":
|
||||
takeItems(player, -1, KETRA_MARKS);
|
||||
takeItems(player, -1, VALOR_TOTEM, WISDOM_TOTEM);
|
||||
st.exitQuest(true, true);
|
||||
break;
|
||||
default:
|
||||
htmltext = null;
|
||||
break;
|
||||
}
|
||||
return htmltext;
|
||||
}
|
||||
|
||||
@Override
|
||||
public String onKill(L2Npc npc, L2PcInstance killer, boolean isSummon)
|
||||
{
|
||||
final L2PcInstance member = getRandomPartyMemberState(killer, State.STARTED);
|
||||
if (member != null)
|
||||
{
|
||||
final QuestState st = getQuestState(member, false);
|
||||
final DropInfo info = MOBS.get(npc.getId());
|
||||
if ((st.getCond() >= info.getMinCond()) && (st.getCond() < 6) && canGetItem(st, info.getItemId()) && (getRandom(1000) < info.getChance()))
|
||||
{
|
||||
st.giveItems(info.getItemId(), 1);
|
||||
}
|
||||
}
|
||||
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) ? "31371-01.htm" : "31371-02.htm";
|
||||
break;
|
||||
case State.STARTED:
|
||||
switch (st.getCond())
|
||||
{
|
||||
case 1:
|
||||
htmltext = (st.getQuestItemsCount(VARKA_BADGE_SOLDIER) >= SOLDIER_BADGE_COUNT[0]) ? "31371-11.html" : "31371-10.html";
|
||||
break;
|
||||
case 2:
|
||||
htmltext = (st.hasQuestItems(KETRA_MARKS[0]) && (st.getQuestItemsCount(VARKA_BADGE_SOLDIER) >= SOLDIER_BADGE_COUNT[1]) && (st.getQuestItemsCount(VARKA_BADGE_OFFICER) >= OFFICER_BADGE_COUNT[1])) ? "31371-14.html" : "31371-13.html";
|
||||
break;
|
||||
case 3:
|
||||
htmltext = (st.hasQuestItems(KETRA_MARKS[1]) && (st.getQuestItemsCount(VARKA_BADGE_SOLDIER) >= SOLDIER_BADGE_COUNT[2]) && (st.getQuestItemsCount(VARKA_BADGE_OFFICER) >= OFFICER_BADGE_COUNT[2]) && (st.getQuestItemsCount(VARKA_BADGE_CAPTAIN) >= CAPTAIN_BADGE_COUNT[2])) ? "31371-17.html" : "31371-16.html";
|
||||
break;
|
||||
case 4:
|
||||
htmltext = (hasQuestItems(player, KETRA_MARKS[2], VALOR_TOTEM) && (st.getQuestItemsCount(VARKA_BADGE_SOLDIER) >= SOLDIER_BADGE_COUNT[3]) && (st.getQuestItemsCount(VARKA_BADGE_OFFICER) >= OFFICER_BADGE_COUNT[3]) && (st.getQuestItemsCount(VARKA_BADGE_CAPTAIN) >= CAPTAIN_BADGE_COUNT[3])) ? "31371-20.html" : "31371-19.html";
|
||||
break;
|
||||
case 5:
|
||||
if (!st.hasQuestItems(KETRA_MARKS[3]) || !st.hasQuestItems(WISDOM_TOTEM) || (st.getQuestItemsCount(VARKA_BADGE_SOLDIER) < SOLDIER_BADGE_COUNT[4]) || (st.getQuestItemsCount(VARKA_BADGE_OFFICER) < OFFICER_BADGE_COUNT[4]) || (st.getQuestItemsCount(VARKA_BADGE_CAPTAIN) < CAPTAIN_BADGE_COUNT[4]))
|
||||
{
|
||||
return "31371-22.html";
|
||||
}
|
||||
st.setCond(6, true);
|
||||
takeItems(player, -1, VARKA_BADGE_SOLDIER, VARKA_BADGE_OFFICER, VARKA_BADGE_CAPTAIN, WISDOM_TOTEM, KETRA_MARKS[3]);
|
||||
st.giveItems(KETRA_MARKS[4], 1);
|
||||
htmltext = "31371-23.html";
|
||||
break;
|
||||
case 6:
|
||||
if (st.hasQuestItems(KETRA_MARKS[4]))
|
||||
{
|
||||
htmltext = "31371-24.html";
|
||||
}
|
||||
break;
|
||||
}
|
||||
break;
|
||||
}
|
||||
return htmltext;
|
||||
}
|
||||
}
|
Reference in New Issue
Block a user