Willie's Special Bait
- ID
- 52
- Название
- Willie's Special Bait
- start_npcs_json
- [31574]
- npc_ids_json
- []
- constants_json
- {"TARLK_EYE":7623,"EARTH_FISHING_LURE":7612}
- Статус разбора
- metadata_only; dynamic Java conditions/rewards retained in source; unresolved starts: []
- Источник
- game/data/scripts/quests/Q00052_WilliesSpecialBait/Q00052_WilliesSpecialBait.java
NPC квеста
Записей нет.
Условия уровней: выражения из Java
htmltext = (player.getLevel() < 48) ? "31574-02.htm" : "31574-01.htm";
Выдача предметов, адены и опыта: выражения из Java
rewardItems(player, EARTH_FISHING_LURE, 4); giveItems(partyMember, TARLK_EYE, 1);
Квесты содержат динамические условия Java. Выражения выдачи включают промежуточные предметы, варианты и случайные награды; это не гарантированная награда. Константы приведены выше. Полные условия — в исходнике.
Тексты квеста
[31574-01.htm] Fishermen's Guild Member Willie: Hi, traveler! You look like an experienced fisherman! You know, if you want to catch something really special, you've got to use special bait! I think you're ready for the big time, my friend! I suggest you try this bait made of Tarlk basilisk's eyes! It pulls the most incredible things from the deep! It's one of the most powerful of my products! It uses the power of the spirit of the land! Will you bring the materials I need to make it for you? What is it for anyways?
[31574-02.htm] Fishermen's Guild Member Willie: Hi, traveler! Have you ever been fishing? You'll find it much more relaxing than the life of a soldier! Why don't you come back and let me teach you to fish when you have the time. It won't be free, but your fishing skill should be exactly level 16. (This quest may only be undertaken by a character of level 48 and above.)
[31574-03.htm] Fishermen's Guild Member Willie: The powers of attraction of elements lie within the elements themselves. The elements are wind, ice, land and flame. Me and some of my buddies at the guild have figured out how to make bait from the elements! I use the power of land. To use it, you must travel all the way to the Forest of Outlaws in Oren. There you'll find Tarlk basilisks, a middle-level spirits of land. Bring me 100 Tarlk basilisks' eyes. I'll make a very special bait for you.
[31574-04.htm] Fishermen's Guild Member Willie: Good job, my friend! You brought everything I need to make the bait! You're really getting a good deal! Well, our guild wants to build our customer base, so we work for free! OK, give me the eyes... "Here they are."
[31574-05.htm] Fishermen's Guild Member Willie: I need 100 Tarlk basilisk's eyes to make the bait. I'm working for free, so the least you can do it bring me the materials I need! Go to the Forest of Outlaws, slaughter the Tarlk basilisks and bring me their eyes.
[31574-06.htm] Fishermen's Guild Member Willie: Thanks for the eyes. Take this bait of land. It finds more valuable items than baits of wind or chill. Remember, this bait only works when your fishing level is exactly 16. Whether or not you land your catch will depend on your skill. Remember, if you catch anything besides fish, bring it to me unopened! Don't even bother bringing me opened boxes.
[31574-07.htm] Fishermen's Guild Member Willie: There aren't 100 Tarlk basilisk's eyes here. This isn't enough to make bait!
Исходник условий и наград (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.Q00052_WilliesSpecialBait;
import org.l2jmobius.gameserver.entity.actor.Npc;
import org.l2jmobius.gameserver.entity.actor.Player;
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;
public class Q00052_WilliesSpecialBait extends Quest
{
// Item
private static final int TARLK_EYE = 7623;
// Reward
private static final int EARTH_FISHING_LURE = 7612;
public Q00052_WilliesSpecialBait()
{
super(52, "Willie's Special Bait");
registerQuestItems(TARLK_EYE);
addStartNpc(31574); // Willie
addTalkId(31574);
addKillId(20573); // Tarlk Basilik
}
@Override
public String onEvent(String event, Npc npc, Player player)
{
String htmltext = event;
final QuestState st = getQuestState(player, false);
if (st == null)
{
return htmltext;
}
if (event.equals("31574-03.htm"))
{
st.startQuest();
}
else if (event.equals("31574-07.htm"))
{
htmltext = "31574-06.htm";
takeItems(player, TARLK_EYE, -1);
rewardItems(player, EARTH_FISHING_LURE, 4);
st.exitQuest(false, true);
}
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:
{
htmltext = (player.getLevel() < 48) ? "31574-02.htm" : "31574-01.htm";
break;
}
case State.STARTED:
{
htmltext = (getQuestItemsCount(player, TARLK_EYE) == 100) ? "31574-04.htm" : "31574-05.htm";
break;
}
case State.COMPLETED:
{
htmltext = getAlreadyCompletedMsg(player);
break;
}
}
return htmltext;
}
@Override
public void onKill(Npc npc, Player player, boolean isSummon)
{
final Player partyMember = getRandomPartyMember(player, 1);
if (partyMember == null)
{
return;
}
final QuestState qs = getQuestState(partyMember, false);
if (getQuestItemsCount(partyMember, TARLK_EYE) < 100)
{
if (getRandom(100) < 33)
{
giveItems(partyMember, TARLK_EYE, 1);
playSound(partyMember, QuestSound.ITEMSOUND_QUEST_ITEMGET);
}
}
if (getQuestItemsCount(partyMember, TARLK_EYE) >= 100)
{
qs.setCond(2, true);
}
}
}