Make a Sewing Kit
- ID
- 36
- Название
- Make a Sewing Kit
- start_npcs_json
- [30847]
- npc_ids_json
- []
- constants_json
- {"REINFORCED_STEEL":7163,"ARTISANS_FRAME":1891,"ORIHARUKON":1893,"SEWING_KIT":7078}
- Статус разбора
- metadata_only; dynamic Java conditions/rewards retained in source; unresolved starts: []
- Источник
- game/data/scripts/quests/Q00036_MakeASewingKit/Q00036_MakeASewingKit.java
NPC квеста
Записей нет.
Условия уровней: выражения из Java
if (player.getLevel() >= 60)
Выдача предметов, адены и опыта: выражения из Java
giveItems(player, SEWING_KIT, 1); giveItems(member, REINFORCED_STEEL, 1);
Квесты содержат динамические условия Java. Выражения выдачи включают промежуточные предметы, варианты и случайные награды; это не гарантированная награда. Константы приведены выше. Полные условия — в исходнике.
Тексты квеста
[30847-0.htm] Head Blacksmith Ferris: What brings you here? Ah, Leikar sent you? The Sewing Kit she ordered, eh? I was just about to get started on it. I'll just be a moment... I must have some scraps of iron around here somewhere... Hmm... I must've used it all up! Hey, I hate to ask you this... But could you get some materials for me? "What do you need?"
[30847-0a.htm] Head Blacksmith Ferris: What brings you here? I was just about to get started on a sewing kit! Right now, I do not have time to talk with you! However, come later. (This quest may only be undertaken by a character who advanced first in Make Formal Wear quest.)
[30847-0b.htm] Head Blacksmith Ferris: What brings you here? Ah, Leikar sent you? The sewing kit she ordered, eh? I was just about to get started on it. I'll just be a moment... I must have some scraps of iron around here somewhere... Hmm... I must've used it all up! Sorry, you'll have to come back later. I'm out of materials. (This quest may only be undertaken by a character of level 60 and above.)
[30847-1.htm] Head Blacksmith Ferris: I need some enchanted iron. It's made by applying magic to Iron Ore. There aren't any Mystics around, so we'll have to improvise... A creature known as the enchanted iron golem can be found in the vicinity of the Ivory Tower. Peel off some of its scrap and bring it to me! I'll need about five pieces. These golems are quite durable, and won't peel away easily. Give it all you've got!
[30847-1a.htm] Head Blacksmith Ferris: What are you still doing here? Where is the enchanted iron you said you'd bring me? Remember? Find the enchanted iron golem in the vicinity of the Ivory Tower, peel off some of its skin and bring it to me! I'll need five pieces. That golem is a sturdy fellow, you'll really need to use all your strength!
[30847-2.htm] Head Blacksmith Ferris: Are these them? Let me see... Ah, yes! The luster, color and hardness... yes, It's definitely enchanted iron! Good job! I hate to ask this, but could you do just one more thing? I'm still lacking some of the ingredients I need to make the sewing kit. Would you obtain them for me too? "What else do you need?"
[30847-3.htm] Head Blacksmith Ferris: I need 10 Artisan's Frames and 10 Oriharukons. Most any Warsmith should be able to make an Artisan's Frame. Finding Oriharukon will be more challenging. Occasionally you can find someone selling it in the village.
[30847-4.htm] Head Blacksmith Ferris: You're a fast worker! Well, let's have them! Here are 10 Artisan's Frames and 10 Oriharukons.
[30847-4a.htm] Head Blacksmith Ferris: You still haven't brought everything I need! I know it's hard work, but you're in a much better position to get it than I am!
[30847-5.htm] Head Blacksmith Ferris: Oh, thank you! You don't mind waiting a moment, do you? It shouldn't take too long... Here's the Sewing kit Leikar requested. It's sturdy, and she can make anything she wants with it! Give Leikar my regards!
Исходник условий и наград (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.Q00036_MakeASewingKit;
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;
import quests.Q00037_MakeFormalWear.Q00037_MakeFormalWear;
public class Q00036_MakeASewingKit extends Quest
{
// Items
private static final int REINFORCED_STEEL = 7163;
private static final int ARTISANS_FRAME = 1891;
private static final int ORIHARUKON = 1893;
// Reward
private static final int SEWING_KIT = 7078;
public Q00036_MakeASewingKit()
{
super(36, "Make a Sewing Kit");
registerQuestItems(REINFORCED_STEEL);
addStartNpc(30847); // Ferris
addTalkId(30847);
addKillId(20566); // Iron Golem
}
@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 "30847-1.htm":
{
st.startQuest();
break;
}
case "30847-3.htm":
{
st.setCond(3, true);
takeItems(player, REINFORCED_STEEL, 5);
break;
}
case "30847-5.htm":
{
if ((getQuestItemsCount(player, ORIHARUKON) >= 10) && (getQuestItemsCount(player, ARTISANS_FRAME) >= 10))
{
takeItems(player, ARTISANS_FRAME, 10);
takeItems(player, ORIHARUKON, 10);
giveItems(player, SEWING_KIT, 1);
st.exitQuest(false, true);
}
else
{
htmltext = "30847-4a.htm";
}
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.getLevel() >= 60)
{
final QuestState fwear = player.getQuestState(Q00037_MakeFormalWear.class.getSimpleName());
if ((fwear != null) && fwear.isCond(6))
{
htmltext = "30847-0.htm";
}
else
{
htmltext = "30847-0a.htm";
}
}
else
{
htmltext = "30847-0b.htm";
}
break;
}
case State.STARTED:
{
final int cond = st.getCond();
if (cond == 1)
{
htmltext = "30847-1a.htm";
}
else if (cond == 2)
{
htmltext = "30847-2.htm";
}
else if (cond == 3)
{
htmltext = ((getQuestItemsCount(player, ORIHARUKON) < 10) || (getQuestItemsCount(player, ARTISANS_FRAME) < 10)) ? "30847-4a.htm" : "30847-4.htm";
}
break;
}
case State.COMPLETED:
{
htmltext = getAlreadyCompletedMsg(player);
break;
}
}
return htmltext;
}
@Override
public void onKill(Npc npc, Player player, boolean isSummon)
{
final Player member = getRandomPartyMember(player, 1);
if ((member != null) && getRandomBoolean())
{
giveItems(member, REINFORCED_STEEL, 1);
if (getQuestItemsCount(member, REINFORCED_STEEL) >= 5)
{
getQuestState(member, false).setCond(2, true);
}
else
{
playSound(member, QuestSound.ITEMSOUND_QUEST_ITEMGET);
}
}
}
}