Trial of the Pilgrim
- ID
- 215
- Название
- Trial of the Pilgrim
- start_npcs_json
- [30648]
- npc_ids_json
- [27116,27117,27118,30036,30117,30362,30550,30571,30612,30648,30649,30650,30651,30652]
- constants_json
- {"SANTIAGO":30648,"TANAPI":30571,"ANCESTOR_MARTANKUS":30649,"GAURI_TWINKLEROCK":30550,"DORF":30651,"GERALD":30650,"PRIMOS":30117,"PETRON":30036,"ANDELLIA":30362,"URUHA":30652,"CASIAN":30612,"LAVA_SALAMANDER":27116,"NAHIR":27117,"BLACK_WILLOW":27118,"BOOK_OF_SAGE":2722,"VOUCHER_OF_TRIAL":2723,"SPIRIT_OF_FLAME":2724,"ESSENCE_OF_FLAME":2725,"BOOK_OF_GERALD":2726,"GRAY_BADGE":2727,"PICTURE_OF_NAHIR":2728,"HAIR_OF_NAHIR":2729,"STATUE_OF_EINHASAD":2730,"BOOK_OF_DARKNESS":2731,"DEBRIS_OF_WILLOW":2732,"TAG_OF_RUMOR":2733,"MARK_OF_PILGRIM":2721,"DIMENSIONAL_DIAMOND":7562}
- Статус разбора
- metadata_only; dynamic Java conditions/rewards retained in source; unresolved starts: []
- Источник
- game/data/scripts/quests/Q00215_TrialOfThePilgrim/Q00215_TrialOfThePilgrim.java
NPC квеста
| ID | Название | Старт квеста | Уровень |
|---|---|---|---|
| 27116 | Lava Salamander | Нет | 35 |
| 27117 | Nahir | Нет | 35 |
| 27118 | Black Willow | Нет | 30 |
| 30036 | Petron | Нет | 70 |
| 30117 | Primos | Нет | 70 |
| 30362 | Andellia | Нет | 70 |
| 30550 | Gauri Twinklerock | Нет | 70 |
| 30571 | Tanapi | Нет | 70 |
| 30612 | Casian | Нет | 70 |
| 30648 | Santiago | Да | 70 |
| 30649 | Ancestor Martankus | Нет | 70 |
| 30650 | Gerald | Нет | 70 |
| 30651 | Dorf | Нет | 70 |
| 30652 | Uruha | Нет | 70 |
Условия уровней: выражения из Java
else if (player.getLevel() < 35) if (player.getLevel() < 36)
Выдача предметов, адены и опыта: выражения из Java
giveItems(player, VOUCHER_OF_TRIAL, 1); giveItems(player, DIMENSIONAL_DIAMOND, DF_REWARD_35.get(player.getPlayerClass().getId())); giveItems(player, SPIRIT_OF_FLAME, 1); giveItems(player, BOOK_OF_GERALD, 1); giveItems(player, BOOK_OF_DARKNESS, 1); giveItems(player, MARK_OF_PILGRIM, 1); addExpAndSp(player, 77382, 16000); giveItems(player, TAG_OF_RUMOR, 1); giveItems(player, GRAY_BADGE, 1); giveAdena(player, 100000, true); giveItems(player, PICTURE_OF_NAHIR, 1); giveItems(player, STATUE_OF_EINHASAD, 1); giveItems(player, BOOK_OF_SAGE, 1); giveItems(player, ESSENCE_OF_FLAME, 1); giveItems(player, HAIR_OF_NAHIR, 1); giveItems(player, DEBRIS_OF_WILLOW, 1);
Квесты содержат динамические условия Java. Выражения выдачи включают промежуточные предметы, варианты и случайные награды; это не гарантированная награда. Константы приведены выше. Полные условия — в исходнике.
Тексты квеста
[30036-01.htm] Priest Petron: So you came to such a remote island to find the true religion of Einhasad... I came here many years ago after I incurred the hatred of the High Priests. Apparently I was trying to clarify the truth too specifically. Anyway, I much prefer the liberal atmosphere here over the corrupt inner circle. ...I have so much to tell you. But first I have a favor I must ask... Please get rid of the malignant spirit Nahir coiling in the Elven Ruins. This will enhance your learning. Please, will you deal with Nahir?
[30036-02.htm] Priest Petron: I beg you! Please get rid of the malignant spirit Nahir coiling in the Elven Ruins. This will enhance your learning.
[30036-03.htm] Priest Petron: Nahir... May his poor spirit rest in peace... Thank you. Now I will tell you Nahir's story. He was once a faithful follower of Einhasad. But while he was helping his friend who was a follower of Shilen, he incurred Einhasad's wrath and was turned into a monster. Until this day he roamed the dark underground. Are you surprised to learn that Einhasad, who is known as the Goddess of sacrifice and life, has in fact the opposite traits of jealousy and destruction? Of course the High Priests only care to mention the side of sacrifice and life... Such is the nature of the truth you seek. It's a bitter truth, isn't it? But that is not the end of the story. I am sure you seek the truth about Eva as well? In that case you should go and see Andellia of the Elven Village.
[30036-04.htm] Priest Petron: Your journey toward the truth has only just begun. You must visit Andellia of the Elven Village and hear what she knows about Eva. May Einhasad protect you on your way...
[30117-01.htm] Priest Primos: So you seek the knowledge of Einhasad? I'm afraid I can't help you. I am embarrassed by the faithful. There are many truths concealed in the shrine's interest... There is nothing I can do about it... If you want to know about Einhasad you should go to see Priest Petron of Talking Island.
[30117-02.htm] Priest Primos: I am not worthy to teach the truth of Einhasad. If you wish to learn the truth about the tenets of light, go and meet Priest Petron of Talking Island.
[30362-01.htm] Andellia: Did you bring a message from Santiago? In search of the truth, are you? Your timing could not be better. I have a favor to ask. There is a Priestess named Uruha in the Neutral Zone. She invaded this forest with her spirits known as Black Willows. You must destroy these spirits. The Black Willows are located near the Waterfalls in the northern part of the Neutral Zone. After destroying them, go to Uruha and warn her not to come to the Elven Forest ever again. After you do this we can discuss what you seek.
[30362-01a.htm] Andellia: Dear pilgrim, seeker of divine truth... Were you sent by the hermit Santiago? There is a task with which I could use your assistance, but I fear that you aren't yet experienced enough to complete it. Please come back to me when you have gained more experience.
[30362-02.htm] Andellia: You must destroy the Black Willow that Uruha has brought. They are located near the waterfall in the northern part of the Neutral Zone. After destroying them, go to Uruha and warn her not to come to the Elven Forest again. We will discuss God after you accomplish this.
[30362-02a.htm] Andellia: The person responsible for this is a Dark Elf called Uruha. Find her and warn her not to come to the Elven Forest again.
[30362-03.htm] Andellia: How dare you bring that blasphemous book here...! Burn it now! Burn the Book of Darkness Do not burn the Book of Darkness
[30362-04.htm] Andellia: You will soon regret your decision! You befoul this Holy Land with your presence! Go and play with that old nag Elder Casian in the Wastelands!
[30362-05.htm] Andellia: Good work. Your soul has remained pure throughout your ordeal. We owe you a debt of gratitude for expelling those foul spirits from this holy forest. About the truth of God you're looking for... It will be better to talk to Wiseman Casian of the Wastelands. He can be abrupt, but knows many stories of God that others do not know. He is even familiar with the knowledge known as 'vice.'
[30362-06.htm] Andellia: Go to the Wastelands and meet Wiseman Casian. You must take what he says with a grain of salt.
[30362-07.htm] Andellia: There are still malignant spirits about! Please expel them for us!
[30550-01.htm] Gauri Twinklerock: Ah, you wish to learn the ways of Maphr? Priest of the Earth Gerald is regarded as one of the best theologians around... The vagabond named Dorf has been overheard saying that he knows the secret of Maphr. You should speak with both of them...
[30550-02.htm] Gauri Twinklerock: At this time of day you will probably find Priest of the Earth Gerald near the entrance of the village counting his money. He is somewhat irritable when he is busy so don't bother him too much. Wanderer Dorf can probably be found at the opposite end of the village. You can bother him as much as you like.
[30571-01.htm] Seer Tanapi: Santiago... I am very weary of being sent these amateurs! Why would a person of my stature be required to deal with such greenhorns! Oh, well! I guess I have no choice... If you truly wish to understand the God of Flame then you must visit the ancestors' altar in the Cave of Trials and ask Ancestor Martankus. If you are sincere, he will respond to you.
[30571-02.htm] Seer Tanapi: Shouldn't you be on you way to the ancestors' altar in the Cave of Trials? You must go there and pray to Ancestor Martankus. What, are you afraid now? If that's the case I wouldn't blame you. Just go back and tell Santiago that you are too scared to complete the task...
[30571-03.htm] Seer Tanapi: That is quite a surprise! You say that you felt the flames of Pa'agrio? Amazing! To tell you the truth, I wasn't very hopeful when I sent you to the Cave of Trials. These days, success seems rare from one so young as you... I shall remember this. So you want to learn about Maphr? You should go and see Gauri Twinklerock of the Dwarven Village! I hope that you will find the light of truth at the end of your journey! Tejakar Pa'agrio!
[30612-01.htm] Elder Casian: Hello, my inquisitive friend. My name is Casian, known to some as 'the Sage of the Wastelands'. The Elves and the Dark Elves that you have met have told you things that could be true or not. The nature of the gods is not known to mankind, and even they are only one small part of a very big universe... The gods each have a role to play. We cannot understand their intentions... We shouldn't make things more difficult than they are. We must each just do the best we can and go about our daily lives... I hope my lecture hasn't bored you. Take this book and return to Hermit Santiago. After all, this whole thing was his idea to begin with.
[30612-02.htm] Elder Casian: I will never understand the Human propensity to assign a value of right or wrong to everything, even the behavior of the gods! The worst offenders are the Priests... There is no crime as long as we act according to our feelings, am I right? After all, we are just the gods creations... So even if there is a crime, it is the gods' fault, not ours! Well, I've said enough. Please go back to Hermit Santiago.
[30648-01.htm] Hermit Santiago: To properly use the power of the gods, you must first understand their nature. That learning process can be most intense... Many of a higher level than yours have tried and failed. I think it would be too hard for you to endure at this moment. Come back after you have advanced your skills. (This quest may only be undertaken by a character of level 35 and above.)
[30648-02.htm] Hermit Santiago: I only teach those who live their lives in service to the gods! (This quest may only be undertaken by Clerics, Oracles, Shilen Oracles, and Orc Shamans.)
[30648-03.htm] Hermit Santiago: To properly use the powers of the gods, you must first understand their nature. That learning process can be quite intense. Many have tried and failed... What is your decision? Will you accept my teachings? Say you will take the Trial of the Pilgrim
[30648-04.htm] Hermit Santiago: I will now impart to you a great truth. The people of this land have distorted and twisted the myths of their gods to suit their own financial and political ends. This is probably also true about the myths that you were taught... I teach a method of purging your mind of all the indoctrination that has come before, and learning the secrets of the gods afresh. Would you care to learn from me? "I shall learn from the beginning."
[30648-04a.htm] Hermit Santiago: All right, I'll tell you. People only care about their own interests and are all too ready to spread false myths to further their own ends. I'm sure that the myths you know are no different . . . My advice is to forget everything you've learned so far and re-learn the story of the gods all over again, from the begining. Do you think you can do it? Wait, before you answer, take this Dimension Diamond first. You can trade it to the village gatekeeper for something special that may help you on your journey. Now, will you answer me? "I would like to learn all over again."
[30648-05.htm] Hermit Santiago: Now listen carefully. First, venture north to the land of the Orcs and meet with Seer Tanapi. He will tell you about their god, Pa'agrio. Continue listening to the explanation
[30648-06.htm] Hermit Santiago: Next, go to the land of the Dwarves and meet with Gauri Twinklerock. Ask her how you may learn the teachings of Maphr. Continue listening to the explanation
[30648-07.htm] Hermit Santiago: After you have completed your studies of Maphr, you must return to the land of the Humans and go to Giran Castle Town. Seek out Priest Primos, and he will lead you to a greater understanding of Einhasad. Continue listening to the explanation
[30648-08.htm] Hermit Santiago: Last of all, you must go to the land of the Elves. Inside the Elven Village is the Mother Tree, one of the purest forms of energy on earth. You will meet under this large and beautiful tree with Andellia, one of the protectors of the Mother Tree. She can teach you about Eva and Shilen. Return
[30648-09.htm] Hermit Santiago: Do you understand? You must meet with Seer Tanapi of the Orc Village, Gauri Twinklerock of the Dwarven Village, Father Primoz of Giran Castle Town, and Andellia of the Elven Village! In that order! Discern from them their ideas on the nature of the gods... You may find this trial unsettling and shocking, but as a seeker of the truth you must endure.
[30648-10.htm] Hermit Santiago: Ah, there's the glimmer in your eyes! You still have far to go and much to learn about the nature of truth, but this is a start. Accept this Mark of Pilgrim. Remember, though, this is not the end of your studies. It is not even the beginning of the end. But it is, I perceive, the end of the beginning. Fare you well!
[30649-01.htm] Ancestor Martankus: I am Martankus of the Hestui tribe! Although my body perished in battle thousands of years ago, my spirit watches over my descendants. This place is a sacred tomb housing the remains of the greatest heroes of the seven tribes. Young Orcs still come here to test their courage, strength and skill! You come seeking the true essence of Pa'agrio? Words alone fall far short. For true enlightenment, you must seek and return with the Essence of Flame. Obtain it from the Lava Salamanders of the Forgotten Temple, located in lands far, far to the west.
[30649-02.htm] Ancestor Martankus: The true essence of Pa'agrio cannot be explained by words alone! To properly understand it, you must obtain the Flame of Essence! If you dare, seek out the Lava Salamanders of the Forgotten Temple, located in lands far, far to the west.
[30649-03.htm] Ancestor Martankus: I see that you have brought the Essence of Flame! Now, to understand Pa'agrio's Flame you must swallow the Essence of Flame! Swallow the Essence of Flame
[30649-04.htm] Ancestor Martankus: So hot! So hot! My body feels as if it will burst into flame. Aieee! Wait... what's this? The Flame of Combative Spirit? Truly, this is the mind possessed by the warriors of old... What is that, there in the distance? What do my old eyes perceive? Oh! Oh! Stay away! The heat, the heat! Ah! Ah, I see... Is this the Flame of Destruction, which engulfs everything in its path and leaves only black ashes? Is this the end? ... No, there is something more! I see a small flame burning bright in the ash. It is the one... the most sacred flame of all! It is the Flame of Life, the vital energy that moves the whole world... (O insignificant creature, would you venture to see and hear more of my mind's thoughts? You cannot! Your frail mortal frame cannot bear more of this inferno! Farewell!)
[30650-01.htm] Priest of the Earth Gerald: You have come to the right place! Maphr is my specialty! 6 years in the seminary, and 10 years of self-guided research after that... I feel that I have learned practically all there is to know about Maphr. I could use additional funds to further my research... Would you consider making a small donation? I will teach you everything I know about Maphr for a mere 100,000 adena. What a deal, er, I mean, blessing it is! Donate 100,000 adena. Do not make a donation.
[30650-02.htm] Priest of the Earth Gerald: What a generous donation! Maphr will surely be pleased, and the world will be a better place thanks to you. What a wonderful investment, er, I mean, offering! Here is a book I wrote regarding the will of Maphr. Study it diligently! May the grace of Maphr be with you!
[30650-03.htm] Priest of the Earth Gerald: I suppose I was wrong about you... I had no idea you were a beggar... Now, on your way! Shoo!
[30650-04.htm] Priest of the Earth Gerald: Oh my, I didn't notice your badge! I, I just... That is... Eh, just a joke... I, I mean, I was going to keep it safe for you and return it with interest. Well I must be going!
[30651-01.htm] Wanderer Dorf: Maphr, the goddess of abundance and prosperity?! Foolish cattle, they don't know anything! Just look at the silly Dwarves in this town. They are mentally unbalanced, always dashing here and there to collect some more money. They are simply ridiculous! Miserable creatures who would even rip out their goddess' heart if it were worth money! And they don't hesitate to unearth things that should not be part of this world! Maphr is indeed the goddess of abundance and prosperity, but that also means that she is responsible for all poverty and downfalls! Why can't you see this simple fact? They have already experienced bankruptcy once before... Tsk tsk... Take this badge and take heed. Prosperity and poverty are just like the two sides of one coin!
[30651-02.htm] Wanderer Dorf: Maphr, the goddess of abundance and prosperity?! Foolish cattle, they don't know anything! Just look at the silly Dwarves in this town. They are mentally unbalanced, always dashing here and there to collect some more money. They are simply ridiculous! Miserable creatures who would even rip out their goddess' heart if it were worth money! And they don't hesitate to unearth things that should not be part of this world! Maphr is indeed the goddess of abundance and prosperity, but that also means that she is responsible for all poverty and downfalls! Why can't you see this simple fact! They have already experienced bankruptcy once before... Tsk tsk... By the way, what is that book you are holding? You bought it from Gerald? You fool! You have been deceived by him! Show him this badge. You might be able to get your money back.
[30651-03.htm] Wanderer Dorf: I have said everything that I intend to say. Now leave here and go learn of your precious Einhasad. You will probably have to go and see the Priest Primos of the Town of Giran!
[30652-01.htm] Uruha: Why are you wasting your time on them? They are just some miserable fellows who are confused by the ramblings of that hypocrite Einhasad. With help from Shilen and Gran Kain, they could live once more... You are not one of those silly followers of Eva, are you? "I only came here at the request of Andellia."
[30652-02.htm] Uruha: Ah ha! That arrogant and reckless follower of Eva! Are you blind? Isn't the indecisiveness of Eva obvious? She who is under the authority of our Goddess Shilen? Her followers are no different! Take this book. I hope it will lead you to the truth, and protect you from contamination by the reckless stupidity of Eva's followers.
[30652-03.htm] Uruha: The malignant spirit of Shilen? The devourer of innocents? Please, leave these miserable creatures alone. They have suffered enough.
Исходник условий и наград (Java)
/*
* Copyright (c) 2013 L2jMobius
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal
* in the Software without restriction, including without limitation the rights
* to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
* copies of the Software, and to permit persons to whom the Software is
* furnished to do so, subject to the following conditions:
*
* The above copyright notice and this permission notice shall be
* included in all copies or substantial portions of the Software.
*
* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
* IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
* FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
* AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY,
* WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR
* IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
*/
package quests.Q00215_TrialOfThePilgrim;
import org.l2jmobius.gameserver.entity.actor.Npc;
import org.l2jmobius.gameserver.entity.actor.Player;
import org.l2jmobius.gameserver.entity.actor.enums.player.PlayerClass;
import org.l2jmobius.gameserver.mechanics.script.Quest;
import org.l2jmobius.gameserver.mechanics.script.QuestSound;
import org.l2jmobius.gameserver.mechanics.script.QuestState;
import org.l2jmobius.gameserver.mechanics.script.State;
import org.l2jmobius.gameserver.network.serverpackets.SocialAction;
public class Q00215_TrialOfThePilgrim extends Quest
{
// NPCs
private static final int SANTIAGO = 30648;
private static final int TANAPI = 30571;
private static final int ANCESTOR_MARTANKUS = 30649;
private static final int GAURI_TWINKLEROCK = 30550;
private static final int DORF = 30651;
private static final int GERALD = 30650;
private static final int PRIMOS = 30117;
private static final int PETRON = 30036;
private static final int ANDELLIA = 30362;
private static final int URUHA = 30652;
private static final int CASIAN = 30612;
// Monsters
private static final int LAVA_SALAMANDER = 27116;
private static final int NAHIR = 27117;
private static final int BLACK_WILLOW = 27118;
// Items
private static final int BOOK_OF_SAGE = 2722;
private static final int VOUCHER_OF_TRIAL = 2723;
private static final int SPIRIT_OF_FLAME = 2724;
private static final int ESSENCE_OF_FLAME = 2725;
private static final int BOOK_OF_GERALD = 2726;
private static final int GRAY_BADGE = 2727;
private static final int PICTURE_OF_NAHIR = 2728;
private static final int HAIR_OF_NAHIR = 2729;
private static final int STATUE_OF_EINHASAD = 2730;
private static final int BOOK_OF_DARKNESS = 2731;
private static final int DEBRIS_OF_WILLOW = 2732;
private static final int TAG_OF_RUMOR = 2733;
// Rewards
private static final int MARK_OF_PILGRIM = 2721;
private static final int DIMENSIONAL_DIAMOND = 7562;
public Q00215_TrialOfThePilgrim()
{
super(215, "Trial of the Pilgrim");
registerQuestItems(BOOK_OF_SAGE, VOUCHER_OF_TRIAL, SPIRIT_OF_FLAME, ESSENCE_OF_FLAME, BOOK_OF_GERALD, GRAY_BADGE, PICTURE_OF_NAHIR, HAIR_OF_NAHIR, STATUE_OF_EINHASAD, BOOK_OF_DARKNESS, DEBRIS_OF_WILLOW, TAG_OF_RUMOR);
addStartNpc(SANTIAGO);
addTalkId(SANTIAGO, TANAPI, ANCESTOR_MARTANKUS, GAURI_TWINKLEROCK, DORF, GERALD, PRIMOS, PETRON, ANDELLIA, URUHA, CASIAN);
addKillId(LAVA_SALAMANDER, NAHIR, BLACK_WILLOW);
}
@Override
public String onEvent(String event, Npc npc, Player player)
{
String htmltext = event;
final QuestState st = getQuestState(player, false);
if (st == null)
{
return htmltext;
}
switch (event)
{
case "30648-04.htm":
{
st.startQuest();
giveItems(player, VOUCHER_OF_TRIAL, 1);
if (!player.getVariables().getBoolean("secondClassChange35", false))
{
htmltext = "30648-04a.htm";
giveItems(player, DIMENSIONAL_DIAMOND, DF_REWARD_35.get(player.getPlayerClass().getId()));
player.getVariables().set("secondClassChange35", true);
}
break;
}
case "30649-04.htm":
{
st.setCond(5, true);
takeItems(player, ESSENCE_OF_FLAME, 1);
giveItems(player, SPIRIT_OF_FLAME, 1);
break;
}
case "30650-02.htm":
{
if (getQuestItemsCount(player, 57) >= 100000)
{
playSound(player, QuestSound.ITEMSOUND_QUEST_ITEMGET);
takeItems(player, 57, 100000);
giveItems(player, BOOK_OF_GERALD, 1);
}
else
{
htmltext = "30650-03.htm";
}
break;
}
case "30652-02.htm":
{
st.setCond(15, true);
takeItems(player, DEBRIS_OF_WILLOW, 1);
giveItems(player, BOOK_OF_DARKNESS, 1);
break;
}
case "30362-04.htm":
{
st.setCond(16, true);
break;
}
case "30362-05.htm":
{
st.setCond(16, true);
takeItems(player, BOOK_OF_DARKNESS, 1);
break;
}
}
return htmltext;
}
@Override
public String onTalk(Npc npc, Player player)
{
String htmltext = getNoQuestMsg(player);
final QuestState st = getQuestState(player, true);
switch (st.getState())
{
case State.CREATED:
{
if ((player.getPlayerClass() != PlayerClass.CLERIC) && (player.getPlayerClass() != PlayerClass.ORACLE) && (player.getPlayerClass() != PlayerClass.SHILLIEN_ORACLE) && (player.getPlayerClass() != PlayerClass.ORC_SHAMAN))
{
htmltext = "30648-02.htm";
}
else if (player.getLevel() < 35)
{
htmltext = "30648-01.htm";
}
else
{
htmltext = "30648-03.htm";
}
break;
}
case State.STARTED:
{
final int cond = st.getCond();
switch (npc.getId())
{
case SANTIAGO:
{
if (cond < 17)
{
htmltext = "30648-09.htm";
}
else if (cond == 17)
{
htmltext = "30648-10.htm";
takeItems(player, BOOK_OF_SAGE, 1);
giveItems(player, MARK_OF_PILGRIM, 1);
addExpAndSp(player, 77382, 16000);
player.broadcastPacket(new SocialAction(player.getObjectId(), 3));
st.exitQuest(false, true);
}
break;
}
case TANAPI:
{
if (cond == 1)
{
htmltext = "30571-01.htm";
st.setCond(2, true);
takeItems(player, VOUCHER_OF_TRIAL, 1);
}
else if (cond < 5)
{
htmltext = "30571-02.htm";
}
else if (cond >= 5)
{
htmltext = "30571-03.htm";
if (cond == 5)
{
st.setCond(6, true);
}
}
break;
}
case ANCESTOR_MARTANKUS:
{
if (cond == 2)
{
htmltext = "30649-01.htm";
st.setCond(3, true);
}
else if (cond == 3)
{
htmltext = "30649-02.htm";
}
else if (cond == 4)
{
htmltext = "30649-03.htm";
}
break;
}
case GAURI_TWINKLEROCK:
{
if (cond == 6)
{
htmltext = "30550-01.htm";
st.setCond(7, true);
giveItems(player, TAG_OF_RUMOR, 1);
}
else if (cond > 6)
{
htmltext = "30550-02.htm";
}
break;
}
case DORF:
{
if (cond == 7)
{
htmltext = (!hasQuestItems(player, BOOK_OF_GERALD)) ? "30651-01.htm" : "30651-02.htm";
st.setCond(8, true);
takeItems(player, TAG_OF_RUMOR, 1);
giveItems(player, GRAY_BADGE, 1);
}
else if (cond > 7)
{
htmltext = "30651-03.htm";
}
break;
}
case GERALD:
{
if ((cond == 7) && !hasQuestItems(player, BOOK_OF_GERALD))
{
htmltext = "30650-01.htm";
}
else if ((cond == 8) && hasQuestItems(player, BOOK_OF_GERALD))
{
htmltext = "30650-04.htm";
playSound(player, QuestSound.ITEMSOUND_QUEST_ITEMGET);
takeItems(player, BOOK_OF_GERALD, 1);
giveAdena(player, 100000, true);
}
break;
}
case PRIMOS:
{
if (cond == 8)
{
htmltext = "30117-01.htm";
st.setCond(9, true);
}
else if (cond > 8)
{
htmltext = "30117-02.htm";
}
break;
}
case PETRON:
{
if (cond == 9)
{
htmltext = "30036-01.htm";
st.setCond(10, true);
giveItems(player, PICTURE_OF_NAHIR, 1);
}
else if (cond == 10)
{
htmltext = "30036-02.htm";
}
else if (cond == 11)
{
htmltext = "30036-03.htm";
st.setCond(12, true);
takeItems(player, HAIR_OF_NAHIR, 1);
takeItems(player, PICTURE_OF_NAHIR, 1);
giveItems(player, STATUE_OF_EINHASAD, 1);
}
else if (cond > 11)
{
htmltext = "30036-04.htm";
}
break;
}
case ANDELLIA:
{
if (cond == 12)
{
if (player.getLevel() < 36)
{
htmltext = "30362-01a.htm";
}
else
{
htmltext = "30362-01.htm";
st.setCond(13, true);
}
}
else if (cond == 13)
{
htmltext = (getRandomBoolean()) ? "30362-02.htm" : "30362-02a.htm";
}
else if (cond == 14)
{
htmltext = "30362-07.htm";
}
else if (cond == 15)
{
htmltext = "30362-03.htm";
}
else if (cond == 16)
{
htmltext = "30362-06.htm";
}
break;
}
case URUHA:
{
if (cond == 14)
{
htmltext = "30652-01.htm";
}
else if (cond == 15)
{
htmltext = "30652-03.htm";
}
break;
}
case CASIAN:
{
if (cond == 16)
{
htmltext = "30612-01.htm";
st.setCond(17, true);
takeItems(player, BOOK_OF_DARKNESS, 1);
takeItems(player, GRAY_BADGE, 1);
takeItems(player, SPIRIT_OF_FLAME, 1);
takeItems(player, STATUE_OF_EINHASAD, 1);
giveItems(player, BOOK_OF_SAGE, 1);
}
else if (cond == 17)
{
htmltext = "30612-02.htm";
}
break;
}
}
break;
}
case State.COMPLETED:
{
htmltext = getAlreadyCompletedMsg(player);
break;
}
}
return htmltext;
}
@Override
public void onKill(Npc npc, Player player, boolean isPet)
{
final QuestState st = getQuestState(player, false);
if ((st == null) || !st.isStarted())
{
return;
}
switch (npc.getId())
{
case LAVA_SALAMANDER:
{
if (st.isCond(3) && (getRandom(10) < 2))
{
giveItems(player, ESSENCE_OF_FLAME, 1);
st.setCond(4, true);
}
break;
}
case NAHIR:
{
if (st.isCond(10) && (getRandom(10) < 2))
{
giveItems(player, HAIR_OF_NAHIR, 1);
st.setCond(11, true);
}
break;
}
case BLACK_WILLOW:
{
if (st.isCond(13) && (getRandom(10) < 2))
{
giveItems(player, DEBRIS_OF_WILLOW, 1);
st.setCond(14, true);
}
break;
}
}
}
}