From bdb814e7e3df94d4f87bf8056142c935141cf2d2 Mon Sep 17 00:00:00 2001 From: MobiusDev <8391001+MobiusDevelopment@users.noreply.github.com> Date: Wed, 18 Apr 2018 20:21:57 +0000 Subject: [PATCH] Addition of Loser Priest quests. Contributed by Stayway. --- .../dist/game/data/html/item/90296.htm | 11 + .../dist/game/data/html/item/90299.htm | 11 + .../dist/game/data/html/item/90302.htm | 9 + .../data/scripts/quests/MissingQuests.txt | 3 - .../quests/Q10997_LoserPriest1/30538-01.html | 5 + .../quests/Q10997_LoserPriest1/30538-02.htm | 4 + .../quests/Q10997_LoserPriest1/30538-02a.html | 3 + .../quests/Q10997_LoserPriest1/30650-01.htm | 4 + .../quests/Q10997_LoserPriest1/30650-01a.html | 3 + .../quests/Q10997_LoserPriest1/30650-02.html | 5 + .../quests/Q10997_LoserPriest1/30650-03.html | 6 + .../quests/Q10997_LoserPriest1/30650-04.html | 6 + .../Q10997_LoserPriest1.java | 229 +++++++++++++++++ .../quests/Q10997_LoserPriest1/no-level.html | 4 + .../quests/Q10997_LoserPriest1/no-race.html | 4 + .../quests/Q10998_LoserPriest2/30650-01.html | 4 + .../quests/Q10998_LoserPriest2/30650-02.htm | 4 + .../quests/Q10998_LoserPriest2/30650-02a.html | 3 + .../quests/Q10998_LoserPriest2/30650-03.html | 5 + .../quests/Q10998_LoserPriest2/30650-04.html | 6 + .../quests/Q10998_LoserPriest2/30650-05.html | 6 + .../quests/Q10998_LoserPriest2/30650-06.html | 3 + .../Q10998_LoserPriest2.java | 214 ++++++++++++++++ .../quests/Q10998_LoserPriest2/abort.html | 3 + .../quests/Q10998_LoserPriest2/no-level.html | 4 + .../quests/Q10998_LoserPriest2/no-race.html | 4 + .../quests/Q10999_LoserPriest3/30650-01.html | 4 + .../quests/Q10999_LoserPriest3/30650-02.htm | 4 + .../quests/Q10999_LoserPriest3/30650-02a.html | 3 + .../quests/Q10999_LoserPriest3/30650-03.html | 5 + .../quests/Q10999_LoserPriest3/30650-04.html | 5 + .../quests/Q10999_LoserPriest3/30650-05.html | 3 + .../Q10999_LoserPriest3.java | 236 ++++++++++++++++++ .../quests/Q10999_LoserPriest3/abort.html | 3 + .../quests/Q10999_LoserPriest3/no-level.html | 4 + .../quests/Q10999_LoserPriest3/no-race.html | 4 + .../scripts/quests/QuestMasterHandler.java | 6 + .../game/data/spawns/Dwarf/DwarfTerritory.xml | 8 + 38 files changed, 845 insertions(+), 3 deletions(-) create mode 100644 L2J_Mobius_Classic_2.0_Zaken/dist/game/data/html/item/90296.htm create mode 100644 L2J_Mobius_Classic_2.0_Zaken/dist/game/data/html/item/90299.htm create mode 100644 L2J_Mobius_Classic_2.0_Zaken/dist/game/data/html/item/90302.htm create mode 100644 L2J_Mobius_Classic_2.0_Zaken/dist/game/data/scripts/quests/Q10997_LoserPriest1/30538-01.html create mode 100644 L2J_Mobius_Classic_2.0_Zaken/dist/game/data/scripts/quests/Q10997_LoserPriest1/30538-02.htm create mode 100644 L2J_Mobius_Classic_2.0_Zaken/dist/game/data/scripts/quests/Q10997_LoserPriest1/30538-02a.html create mode 100644 L2J_Mobius_Classic_2.0_Zaken/dist/game/data/scripts/quests/Q10997_LoserPriest1/30650-01.htm create mode 100644 L2J_Mobius_Classic_2.0_Zaken/dist/game/data/scripts/quests/Q10997_LoserPriest1/30650-01a.html create mode 100644 L2J_Mobius_Classic_2.0_Zaken/dist/game/data/scripts/quests/Q10997_LoserPriest1/30650-02.html create mode 100644 L2J_Mobius_Classic_2.0_Zaken/dist/game/data/scripts/quests/Q10997_LoserPriest1/30650-03.html create mode 100644 L2J_Mobius_Classic_2.0_Zaken/dist/game/data/scripts/quests/Q10997_LoserPriest1/30650-04.html create mode 100644 L2J_Mobius_Classic_2.0_Zaken/dist/game/data/scripts/quests/Q10997_LoserPriest1/Q10997_LoserPriest1.java create mode 100644 L2J_Mobius_Classic_2.0_Zaken/dist/game/data/scripts/quests/Q10997_LoserPriest1/no-level.html create mode 100644 L2J_Mobius_Classic_2.0_Zaken/dist/game/data/scripts/quests/Q10997_LoserPriest1/no-race.html create mode 100644 L2J_Mobius_Classic_2.0_Zaken/dist/game/data/scripts/quests/Q10998_LoserPriest2/30650-01.html create mode 100644 L2J_Mobius_Classic_2.0_Zaken/dist/game/data/scripts/quests/Q10998_LoserPriest2/30650-02.htm create mode 100644 L2J_Mobius_Classic_2.0_Zaken/dist/game/data/scripts/quests/Q10998_LoserPriest2/30650-02a.html create mode 100644 L2J_Mobius_Classic_2.0_Zaken/dist/game/data/scripts/quests/Q10998_LoserPriest2/30650-03.html create mode 100644 L2J_Mobius_Classic_2.0_Zaken/dist/game/data/scripts/quests/Q10998_LoserPriest2/30650-04.html create mode 100644 L2J_Mobius_Classic_2.0_Zaken/dist/game/data/scripts/quests/Q10998_LoserPriest2/30650-05.html create mode 100644 L2J_Mobius_Classic_2.0_Zaken/dist/game/data/scripts/quests/Q10998_LoserPriest2/30650-06.html create mode 100644 L2J_Mobius_Classic_2.0_Zaken/dist/game/data/scripts/quests/Q10998_LoserPriest2/Q10998_LoserPriest2.java create mode 100644 L2J_Mobius_Classic_2.0_Zaken/dist/game/data/scripts/quests/Q10998_LoserPriest2/abort.html create mode 100644 L2J_Mobius_Classic_2.0_Zaken/dist/game/data/scripts/quests/Q10998_LoserPriest2/no-level.html create mode 100644 L2J_Mobius_Classic_2.0_Zaken/dist/game/data/scripts/quests/Q10998_LoserPriest2/no-race.html create mode 100644 L2J_Mobius_Classic_2.0_Zaken/dist/game/data/scripts/quests/Q10999_LoserPriest3/30650-01.html create mode 100644 L2J_Mobius_Classic_2.0_Zaken/dist/game/data/scripts/quests/Q10999_LoserPriest3/30650-02.htm create mode 100644 L2J_Mobius_Classic_2.0_Zaken/dist/game/data/scripts/quests/Q10999_LoserPriest3/30650-02a.html create mode 100644 L2J_Mobius_Classic_2.0_Zaken/dist/game/data/scripts/quests/Q10999_LoserPriest3/30650-03.html create mode 100644 L2J_Mobius_Classic_2.0_Zaken/dist/game/data/scripts/quests/Q10999_LoserPriest3/30650-04.html create mode 100644 L2J_Mobius_Classic_2.0_Zaken/dist/game/data/scripts/quests/Q10999_LoserPriest3/30650-05.html create mode 100644 L2J_Mobius_Classic_2.0_Zaken/dist/game/data/scripts/quests/Q10999_LoserPriest3/Q10999_LoserPriest3.java create mode 100644 L2J_Mobius_Classic_2.0_Zaken/dist/game/data/scripts/quests/Q10999_LoserPriest3/abort.html create mode 100644 L2J_Mobius_Classic_2.0_Zaken/dist/game/data/scripts/quests/Q10999_LoserPriest3/no-level.html create mode 100644 L2J_Mobius_Classic_2.0_Zaken/dist/game/data/scripts/quests/Q10999_LoserPriest3/no-race.html diff --git a/L2J_Mobius_Classic_2.0_Zaken/dist/game/data/html/item/90296.htm b/L2J_Mobius_Classic_2.0_Zaken/dist/game/data/html/item/90296.htm new file mode 100644 index 0000000000..6734437ca2 --- /dev/null +++ b/L2J_Mobius_Classic_2.0_Zaken/dist/game/data/html/item/90296.htm @@ -0,0 +1,11 @@ +Maintenance Request:
+(This looks like an answer for Priest Gerald's request to repair a broken statue.)
+We have made an estimate for your request. Restoration of the statue at the cost of 2500 Adena does not seem possible.
+This work will cost you at least 200,000 Adena. See below of the detailed estimation.

+Hunter Tarantula's Venom: 5000 Adena for a piece. 20 pcs. needed.
+Necessary for gluing the broken pieces. If you want to use quality material for Marphr's statue, then you need to pay at least 5000 Adena for a piece.
+Plunder Taratula's Kidney Stone: 10,000 Adena for a piece. 10 pcs. needed.
+You do not have to pick the most expensive stones. But if you do not want spots to appear on the statue, then expect one piece to cost 10,000 Adena. The damage is to big. At least 10 stones are needed to get rid of it.

+Sum-total: 200,000 Adena
+And this is just the cost of materials. If you add the fee for the work itself, then it will be from 250,000 to 300,000 Adena in total.
+ \ No newline at end of file diff --git a/L2J_Mobius_Classic_2.0_Zaken/dist/game/data/html/item/90299.htm b/L2J_Mobius_Classic_2.0_Zaken/dist/game/data/html/item/90299.htm new file mode 100644 index 0000000000..6734437ca2 --- /dev/null +++ b/L2J_Mobius_Classic_2.0_Zaken/dist/game/data/html/item/90299.htm @@ -0,0 +1,11 @@ +Maintenance Request:
+(This looks like an answer for Priest Gerald's request to repair a broken statue.)
+We have made an estimate for your request. Restoration of the statue at the cost of 2500 Adena does not seem possible.
+This work will cost you at least 200,000 Adena. See below of the detailed estimation.

+Hunter Tarantula's Venom: 5000 Adena for a piece. 20 pcs. needed.
+Necessary for gluing the broken pieces. If you want to use quality material for Marphr's statue, then you need to pay at least 5000 Adena for a piece.
+Plunder Taratula's Kidney Stone: 10,000 Adena for a piece. 10 pcs. needed.
+You do not have to pick the most expensive stones. But if you do not want spots to appear on the statue, then expect one piece to cost 10,000 Adena. The damage is to big. At least 10 stones are needed to get rid of it.

+Sum-total: 200,000 Adena
+And this is just the cost of materials. If you add the fee for the work itself, then it will be from 250,000 to 300,000 Adena in total.
+ \ No newline at end of file diff --git a/L2J_Mobius_Classic_2.0_Zaken/dist/game/data/html/item/90302.htm b/L2J_Mobius_Classic_2.0_Zaken/dist/game/data/html/item/90302.htm new file mode 100644 index 0000000000..e400cdea58 --- /dev/null +++ b/L2J_Mobius_Classic_2.0_Zaken/dist/game/data/html/item/90302.htm @@ -0,0 +1,9 @@ +New Cleaning Tool's Supply List
+After that incident with Marphr's statue Priest Daichir charged me with cleaning it and gave me one Month to do it. Here is the list of materials that I need for that:
+Bat Bristle
+Bristles from the neck of a Barbed Bat. Because of it softness It's used for adorning clothes. It will make a perfect dustbrush, since it won't leave any traces on Marphr's statue.

+Trimden Web
+Web threads of Trimdens are very sticky, which is going to help me with my work. You can shove it into hard-to-reach spots and gather all dust with it.

+Kerope Werewolf's Twig Charm +Kerope Werewolves use such kind of charms. As the rumor goes, if you told it to cracks or scratches, they will disappear.
+ \ No newline at end of file diff --git a/L2J_Mobius_Classic_2.0_Zaken/dist/game/data/scripts/quests/MissingQuests.txt b/L2J_Mobius_Classic_2.0_Zaken/dist/game/data/scripts/quests/MissingQuests.txt index 18de055020..b036114a25 100644 --- a/L2J_Mobius_Classic_2.0_Zaken/dist/game/data/scripts/quests/MissingQuests.txt +++ b/L2J_Mobius_Classic_2.0_Zaken/dist/game/data/scripts/quests/MissingQuests.txt @@ -20,9 +20,6 @@ 10871 Death to the Pirate King! 10993 Future: Dwarves 10994 Future: Orcs -10997 Loser Priest (1/3) -10998 Loser Priest (2/3) -10999 Loser Priest (3/3) 11006 Future: People 11009 New Potion Development (1/3) 11010 New Potion Development (2/3) diff --git a/L2J_Mobius_Classic_2.0_Zaken/dist/game/data/scripts/quests/Q10997_LoserPriest1/30538-01.html b/L2J_Mobius_Classic_2.0_Zaken/dist/game/data/scripts/quests/Q10997_LoserPriest1/30538-01.html new file mode 100644 index 0000000000..b46372f966 --- /dev/null +++ b/L2J_Mobius_Classic_2.0_Zaken/dist/game/data/scripts/quests/Q10997_LoserPriest1/30538-01.html @@ -0,0 +1,5 @@ +Priest of the Earth Zimenf:
+Frankly speaking, it's because of me that Priest Gerald needs help. I asked him to clean Maphr's statue, but as soon as he picked it up, it slipped from his hands and broke into pieces. I heard Priest Daichir gave Gerald a tongue-lashing... He ordered to repair the statue within a week.
+I'm afraid if Gerald fails to do it, then Priest Daichir will think up a severe punishment for him.
+
+ \ No newline at end of file diff --git a/L2J_Mobius_Classic_2.0_Zaken/dist/game/data/scripts/quests/Q10997_LoserPriest1/30538-02.htm b/L2J_Mobius_Classic_2.0_Zaken/dist/game/data/scripts/quests/Q10997_LoserPriest1/30538-02.htm new file mode 100644 index 0000000000..a1b8547213 --- /dev/null +++ b/L2J_Mobius_Classic_2.0_Zaken/dist/game/data/scripts/quests/Q10997_LoserPriest1/30538-02.htm @@ -0,0 +1,4 @@ +Priest of the Earth Zimenf:
+Thank you for helping us out.
+Right now Priest Gerald is collecting donations near the entrance to the village that's just next to the Temple.
+ \ No newline at end of file diff --git a/L2J_Mobius_Classic_2.0_Zaken/dist/game/data/scripts/quests/Q10997_LoserPriest1/30538-02a.html b/L2J_Mobius_Classic_2.0_Zaken/dist/game/data/scripts/quests/Q10997_LoserPriest1/30538-02a.html new file mode 100644 index 0000000000..8e73443fe2 --- /dev/null +++ b/L2J_Mobius_Classic_2.0_Zaken/dist/game/data/scripts/quests/Q10997_LoserPriest1/30538-02a.html @@ -0,0 +1,3 @@ +Priest of the Earth Zimenf:
+Priest Gerald can be found near the Temple, it's next to the village entrance.
+ \ No newline at end of file diff --git a/L2J_Mobius_Classic_2.0_Zaken/dist/game/data/scripts/quests/Q10997_LoserPriest1/30650-01.htm b/L2J_Mobius_Classic_2.0_Zaken/dist/game/data/scripts/quests/Q10997_LoserPriest1/30650-01.htm new file mode 100644 index 0000000000..8ebb26c348 --- /dev/null +++ b/L2J_Mobius_Classic_2.0_Zaken/dist/game/data/scripts/quests/Q10997_LoserPriest1/30650-01.htm @@ -0,0 +1,4 @@ +Head Priest of the Earth Gerald:
+So, Zimenf mentioned me, huh? I'm so ashamed. I've got a week to restore the broken statue, otherwise Priest Daichir will be very angry. I need a big amount of money for the repairs, along with special supplies. I have got the money, alright, but I don't have the supplies I need. Please, help me.
+I can see you agree. Here, take this, it's Maintenance Request. This cost sheet contains the list of all required supplies. Please, bring them to me.
+ \ No newline at end of file diff --git a/L2J_Mobius_Classic_2.0_Zaken/dist/game/data/scripts/quests/Q10997_LoserPriest1/30650-01a.html b/L2J_Mobius_Classic_2.0_Zaken/dist/game/data/scripts/quests/Q10997_LoserPriest1/30650-01a.html new file mode 100644 index 0000000000..49c37a3ec6 --- /dev/null +++ b/L2J_Mobius_Classic_2.0_Zaken/dist/game/data/scripts/quests/Q10997_LoserPriest1/30650-01a.html @@ -0,0 +1,3 @@ +Head Priest of the Earth Gerald:
+You haven't collected all the materials yet. Perhaps, you could work a little longer? + \ No newline at end of file diff --git a/L2J_Mobius_Classic_2.0_Zaken/dist/game/data/scripts/quests/Q10997_LoserPriest1/30650-02.html b/L2J_Mobius_Classic_2.0_Zaken/dist/game/data/scripts/quests/Q10997_LoserPriest1/30650-02.html new file mode 100644 index 0000000000..5d6c234ee0 --- /dev/null +++ b/L2J_Mobius_Classic_2.0_Zaken/dist/game/data/scripts/quests/Q10997_LoserPriest1/30650-02.html @@ -0,0 +1,5 @@ +Head Priest of the Earth Gerald:
+Thank you! Now I'm packed and good to go with the repairs. I'd like to thank you for your help. Unfortunately, I have no idea what is better for you, so here are two rewards to pick from. You may choose whatever you like.
+
+
+ \ No newline at end of file diff --git a/L2J_Mobius_Classic_2.0_Zaken/dist/game/data/scripts/quests/Q10997_LoserPriest1/30650-03.html b/L2J_Mobius_Classic_2.0_Zaken/dist/game/data/scripts/quests/Q10997_LoserPriest1/30650-03.html new file mode 100644 index 0000000000..5134e83c7c --- /dev/null +++ b/L2J_Mobius_Classic_2.0_Zaken/dist/game/data/scripts/quests/Q10997_LoserPriest1/30650-03.html @@ -0,0 +1,6 @@ +Head Priest of the Earth Gerald:
+You chose Soulshot, I see. There are never enough Soulshots on a journey.
+And one more thing... Could you, please, bring some more materials for the repairs? I keep receiving assignments on restoration of collapsed buildings. There are just too many, I'm out of materials! I understand that you're really busy, but I'm begging you to help me once more!
+
+
+ \ No newline at end of file diff --git a/L2J_Mobius_Classic_2.0_Zaken/dist/game/data/scripts/quests/Q10997_LoserPriest1/30650-04.html b/L2J_Mobius_Classic_2.0_Zaken/dist/game/data/scripts/quests/Q10997_LoserPriest1/30650-04.html new file mode 100644 index 0000000000..ae7ed96892 --- /dev/null +++ b/L2J_Mobius_Classic_2.0_Zaken/dist/game/data/scripts/quests/Q10997_LoserPriest1/30650-04.html @@ -0,0 +1,6 @@ +Head Priest of the Earth Gerald:
+You chose Spiritshot, I see. There are never enough Spiritshots on a journey.
+And one more thing... Could you, please, bring some more materials for the repairs? I keep receiving assignments on restoration of collapsed buildings. There are just too many, I'm out of materials! I understand that you're really busy, but I'm begging you to help me once more!
+
+
+ \ No newline at end of file diff --git a/L2J_Mobius_Classic_2.0_Zaken/dist/game/data/scripts/quests/Q10997_LoserPriest1/Q10997_LoserPriest1.java b/L2J_Mobius_Classic_2.0_Zaken/dist/game/data/scripts/quests/Q10997_LoserPriest1/Q10997_LoserPriest1.java new file mode 100644 index 0000000000..4fc9cbb003 --- /dev/null +++ b/L2J_Mobius_Classic_2.0_Zaken/dist/game/data/scripts/quests/Q10997_LoserPriest1/Q10997_LoserPriest1.java @@ -0,0 +1,229 @@ +/* + * 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 . + */ +package quests.Q10997_LoserPriest1; + +import com.l2jmobius.gameserver.enums.QuestSound; +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.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.ExShowScreenMessage; + +/** + * Loser Priest (1/3) (10997) + * @author Stayway + */ +public class Q10997_LoserPriest1 extends Quest +{ + // NPCs + private static final int ZIMENF = 30538; + private static final int GERALD = 30650; + // Items + private static final int HUNTER_TARANTULA_VENOM = 90297; + private static final int PLUNDER_TARANTULA_KIDNEY = 90298; + private static final int MAINTENANCE_REQUEST = 90296; + // Rewards + private static final int SCROLL_OF_ESCAPE = 10650; + private static final int HEALING_POTION = 1073; + private static final int MP_RECOVERY_POTION = 90310; + private static final int SOULSHOTS_NO_GRADE = 5789; + private static final int SPIRITSHOT_NO_GRADE = 5790; + // Monsters + private static final int HUNTER_TARANTULA = 20403; + private static final int PLUNDER_TARANTULA = 20508; + // Misc + private static final int MIN_LVL = 15; + private static final int MAX_LVL = 20; + + public Q10997_LoserPriest1() + { + super(10997); + addStartNpc(ZIMENF); + addTalkId(ZIMENF, GERALD); + addKillId(PLUNDER_TARANTULA, HUNTER_TARANTULA); + addCondLevel(MIN_LVL, MAX_LVL, "no-level.html"); // Custom + addCondRace(Race.DWARF, "no-race.html"); // Custom + registerQuestItems(MAINTENANCE_REQUEST, HUNTER_TARANTULA_VENOM, PLUNDER_TARANTULA_KIDNEY); + setQuestNameNpcStringId(NpcStringId.LV_15_20_LOSER_PRIEST_1_3); + } + + @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 "30538-02.htm": + { + qs.startQuest(); + htmltext = event; + break; + } + case "reward1": + { + if (qs.isCond(4)) + { + takeItems(player, MAINTENANCE_REQUEST, 1); + takeItems(player, HUNTER_TARANTULA_VENOM, 20); + takeItems(player, PLUNDER_TARANTULA_KIDNEY, 20); + giveItems(player, SCROLL_OF_ESCAPE, 5); + giveItems(player, HEALING_POTION, 40); + giveItems(player, MP_RECOVERY_POTION, 40); + giveItems(player, SOULSHOTS_NO_GRADE, 1000); + addExpAndSp(player, 70000, 3600); + qs.exitQuest(false, true); + htmltext = "30650-03.html"; + } + break; + } + case "reward2": + { + if (qs.isCond(4)) + { + takeItems(player, MAINTENANCE_REQUEST, 1); + takeItems(player, HUNTER_TARANTULA_VENOM, 20); + takeItems(player, PLUNDER_TARANTULA_KIDNEY, 20); + giveItems(player, SCROLL_OF_ESCAPE, 5); + giveItems(player, HEALING_POTION, 40); + giveItems(player, MP_RECOVERY_POTION, 40); + giveItems(player, SPIRITSHOT_NO_GRADE, 1000); + addExpAndSp(player, 70000, 3600); + qs.exitQuest(false, true); + htmltext = "30650-04.html"; + } + break; + } + } + return htmltext; + } + + @Override + public String onTalk(L2Npc npc, L2PcInstance talker) + { + final QuestState qs = getQuestState(talker, true); + String htmltext = getNoQuestMsg(talker); + switch (qs.getState()) + { + case State.CREATED: + { + if (npc.getId() == ZIMENF) + { + htmltext = "30538-01.html"; + } + break; + } + case State.STARTED: + { + if (npc.getId() == ZIMENF) + { + if (qs.isCond(1)) + { + htmltext = "30538-02a.html"; + } + break; + } + else if (npc.getId() == GERALD) + { + switch (qs.getCond()) + { + case 1: + { + htmltext = "30650-01.htm"; + qs.setCond(2, true); + showOnScreenMsg(talker, NpcStringId.GO_HUNTING_AND_KILL_HUNTER_TARANTULAS, ExShowScreenMessage.TOP_CENTER, 10000); + giveItems(talker, MAINTENANCE_REQUEST, 1); + break; + } + case 2: + { + htmltext = "30650-01a.html"; + break; + } + case 4: + { + htmltext = "30650-02.html"; + break; + } + } + } + break; + } + case State.COMPLETED: + { + htmltext = getAlreadyCompletedMsg(talker); + break; + } + } + return htmltext; + } + + @Override + public String onKill(L2Npc npc, L2PcInstance killer, boolean isSummon) + { + final QuestState qs = getQuestState(killer, false); + if (qs != null) + { + switch (npc.getId()) + { + case HUNTER_TARANTULA: + { + if (qs.isCond(2) && (getQuestItemsCount(killer, HUNTER_TARANTULA_VENOM) < 20)) + { + if (getRandom(100) < 94) + { + giveItems(killer, HUNTER_TARANTULA_VENOM, 1); + playSound(killer, QuestSound.ITEMSOUND_QUEST_MIDDLE); + if (getQuestItemsCount(killer, HUNTER_TARANTULA_VENOM) >= 20) + { + showOnScreenMsg(killer, NpcStringId.YOU_HAVE_KILLED_ENOUGH_HUNTER_TARANTULAS_N_GO_HUNTING_AND_KILL_PLUNDER_TARANTULAS, ExShowScreenMessage.TOP_CENTER, 10000); + qs.setCond(3); + } + } + } + break; + } + case PLUNDER_TARANTULA: + { + if (qs.isCond(3) && (getQuestItemsCount(killer, PLUNDER_TARANTULA_KIDNEY) < 20)) + { + if (getRandom(100) < 94) + { + giveItems(killer, PLUNDER_TARANTULA_KIDNEY, 1); + playSound(killer, QuestSound.ITEMSOUND_QUEST_MIDDLE); + if (getQuestItemsCount(killer, PLUNDER_TARANTULA_KIDNEY) >= 20) + { + showOnScreenMsg(killer, NpcStringId.YOU_HAVE_KILLED_ENOUGH_PLUNDER_TARANTULAS_NRETURN_TO_PRIEST_OF_THE_EARTH_GERALD, ExShowScreenMessage.TOP_CENTER, 10000); + qs.setCond(4); + } + } + } + break; + } + } + } + return super.onKill(npc, killer, isSummon); + } +} \ No newline at end of file diff --git a/L2J_Mobius_Classic_2.0_Zaken/dist/game/data/scripts/quests/Q10997_LoserPriest1/no-level.html b/L2J_Mobius_Classic_2.0_Zaken/dist/game/data/scripts/quests/Q10997_LoserPriest1/no-level.html new file mode 100644 index 0000000000..3ab5111692 --- /dev/null +++ b/L2J_Mobius_Classic_2.0_Zaken/dist/game/data/scripts/quests/Q10997_LoserPriest1/no-level.html @@ -0,0 +1,4 @@ +Priest of the Earth Zimenf:
+You ought to gain more experience. Come back later.
+(This quest is available to characters of Level 15 or higher.)
+ \ No newline at end of file diff --git a/L2J_Mobius_Classic_2.0_Zaken/dist/game/data/scripts/quests/Q10997_LoserPriest1/no-race.html b/L2J_Mobius_Classic_2.0_Zaken/dist/game/data/scripts/quests/Q10997_LoserPriest1/no-race.html new file mode 100644 index 0000000000..881d21aaf8 --- /dev/null +++ b/L2J_Mobius_Classic_2.0_Zaken/dist/game/data/scripts/quests/Q10997_LoserPriest1/no-race.html @@ -0,0 +1,4 @@ +Priest of the Earth Zimenf:
+I can see you're a stranger here. Pardon me, but I am asking only citizens for help.
+(This quest is available to Dark Elves only.)
+ \ No newline at end of file diff --git a/L2J_Mobius_Classic_2.0_Zaken/dist/game/data/scripts/quests/Q10998_LoserPriest2/30650-01.html b/L2J_Mobius_Classic_2.0_Zaken/dist/game/data/scripts/quests/Q10998_LoserPriest2/30650-01.html new file mode 100644 index 0000000000..279922d703 --- /dev/null +++ b/L2J_Mobius_Classic_2.0_Zaken/dist/game/data/scripts/quests/Q10998_LoserPriest2/30650-01.html @@ -0,0 +1,4 @@ +Head Priest of the Earth Gerald:
+You want to help me out again? Thank you!
+
+ \ No newline at end of file diff --git a/L2J_Mobius_Classic_2.0_Zaken/dist/game/data/scripts/quests/Q10998_LoserPriest2/30650-02.htm b/L2J_Mobius_Classic_2.0_Zaken/dist/game/data/scripts/quests/Q10998_LoserPriest2/30650-02.htm new file mode 100644 index 0000000000..4faeebd74c --- /dev/null +++ b/L2J_Mobius_Classic_2.0_Zaken/dist/game/data/scripts/quests/Q10998_LoserPriest2/30650-02.htm @@ -0,0 +1,4 @@ +Head Priest of the Earth Gerald:
+Thank you for accepting my request for help.
+If it weren't for you, Priest Daichir would have been really mad at me. He would have probably even ban me from the temple. Here, take this, it's Maintenance Request. It contains titles and quantity of required materials.
+ \ No newline at end of file diff --git a/L2J_Mobius_Classic_2.0_Zaken/dist/game/data/scripts/quests/Q10998_LoserPriest2/30650-02a.html b/L2J_Mobius_Classic_2.0_Zaken/dist/game/data/scripts/quests/Q10998_LoserPriest2/30650-02a.html new file mode 100644 index 0000000000..bb63015cf8 --- /dev/null +++ b/L2J_Mobius_Classic_2.0_Zaken/dist/game/data/scripts/quests/Q10998_LoserPriest2/30650-02a.html @@ -0,0 +1,3 @@ +Head Priest of the Earth Gerald:
+I hope, I can finish the repairs with the materials you are going to bring. Please, try hard! + \ No newline at end of file diff --git a/L2J_Mobius_Classic_2.0_Zaken/dist/game/data/scripts/quests/Q10998_LoserPriest2/30650-03.html b/L2J_Mobius_Classic_2.0_Zaken/dist/game/data/scripts/quests/Q10998_LoserPriest2/30650-03.html new file mode 100644 index 0000000000..9ee10e188b --- /dev/null +++ b/L2J_Mobius_Classic_2.0_Zaken/dist/game/data/scripts/quests/Q10998_LoserPriest2/30650-03.html @@ -0,0 +1,5 @@ +Head Priest of the Earth Gerald:
+You did a good job. I only have to start the repairs. Thank you! I'd like to give you something as a token of my gratitude. Actually, I gave you the same last time, but there can never be too many of these. What will you pick?
+
+
+ \ No newline at end of file diff --git a/L2J_Mobius_Classic_2.0_Zaken/dist/game/data/scripts/quests/Q10998_LoserPriest2/30650-04.html b/L2J_Mobius_Classic_2.0_Zaken/dist/game/data/scripts/quests/Q10998_LoserPriest2/30650-04.html new file mode 100644 index 0000000000..a57cced9d1 --- /dev/null +++ b/L2J_Mobius_Classic_2.0_Zaken/dist/game/data/scripts/quests/Q10998_LoserPriest2/30650-04.html @@ -0,0 +1,6 @@ +Head Priest of the Earth Gerald:
+There can never be too many Soulshots.
+Thanks to you, I may start the repairs. The only thing is... that I might have another request. Daichir recently ordered me to clean up the temple. Of course, Maphr's Temple must be shining clean, but why do I have to scrub it all on my own?! Oh yes, and the mess was so bad, that all cleaning tools went out of order right way. I asked Daichir to buy new ones, but he told me to deal with it myself. So I decided to craft them. I wish I had time to look for the necessary materials. So many things to do... For that reason I would like to ask you to bring me materials for cleaning tools.
+
+
+ \ No newline at end of file diff --git a/L2J_Mobius_Classic_2.0_Zaken/dist/game/data/scripts/quests/Q10998_LoserPriest2/30650-05.html b/L2J_Mobius_Classic_2.0_Zaken/dist/game/data/scripts/quests/Q10998_LoserPriest2/30650-05.html new file mode 100644 index 0000000000..4a1c68c7e0 --- /dev/null +++ b/L2J_Mobius_Classic_2.0_Zaken/dist/game/data/scripts/quests/Q10998_LoserPriest2/30650-05.html @@ -0,0 +1,6 @@ +Head Priest of the Earth Gerald:
+There can never be too many Spiritshots.
+Thanks to you, I may start the repairs. The only thing is... that I might have another request. Daichir recently ordered me to clean up the temple. Of course, Maphr's Temple must be shining clean, but why do I have to scrub it all on my own?! Oh yes, and the mess was so bad, that all cleaning tools went out of order right way. I asked Daichir to buy new ones, but he told me to deal with it myself. So I decided to craft them. I wish I had time to look for the necessary materials. So many things to do... For that reason I would like to ask you to bring me materials for cleaning tools.
+
+
+ \ No newline at end of file diff --git a/L2J_Mobius_Classic_2.0_Zaken/dist/game/data/scripts/quests/Q10998_LoserPriest2/30650-06.html b/L2J_Mobius_Classic_2.0_Zaken/dist/game/data/scripts/quests/Q10998_LoserPriest2/30650-06.html new file mode 100644 index 0000000000..afb6229167 --- /dev/null +++ b/L2J_Mobius_Classic_2.0_Zaken/dist/game/data/scripts/quests/Q10998_LoserPriest2/30650-06.html @@ -0,0 +1,3 @@ +Head Priest of the Earth Gerald:
+(Only characters who are level 15 or above and who have completed the Loser Priest (1/3) quests may undertake this quest.) + \ No newline at end of file diff --git a/L2J_Mobius_Classic_2.0_Zaken/dist/game/data/scripts/quests/Q10998_LoserPriest2/Q10998_LoserPriest2.java b/L2J_Mobius_Classic_2.0_Zaken/dist/game/data/scripts/quests/Q10998_LoserPriest2/Q10998_LoserPriest2.java new file mode 100644 index 0000000000..d75026376f --- /dev/null +++ b/L2J_Mobius_Classic_2.0_Zaken/dist/game/data/scripts/quests/Q10998_LoserPriest2/Q10998_LoserPriest2.java @@ -0,0 +1,214 @@ +/* + * 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 . + */ +package quests.Q10998_LoserPriest2; + +import com.l2jmobius.gameserver.enums.QuestSound; +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.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.ExShowScreenMessage; + +import quests.Q10997_LoserPriest1.Q10997_LoserPriest1; + +/** + * Loser Priest (2/3) (10998) + * @author Stayway + */ +public class Q10998_LoserPriest2 extends Quest +{ + // NPCs + private static final int GERALD = 30650; + // Items + private static final int HUNTER_TARANTULA_VENOM = 90300; + private static final int PLUNDER_TARANTULA_KIDNEY = 90301; + private static final int MAINTENANCE_REQUEST = 90299; + // Rewards + private static final int SCROLL_OF_ESCAPE = 10650; + private static final int HEALING_POTION = 1073; + private static final int MP_RECOVERY_POTION = 90310; + private static final int SOULSHOTS_NO_GRADE = 5789; + private static final int SPIRITSHOT_NO_GRADE = 5790; + // Monsters + private static final int HUNTER_TARANTULA = 20403; + private static final int PLUNDER_TARANTULA = 20508; + // Misc + private static final int MIN_LVL = 15; + private static final int MAX_LVL = 20; + + public Q10998_LoserPriest2() + { + super(10998); + addStartNpc(GERALD); + addTalkId(GERALD); + addKillId(PLUNDER_TARANTULA, HUNTER_TARANTULA); + addCondLevel(MIN_LVL, MAX_LVL, "no-level.html"); // Custom + addCondRace(Race.DWARF, "no-race.html"); // Custom + addCondCompletedQuest(Q10997_LoserPriest1.class.getSimpleName(), "30650-06.html"); + registerQuestItems(MAINTENANCE_REQUEST, HUNTER_TARANTULA_VENOM, PLUNDER_TARANTULA_KIDNEY); + setQuestNameNpcStringId(NpcStringId.LV_15_LOSER_PRIEST_2_3); + } + + @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 "abort.html": + { + htmltext = event; + break; + } + case "30650-02.htm": + { + qs.startQuest(); + qs.setCond(1); + qs.setCond(2); + showOnScreenMsg(player, NpcStringId.GO_HUNTING_AND_KILL_HUNTER_TARANTULAS, ExShowScreenMessage.TOP_CENTER, 10000); + giveItems(player, MAINTENANCE_REQUEST, 1); + htmltext = event; + break; + } + case "reward1": + { + if (qs.isCond(4)) + { + takeItems(player, MAINTENANCE_REQUEST, 1); + takeItems(player, HUNTER_TARANTULA_VENOM, 20); + takeItems(player, PLUNDER_TARANTULA_KIDNEY, 20); + giveItems(player, SCROLL_OF_ESCAPE, 5); + giveItems(player, HEALING_POTION, 40); + giveItems(player, MP_RECOVERY_POTION, 40); + giveItems(player, SOULSHOTS_NO_GRADE, 1000); + addExpAndSp(player, 70000, 3600); + qs.exitQuest(false, true); + htmltext = "30650-04.html"; + } + break; + } + case "reward2": + { + if (qs.isCond(4)) + { + takeItems(player, MAINTENANCE_REQUEST, 1); + takeItems(player, HUNTER_TARANTULA_VENOM, 20); + takeItems(player, PLUNDER_TARANTULA_KIDNEY, 20); + giveItems(player, SCROLL_OF_ESCAPE, 5); + giveItems(player, HEALING_POTION, 40); + giveItems(player, MP_RECOVERY_POTION, 40); + giveItems(player, SPIRITSHOT_NO_GRADE, 1000); + addExpAndSp(player, 70000, 3600); + qs.exitQuest(false, true); + htmltext = "30650-05.html"; + } + break; + } + } + return htmltext; + } + + @Override + public String onTalk(L2Npc npc, L2PcInstance talker) + { + final QuestState qs = getQuestState(talker, true); + String htmltext = getNoQuestMsg(talker); + + switch (qs.getState()) + { + case State.CREATED: + { + htmltext = "30650-01.html"; + break; + } + case State.STARTED: + { + if (qs.isCond(2)) + { + htmltext = "30650-02a.html"; + } + else if (qs.isCond(4)) + { + htmltext = "30650-03.html"; + } + break; + } + case State.COMPLETED: + { + htmltext = getAlreadyCompletedMsg(talker); + break; + } + } + return htmltext; + } + + @Override + public String onKill(L2Npc npc, L2PcInstance killer, boolean isSummon) + { + final QuestState qs = getQuestState(killer, false); + if (qs != null) + { + switch (npc.getId()) + { + case HUNTER_TARANTULA: + { + if (qs.isCond(2) && (getQuestItemsCount(killer, HUNTER_TARANTULA_VENOM) < 20)) + { + if (getRandom(100) < 94) + { + giveItems(killer, HUNTER_TARANTULA_VENOM, 1); + playSound(killer, QuestSound.ITEMSOUND_QUEST_MIDDLE); + if (getQuestItemsCount(killer, HUNTER_TARANTULA_VENOM) >= 20) + { + showOnScreenMsg(killer, NpcStringId.YOU_HAVE_KILLED_ENOUGH_HUNTER_TARANTULAS_N_GO_HUNTING_AND_KILL_PLUNDER_TARANTULAS, ExShowScreenMessage.TOP_CENTER, 10000); + qs.setCond(3); + } + } + } + break; + } + case PLUNDER_TARANTULA: + { + if (qs.isCond(3) && (getQuestItemsCount(killer, PLUNDER_TARANTULA_KIDNEY) < 20)) + { + if (getRandom(100) < 94) + { + giveItems(killer, PLUNDER_TARANTULA_KIDNEY, 1); + playSound(killer, QuestSound.ITEMSOUND_QUEST_MIDDLE); + if (getQuestItemsCount(killer, PLUNDER_TARANTULA_KIDNEY) >= 20) + { + showOnScreenMsg(killer, NpcStringId.YOU_HAVE_KILLED_ENOUGH_PLUNDER_TARANTULAS_NRETURN_TO_PRIEST_OF_THE_EARTH_GERALD, ExShowScreenMessage.TOP_CENTER, 10000); + qs.setCond(4); + } + } + } + break; + } + } + } + return super.onKill(npc, killer, isSummon); + } +} \ No newline at end of file diff --git a/L2J_Mobius_Classic_2.0_Zaken/dist/game/data/scripts/quests/Q10998_LoserPriest2/abort.html b/L2J_Mobius_Classic_2.0_Zaken/dist/game/data/scripts/quests/Q10998_LoserPriest2/abort.html new file mode 100644 index 0000000000..39996df963 --- /dev/null +++ b/L2J_Mobius_Classic_2.0_Zaken/dist/game/data/scripts/quests/Q10998_LoserPriest2/abort.html @@ -0,0 +1,3 @@ +Head Priest of the Earth Gerald:
+I can see you're busy doing other stuff. It's a pity you can't help me. Come back, if you change your mind. + \ No newline at end of file diff --git a/L2J_Mobius_Classic_2.0_Zaken/dist/game/data/scripts/quests/Q10998_LoserPriest2/no-level.html b/L2J_Mobius_Classic_2.0_Zaken/dist/game/data/scripts/quests/Q10998_LoserPriest2/no-level.html new file mode 100644 index 0000000000..e321303f3e --- /dev/null +++ b/L2J_Mobius_Classic_2.0_Zaken/dist/game/data/scripts/quests/Q10998_LoserPriest2/no-level.html @@ -0,0 +1,4 @@ +Head Priest of the Earth Gerald:
+You ought to gain more experience. Come back later.
+(This quest is available to characters of Level 15 or higher.)
+ \ No newline at end of file diff --git a/L2J_Mobius_Classic_2.0_Zaken/dist/game/data/scripts/quests/Q10998_LoserPriest2/no-race.html b/L2J_Mobius_Classic_2.0_Zaken/dist/game/data/scripts/quests/Q10998_LoserPriest2/no-race.html new file mode 100644 index 0000000000..52f768eeb0 --- /dev/null +++ b/L2J_Mobius_Classic_2.0_Zaken/dist/game/data/scripts/quests/Q10998_LoserPriest2/no-race.html @@ -0,0 +1,4 @@ +Head Priest of the Earth Gerald:
+I can see you're a stranger here. Pardon me, but I am asking only citizens for help.
+(This quest is available to Dark Elves only.)
+ \ No newline at end of file diff --git a/L2J_Mobius_Classic_2.0_Zaken/dist/game/data/scripts/quests/Q10999_LoserPriest3/30650-01.html b/L2J_Mobius_Classic_2.0_Zaken/dist/game/data/scripts/quests/Q10999_LoserPriest3/30650-01.html new file mode 100644 index 0000000000..297988ffc7 --- /dev/null +++ b/L2J_Mobius_Classic_2.0_Zaken/dist/game/data/scripts/quests/Q10999_LoserPriest3/30650-01.html @@ -0,0 +1,4 @@ +Head Priest of the Earth Gerald:
+You want to help me out again? Thank you!
+
+ \ No newline at end of file diff --git a/L2J_Mobius_Classic_2.0_Zaken/dist/game/data/scripts/quests/Q10999_LoserPriest3/30650-02.htm b/L2J_Mobius_Classic_2.0_Zaken/dist/game/data/scripts/quests/Q10999_LoserPriest3/30650-02.htm new file mode 100644 index 0000000000..96eb328056 --- /dev/null +++ b/L2J_Mobius_Classic_2.0_Zaken/dist/game/data/scripts/quests/Q10999_LoserPriest3/30650-02.htm @@ -0,0 +1,4 @@ +Head Priest of the Earth Gerald:
+I'm so embarrassed... I thought I couldn't craft yhe cleaning tools on my own, and I was just about to spend temple's charity donations on materials. But then I had to drop this idea. priest Daichir would have never forgiven me, not until the day that I die.
+Here, take the New Cleaning Tool's Supply List. A dusting brush can be made from Bat Bristles. You will also need Trimden web, which is perfect for making a rag, and Kerope Werewolf's Twig Charms for a twig broom. I will use these materials for crafting the cleaning tools. I hope you can help us.
+ \ No newline at end of file diff --git a/L2J_Mobius_Classic_2.0_Zaken/dist/game/data/scripts/quests/Q10999_LoserPriest3/30650-02a.html b/L2J_Mobius_Classic_2.0_Zaken/dist/game/data/scripts/quests/Q10999_LoserPriest3/30650-02a.html new file mode 100644 index 0000000000..ea86d93f15 --- /dev/null +++ b/L2J_Mobius_Classic_2.0_Zaken/dist/game/data/scripts/quests/Q10999_LoserPriest3/30650-02a.html @@ -0,0 +1,3 @@ +Head Priest of the Earth Gerald:
+As soon as I've finished, Priest Daichir will stop being angry with me. He is bound to notice, how well I cleaned the temple. Daichir is not as heartless as he tries to look. I can't cope with such a difficult task alone, though. That's why I'm asking you to help me. + \ No newline at end of file diff --git a/L2J_Mobius_Classic_2.0_Zaken/dist/game/data/scripts/quests/Q10999_LoserPriest3/30650-03.html b/L2J_Mobius_Classic_2.0_Zaken/dist/game/data/scripts/quests/Q10999_LoserPriest3/30650-03.html new file mode 100644 index 0000000000..650101ac7a --- /dev/null +++ b/L2J_Mobius_Classic_2.0_Zaken/dist/game/data/scripts/quests/Q10999_LoserPriest3/30650-03.html @@ -0,0 +1,5 @@ +Head Priest of the Earth Gerald:
+Thank you! Now all I have to do is cleaning. Priest Daichir is bound to stop being mad then. I am so grateful! Thank you! And here is your reward.
+
+
+ \ No newline at end of file diff --git a/L2J_Mobius_Classic_2.0_Zaken/dist/game/data/scripts/quests/Q10999_LoserPriest3/30650-04.html b/L2J_Mobius_Classic_2.0_Zaken/dist/game/data/scripts/quests/Q10999_LoserPriest3/30650-04.html new file mode 100644 index 0000000000..c3a04f0faa --- /dev/null +++ b/L2J_Mobius_Classic_2.0_Zaken/dist/game/data/scripts/quests/Q10999_LoserPriest3/30650-04.html @@ -0,0 +1,5 @@ +Head Priest of the Earth Gerald:
+I am sorry about a small reward, but this is all I have managed to scrape up.
+Thank to you, I prepared for the cleaning really well. Now I need to get work. It's time for you travel and see the world. You need to remember that journeys are often full of danger. I have friends who will help you grow stronger.
+
+ \ No newline at end of file diff --git a/L2J_Mobius_Classic_2.0_Zaken/dist/game/data/scripts/quests/Q10999_LoserPriest3/30650-05.html b/L2J_Mobius_Classic_2.0_Zaken/dist/game/data/scripts/quests/Q10999_LoserPriest3/30650-05.html new file mode 100644 index 0000000000..5725f144ae --- /dev/null +++ b/L2J_Mobius_Classic_2.0_Zaken/dist/game/data/scripts/quests/Q10999_LoserPriest3/30650-05.html @@ -0,0 +1,3 @@ +Head Priest of the Earth Gerald:
+(Only characters who are level 15 or above and who have completed the Loser Priest (2/3) quests may undertake this quest.) + \ No newline at end of file diff --git a/L2J_Mobius_Classic_2.0_Zaken/dist/game/data/scripts/quests/Q10999_LoserPriest3/Q10999_LoserPriest3.java b/L2J_Mobius_Classic_2.0_Zaken/dist/game/data/scripts/quests/Q10999_LoserPriest3/Q10999_LoserPriest3.java new file mode 100644 index 0000000000..15ff84cc37 --- /dev/null +++ b/L2J_Mobius_Classic_2.0_Zaken/dist/game/data/scripts/quests/Q10999_LoserPriest3/Q10999_LoserPriest3.java @@ -0,0 +1,236 @@ +/* + * 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 . + */ +package quests.Q10999_LoserPriest3; + +import com.l2jmobius.gameserver.enums.QuestSound; +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.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.ExShowScreenMessage; + +import quests.Q10998_LoserPriest2.Q10998_LoserPriest2; + +/** + * Loser Priest (3/3) (10999) + * @author Stayway + */ +public class Q10999_LoserPriest3 extends Quest +{ + // NPCs + private static final int GERALD = 30650; + // Items + private static final int BAT_BRISTLE = 90303; + private static final int TRIMDEN_WEB = 90304; + private static final int KEROPE_WEREWOLF_TWIG_CHARM = 90305; + private static final int NEW_CLEANING_TOOLS_LIST = 90302; + // Rewards + private static final int SCROLL_OF_ESCAPE = 10650; + private static final int HEALING_POTION = 1073; + private static final int MP_RECOVERY_POTION = 90310; + private static final int SOULSHOTS_NO_GRADE = 5789; + private static final int SPIRITSHOT_NO_GRADE = 5790; + // Monsters + private static final int RED_EYE_BARBED_BAT = 21124; + private static final int NORTHERN_TRIMDEN = 21125; + private static final int KEROPE_WEREWOLF = 21126; + private static final int KEROPE_WEREWOLF_CHIEFTAIN = 21129; + // Misc + private static final int MIN_LVL = 15; + private static final int MAX_LVL = 20; + + public Q10999_LoserPriest3() + { + super(10999); + addStartNpc(GERALD); + addTalkId(GERALD); + addKillId(NORTHERN_TRIMDEN, RED_EYE_BARBED_BAT, KEROPE_WEREWOLF_CHIEFTAIN, KEROPE_WEREWOLF); + addCondLevel(MIN_LVL, MAX_LVL, "no-level.html"); // Custom + addCondRace(Race.DWARF, "no-race.html"); // Custom + addCondCompletedQuest(Q10998_LoserPriest2.class.getSimpleName(), "30650-05.html"); + registerQuestItems(NEW_CLEANING_TOOLS_LIST, BAT_BRISTLE, TRIMDEN_WEB, KEROPE_WEREWOLF_TWIG_CHARM); + setQuestNameNpcStringId(NpcStringId.LV_15_LOSER_PRIEST_3_3); + } + + @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 "abort.html": + { + htmltext = event; + break; + } + case "30650-02.htm": + { + qs.startQuest(); + qs.setCond(2); + showOnScreenMsg(player, NpcStringId.GO_HUNTING_AND_KILL_RED_EYE_BARBED_BATS, ExShowScreenMessage.TOP_CENTER, 10000); + giveItems(player, NEW_CLEANING_TOOLS_LIST, 1); + htmltext = event; + break; + } + case "reward1": + { + if (qs.isCond(5)) + { + takeItems(player, NEW_CLEANING_TOOLS_LIST, 1); + takeItems(player, BAT_BRISTLE, 20); + takeItems(player, TRIMDEN_WEB, 20); + takeItems(player, KEROPE_WEREWOLF_TWIG_CHARM, 20); + giveItems(player, SCROLL_OF_ESCAPE, 5); + giveItems(player, HEALING_POTION, 40); + giveItems(player, MP_RECOVERY_POTION, 40); + giveItems(player, SOULSHOTS_NO_GRADE, 1000); + addExpAndSp(player, 70000, 3600); + qs.exitQuest(false, true); + htmltext = "30650-04.html"; + } + break; + } + case "reward2": + { + if (qs.isCond(5)) + { + takeItems(player, NEW_CLEANING_TOOLS_LIST, 1); + takeItems(player, BAT_BRISTLE, 20); + takeItems(player, TRIMDEN_WEB, 20); + takeItems(player, KEROPE_WEREWOLF_TWIG_CHARM, 20); + giveItems(player, SCROLL_OF_ESCAPE, 5); + giveItems(player, HEALING_POTION, 40); + giveItems(player, MP_RECOVERY_POTION, 40); + giveItems(player, SPIRITSHOT_NO_GRADE, 1000); + addExpAndSp(player, 70000, 3600); + qs.exitQuest(false, true); + htmltext = "30650-04.html"; + } + break; + } + } + return htmltext; + } + + @Override + public String onTalk(L2Npc npc, L2PcInstance talker) + { + final QuestState qs = getQuestState(talker, true); + String htmltext = getNoQuestMsg(talker); + + switch (qs.getState()) + { + case State.CREATED: + { + htmltext = "30650-01.html"; + break; + } + case State.STARTED: + { + if (qs.isCond(2)) + { + htmltext = "30650-02a.html"; + } + else if (qs.isCond(5)) + { + htmltext = "30650-03.html"; + } + break; + } + case State.COMPLETED: + { + htmltext = getAlreadyCompletedMsg(talker); + break; + } + } + return htmltext; + } + + @Override + public String onKill(L2Npc npc, L2PcInstance killer, boolean isSummon) + { + final QuestState qs = getQuestState(killer, false); + if (qs != null) + { + switch (npc.getId()) + { + case RED_EYE_BARBED_BAT: + { + if (qs.isCond(2) && (getQuestItemsCount(killer, BAT_BRISTLE) < 20)) + { + if (getRandom(100) < 90) + { + giveItems(killer, BAT_BRISTLE, 1); + playSound(killer, QuestSound.ITEMSOUND_QUEST_MIDDLE); + if (getQuestItemsCount(killer, BAT_BRISTLE) >= 20) + { + showOnScreenMsg(killer, NpcStringId.YOU_HAVE_KILLED_ENOUGH_RED_EYE_BARBED_BATS_NGO_HUNTING_AND_KILL_NORTHERN_TRIMDENS, ExShowScreenMessage.TOP_CENTER, 10000); + qs.setCond(3); + } + } + } + break; + } + case NORTHERN_TRIMDEN: + { + if (qs.isCond(3) && (getQuestItemsCount(killer, TRIMDEN_WEB) < 20)) + { + if (getRandom(100) < 90) + { + giveItems(killer, TRIMDEN_WEB, 1); + playSound(killer, QuestSound.ITEMSOUND_QUEST_MIDDLE); + if (getQuestItemsCount(killer, TRIMDEN_WEB) >= 20) + { + showOnScreenMsg(killer, NpcStringId.YOU_HAVE_KILLED_ENOUGH_NORTHERN_TRIMDENS_N_GO_HUNTING_AND_KILL_KEROPE_WEREWOLVES, ExShowScreenMessage.TOP_CENTER, 10000); + qs.setCond(4); + } + } + } + break; + } + case KEROPE_WEREWOLF_CHIEFTAIN: + case KEROPE_WEREWOLF: + { + if (qs.isCond(4) && (getQuestItemsCount(killer, KEROPE_WEREWOLF_TWIG_CHARM) < 20)) + { + if (getRandom(100) < 90) + { + giveItems(killer, KEROPE_WEREWOLF_TWIG_CHARM, 1); + playSound(killer, QuestSound.ITEMSOUND_QUEST_MIDDLE); + if (getQuestItemsCount(killer, KEROPE_WEREWOLF_TWIG_CHARM) >= 20) + { + showOnScreenMsg(killer, NpcStringId.YOU_HAVE_KILLED_ENOUGH_KEROPE_WEREWOLVES_NRETURN_TO_PRIEST_OF_THE_EARTH_GERALD, ExShowScreenMessage.TOP_CENTER, 10000); + qs.setCond(5); + } + } + } + break; + } + } + } + return super.onKill(npc, killer, isSummon); + } +} \ No newline at end of file diff --git a/L2J_Mobius_Classic_2.0_Zaken/dist/game/data/scripts/quests/Q10999_LoserPriest3/abort.html b/L2J_Mobius_Classic_2.0_Zaken/dist/game/data/scripts/quests/Q10999_LoserPriest3/abort.html new file mode 100644 index 0000000000..39996df963 --- /dev/null +++ b/L2J_Mobius_Classic_2.0_Zaken/dist/game/data/scripts/quests/Q10999_LoserPriest3/abort.html @@ -0,0 +1,3 @@ +Head Priest of the Earth Gerald:
+I can see you're busy doing other stuff. It's a pity you can't help me. Come back, if you change your mind. + \ No newline at end of file diff --git a/L2J_Mobius_Classic_2.0_Zaken/dist/game/data/scripts/quests/Q10999_LoserPriest3/no-level.html b/L2J_Mobius_Classic_2.0_Zaken/dist/game/data/scripts/quests/Q10999_LoserPriest3/no-level.html new file mode 100644 index 0000000000..e321303f3e --- /dev/null +++ b/L2J_Mobius_Classic_2.0_Zaken/dist/game/data/scripts/quests/Q10999_LoserPriest3/no-level.html @@ -0,0 +1,4 @@ +Head Priest of the Earth Gerald:
+You ought to gain more experience. Come back later.
+(This quest is available to characters of Level 15 or higher.)
+ \ No newline at end of file diff --git a/L2J_Mobius_Classic_2.0_Zaken/dist/game/data/scripts/quests/Q10999_LoserPriest3/no-race.html b/L2J_Mobius_Classic_2.0_Zaken/dist/game/data/scripts/quests/Q10999_LoserPriest3/no-race.html new file mode 100644 index 0000000000..52f768eeb0 --- /dev/null +++ b/L2J_Mobius_Classic_2.0_Zaken/dist/game/data/scripts/quests/Q10999_LoserPriest3/no-race.html @@ -0,0 +1,4 @@ +Head Priest of the Earth Gerald:
+I can see you're a stranger here. Pardon me, but I am asking only citizens for help.
+(This quest is available to Dark Elves only.)
+ \ No newline at end of file diff --git a/L2J_Mobius_Classic_2.0_Zaken/dist/game/data/scripts/quests/QuestMasterHandler.java b/L2J_Mobius_Classic_2.0_Zaken/dist/game/data/scripts/quests/QuestMasterHandler.java index 406d9ab4a2..d148c2eb0b 100644 --- a/L2J_Mobius_Classic_2.0_Zaken/dist/game/data/scripts/quests/QuestMasterHandler.java +++ b/L2J_Mobius_Classic_2.0_Zaken/dist/game/data/scripts/quests/QuestMasterHandler.java @@ -149,6 +149,9 @@ import quests.Q00933_ExploringTheWestWingOfTheDungeonOfAbyss.Q00933_ExploringThe import quests.Q00935_ExploringTheEastWingOfTheDungeonOfAbyss.Q00935_ExploringTheEastWingOfTheDungeonOfAbyss; import quests.Q10995_MutualBenefit.Q10995_MutualBenefit; import quests.Q10996_TemplesDecorations.Q10996_TemplesDecorations; +import quests.Q10997_LoserPriest1.Q10997_LoserPriest1; +import quests.Q10998_LoserPriest2.Q10998_LoserPriest2; +import quests.Q10999_LoserPriest3.Q10999_LoserPriest3; import quests.Q11000_MoonKnight.Q11000_MoonKnight; import quests.Q11001_TombsOfAncestors.Q11001_TombsOfAncestors; import quests.Q11002_HelpWithTempleRestoration.Q11002_HelpWithTempleRestoration; @@ -303,6 +306,9 @@ public class QuestMasterHandler Q00935_ExploringTheEastWingOfTheDungeonOfAbyss.class, Q10995_MutualBenefit.class, Q10996_TemplesDecorations.class, + Q10997_LoserPriest1.class, + Q10998_LoserPriest2.class, + Q10999_LoserPriest3.class, Q11000_MoonKnight.class, Q11001_TombsOfAncestors.class, Q11002_HelpWithTempleRestoration.class, diff --git a/L2J_Mobius_Classic_2.0_Zaken/dist/game/data/spawns/Dwarf/DwarfTerritory.xml b/L2J_Mobius_Classic_2.0_Zaken/dist/game/data/spawns/Dwarf/DwarfTerritory.xml index ebe434c586..4475a24484 100644 --- a/L2J_Mobius_Classic_2.0_Zaken/dist/game/data/spawns/Dwarf/DwarfTerritory.xml +++ b/L2J_Mobius_Classic_2.0_Zaken/dist/game/data/spawns/Dwarf/DwarfTerritory.xml @@ -19,6 +19,14 @@ + + + + + + + + \ No newline at end of file