actual freya branch

This commit is contained in:
2026-09-12 15:39:57 +00:00
parent 9fa534b20e
commit 8049e0a882
18540 changed files with 1228200 additions and 0 deletions
@@ -0,0 +1,7 @@
<html><body>Weaver Olf Kanore:<br>
Select an item from which you wish the seal removed.<br>
<a action="bypass -h Quest PinsAndPouchUnseal 32610-2.htm">Remove the seal on the pin.</a><br>
<a action="bypass -h Quest PinsAndPouchUnseal 32610-3.htm">Remove the seal on the pouch.</a><br>
<a action="bypass -h Quest PinsAndPouchUnseal 32610-4.htm">Remove the seal on the clip.</a><br>
<a action="bypass -h Quest PinsAndPouchUnseal 32610-5.htm">Remove the seal on the accessory.</a>
</body></html>
@@ -0,0 +1,7 @@
<html><body>Weaver Olf Kanore:<br>
Select a magic pin from which to remove the seal. Keep in mind that there is a fee for doing so.<br>
<a action="bypass -h Quest PinsAndPouchUnseal 0_grade_pin">C-Grade Magic Pin (3200 Adena)</a><br>
<a action="bypass -h Quest PinsAndPouchUnseal 1_grade_pin">B-Grade Magic Pin (11,800 Adena)</a><br>
<a action="bypass -h Quest PinsAndPouchUnseal 2_grade_pin">A-Grade Magic Pin (26,500 Adena)</a><br>
<a action="bypass -h Quest PinsAndPouchUnseal 3_grade_pin">S-Grade Magic Pin (136,600 Adena)</a>
</body></html>
@@ -0,0 +1,7 @@
<html><body>Weaver Olf Kanore:<br>
Select a magic pouch from which to remove the seal. Keep in mind that there is a fee for doing so.<br>
<a action="bypass -h Quest PinsAndPouchUnseal 0_grade_pouch">C-Grade Magic Pouch (3200 Adena)</a><br>
<a action="bypass -h Quest PinsAndPouchUnseal 1_grade_pouch">B-Grade Magic Pouch (11,800 Adena)</a><br>
<a action="bypass -h Quest PinsAndPouchUnseal 2_grade_pouch">A-Grade Magic Pouch (26,500 Adena)</a><br>
<a action="bypass -h Quest PinsAndPouchUnseal 3_grade_pouch">S-Grade Magic Pouch (136,600 Adena)</a>
</body></html>
@@ -0,0 +1,5 @@
<html><body>Weaver Olf Kanore:<br>
Select a magic clip from which to remove the seal. Keep in mind that there is a fee for doing so.<br>
<a action="bypass -h Quest PinsAndPouchUnseal 2_grade_clip">A-Grade Magic Clip (26,500 Adena)</a><br>
<a action="bypass -h Quest PinsAndPouchUnseal 3_grade_clip">S-Grade Magic Clip (136,600 Adena)</a>
</body></html>
@@ -0,0 +1,5 @@
<html><body>Weaver Olf Kanore:<br>
Select an accessory from which to remove the seal. Keep in mind that there is a fee for doing so.<br>
<a action="bypass -h Quest PinsAndPouchUnseal 2_grade_ornament">A-Grade Accessory (26,500 Adena)</a><br>
<a action="bypass -h Quest PinsAndPouchUnseal 3_grade_ornament">S-Grade Accessory (136,600 Adena)</a>
</body></html>
@@ -0,0 +1,3 @@
<html><body>Weaver Olf Kanore:<br>
You don't have enough adena.
</body></html>
@@ -0,0 +1,3 @@
<html><body>Weaver Olf Kanore:<br>
I don't see any sealed item here.
</body></html>
@@ -0,0 +1,7 @@
<html><body>Weaver Olf Adams:<br>
Select an item from which you wish the seal removed.<br>
<a action="bypass -h Quest PinsAndPouchUnseal 32612-2.htm">Remove the seal on the pin.</a><br>
<a action="bypass -h Quest PinsAndPouchUnseal 32612-3.htm">Remove the seal on the pouch.</a><br>
<a action="bypass -h Quest PinsAndPouchUnseal 32612-4.htm">Remove the seal on the clip.</a><br>
<a action="bypass -h Quest PinsAndPouchUnseal 32612-5.htm">Remove the seal on the accessory.</a>
</body></html>
@@ -0,0 +1,7 @@
<html><body>Weaver Olf Adams:<br>
Select a magic pin from which to remove the seal. Keep in mind that there is a fee for doing so.<br>
<a action="bypass -h Quest PinsAndPouchUnseal 0_grade_pin">C-Grade Magic Pin (3200 Adena)</a><br>
<a action="bypass -h Quest PinsAndPouchUnseal 1_grade_pin">B-Grade Magic Pin (11,800 Adena)</a><br>
<a action="bypass -h Quest PinsAndPouchUnseal 2_grade_pin">A-Grade Magic Pin (26,500 Adena)</a><br>
<a action="bypass -h Quest PinsAndPouchUnseal 3_grade_pin">S-Grade Magic Pin (136,600 Adena)</a>
</body></html>
@@ -0,0 +1,7 @@
<html><body>Weaver Olf Adams:<br>
Select a magic pouch from which to remove the seal. Keep in mind that there is a fee for doing so.<br>
<a action="bypass -h Quest PinsAndPouchUnseal 0_grade_pouch">C-Grade Magic Pouch (3200 Adena)</a><br>
<a action="bypass -h Quest PinsAndPouchUnseal 1_grade_pouch">B-Grade Magic Pouch (11,800 Adena)</a><br>
<a action="bypass -h Quest PinsAndPouchUnseal 2_grade_pouch">A-Grade Magic Pouch (26,500 Adena)</a><br>
<a action="bypass -h Quest PinsAndPouchUnseal 3_grade_pouch">S-Grade Magic Pouch (136,600 Adena)</a>
</body></html>
@@ -0,0 +1,5 @@
<html><body>Weaver Olf Adams:<br>
Select a magic clip from which to remove the seal. Keep in mind that there is a fee for doing so.<br>
<a action="bypass -h Quest PinsAndPouchUnseal 2_grade_clip">A-Grade Magic Clip (26,500 Adena)</a><br>
<a action="bypass -h Quest PinsAndPouchUnseal 3_grade_clip">S-Grade Magic Clip (136,600 Adena)</a>
</body></html>
@@ -0,0 +1,5 @@
<html><body>Weaver Olf Adams:<br>
Select an accessory from which to remove the seal. Keep in mind that there is a fee for doing so.<br>
<a action="bypass -h Quest PinsAndPouchUnseal 2_grade_ornament">A-Grade Accessory (26,500 Adena)</a><br>
<a action="bypass -h Quest PinsAndPouchUnseal 3_grade_ornament">S-Grade Accessory (136,600 Adena)</a>
</body></html>
@@ -0,0 +1,3 @@
<html><body>Weaver Olf Adams:<br>
You don't have enough adena.
</body></html>
@@ -0,0 +1,3 @@
<html><body>Weaver Olf Adams:<br>
I don't see any sealed item here.
</body></html>
@@ -0,0 +1,146 @@
/*
* 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 <http://www.gnu.org/licenses/>.
*/
package custom.PinsAndPouchUnseal;
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.network.serverpackets.NpcSay;
import com.l2jserver.util.Rnd;
public class PinsAndPouchUnseal extends Quest
{
private final static int[] NPCs =
{
32610,32612
};
private final static int[] UNSEALPRICE = {3200,11800,26500,136600};
// failed, low, mid, high, top
private final static int[] CHANCES = {49,78,95,99,100};
// sealdId, lowId, midId, highId, topId
private final static int[][] PINS = {{13898,13902,13903,13904,13905},
{13899,13906,13907,13908,13909},
{13900,13910,13911,13912,13913},
{13901,13914,13915,13916,13917}
};
// sealdId, lowId, midId, highId, topId
private final static int[][] POUCHS = {{13918,13922,13923,13924,13925},
{13919,13926,13927,13928,13929},
{13920,13930,13931,13932,13933},
{13921,13934,13935,13936,13937}
};
// "B,C grade" is the Magic Clip
// "A,S grade" is the Magic Ornament
// sealdId, lowId, midId, highId, topId
private final static int[][] CLIPSORNAMENTS = {{14902,14906,14907,14908,14909},
{14903,14910,14911,14912,14913},
{14904,14914,14915,14916,14917},
{14905,14918,14919,14920,14921}
};
public PinsAndPouchUnseal(int questId, String name, String descr)
{
super(questId, name, descr);
for (int id : NPCs)
{
addStartNpc(id);
addTalkId(id);
}
}
@Override
public String onAdvEvent(String event, L2Npc npc, L2PcInstance player)
{
String htmltext = "";
QuestState st = player.getQuestState(getName());
htmltext = event;
if (event.contains("_grade_"))
{
int grade = Integer.parseInt(event.substring(0, 1));
int price;
int[] itemIds;
if (event.endsWith("_pin"))
{
price = UNSEALPRICE[grade];
itemIds = PINS[grade];
}
else if (event.endsWith("_pouch"))
{
price = UNSEALPRICE[grade];
itemIds = POUCHS[grade];
}
else if (event.endsWith("_clip"))
{
price = UNSEALPRICE[grade];
itemIds = CLIPSORNAMENTS[grade - 2];
}
else if (event.endsWith("_ornament"))
{
price = UNSEALPRICE[grade];
itemIds = CLIPSORNAMENTS[grade];
}
else
// this should not happen!
return "";
if (st.getQuestItemsCount(itemIds[0]) > 0)
{
if (st.getQuestItemsCount(57) > price)
{
htmltext = "";
st.takeItems(57, price);
st.takeItems(itemIds[0], 1);
int rand = Rnd.get(100);
if (rand < CHANCES[0])
npc.broadcastPacket(new NpcSay(npc.getObjectId(), 0, npc.getNpcId(), 1300162));
else if (rand < CHANCES[1])
st.giveItems(itemIds[1], 1);
else if (rand < CHANCES[2])
st.giveItems(itemIds[2], 1);
else if (rand < CHANCES[3])
st.giveItems(itemIds[3], 1);
else
st.giveItems(itemIds[4], 1);
}
else
htmltext = npc.getNpcId() + "-low.htm";
}
else
htmltext = npc.getNpcId() + "-no.htm";
st.exitQuest(true);
}
return htmltext;
}
@Override
public String onTalk(L2Npc npc, L2PcInstance player)
{
String htmltext = "";
htmltext = npc.getNpcId() + "-1.htm";
return htmltext;
}
public static void main(String[] args)
{
new PinsAndPouchUnseal(-1, "PinsAndPouchUnseal", "custom");
}
}