From ac2cc56f0d9441e68b960f4c14d0a4b07e03ba07 Mon Sep 17 00:00:00 2001 From: MobiusDev <8391001+MobiusDevelopment@users.noreply.github.com> Date: Thu, 26 Nov 2015 21:32:43 +0000 Subject: [PATCH] Quest Obtain a Wolf Pet (210). Contributed by Stayway. --- .../Q00210_ObtainAWolfPet/30256-01.html | 4 + .../Q00210_ObtainAWolfPet/30256-02.html | 6 + .../Q00210_ObtainAWolfPet/30256-03.html | 5 + .../Q00210_ObtainAWolfPet/30321-01.html | 4 + .../Q00210_ObtainAWolfPet/30321-02.html | 5 + .../Q00210_ObtainAWolfPet/30335-01.html | 4 + .../Q00210_ObtainAWolfPet/30335-02.html | 5 + .../quests/Q00210_ObtainAWolfPet/30827-01.htm | 4 + .../quests/Q00210_ObtainAWolfPet/30827-02.htm | 4 + .../quests/Q00210_ObtainAWolfPet/30827-03.htm | 4 + .../Q00210_ObtainAWolfPet/30827-04.html | 4 + .../Q00210_ObtainAWolfPet/30827-05.html | 3 + .../Q00210_ObtainAWolfPet/30827-07.html | 4 + .../Q00210_ObtainAWolfPet.java | 184 ++++++++++++++++++ .../quests/Q00210_ObtainAWolfPet/no_level.htm | 3 + .../scripts/quests/QuestMasterHandler.java | 2 + 16 files changed, 245 insertions(+) create mode 100644 trunk/dist/game/data/scripts/quests/Q00210_ObtainAWolfPet/30256-01.html create mode 100644 trunk/dist/game/data/scripts/quests/Q00210_ObtainAWolfPet/30256-02.html create mode 100644 trunk/dist/game/data/scripts/quests/Q00210_ObtainAWolfPet/30256-03.html create mode 100644 trunk/dist/game/data/scripts/quests/Q00210_ObtainAWolfPet/30321-01.html create mode 100644 trunk/dist/game/data/scripts/quests/Q00210_ObtainAWolfPet/30321-02.html create mode 100644 trunk/dist/game/data/scripts/quests/Q00210_ObtainAWolfPet/30335-01.html create mode 100644 trunk/dist/game/data/scripts/quests/Q00210_ObtainAWolfPet/30335-02.html create mode 100644 trunk/dist/game/data/scripts/quests/Q00210_ObtainAWolfPet/30827-01.htm create mode 100644 trunk/dist/game/data/scripts/quests/Q00210_ObtainAWolfPet/30827-02.htm create mode 100644 trunk/dist/game/data/scripts/quests/Q00210_ObtainAWolfPet/30827-03.htm create mode 100644 trunk/dist/game/data/scripts/quests/Q00210_ObtainAWolfPet/30827-04.html create mode 100644 trunk/dist/game/data/scripts/quests/Q00210_ObtainAWolfPet/30827-05.html create mode 100644 trunk/dist/game/data/scripts/quests/Q00210_ObtainAWolfPet/30827-07.html create mode 100644 trunk/dist/game/data/scripts/quests/Q00210_ObtainAWolfPet/Q00210_ObtainAWolfPet.java create mode 100644 trunk/dist/game/data/scripts/quests/Q00210_ObtainAWolfPet/no_level.htm diff --git a/trunk/dist/game/data/scripts/quests/Q00210_ObtainAWolfPet/30256-01.html b/trunk/dist/game/data/scripts/quests/Q00210_ObtainAWolfPet/30256-01.html new file mode 100644 index 0000000000..c1f9b2cd57 --- /dev/null +++ b/trunk/dist/game/data/scripts/quests/Q00210_ObtainAWolfPet/30256-01.html @@ -0,0 +1,4 @@ +Gatekeeper Bella:
+Yes, it is true. I am a Gatekeeper from Ivory Tower and also a member of the Animal Lovers Association. Why have you come? Did Lundy send you?
+ + \ No newline at end of file diff --git a/trunk/dist/game/data/scripts/quests/Q00210_ObtainAWolfPet/30256-02.html b/trunk/dist/game/data/scripts/quests/Q00210_ObtainAWolfPet/30256-02.html new file mode 100644 index 0000000000..cb8b6e7c35 --- /dev/null +++ b/trunk/dist/game/data/scripts/quests/Q00210_ObtainAWolfPet/30256-02.html @@ -0,0 +1,6 @@ +Gatekeeper Bella:
+Pets help their owners in a number of ways.
+If your inventory is low or you have exceeded your weight limit, your pets can carry some of your item. Just be careful not to use your pets too often on errands, no mater how useful they may be.
+Now if your pets die, you can ressurect them without the 24 hour time limit. No need to worry about losing your pets forever!
+ + \ No newline at end of file diff --git a/trunk/dist/game/data/scripts/quests/Q00210_ObtainAWolfPet/30256-03.html b/trunk/dist/game/data/scripts/quests/Q00210_ObtainAWolfPet/30256-03.html new file mode 100644 index 0000000000..49eb29f0fb --- /dev/null +++ b/trunk/dist/game/data/scripts/quests/Q00210_ObtainAWolfPet/30256-03.html @@ -0,0 +1,5 @@ +Gatekeeper Bella:
+How about a wolf for you first pet?
+Wolves are biologically classified as canines. Canines are extremely varied and include dogs, raccoons, foxes, jakals, and even timberwolves. The lifespan of wolves in the wild is unknown, but wolves in captivity can live from 12 to 15 years.
+This is all I can tell you. For more information, go talk to Guard Brynn in the Town of Gludio.
+ \ No newline at end of file diff --git a/trunk/dist/game/data/scripts/quests/Q00210_ObtainAWolfPet/30321-01.html b/trunk/dist/game/data/scripts/quests/Q00210_ObtainAWolfPet/30321-01.html new file mode 100644 index 0000000000..17ec03e15e --- /dev/null +++ b/trunk/dist/game/data/scripts/quests/Q00210_ObtainAWolfPet/30321-01.html @@ -0,0 +1,4 @@ +Trader Sydnia:
+How did you know that I am a member of the Animal Lovers Association? Ah, I see - Mr. Lundy must have mentioned me. So, what can I do for you?
+ + \ No newline at end of file diff --git a/trunk/dist/game/data/scripts/quests/Q00210_ObtainAWolfPet/30321-02.html b/trunk/dist/game/data/scripts/quests/Q00210_ObtainAWolfPet/30321-02.html new file mode 100644 index 0000000000..139ca781bc --- /dev/null +++ b/trunk/dist/game/data/scripts/quests/Q00210_ObtainAWolfPet/30321-02.html @@ -0,0 +1,5 @@ +Trader Sydnia:
+Raising a wolf, are you? Well, there are many things you must know.
+I must first explain their reproductive cycle. A wolf is fertile for 1-2 months, and the pregnancy lasts for approximately Pet Manager Lundy in the Town of Gludio and show off your new knowledge.
+ \ No newline at end of file diff --git a/trunk/dist/game/data/scripts/quests/Q00210_ObtainAWolfPet/30335-01.html b/trunk/dist/game/data/scripts/quests/Q00210_ObtainAWolfPet/30335-01.html new file mode 100644 index 0000000000..48aedd024e --- /dev/null +++ b/trunk/dist/game/data/scripts/quests/Q00210_ObtainAWolfPet/30335-01.html @@ -0,0 +1,4 @@ +Guard Brynn:
+You're right. I am a member of the Animal Lovers Association, too. What brought you here? If you have a question for me, spit it out.
+ + \ No newline at end of file diff --git a/trunk/dist/game/data/scripts/quests/Q00210_ObtainAWolfPet/30335-02.html b/trunk/dist/game/data/scripts/quests/Q00210_ObtainAWolfPet/30335-02.html new file mode 100644 index 0000000000..e70e88c823 --- /dev/null +++ b/trunk/dist/game/data/scripts/quests/Q00210_ObtainAWolfPet/30335-02.html @@ -0,0 +1,5 @@ +Guard Brynn:
+Since you are going to have a wolf as a pet, let me tell you about wolves.
+They have a great sense of smell. They can even smell their prey up to 2.4 km away. When hunting, a pack of 7 to 13 wolves go around together. Every pack is led by a male. Regarding their appearance, fully grown ones weigh less than the average adult human. Some people say that dogs are domesticated wolves. But unlike dogs, wolves drop their tail down at times.
+This is all I can tell you! For more information, go ask Town of Gludio.
+ \ No newline at end of file diff --git a/trunk/dist/game/data/scripts/quests/Q00210_ObtainAWolfPet/30827-01.htm b/trunk/dist/game/data/scripts/quests/Q00210_ObtainAWolfPet/30827-01.htm new file mode 100644 index 0000000000..bafeac56f3 --- /dev/null +++ b/trunk/dist/game/data/scripts/quests/Q00210_ObtainAWolfPet/30827-01.htm @@ -0,0 +1,4 @@ +Pet Manager Lundy:
+So, you have an honest face, but I don't give away pets to just anybody. Let's talk about the right companion for you
+ + \ No newline at end of file diff --git a/trunk/dist/game/data/scripts/quests/Q00210_ObtainAWolfPet/30827-02.htm b/trunk/dist/game/data/scripts/quests/Q00210_ObtainAWolfPet/30827-02.htm new file mode 100644 index 0000000000..e22180bd64 --- /dev/null +++ b/trunk/dist/game/data/scripts/quests/Q00210_ObtainAWolfPet/30827-02.htm @@ -0,0 +1,4 @@ +Pet Manager Lundy:
+To have a pet, you need to know about them. The pet I think is best for you is a wolf, but you'll need to learn the basics about them. Go get some information about pet wolves then come back to me.
+ + \ No newline at end of file diff --git a/trunk/dist/game/data/scripts/quests/Q00210_ObtainAWolfPet/30827-03.htm b/trunk/dist/game/data/scripts/quests/Q00210_ObtainAWolfPet/30827-03.htm new file mode 100644 index 0000000000..227d929080 --- /dev/null +++ b/trunk/dist/game/data/scripts/quests/Q00210_ObtainAWolfPet/30827-03.htm @@ -0,0 +1,4 @@ +Pet Manager Lundy:
+Not from me! The people who can give you information about pet wolves are here in the Town of Gludio
+First, go see Gatekeeper Bella.
+ \ No newline at end of file diff --git a/trunk/dist/game/data/scripts/quests/Q00210_ObtainAWolfPet/30827-04.html b/trunk/dist/game/data/scripts/quests/Q00210_ObtainAWolfPet/30827-04.html new file mode 100644 index 0000000000..dc8de94f75 --- /dev/null +++ b/trunk/dist/game/data/scripts/quests/Q00210_ObtainAWolfPet/30827-04.html @@ -0,0 +1,4 @@ +Pet Manager Lundy:
+I would normally wouldn't give you a pet until testing you about the stories you've heard, but I've received only glowing reports from everyone you talked to. I believe you fully understand how to treat your companion, and are ready for the next step. Here is a Wolf Necklace that will help you handle a pet wolf.
+ + \ No newline at end of file diff --git a/trunk/dist/game/data/scripts/quests/Q00210_ObtainAWolfPet/30827-05.html b/trunk/dist/game/data/scripts/quests/Q00210_ObtainAWolfPet/30827-05.html new file mode 100644 index 0000000000..ca1c95481f --- /dev/null +++ b/trunk/dist/game/data/scripts/quests/Q00210_ObtainAWolfPet/30827-05.html @@ -0,0 +1,3 @@ +Pet Manager Lundy:
+Never lose your compassion and love for animals. If you have more questions about your pets, feel free to come see me.
+ \ No newline at end of file diff --git a/trunk/dist/game/data/scripts/quests/Q00210_ObtainAWolfPet/30827-07.html b/trunk/dist/game/data/scripts/quests/Q00210_ObtainAWolfPet/30827-07.html new file mode 100644 index 0000000000..850cc6f469 --- /dev/null +++ b/trunk/dist/game/data/scripts/quests/Q00210_ObtainAWolfPet/30827-07.html @@ -0,0 +1,4 @@ +Pet Manager Lundy:
+All the people who can give you information about pet wolves are here in the Town of Gludio.
+First, go see Gatekeeper Bella. + \ No newline at end of file diff --git a/trunk/dist/game/data/scripts/quests/Q00210_ObtainAWolfPet/Q00210_ObtainAWolfPet.java b/trunk/dist/game/data/scripts/quests/Q00210_ObtainAWolfPet/Q00210_ObtainAWolfPet.java new file mode 100644 index 0000000000..e566a87816 --- /dev/null +++ b/trunk/dist/game/data/scripts/quests/Q00210_ObtainAWolfPet/Q00210_ObtainAWolfPet.java @@ -0,0 +1,184 @@ +/* + * Copyright (C) 2004-2015 L2J DataPack + * + * This file is part of L2J DataPack. + * + * L2J DataPack is free software: you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation, either version 3 of the License, or + * (at your option) any later version. + * + * L2J DataPack is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program. If not, see . + */ +package quests.Q00210_ObtainAWolfPet; + +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; + +/** + * @author Stayway + */ +public class Q00210_ObtainAWolfPet extends Quest +{ + // NPCs + private static final int LUNDY = 30827; + private static final int BELLA = 30256; + private static final int BYNN = 30335; + private static final int SYDNIA = 30321; + // Items + private static final int WOLF_COLLAR = 2375; + // Misc + private static final int MIN_LEVEL = 15; + + public Q00210_ObtainAWolfPet() + { + super(210, Q00210_ObtainAWolfPet.class.getSimpleName(), "Obtain a Wolf Pet"); + addStartNpc(LUNDY); + addTalkId(LUNDY, BELLA, BYNN, SYDNIA); + addCondMinLevel(MIN_LEVEL, "no_level.htm"); + } + + @Override + public String onAdvEvent(String event, L2Npc npc, L2PcInstance player) + { + String htmltext = event; + final QuestState qs = getQuestState(player, false); + if (qs == null) + { + return htmltext; + } + + switch (event) + { + case "30827-02.htm": + case "30827-04.htm": + case "30256-02.html": + case "30256-03.html": + { + htmltext = event; + break; + } + case "30827-03.htm": + { + qs.startQuest(); + htmltext = event; + break; + } + case "30335-02.html": + { + if (qs.isCond(2)) + { + qs.setCond(3); + htmltext = event; + } + break; + } + case "30321-02.html": + { + if (qs.isCond(3)) + { + qs.setCond(4); + htmltext = event; + } + break; + } + case "30827-05.html": + { + if (qs.isCond(4)) + { + rewardItems(player, WOLF_COLLAR, 1); + qs.exitQuest(false, true); + htmltext = event; + } + break; + } + } + return htmltext; + } + + @Override + public String onTalk(L2Npc npc, L2PcInstance player) + { + String htmltext = getNoQuestMsg(player); + final QuestState qs = getQuestState(player, true); + if (qs == null) + { + return htmltext; + } + + switch (qs.getState()) + { + case State.CREATED: + { + if (npc.getId() == LUNDY) + { + htmltext = "30827-01.htm"; + } + break; + } + case State.STARTED: + { + switch (npc.getId()) + { + case LUNDY: + { + if (qs.isCond(1)) + { + htmltext = "30827-07.html"; + } + else if (qs.isCond(2)) + { + htmltext = "30827-07.html"; + } + else if (qs.isCond(4)) + { + htmltext = "30827-04.html"; + } + break; + } + case BELLA: + { + if (qs.isCond(1)) + { + qs.setCond(2); + htmltext = "30256-01.html"; + } + break; + } + case BYNN: + { + if (qs.isCond(2)) + { + htmltext = "30335-01.html"; + } + break; + } + case SYDNIA: + { + if (qs.isCond(3)) + { + htmltext = "30321-01.html"; + } + break; + } + } + break; + } + case State.COMPLETED: + { + htmltext = getAlreadyCompletedMsg(player); + break; + } + } + return htmltext; + } +} \ No newline at end of file diff --git a/trunk/dist/game/data/scripts/quests/Q00210_ObtainAWolfPet/no_level.htm b/trunk/dist/game/data/scripts/quests/Q00210_ObtainAWolfPet/no_level.htm new file mode 100644 index 0000000000..79526caffb --- /dev/null +++ b/trunk/dist/game/data/scripts/quests/Q00210_ObtainAWolfPet/no_level.htm @@ -0,0 +1,3 @@ +You don't meet level requirements
+(Quest available from level 15 and above) + \ No newline at end of file diff --git a/trunk/dist/game/data/scripts/quests/QuestMasterHandler.java b/trunk/dist/game/data/scripts/quests/QuestMasterHandler.java index 6f85879f03..4511c6b16d 100644 --- a/trunk/dist/game/data/scripts/quests/QuestMasterHandler.java +++ b/trunk/dist/game/data/scripts/quests/QuestMasterHandler.java @@ -87,6 +87,7 @@ import quests.Q00195_SevenSignsSecretRitualOfThePriests.Q00195_SevenSignsSecretR import quests.Q00196_SevenSignsSealOfTheEmperor.Q00196_SevenSignsSealOfTheEmperor; import quests.Q00197_SevenSignsTheSacredBookOfSeal.Q00197_SevenSignsTheSacredBookOfSeal; import quests.Q00198_SevenSignsEmbryo.Q00198_SevenSignsEmbryo; +import quests.Q00210_ObtainAWolfPet.Q00210_ObtainAWolfPet; import quests.Q00237_WindsOfChange.Q00237_WindsOfChange; import quests.Q00238_SuccessFailureOfBusiness.Q00238_SuccessFailureOfBusiness; import quests.Q00239_WontYouJoinUs.Q00239_WontYouJoinUs; @@ -322,6 +323,7 @@ public class QuestMasterHandler Q00196_SevenSignsSealOfTheEmperor.class, Q00197_SevenSignsTheSacredBookOfSeal.class, Q00198_SevenSignsEmbryo.class, + Q00210_ObtainAWolfPet.class, Q00237_WindsOfChange.class, Q00238_SuccessFailureOfBusiness.class, Q00239_WontYouJoinUs.class,