Blacksmith Rupio:
+Do you want to know how to obtain a brilliant weapon? Then, listen. This will an awesome opportunity for Adventurers who need to grow quickly.
+
+
\ No newline at end of file
diff --git a/L2J_Mobius_5.0_Salvation/dist/game/data/scripts/quests/Q10576_GlitteringWeapons/30471-02.htm b/L2J_Mobius_5.0_Salvation/dist/game/data/scripts/quests/Q10576_GlitteringWeapons/30471-02.htm
new file mode 100644
index 0000000000..2d0ed27808
--- /dev/null
+++ b/L2J_Mobius_5.0_Salvation/dist/game/data/scripts/quests/Q10576_GlitteringWeapons/30471-02.htm
@@ -0,0 +1,5 @@
+Blacksmith Rupio:
+There are a lot of options to make an item stronger, but the best way is Enchantment. It's not just easier, faster, and stronger, if you succeed in enchanting the weapon higher than a certain level, there will be a sparkling effect on the weapon. Isn't that great?
+It isn't that difficult. Why don't you give it a try?
+
+
\ No newline at end of file
diff --git a/L2J_Mobius_5.0_Salvation/dist/game/data/scripts/quests/Q10576_GlitteringWeapons/30471-03.htm b/L2J_Mobius_5.0_Salvation/dist/game/data/scripts/quests/Q10576_GlitteringWeapons/30471-03.htm
new file mode 100644
index 0000000000..9226efbf31
--- /dev/null
+++ b/L2J_Mobius_5.0_Salvation/dist/game/data/scripts/quests/Q10576_GlitteringWeapons/30471-03.htm
@@ -0,0 +1,5 @@
+Blacksmith Rupio:
+Let me tell you. Frst of all, you need a weapon. And then, you need a Scroll: Enchant Weapon appropriate for the grade of your weapon.
+You can get, or buy the Scroll: Enchant Weapon. It doesn't matter how you obtain the scroll, however, you need the scroll for Enchantment. So, if you want to try, you have to have the know-how to get it.
+
+
\ No newline at end of file
diff --git a/L2J_Mobius_5.0_Salvation/dist/game/data/scripts/quests/Q10576_GlitteringWeapons/30471-04.html b/L2J_Mobius_5.0_Salvation/dist/game/data/scripts/quests/Q10576_GlitteringWeapons/30471-04.html
new file mode 100644
index 0000000000..d4314a35c3
--- /dev/null
+++ b/L2J_Mobius_5.0_Salvation/dist/game/data/scripts/quests/Q10576_GlitteringWeapons/30471-04.html
@@ -0,0 +1,6 @@
+Blacksmith Rupio:
+But, there is one way. You can Trade. The thing you desperately need, may be not that useful to others. This goes the other way around too. One man's trash is another man's treasure.
+Therefore, if you utilize the network well, you can get what you want at a minimum cost. Does that make sense?
+But, check the item and the quantity when you are trading. Be wary of those who want to deceive you while trading!
+
+
\ No newline at end of file
diff --git a/L2J_Mobius_5.0_Salvation/dist/game/data/scripts/quests/Q10576_GlitteringWeapons/30471-05.html b/L2J_Mobius_5.0_Salvation/dist/game/data/scripts/quests/Q10576_GlitteringWeapons/30471-05.html
new file mode 100644
index 0000000000..bf3d6508cb
--- /dev/null
+++ b/L2J_Mobius_5.0_Salvation/dist/game/data/scripts/quests/Q10576_GlitteringWeapons/30471-05.html
@@ -0,0 +1,6 @@
+Blacksmith Rupio:
+It is now time for Enchantment. Most equipment can go through Enchantment. While early level Enchantment is always successful, after a certain level, there are possibilities of failure.
+When it fails, everything will come to nothing. You'll lose the weapon, and the Enchantment level will be gone, too.
+I think its the time for practice. Let's make the weapon sparkle!
+
+
\ No newline at end of file
diff --git a/L2J_Mobius_5.0_Salvation/dist/game/data/scripts/quests/Q10576_GlitteringWeapons/30471-06.html b/L2J_Mobius_5.0_Salvation/dist/game/data/scripts/quests/Q10576_GlitteringWeapons/30471-06.html
new file mode 100644
index 0000000000..ea0dad6e2d
--- /dev/null
+++ b/L2J_Mobius_5.0_Salvation/dist/game/data/scripts/quests/Q10576_GlitteringWeapons/30471-06.html
@@ -0,0 +1,5 @@
+Blacksmith Rupio:
+The practice mission is quite simple. Although I talked a lot about how to obtain the items necessary for Enchantment, for now, I'll supply you with the necessary supplies since it's a practice session.
+Here, take the Weapon Enhancing Practice Long Sword and the Practice Weapon Enchant Scroll. Repeat the Enchantment so your Weapon's Enchantment level reaches +7. Use all of the Practice Weapon Enchant Scrolls to reach the level.
+Even if you fail, don't worry. Just come back to me, as I have a Plan B. Good luck to you, then!
+
\ No newline at end of file
diff --git a/L2J_Mobius_5.0_Salvation/dist/game/data/scripts/quests/Q10576_GlitteringWeapons/30471-07.html b/L2J_Mobius_5.0_Salvation/dist/game/data/scripts/quests/Q10576_GlitteringWeapons/30471-07.html
new file mode 100644
index 0000000000..503b2b1fec
--- /dev/null
+++ b/L2J_Mobius_5.0_Salvation/dist/game/data/scripts/quests/Q10576_GlitteringWeapons/30471-07.html
@@ -0,0 +1,6 @@
+Blacksmith Rupio:
+Why did you come back?
+
+
+
+
\ No newline at end of file
diff --git a/L2J_Mobius_5.0_Salvation/dist/game/data/scripts/quests/Q10576_GlitteringWeapons/30471-08.html b/L2J_Mobius_5.0_Salvation/dist/game/data/scripts/quests/Q10576_GlitteringWeapons/30471-08.html
new file mode 100644
index 0000000000..9403c560b0
--- /dev/null
+++ b/L2J_Mobius_5.0_Salvation/dist/game/data/scripts/quests/Q10576_GlitteringWeapons/30471-08.html
@@ -0,0 +1,4 @@
+Blacksmith Rupio:
+Oh, you failed?! But you know, we can learn a lesson from our failures. Now you learned that Enchantment can be a double-edged sword. If you are not careful, you could lose your weapon.
+I'll give you the Enhancement Practice Long Sword and the Practice Weapon Enchant Scroll again. This time, try raising the Enhancement level to +3.
+
\ No newline at end of file
diff --git a/L2J_Mobius_5.0_Salvation/dist/game/data/scripts/quests/Q10576_GlitteringWeapons/30471-09.html b/L2J_Mobius_5.0_Salvation/dist/game/data/scripts/quests/Q10576_GlitteringWeapons/30471-09.html
new file mode 100644
index 0000000000..527b21f970
--- /dev/null
+++ b/L2J_Mobius_5.0_Salvation/dist/game/data/scripts/quests/Q10576_GlitteringWeapons/30471-09.html
@@ -0,0 +1,5 @@
+Blacksmith Rupio:
+You were succesful this time! This amount of Enhancement wasn't difficult, so I knew that you would succeed! Consider this task complete!.
+Good job.
+
+
\ No newline at end of file
diff --git a/L2J_Mobius_5.0_Salvation/dist/game/data/scripts/quests/Q10576_GlitteringWeapons/30471-10.html b/L2J_Mobius_5.0_Salvation/dist/game/data/scripts/quests/Q10576_GlitteringWeapons/30471-10.html
new file mode 100644
index 0000000000..40d45f5f3d
--- /dev/null
+++ b/L2J_Mobius_5.0_Salvation/dist/game/data/scripts/quests/Q10576_GlitteringWeapons/30471-10.html
@@ -0,0 +1,3 @@
+Blacksmith Rupio:
+Any time! With adventurers like you around, Blacksmiths like me have more opportunities to make weapons! It was rewarding for me. Well, I'll see you around!
+
\ No newline at end of file
diff --git a/L2J_Mobius_5.0_Salvation/dist/game/data/scripts/quests/Q10576_GlitteringWeapons/30471-11.html b/L2J_Mobius_5.0_Salvation/dist/game/data/scripts/quests/Q10576_GlitteringWeapons/30471-11.html
new file mode 100644
index 0000000000..1bd7769196
--- /dev/null
+++ b/L2J_Mobius_5.0_Salvation/dist/game/data/scripts/quests/Q10576_GlitteringWeapons/30471-11.html
@@ -0,0 +1,6 @@
+Blacksmith Rupio:
+Do you want to know how to obtain the items needed for Enchantment? OK, I'll tell you again.
+You can Trade to get the item needed. The thing you desperately need, may be not that useful to others. This goes the other way around too. One man's trash is another man's treasure.
+Therefore, if you utilize the network well, you can get what you want at a minimum cost.
+
+
\ No newline at end of file
diff --git a/L2J_Mobius_5.0_Salvation/dist/game/data/scripts/quests/Q10576_GlitteringWeapons/30471-12.html b/L2J_Mobius_5.0_Salvation/dist/game/data/scripts/quests/Q10576_GlitteringWeapons/30471-12.html
new file mode 100644
index 0000000000..4a8df15b0d
--- /dev/null
+++ b/L2J_Mobius_5.0_Salvation/dist/game/data/scripts/quests/Q10576_GlitteringWeapons/30471-12.html
@@ -0,0 +1,7 @@
+Blacksmith Rupio:
+But, check the item and the quantity when you are trading. Be there are those who want to deceive you while trading so be careful!
+This is the method that I mentioned before. I think you'll remember now.
+Any other questions?
+
+
+
\ No newline at end of file
diff --git a/L2J_Mobius_5.0_Salvation/dist/game/data/scripts/quests/Q10576_GlitteringWeapons/30471-13.html b/L2J_Mobius_5.0_Salvation/dist/game/data/scripts/quests/Q10576_GlitteringWeapons/30471-13.html
new file mode 100644
index 0000000000..7fd45aedf1
--- /dev/null
+++ b/L2J_Mobius_5.0_Salvation/dist/game/data/scripts/quests/Q10576_GlitteringWeapons/30471-13.html
@@ -0,0 +1,6 @@
+Blacksmith Rupio:
+Now I'll talk about Enchantment Most equipment can go through Enchantment While early level Enchantment is always successful, after a certain level, there are possibilities of failure.
+If it fails, the Enhance level and the Weapon will be destroyed.
+Keep this in mind. You should have no problem with Enchantment with this knowledge at hand.
+
+
\ No newline at end of file
diff --git a/L2J_Mobius_5.0_Salvation/dist/game/data/scripts/quests/Q10576_GlitteringWeapons/30471-14.html b/L2J_Mobius_5.0_Salvation/dist/game/data/scripts/quests/Q10576_GlitteringWeapons/30471-14.html
new file mode 100644
index 0000000000..9212be93f5
--- /dev/null
+++ b/L2J_Mobius_5.0_Salvation/dist/game/data/scripts/quests/Q10576_GlitteringWeapons/30471-14.html
@@ -0,0 +1,3 @@
+Blacksmith Rupio:
+Now, Enhance the Enhancement Practice Long Sword using the Practice Enchant Scroll that I gave you! Good luck!
+
\ No newline at end of file
diff --git a/L2J_Mobius_5.0_Salvation/dist/game/data/scripts/quests/Q10576_GlitteringWeapons/30471-15.html b/L2J_Mobius_5.0_Salvation/dist/game/data/scripts/quests/Q10576_GlitteringWeapons/30471-15.html
new file mode 100644
index 0000000000..a3ed69e849
--- /dev/null
+++ b/L2J_Mobius_5.0_Salvation/dist/game/data/scripts/quests/Q10576_GlitteringWeapons/30471-15.html
@@ -0,0 +1,3 @@
+Blacksmith Rupio:
+Not successful yet?! Since this is your second time, you only need to raise the Enchantment level to +3. This isn't hard, so don't worry too much about it and go for it!
+
\ No newline at end of file
diff --git a/L2J_Mobius_5.0_Salvation/dist/game/data/scripts/quests/Q10576_GlitteringWeapons/30471-16.html b/L2J_Mobius_5.0_Salvation/dist/game/data/scripts/quests/Q10576_GlitteringWeapons/30471-16.html
new file mode 100644
index 0000000000..15022c6651
--- /dev/null
+++ b/L2J_Mobius_5.0_Salvation/dist/game/data/scripts/quests/Q10576_GlitteringWeapons/30471-16.html
@@ -0,0 +1,3 @@
+Blacksmith Rupio:
+Oh, you still have a sword? Then, you must not have failed! Don't worry and keep going!
+
\ No newline at end of file
diff --git a/L2J_Mobius_5.0_Salvation/dist/game/data/scripts/quests/Q10576_GlitteringWeapons/Q10576_GlitteringWeapons.java b/L2J_Mobius_5.0_Salvation/dist/game/data/scripts/quests/Q10576_GlitteringWeapons/Q10576_GlitteringWeapons.java
new file mode 100644
index 0000000000..a1028d5f15
--- /dev/null
+++ b/L2J_Mobius_5.0_Salvation/dist/game/data/scripts/quests/Q10576_GlitteringWeapons/Q10576_GlitteringWeapons.java
@@ -0,0 +1,222 @@
+/*
+ * 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.Q10576_GlitteringWeapons;
+
+import org.l2jmobius.gameserver.enums.QuestType;
+import org.l2jmobius.gameserver.model.actor.Npc;
+import org.l2jmobius.gameserver.model.actor.instance.PlayerInstance;
+import org.l2jmobius.gameserver.model.events.Containers;
+import org.l2jmobius.gameserver.model.events.EventType;
+import org.l2jmobius.gameserver.model.events.impl.item.OnItemEnchantAdd;
+import org.l2jmobius.gameserver.model.events.listeners.ConsumerEventListener;
+import org.l2jmobius.gameserver.model.quest.Quest;
+import org.l2jmobius.gameserver.model.quest.QuestState;
+import org.l2jmobius.gameserver.model.quest.State;
+import org.l2jmobius.gameserver.network.serverpackets.ExTutorialShowId;
+
+import quests.Q10566_BestChoice.Q10566_BestChoice;
+
+/**
+ * Glittering Weapons (10576)
+ * @URL https://l2wiki.com/Glittering_Weapons
+ * @author NightBR
+ * @html by Werum
+ */
+public final class Q10576_GlitteringWeapons extends Quest
+{
+ // NPCs
+ private static final int RUPIO = 30471;
+ // Item
+ private static final int ENHANCEMENT_PRACTICE_LONG_SWORD = 48170;
+ private static final int PRACTICE_WEAPON_ENCHANT_SCROLL = 48171;
+ // Rewards
+ private static final long XP = 597699960;
+ private static final int SP = 597690;
+ private static final int CERTIFICATE_FROM_RUPIO = 48174;
+ // Misc
+ private static final int MIN_LEVEL = 95;
+
+ public Q10576_GlitteringWeapons()
+ {
+ super(10576);
+ addStartNpc(RUPIO);
+ addTalkId(RUPIO);
+ addCondMinLevel(MIN_LEVEL, "noLevel.html");
+ registerQuestItems(ENHANCEMENT_PRACTICE_LONG_SWORD, PRACTICE_WEAPON_ENCHANT_SCROLL);
+ addCondStartedQuest(Q10566_BestChoice.class.getSimpleName(), "30471-99.html");
+ Containers.Global().addListener(new ConsumerEventListener(Containers.Global(), EventType.ON_ITEM_ENCHANT_ADD, (OnItemEnchantAdd event) -> OnItemEnchantAdd(event), this));
+ }
+
+ @Override
+ public String onAdvEvent(String event, Npc npc, PlayerInstance player)
+ {
+ final QuestState qs = getQuestState(player, false);
+ if (qs == null)
+ {
+ return getNoQuestMsg(player);
+ }
+ String htmltext = null;
+ switch (event)
+ {
+ case "30471-02.htm":
+ case "30471-05.html":
+ case "30471-07.html":
+ case "30471-12.html":
+ case "30471-14.html":
+ {
+ htmltext = event;
+ break;
+ }
+ case "30471-03.htm":
+ {
+ qs.startQuest();
+ htmltext = event;
+ break;
+ }
+ case "30471-04.html":
+ {
+ // show Service/Help/Trade page
+ player.sendPacket(new ExTutorialShowId(56));
+ htmltext = event;
+ break;
+ }
+ case "30471-06.html":
+ {
+ // show Service/Help/Enchant page
+ player.sendPacket(new ExTutorialShowId(38));
+ giveItems(player, ENHANCEMENT_PRACTICE_LONG_SWORD, 1);
+ giveItems(player, PRACTICE_WEAPON_ENCHANT_SCROLL, 7);
+ qs.setCond(2, true);
+ htmltext = event;
+ break;
+ }
+ case "30471-10.html":
+ {
+ // Rewards
+ addExpAndSp(player, XP, SP);
+ giveItems(player, CERTIFICATE_FROM_RUPIO, 1);
+ qs.exitQuest(QuestType.ONE_TIME, true);
+ htmltext = event;
+ break;
+ }
+ case "30471-08.html":
+ {
+ // check if player already have quest items
+ if (hasQuestItems(player, ENHANCEMENT_PRACTICE_LONG_SWORD, PRACTICE_WEAPON_ENCHANT_SCROLL))
+ {
+ htmltext = "30471-16.html";
+ }
+ else
+ {
+ // To make sure player does not have them already
+ removeRegisteredQuestItems(player);
+ giveItems(player, ENHANCEMENT_PRACTICE_LONG_SWORD, 1);
+ giveItems(player, PRACTICE_WEAPON_ENCHANT_SCROLL, 3);
+ qs.setCond(3, true);
+ htmltext = event;
+ }
+ break;
+ }
+ case "30471-11.html":
+ {
+ // show Service/Help/Trade page
+ player.sendPacket(new ExTutorialShowId(56));
+ htmltext = event;
+ break;
+ }
+ case "30471-13.html":
+ {
+ // show Service/Help/Enchant page
+ player.sendPacket(new ExTutorialShowId(38));
+ htmltext = event;
+ break;
+ }
+ }
+ return htmltext;
+ }
+
+ @Override
+ public String onTalk(Npc npc, PlayerInstance player)
+ {
+ final QuestState qs = getQuestState(player, true);
+ String htmltext = getNoQuestMsg(player);
+
+ switch (qs.getState())
+ {
+ case State.CREATED:
+ {
+ htmltext = "30471-01.htm";
+ break;
+ }
+ case State.STARTED:
+ {
+ if (qs.isCond(1))
+ {
+ htmltext = "30471-03.html";
+ }
+ else if (qs.isCond(2))
+ {
+ htmltext = "30471-07.html";
+ }
+ else if (qs.isCond(3))
+ {
+ htmltext = "30471-15.html";
+ }
+ else
+ {
+ htmltext = "30471-09.html";
+ }
+ break;
+ }
+ case State.COMPLETED:
+ {
+ htmltext = getAlreadyCompletedMsg(player);
+ break;
+ }
+ }
+ return htmltext;
+ }
+
+ public void OnItemEnchantAdd(OnItemEnchantAdd event)
+ {
+ final PlayerInstance player = event.getPlayer();
+ if ((player == null) || (event.getItem().getId() != ENHANCEMENT_PRACTICE_LONG_SWORD))
+ {
+ return;
+ }
+
+ final QuestState qs = getQuestState(player, false);
+ // Check if weapon has been augmented to complete the quest
+ if ((qs != null) && qs.isCond(2))
+ {
+ // Check if Item has been destroyed during enchantment process
+ if (!hasQuestItems(player, ENHANCEMENT_PRACTICE_LONG_SWORD))
+ {
+ return;
+ }
+
+ if (player.getInventory().getItemByItemId(ENHANCEMENT_PRACTICE_LONG_SWORD).getEnchantLevel() == 7)
+ {
+ qs.setCond(4, true);
+ }
+ }
+ else if ((qs != null) && qs.isCond(3) && (player.getInventory().getItemByItemId(ENHANCEMENT_PRACTICE_LONG_SWORD).getEnchantLevel() == 3))
+ {
+ qs.setCond(4, true);
+ }
+ }
+}
diff --git a/L2J_Mobius_5.0_Salvation/dist/game/data/scripts/quests/QuestMasterHandler.java b/L2J_Mobius_5.0_Salvation/dist/game/data/scripts/quests/QuestMasterHandler.java
index 3a3e8fbb0c..68f3ef2414 100644
--- a/L2J_Mobius_5.0_Salvation/dist/game/data/scripts/quests/QuestMasterHandler.java
+++ b/L2J_Mobius_5.0_Salvation/dist/game/data/scripts/quests/QuestMasterHandler.java
@@ -356,6 +356,7 @@ import quests.Q10561_AcrossTheDeathLine.Q10561_AcrossTheDeathLine;
import quests.Q10562_TakeUpArms.Q10562_TakeUpArms;
import quests.Q10566_BestChoice.Q10566_BestChoice;
import quests.Q10575_LetsGoFishing.Q10575_LetsGoFishing;
+import quests.Q10576_GlitteringWeapons.Q10576_GlitteringWeapons;
import quests.Q10577_TemperARustingBlade.Q10577_TemperARustingBlade;
import quests.Q10578_TheSoulOfASword.Q10578_TheSoulOfASword;
import quests.Q10579_ContainingTheAttributePower.Q10579_ContainingTheAttributePower;
@@ -914,7 +915,7 @@ public class QuestMasterHandler
Q10572_ToExpelTheEmbryosForces.class, // TODO: Not done.
Q10574_SpecialMissionFortuna.class, // TODO: Not done.
Q10575_LetsGoFishing.class,
- Q10576_GlitteringWeapons.class, // TODO: Not done.
+ Q10576_GlitteringWeapons.class,
Q10577_TemperARustingBlade.class,
Q10578_TheSoulOfASword.class,
Q10579_ContainingTheAttributePower.class,
diff --git a/L2J_Mobius_5.0_Salvation/dist/game/data/scripts/quests/not_done/Q10576_GlitteringWeapons.java b/L2J_Mobius_5.0_Salvation/dist/game/data/scripts/quests/not_done/Q10576_GlitteringWeapons.java
deleted file mode 100644
index 6866cb117b..0000000000
--- a/L2J_Mobius_5.0_Salvation/dist/game/data/scripts/quests/not_done/Q10576_GlitteringWeapons.java
+++ /dev/null
@@ -1,36 +0,0 @@
-/*
- * 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.not_done;
-
-import org.l2jmobius.Config;
-import org.l2jmobius.gameserver.model.quest.Quest;
-
-/**
- * @author Mobius
- */
-public class Q10576_GlitteringWeapons extends Quest
-{
- private static final int START_NPC = 30471;
-
- public Q10576_GlitteringWeapons()
- {
- super(10576);
- addStartNpc(START_NPC);
- addTalkId(START_NPC);
- addCondMinLevel(Config.PLAYER_MAXIMUM_LEVEL, getNoQuestMsg(null));
- }
-}
diff --git a/L2J_Mobius_5.0_Salvation/dist/game/data/stats/items/48100-48199.xml b/L2J_Mobius_5.0_Salvation/dist/game/data/stats/items/48100-48199.xml
index 1174aa2b82..d4df114f5d 100644
--- a/L2J_Mobius_5.0_Salvation/dist/game/data/stats/items/48100-48199.xml
+++ b/L2J_Mobius_5.0_Salvation/dist/game/data/stats/items/48100-48199.xml
@@ -902,6 +902,7 @@
+
@@ -918,13 +919,14 @@
-
+
+
@@ -941,16 +943,20 @@
+
+
+
+ 2417
@@ -972,6 +978,14 @@
+
+
+
+
+
+
+
+
diff --git a/L2J_Mobius_5.0_Salvation/java/org/l2jmobius/gameserver/model/events/EventType.java b/L2J_Mobius_5.0_Salvation/java/org/l2jmobius/gameserver/model/events/EventType.java
index cc88e4a987..424a7e111b 100644
--- a/L2J_Mobius_5.0_Salvation/java/org/l2jmobius/gameserver/model/events/EventType.java
+++ b/L2J_Mobius_5.0_Salvation/java/org/l2jmobius/gameserver/model/events/EventType.java
@@ -123,6 +123,7 @@ import org.l2jmobius.gameserver.model.events.impl.instance.OnInstanceStatusChang
import org.l2jmobius.gameserver.model.events.impl.item.OnItemAttributeAdd;
import org.l2jmobius.gameserver.model.events.impl.item.OnItemBypassEvent;
import org.l2jmobius.gameserver.model.events.impl.item.OnItemCreate;
+import org.l2jmobius.gameserver.model.events.impl.item.OnItemEnchantAdd;
import org.l2jmobius.gameserver.model.events.impl.item.OnItemSoulCrystalAdd;
import org.l2jmobius.gameserver.model.events.impl.item.OnItemTalk;
import org.l2jmobius.gameserver.model.events.impl.olympiad.OnOlympiadMatchResult;
@@ -185,6 +186,7 @@ public enum EventType
ON_ITEM_TALK(OnItemTalk.class, void.class),
ON_ITEM_ATTRIBUTE_ADD(OnItemAttributeAdd.class, void.class),
ON_ITEM_SOUL_CRYSTAL_ADD(OnItemSoulCrystalAdd.class, void.class),
+ ON_ITEM_ENCHANT_ADD(OnItemEnchantAdd.class, void.class),
// NPC events
ON_NPC_CAN_BE_SEEN(OnNpcCanBeSeen.class, void.class, TerminateReturn.class),
diff --git a/L2J_Mobius_5.0_Salvation/java/org/l2jmobius/gameserver/model/events/impl/item/OnItemEnchantAdd.java b/L2J_Mobius_5.0_Salvation/java/org/l2jmobius/gameserver/model/events/impl/item/OnItemEnchantAdd.java
new file mode 100644
index 0000000000..0a7d31c93d
--- /dev/null
+++ b/L2J_Mobius_5.0_Salvation/java/org/l2jmobius/gameserver/model/events/impl/item/OnItemEnchantAdd.java
@@ -0,0 +1,53 @@
+/*
+ * 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 org.l2jmobius.gameserver.model.events.impl.item;
+
+import org.l2jmobius.gameserver.model.actor.instance.PlayerInstance;
+import org.l2jmobius.gameserver.model.events.EventType;
+import org.l2jmobius.gameserver.model.events.impl.IBaseEvent;
+import org.l2jmobius.gameserver.model.items.instance.ItemInstance;
+
+/**
+ * @author NightBR
+ */
+public class OnItemEnchantAdd implements IBaseEvent
+{
+ private final PlayerInstance _player;
+ private final ItemInstance _item;
+
+ public OnItemEnchantAdd(PlayerInstance player, ItemInstance item)
+ {
+ _player = player;
+ _item = item;
+ }
+
+ public PlayerInstance getPlayer()
+ {
+ return _player;
+ }
+
+ public ItemInstance getItem()
+ {
+ return _item;
+ }
+
+ @Override
+ public EventType getType()
+ {
+ return EventType.ON_ITEM_ENCHANT_ADD;
+ }
+}
\ No newline at end of file
diff --git a/L2J_Mobius_5.0_Salvation/java/org/l2jmobius/gameserver/model/items/instance/ItemInstance.java b/L2J_Mobius_5.0_Salvation/java/org/l2jmobius/gameserver/model/items/instance/ItemInstance.java
index 58c4d4b894..da65d00ca5 100644
--- a/L2J_Mobius_5.0_Salvation/java/org/l2jmobius/gameserver/model/items/instance/ItemInstance.java
+++ b/L2J_Mobius_5.0_Salvation/java/org/l2jmobius/gameserver/model/items/instance/ItemInstance.java
@@ -69,6 +69,7 @@ import org.l2jmobius.gameserver.model.events.impl.creature.player.OnPlayerItemDr
import org.l2jmobius.gameserver.model.events.impl.creature.player.OnPlayerItemPickup;
import org.l2jmobius.gameserver.model.events.impl.item.OnItemAttributeAdd;
import org.l2jmobius.gameserver.model.events.impl.item.OnItemBypassEvent;
+import org.l2jmobius.gameserver.model.events.impl.item.OnItemEnchantAdd;
import org.l2jmobius.gameserver.model.events.impl.item.OnItemSoulCrystalAdd;
import org.l2jmobius.gameserver.model.events.impl.item.OnItemTalk;
import org.l2jmobius.gameserver.model.instancezone.Instance;
@@ -943,6 +944,9 @@ public final class ItemInstance extends WorldObject
_enchantLevel = enchantLevel;
applyEnchantStats();
_storedInDb = false;
+
+ // Notify to Scripts
+ EventDispatcher.getInstance().notifyEventAsync(new OnItemEnchantAdd(getActingPlayer(), this));
}
/**
diff --git a/L2J_Mobius_5.5_EtinasFate/dist/game/data/scripts/quests/MissingQuests.txt b/L2J_Mobius_5.5_EtinasFate/dist/game/data/scripts/quests/MissingQuests.txt
index ca5f482212..4317108805 100644
--- a/L2J_Mobius_5.5_EtinasFate/dist/game/data/scripts/quests/MissingQuests.txt
+++ b/L2J_Mobius_5.5_EtinasFate/dist/game/data/scripts/quests/MissingQuests.txt
@@ -196,7 +196,6 @@
10571 Strategic Reconciliation
10572 To Expel the Embryo's Forces
10574 Special Mission: Fortuna
-10576 Glittering Weapons
10580 Special Mission: Defeat Spezion
10594 Fergason's Scheme
10595 The Dimensional Warp, Part 8
diff --git a/L2J_Mobius_5.5_EtinasFate/dist/game/data/scripts/quests/Q10576_GlitteringWeapons/30471-01.htm b/L2J_Mobius_5.5_EtinasFate/dist/game/data/scripts/quests/Q10576_GlitteringWeapons/30471-01.htm
new file mode 100644
index 0000000000..17358886e4
--- /dev/null
+++ b/L2J_Mobius_5.5_EtinasFate/dist/game/data/scripts/quests/Q10576_GlitteringWeapons/30471-01.htm
@@ -0,0 +1,4 @@
+Blacksmith Rupio:
+Do you want to know how to obtain a brilliant weapon? Then, listen. This will an awesome opportunity for Adventurers who need to grow quickly.
+
+
\ No newline at end of file
diff --git a/L2J_Mobius_5.5_EtinasFate/dist/game/data/scripts/quests/Q10576_GlitteringWeapons/30471-02.htm b/L2J_Mobius_5.5_EtinasFate/dist/game/data/scripts/quests/Q10576_GlitteringWeapons/30471-02.htm
new file mode 100644
index 0000000000..2d0ed27808
--- /dev/null
+++ b/L2J_Mobius_5.5_EtinasFate/dist/game/data/scripts/quests/Q10576_GlitteringWeapons/30471-02.htm
@@ -0,0 +1,5 @@
+Blacksmith Rupio:
+There are a lot of options to make an item stronger, but the best way is Enchantment. It's not just easier, faster, and stronger, if you succeed in enchanting the weapon higher than a certain level, there will be a sparkling effect on the weapon. Isn't that great?
+It isn't that difficult. Why don't you give it a try?
+
+
\ No newline at end of file
diff --git a/L2J_Mobius_5.5_EtinasFate/dist/game/data/scripts/quests/Q10576_GlitteringWeapons/30471-03.htm b/L2J_Mobius_5.5_EtinasFate/dist/game/data/scripts/quests/Q10576_GlitteringWeapons/30471-03.htm
new file mode 100644
index 0000000000..9226efbf31
--- /dev/null
+++ b/L2J_Mobius_5.5_EtinasFate/dist/game/data/scripts/quests/Q10576_GlitteringWeapons/30471-03.htm
@@ -0,0 +1,5 @@
+Blacksmith Rupio:
+Let me tell you. Frst of all, you need a weapon. And then, you need a Scroll: Enchant Weapon appropriate for the grade of your weapon.
+You can get, or buy the Scroll: Enchant Weapon. It doesn't matter how you obtain the scroll, however, you need the scroll for Enchantment. So, if you want to try, you have to have the know-how to get it.
+
+
\ No newline at end of file
diff --git a/L2J_Mobius_5.5_EtinasFate/dist/game/data/scripts/quests/Q10576_GlitteringWeapons/30471-04.html b/L2J_Mobius_5.5_EtinasFate/dist/game/data/scripts/quests/Q10576_GlitteringWeapons/30471-04.html
new file mode 100644
index 0000000000..d4314a35c3
--- /dev/null
+++ b/L2J_Mobius_5.5_EtinasFate/dist/game/data/scripts/quests/Q10576_GlitteringWeapons/30471-04.html
@@ -0,0 +1,6 @@
+Blacksmith Rupio:
+But, there is one way. You can Trade. The thing you desperately need, may be not that useful to others. This goes the other way around too. One man's trash is another man's treasure.
+Therefore, if you utilize the network well, you can get what you want at a minimum cost. Does that make sense?
+But, check the item and the quantity when you are trading. Be wary of those who want to deceive you while trading!
+
+
\ No newline at end of file
diff --git a/L2J_Mobius_5.5_EtinasFate/dist/game/data/scripts/quests/Q10576_GlitteringWeapons/30471-05.html b/L2J_Mobius_5.5_EtinasFate/dist/game/data/scripts/quests/Q10576_GlitteringWeapons/30471-05.html
new file mode 100644
index 0000000000..bf3d6508cb
--- /dev/null
+++ b/L2J_Mobius_5.5_EtinasFate/dist/game/data/scripts/quests/Q10576_GlitteringWeapons/30471-05.html
@@ -0,0 +1,6 @@
+Blacksmith Rupio:
+It is now time for Enchantment. Most equipment can go through Enchantment. While early level Enchantment is always successful, after a certain level, there are possibilities of failure.
+When it fails, everything will come to nothing. You'll lose the weapon, and the Enchantment level will be gone, too.
+I think its the time for practice. Let's make the weapon sparkle!
+
+
\ No newline at end of file
diff --git a/L2J_Mobius_5.5_EtinasFate/dist/game/data/scripts/quests/Q10576_GlitteringWeapons/30471-06.html b/L2J_Mobius_5.5_EtinasFate/dist/game/data/scripts/quests/Q10576_GlitteringWeapons/30471-06.html
new file mode 100644
index 0000000000..ea0dad6e2d
--- /dev/null
+++ b/L2J_Mobius_5.5_EtinasFate/dist/game/data/scripts/quests/Q10576_GlitteringWeapons/30471-06.html
@@ -0,0 +1,5 @@
+Blacksmith Rupio:
+The practice mission is quite simple. Although I talked a lot about how to obtain the items necessary for Enchantment, for now, I'll supply you with the necessary supplies since it's a practice session.
+Here, take the Weapon Enhancing Practice Long Sword and the Practice Weapon Enchant Scroll. Repeat the Enchantment so your Weapon's Enchantment level reaches +7. Use all of the Practice Weapon Enchant Scrolls to reach the level.
+Even if you fail, don't worry. Just come back to me, as I have a Plan B. Good luck to you, then!
+
\ No newline at end of file
diff --git a/L2J_Mobius_5.5_EtinasFate/dist/game/data/scripts/quests/Q10576_GlitteringWeapons/30471-07.html b/L2J_Mobius_5.5_EtinasFate/dist/game/data/scripts/quests/Q10576_GlitteringWeapons/30471-07.html
new file mode 100644
index 0000000000..503b2b1fec
--- /dev/null
+++ b/L2J_Mobius_5.5_EtinasFate/dist/game/data/scripts/quests/Q10576_GlitteringWeapons/30471-07.html
@@ -0,0 +1,6 @@
+Blacksmith Rupio:
+Why did you come back?
+
+
+
+
\ No newline at end of file
diff --git a/L2J_Mobius_5.5_EtinasFate/dist/game/data/scripts/quests/Q10576_GlitteringWeapons/30471-08.html b/L2J_Mobius_5.5_EtinasFate/dist/game/data/scripts/quests/Q10576_GlitteringWeapons/30471-08.html
new file mode 100644
index 0000000000..9403c560b0
--- /dev/null
+++ b/L2J_Mobius_5.5_EtinasFate/dist/game/data/scripts/quests/Q10576_GlitteringWeapons/30471-08.html
@@ -0,0 +1,4 @@
+Blacksmith Rupio:
+Oh, you failed?! But you know, we can learn a lesson from our failures. Now you learned that Enchantment can be a double-edged sword. If you are not careful, you could lose your weapon.
+I'll give you the Enhancement Practice Long Sword and the Practice Weapon Enchant Scroll again. This time, try raising the Enhancement level to +3.
+
\ No newline at end of file
diff --git a/L2J_Mobius_5.5_EtinasFate/dist/game/data/scripts/quests/Q10576_GlitteringWeapons/30471-09.html b/L2J_Mobius_5.5_EtinasFate/dist/game/data/scripts/quests/Q10576_GlitteringWeapons/30471-09.html
new file mode 100644
index 0000000000..527b21f970
--- /dev/null
+++ b/L2J_Mobius_5.5_EtinasFate/dist/game/data/scripts/quests/Q10576_GlitteringWeapons/30471-09.html
@@ -0,0 +1,5 @@
+Blacksmith Rupio:
+You were succesful this time! This amount of Enhancement wasn't difficult, so I knew that you would succeed! Consider this task complete!.
+Good job.
+
+
\ No newline at end of file
diff --git a/L2J_Mobius_5.5_EtinasFate/dist/game/data/scripts/quests/Q10576_GlitteringWeapons/30471-10.html b/L2J_Mobius_5.5_EtinasFate/dist/game/data/scripts/quests/Q10576_GlitteringWeapons/30471-10.html
new file mode 100644
index 0000000000..40d45f5f3d
--- /dev/null
+++ b/L2J_Mobius_5.5_EtinasFate/dist/game/data/scripts/quests/Q10576_GlitteringWeapons/30471-10.html
@@ -0,0 +1,3 @@
+Blacksmith Rupio:
+Any time! With adventurers like you around, Blacksmiths like me have more opportunities to make weapons! It was rewarding for me. Well, I'll see you around!
+
\ No newline at end of file
diff --git a/L2J_Mobius_5.5_EtinasFate/dist/game/data/scripts/quests/Q10576_GlitteringWeapons/30471-11.html b/L2J_Mobius_5.5_EtinasFate/dist/game/data/scripts/quests/Q10576_GlitteringWeapons/30471-11.html
new file mode 100644
index 0000000000..1bd7769196
--- /dev/null
+++ b/L2J_Mobius_5.5_EtinasFate/dist/game/data/scripts/quests/Q10576_GlitteringWeapons/30471-11.html
@@ -0,0 +1,6 @@
+Blacksmith Rupio:
+Do you want to know how to obtain the items needed for Enchantment? OK, I'll tell you again.
+You can Trade to get the item needed. The thing you desperately need, may be not that useful to others. This goes the other way around too. One man's trash is another man's treasure.
+Therefore, if you utilize the network well, you can get what you want at a minimum cost.
+
+
\ No newline at end of file
diff --git a/L2J_Mobius_5.5_EtinasFate/dist/game/data/scripts/quests/Q10576_GlitteringWeapons/30471-12.html b/L2J_Mobius_5.5_EtinasFate/dist/game/data/scripts/quests/Q10576_GlitteringWeapons/30471-12.html
new file mode 100644
index 0000000000..4a8df15b0d
--- /dev/null
+++ b/L2J_Mobius_5.5_EtinasFate/dist/game/data/scripts/quests/Q10576_GlitteringWeapons/30471-12.html
@@ -0,0 +1,7 @@
+Blacksmith Rupio:
+But, check the item and the quantity when you are trading. Be there are those who want to deceive you while trading so be careful!
+This is the method that I mentioned before. I think you'll remember now.
+Any other questions?
+
+
+
\ No newline at end of file
diff --git a/L2J_Mobius_5.5_EtinasFate/dist/game/data/scripts/quests/Q10576_GlitteringWeapons/30471-13.html b/L2J_Mobius_5.5_EtinasFate/dist/game/data/scripts/quests/Q10576_GlitteringWeapons/30471-13.html
new file mode 100644
index 0000000000..7fd45aedf1
--- /dev/null
+++ b/L2J_Mobius_5.5_EtinasFate/dist/game/data/scripts/quests/Q10576_GlitteringWeapons/30471-13.html
@@ -0,0 +1,6 @@
+Blacksmith Rupio:
+Now I'll talk about Enchantment Most equipment can go through Enchantment While early level Enchantment is always successful, after a certain level, there are possibilities of failure.
+If it fails, the Enhance level and the Weapon will be destroyed.
+Keep this in mind. You should have no problem with Enchantment with this knowledge at hand.
+
+
\ No newline at end of file
diff --git a/L2J_Mobius_5.5_EtinasFate/dist/game/data/scripts/quests/Q10576_GlitteringWeapons/30471-14.html b/L2J_Mobius_5.5_EtinasFate/dist/game/data/scripts/quests/Q10576_GlitteringWeapons/30471-14.html
new file mode 100644
index 0000000000..9212be93f5
--- /dev/null
+++ b/L2J_Mobius_5.5_EtinasFate/dist/game/data/scripts/quests/Q10576_GlitteringWeapons/30471-14.html
@@ -0,0 +1,3 @@
+Blacksmith Rupio:
+Now, Enhance the Enhancement Practice Long Sword using the Practice Enchant Scroll that I gave you! Good luck!
+
\ No newline at end of file
diff --git a/L2J_Mobius_5.5_EtinasFate/dist/game/data/scripts/quests/Q10576_GlitteringWeapons/30471-15.html b/L2J_Mobius_5.5_EtinasFate/dist/game/data/scripts/quests/Q10576_GlitteringWeapons/30471-15.html
new file mode 100644
index 0000000000..a3ed69e849
--- /dev/null
+++ b/L2J_Mobius_5.5_EtinasFate/dist/game/data/scripts/quests/Q10576_GlitteringWeapons/30471-15.html
@@ -0,0 +1,3 @@
+Blacksmith Rupio:
+Not successful yet?! Since this is your second time, you only need to raise the Enchantment level to +3. This isn't hard, so don't worry too much about it and go for it!
+
\ No newline at end of file
diff --git a/L2J_Mobius_5.5_EtinasFate/dist/game/data/scripts/quests/Q10576_GlitteringWeapons/30471-16.html b/L2J_Mobius_5.5_EtinasFate/dist/game/data/scripts/quests/Q10576_GlitteringWeapons/30471-16.html
new file mode 100644
index 0000000000..15022c6651
--- /dev/null
+++ b/L2J_Mobius_5.5_EtinasFate/dist/game/data/scripts/quests/Q10576_GlitteringWeapons/30471-16.html
@@ -0,0 +1,3 @@
+Blacksmith Rupio:
+Oh, you still have a sword? Then, you must not have failed! Don't worry and keep going!
+
\ No newline at end of file
diff --git a/L2J_Mobius_5.5_EtinasFate/dist/game/data/scripts/quests/Q10576_GlitteringWeapons/Q10576_GlitteringWeapons.java b/L2J_Mobius_5.5_EtinasFate/dist/game/data/scripts/quests/Q10576_GlitteringWeapons/Q10576_GlitteringWeapons.java
new file mode 100644
index 0000000000..a1028d5f15
--- /dev/null
+++ b/L2J_Mobius_5.5_EtinasFate/dist/game/data/scripts/quests/Q10576_GlitteringWeapons/Q10576_GlitteringWeapons.java
@@ -0,0 +1,222 @@
+/*
+ * 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.Q10576_GlitteringWeapons;
+
+import org.l2jmobius.gameserver.enums.QuestType;
+import org.l2jmobius.gameserver.model.actor.Npc;
+import org.l2jmobius.gameserver.model.actor.instance.PlayerInstance;
+import org.l2jmobius.gameserver.model.events.Containers;
+import org.l2jmobius.gameserver.model.events.EventType;
+import org.l2jmobius.gameserver.model.events.impl.item.OnItemEnchantAdd;
+import org.l2jmobius.gameserver.model.events.listeners.ConsumerEventListener;
+import org.l2jmobius.gameserver.model.quest.Quest;
+import org.l2jmobius.gameserver.model.quest.QuestState;
+import org.l2jmobius.gameserver.model.quest.State;
+import org.l2jmobius.gameserver.network.serverpackets.ExTutorialShowId;
+
+import quests.Q10566_BestChoice.Q10566_BestChoice;
+
+/**
+ * Glittering Weapons (10576)
+ * @URL https://l2wiki.com/Glittering_Weapons
+ * @author NightBR
+ * @html by Werum
+ */
+public final class Q10576_GlitteringWeapons extends Quest
+{
+ // NPCs
+ private static final int RUPIO = 30471;
+ // Item
+ private static final int ENHANCEMENT_PRACTICE_LONG_SWORD = 48170;
+ private static final int PRACTICE_WEAPON_ENCHANT_SCROLL = 48171;
+ // Rewards
+ private static final long XP = 597699960;
+ private static final int SP = 597690;
+ private static final int CERTIFICATE_FROM_RUPIO = 48174;
+ // Misc
+ private static final int MIN_LEVEL = 95;
+
+ public Q10576_GlitteringWeapons()
+ {
+ super(10576);
+ addStartNpc(RUPIO);
+ addTalkId(RUPIO);
+ addCondMinLevel(MIN_LEVEL, "noLevel.html");
+ registerQuestItems(ENHANCEMENT_PRACTICE_LONG_SWORD, PRACTICE_WEAPON_ENCHANT_SCROLL);
+ addCondStartedQuest(Q10566_BestChoice.class.getSimpleName(), "30471-99.html");
+ Containers.Global().addListener(new ConsumerEventListener(Containers.Global(), EventType.ON_ITEM_ENCHANT_ADD, (OnItemEnchantAdd event) -> OnItemEnchantAdd(event), this));
+ }
+
+ @Override
+ public String onAdvEvent(String event, Npc npc, PlayerInstance player)
+ {
+ final QuestState qs = getQuestState(player, false);
+ if (qs == null)
+ {
+ return getNoQuestMsg(player);
+ }
+ String htmltext = null;
+ switch (event)
+ {
+ case "30471-02.htm":
+ case "30471-05.html":
+ case "30471-07.html":
+ case "30471-12.html":
+ case "30471-14.html":
+ {
+ htmltext = event;
+ break;
+ }
+ case "30471-03.htm":
+ {
+ qs.startQuest();
+ htmltext = event;
+ break;
+ }
+ case "30471-04.html":
+ {
+ // show Service/Help/Trade page
+ player.sendPacket(new ExTutorialShowId(56));
+ htmltext = event;
+ break;
+ }
+ case "30471-06.html":
+ {
+ // show Service/Help/Enchant page
+ player.sendPacket(new ExTutorialShowId(38));
+ giveItems(player, ENHANCEMENT_PRACTICE_LONG_SWORD, 1);
+ giveItems(player, PRACTICE_WEAPON_ENCHANT_SCROLL, 7);
+ qs.setCond(2, true);
+ htmltext = event;
+ break;
+ }
+ case "30471-10.html":
+ {
+ // Rewards
+ addExpAndSp(player, XP, SP);
+ giveItems(player, CERTIFICATE_FROM_RUPIO, 1);
+ qs.exitQuest(QuestType.ONE_TIME, true);
+ htmltext = event;
+ break;
+ }
+ case "30471-08.html":
+ {
+ // check if player already have quest items
+ if (hasQuestItems(player, ENHANCEMENT_PRACTICE_LONG_SWORD, PRACTICE_WEAPON_ENCHANT_SCROLL))
+ {
+ htmltext = "30471-16.html";
+ }
+ else
+ {
+ // To make sure player does not have them already
+ removeRegisteredQuestItems(player);
+ giveItems(player, ENHANCEMENT_PRACTICE_LONG_SWORD, 1);
+ giveItems(player, PRACTICE_WEAPON_ENCHANT_SCROLL, 3);
+ qs.setCond(3, true);
+ htmltext = event;
+ }
+ break;
+ }
+ case "30471-11.html":
+ {
+ // show Service/Help/Trade page
+ player.sendPacket(new ExTutorialShowId(56));
+ htmltext = event;
+ break;
+ }
+ case "30471-13.html":
+ {
+ // show Service/Help/Enchant page
+ player.sendPacket(new ExTutorialShowId(38));
+ htmltext = event;
+ break;
+ }
+ }
+ return htmltext;
+ }
+
+ @Override
+ public String onTalk(Npc npc, PlayerInstance player)
+ {
+ final QuestState qs = getQuestState(player, true);
+ String htmltext = getNoQuestMsg(player);
+
+ switch (qs.getState())
+ {
+ case State.CREATED:
+ {
+ htmltext = "30471-01.htm";
+ break;
+ }
+ case State.STARTED:
+ {
+ if (qs.isCond(1))
+ {
+ htmltext = "30471-03.html";
+ }
+ else if (qs.isCond(2))
+ {
+ htmltext = "30471-07.html";
+ }
+ else if (qs.isCond(3))
+ {
+ htmltext = "30471-15.html";
+ }
+ else
+ {
+ htmltext = "30471-09.html";
+ }
+ break;
+ }
+ case State.COMPLETED:
+ {
+ htmltext = getAlreadyCompletedMsg(player);
+ break;
+ }
+ }
+ return htmltext;
+ }
+
+ public void OnItemEnchantAdd(OnItemEnchantAdd event)
+ {
+ final PlayerInstance player = event.getPlayer();
+ if ((player == null) || (event.getItem().getId() != ENHANCEMENT_PRACTICE_LONG_SWORD))
+ {
+ return;
+ }
+
+ final QuestState qs = getQuestState(player, false);
+ // Check if weapon has been augmented to complete the quest
+ if ((qs != null) && qs.isCond(2))
+ {
+ // Check if Item has been destroyed during enchantment process
+ if (!hasQuestItems(player, ENHANCEMENT_PRACTICE_LONG_SWORD))
+ {
+ return;
+ }
+
+ if (player.getInventory().getItemByItemId(ENHANCEMENT_PRACTICE_LONG_SWORD).getEnchantLevel() == 7)
+ {
+ qs.setCond(4, true);
+ }
+ }
+ else if ((qs != null) && qs.isCond(3) && (player.getInventory().getItemByItemId(ENHANCEMENT_PRACTICE_LONG_SWORD).getEnchantLevel() == 3))
+ {
+ qs.setCond(4, true);
+ }
+ }
+}
diff --git a/L2J_Mobius_5.5_EtinasFate/dist/game/data/scripts/quests/QuestMasterHandler.java b/L2J_Mobius_5.5_EtinasFate/dist/game/data/scripts/quests/QuestMasterHandler.java
index c30181a248..1a9ac32925 100644
--- a/L2J_Mobius_5.5_EtinasFate/dist/game/data/scripts/quests/QuestMasterHandler.java
+++ b/L2J_Mobius_5.5_EtinasFate/dist/game/data/scripts/quests/QuestMasterHandler.java
@@ -310,6 +310,7 @@ import quests.Q10561_AcrossTheDeathLine.Q10561_AcrossTheDeathLine;
import quests.Q10562_TakeUpArms.Q10562_TakeUpArms;
import quests.Q10566_BestChoice.Q10566_BestChoice;
import quests.Q10575_LetsGoFishing.Q10575_LetsGoFishing;
+import quests.Q10576_GlitteringWeapons.Q10576_GlitteringWeapons;
import quests.Q10577_TemperARustingBlade.Q10577_TemperARustingBlade;
import quests.Q10578_TheSoulOfASword.Q10578_TheSoulOfASword;
import quests.Q10579_ContainingTheAttributePower.Q10579_ContainingTheAttributePower;
@@ -827,7 +828,7 @@ public class QuestMasterHandler
Q10572_ToExpelTheEmbryosForces.class, // TODO: Not done.
Q10574_SpecialMissionFortuna.class, // TODO: Not done.
Q10575_LetsGoFishing.class,
- Q10576_GlitteringWeapons.class, // TODO: Not done.
+ Q10576_GlitteringWeapons.class,
Q10577_TemperARustingBlade.class,
Q10578_TheSoulOfASword.class,
Q10579_ContainingTheAttributePower.class,
diff --git a/L2J_Mobius_5.5_EtinasFate/dist/game/data/scripts/quests/not_done/Q10576_GlitteringWeapons.java b/L2J_Mobius_5.5_EtinasFate/dist/game/data/scripts/quests/not_done/Q10576_GlitteringWeapons.java
deleted file mode 100644
index 6866cb117b..0000000000
--- a/L2J_Mobius_5.5_EtinasFate/dist/game/data/scripts/quests/not_done/Q10576_GlitteringWeapons.java
+++ /dev/null
@@ -1,36 +0,0 @@
-/*
- * 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.not_done;
-
-import org.l2jmobius.Config;
-import org.l2jmobius.gameserver.model.quest.Quest;
-
-/**
- * @author Mobius
- */
-public class Q10576_GlitteringWeapons extends Quest
-{
- private static final int START_NPC = 30471;
-
- public Q10576_GlitteringWeapons()
- {
- super(10576);
- addStartNpc(START_NPC);
- addTalkId(START_NPC);
- addCondMinLevel(Config.PLAYER_MAXIMUM_LEVEL, getNoQuestMsg(null));
- }
-}
diff --git a/L2J_Mobius_5.5_EtinasFate/dist/game/data/stats/items/48100-48199.xml b/L2J_Mobius_5.5_EtinasFate/dist/game/data/stats/items/48100-48199.xml
index 93b4cb32da..db5e47b46c 100644
--- a/L2J_Mobius_5.5_EtinasFate/dist/game/data/stats/items/48100-48199.xml
+++ b/L2J_Mobius_5.5_EtinasFate/dist/game/data/stats/items/48100-48199.xml
@@ -902,6 +902,7 @@
+
@@ -925,6 +926,7 @@
+
@@ -941,16 +943,20 @@
+
+
+
+ 2417
@@ -972,6 +978,14 @@
+
+
+
+
+
+
+
+
diff --git a/L2J_Mobius_5.5_EtinasFate/java/org/l2jmobius/gameserver/model/events/EventType.java b/L2J_Mobius_5.5_EtinasFate/java/org/l2jmobius/gameserver/model/events/EventType.java
index cc88e4a987..424a7e111b 100644
--- a/L2J_Mobius_5.5_EtinasFate/java/org/l2jmobius/gameserver/model/events/EventType.java
+++ b/L2J_Mobius_5.5_EtinasFate/java/org/l2jmobius/gameserver/model/events/EventType.java
@@ -123,6 +123,7 @@ import org.l2jmobius.gameserver.model.events.impl.instance.OnInstanceStatusChang
import org.l2jmobius.gameserver.model.events.impl.item.OnItemAttributeAdd;
import org.l2jmobius.gameserver.model.events.impl.item.OnItemBypassEvent;
import org.l2jmobius.gameserver.model.events.impl.item.OnItemCreate;
+import org.l2jmobius.gameserver.model.events.impl.item.OnItemEnchantAdd;
import org.l2jmobius.gameserver.model.events.impl.item.OnItemSoulCrystalAdd;
import org.l2jmobius.gameserver.model.events.impl.item.OnItemTalk;
import org.l2jmobius.gameserver.model.events.impl.olympiad.OnOlympiadMatchResult;
@@ -185,6 +186,7 @@ public enum EventType
ON_ITEM_TALK(OnItemTalk.class, void.class),
ON_ITEM_ATTRIBUTE_ADD(OnItemAttributeAdd.class, void.class),
ON_ITEM_SOUL_CRYSTAL_ADD(OnItemSoulCrystalAdd.class, void.class),
+ ON_ITEM_ENCHANT_ADD(OnItemEnchantAdd.class, void.class),
// NPC events
ON_NPC_CAN_BE_SEEN(OnNpcCanBeSeen.class, void.class, TerminateReturn.class),
diff --git a/L2J_Mobius_5.5_EtinasFate/java/org/l2jmobius/gameserver/model/events/impl/item/OnItemEnchantAdd.java b/L2J_Mobius_5.5_EtinasFate/java/org/l2jmobius/gameserver/model/events/impl/item/OnItemEnchantAdd.java
new file mode 100644
index 0000000000..0a7d31c93d
--- /dev/null
+++ b/L2J_Mobius_5.5_EtinasFate/java/org/l2jmobius/gameserver/model/events/impl/item/OnItemEnchantAdd.java
@@ -0,0 +1,53 @@
+/*
+ * 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 org.l2jmobius.gameserver.model.events.impl.item;
+
+import org.l2jmobius.gameserver.model.actor.instance.PlayerInstance;
+import org.l2jmobius.gameserver.model.events.EventType;
+import org.l2jmobius.gameserver.model.events.impl.IBaseEvent;
+import org.l2jmobius.gameserver.model.items.instance.ItemInstance;
+
+/**
+ * @author NightBR
+ */
+public class OnItemEnchantAdd implements IBaseEvent
+{
+ private final PlayerInstance _player;
+ private final ItemInstance _item;
+
+ public OnItemEnchantAdd(PlayerInstance player, ItemInstance item)
+ {
+ _player = player;
+ _item = item;
+ }
+
+ public PlayerInstance getPlayer()
+ {
+ return _player;
+ }
+
+ public ItemInstance getItem()
+ {
+ return _item;
+ }
+
+ @Override
+ public EventType getType()
+ {
+ return EventType.ON_ITEM_ENCHANT_ADD;
+ }
+}
\ No newline at end of file
diff --git a/L2J_Mobius_5.5_EtinasFate/java/org/l2jmobius/gameserver/model/items/instance/ItemInstance.java b/L2J_Mobius_5.5_EtinasFate/java/org/l2jmobius/gameserver/model/items/instance/ItemInstance.java
index 58c4d4b894..da65d00ca5 100644
--- a/L2J_Mobius_5.5_EtinasFate/java/org/l2jmobius/gameserver/model/items/instance/ItemInstance.java
+++ b/L2J_Mobius_5.5_EtinasFate/java/org/l2jmobius/gameserver/model/items/instance/ItemInstance.java
@@ -69,6 +69,7 @@ import org.l2jmobius.gameserver.model.events.impl.creature.player.OnPlayerItemDr
import org.l2jmobius.gameserver.model.events.impl.creature.player.OnPlayerItemPickup;
import org.l2jmobius.gameserver.model.events.impl.item.OnItemAttributeAdd;
import org.l2jmobius.gameserver.model.events.impl.item.OnItemBypassEvent;
+import org.l2jmobius.gameserver.model.events.impl.item.OnItemEnchantAdd;
import org.l2jmobius.gameserver.model.events.impl.item.OnItemSoulCrystalAdd;
import org.l2jmobius.gameserver.model.events.impl.item.OnItemTalk;
import org.l2jmobius.gameserver.model.instancezone.Instance;
@@ -943,6 +944,9 @@ public final class ItemInstance extends WorldObject
_enchantLevel = enchantLevel;
applyEnchantStats();
_storedInDb = false;
+
+ // Notify to Scripts
+ EventDispatcher.getInstance().notifyEventAsync(new OnItemEnchantAdd(getActingPlayer(), this));
}
/**
diff --git a/L2J_Mobius_6.0_Fafurion/dist/game/data/scripts/quests/MissingQuests.txt b/L2J_Mobius_6.0_Fafurion/dist/game/data/scripts/quests/MissingQuests.txt
index ef619b7ba1..8d87bc619e 100644
--- a/L2J_Mobius_6.0_Fafurion/dist/game/data/scripts/quests/MissingQuests.txt
+++ b/L2J_Mobius_6.0_Fafurion/dist/game/data/scripts/quests/MissingQuests.txt
@@ -201,7 +201,8 @@
10570 Hurrah for Kamael's Independence
10571 Strategic Reconciliation
10572 To Expel the Embryo's Forces
-10576 Glittering Weapons
+10577 Temper a Rusting Blade
+10578 The Soul of a Sword
10580 Special Mission: Defeat Spezion
10588 Special Mission: Defeat Baylor
10594 Fergason's Scheme
diff --git a/L2J_Mobius_6.0_Fafurion/dist/game/data/scripts/quests/Q10576_GlitteringWeapons/30471-01.htm b/L2J_Mobius_6.0_Fafurion/dist/game/data/scripts/quests/Q10576_GlitteringWeapons/30471-01.htm
new file mode 100644
index 0000000000..17358886e4
--- /dev/null
+++ b/L2J_Mobius_6.0_Fafurion/dist/game/data/scripts/quests/Q10576_GlitteringWeapons/30471-01.htm
@@ -0,0 +1,4 @@
+Blacksmith Rupio:
+Do you want to know how to obtain a brilliant weapon? Then, listen. This will an awesome opportunity for Adventurers who need to grow quickly.
+
+
\ No newline at end of file
diff --git a/L2J_Mobius_6.0_Fafurion/dist/game/data/scripts/quests/Q10576_GlitteringWeapons/30471-02.htm b/L2J_Mobius_6.0_Fafurion/dist/game/data/scripts/quests/Q10576_GlitteringWeapons/30471-02.htm
new file mode 100644
index 0000000000..2d0ed27808
--- /dev/null
+++ b/L2J_Mobius_6.0_Fafurion/dist/game/data/scripts/quests/Q10576_GlitteringWeapons/30471-02.htm
@@ -0,0 +1,5 @@
+Blacksmith Rupio:
+There are a lot of options to make an item stronger, but the best way is Enchantment. It's not just easier, faster, and stronger, if you succeed in enchanting the weapon higher than a certain level, there will be a sparkling effect on the weapon. Isn't that great?
+It isn't that difficult. Why don't you give it a try?
+
+
\ No newline at end of file
diff --git a/L2J_Mobius_6.0_Fafurion/dist/game/data/scripts/quests/Q10576_GlitteringWeapons/30471-03.htm b/L2J_Mobius_6.0_Fafurion/dist/game/data/scripts/quests/Q10576_GlitteringWeapons/30471-03.htm
new file mode 100644
index 0000000000..9226efbf31
--- /dev/null
+++ b/L2J_Mobius_6.0_Fafurion/dist/game/data/scripts/quests/Q10576_GlitteringWeapons/30471-03.htm
@@ -0,0 +1,5 @@
+Blacksmith Rupio:
+Let me tell you. Frst of all, you need a weapon. And then, you need a Scroll: Enchant Weapon appropriate for the grade of your weapon.
+You can get, or buy the Scroll: Enchant Weapon. It doesn't matter how you obtain the scroll, however, you need the scroll for Enchantment. So, if you want to try, you have to have the know-how to get it.
+
+
\ No newline at end of file
diff --git a/L2J_Mobius_6.0_Fafurion/dist/game/data/scripts/quests/Q10576_GlitteringWeapons/30471-04.html b/L2J_Mobius_6.0_Fafurion/dist/game/data/scripts/quests/Q10576_GlitteringWeapons/30471-04.html
new file mode 100644
index 0000000000..d4314a35c3
--- /dev/null
+++ b/L2J_Mobius_6.0_Fafurion/dist/game/data/scripts/quests/Q10576_GlitteringWeapons/30471-04.html
@@ -0,0 +1,6 @@
+Blacksmith Rupio:
+But, there is one way. You can Trade. The thing you desperately need, may be not that useful to others. This goes the other way around too. One man's trash is another man's treasure.
+Therefore, if you utilize the network well, you can get what you want at a minimum cost. Does that make sense?
+But, check the item and the quantity when you are trading. Be wary of those who want to deceive you while trading!
+
+
\ No newline at end of file
diff --git a/L2J_Mobius_6.0_Fafurion/dist/game/data/scripts/quests/Q10576_GlitteringWeapons/30471-05.html b/L2J_Mobius_6.0_Fafurion/dist/game/data/scripts/quests/Q10576_GlitteringWeapons/30471-05.html
new file mode 100644
index 0000000000..bf3d6508cb
--- /dev/null
+++ b/L2J_Mobius_6.0_Fafurion/dist/game/data/scripts/quests/Q10576_GlitteringWeapons/30471-05.html
@@ -0,0 +1,6 @@
+Blacksmith Rupio:
+It is now time for Enchantment. Most equipment can go through Enchantment. While early level Enchantment is always successful, after a certain level, there are possibilities of failure.
+When it fails, everything will come to nothing. You'll lose the weapon, and the Enchantment level will be gone, too.
+I think its the time for practice. Let's make the weapon sparkle!
+
+
\ No newline at end of file
diff --git a/L2J_Mobius_6.0_Fafurion/dist/game/data/scripts/quests/Q10576_GlitteringWeapons/30471-06.html b/L2J_Mobius_6.0_Fafurion/dist/game/data/scripts/quests/Q10576_GlitteringWeapons/30471-06.html
new file mode 100644
index 0000000000..ea0dad6e2d
--- /dev/null
+++ b/L2J_Mobius_6.0_Fafurion/dist/game/data/scripts/quests/Q10576_GlitteringWeapons/30471-06.html
@@ -0,0 +1,5 @@
+Blacksmith Rupio:
+The practice mission is quite simple. Although I talked a lot about how to obtain the items necessary for Enchantment, for now, I'll supply you with the necessary supplies since it's a practice session.
+Here, take the Weapon Enhancing Practice Long Sword and the Practice Weapon Enchant Scroll. Repeat the Enchantment so your Weapon's Enchantment level reaches +7. Use all of the Practice Weapon Enchant Scrolls to reach the level.
+Even if you fail, don't worry. Just come back to me, as I have a Plan B. Good luck to you, then!
+
\ No newline at end of file
diff --git a/L2J_Mobius_6.0_Fafurion/dist/game/data/scripts/quests/Q10576_GlitteringWeapons/30471-07.html b/L2J_Mobius_6.0_Fafurion/dist/game/data/scripts/quests/Q10576_GlitteringWeapons/30471-07.html
new file mode 100644
index 0000000000..503b2b1fec
--- /dev/null
+++ b/L2J_Mobius_6.0_Fafurion/dist/game/data/scripts/quests/Q10576_GlitteringWeapons/30471-07.html
@@ -0,0 +1,6 @@
+Blacksmith Rupio:
+Why did you come back?
+
+
+
+
\ No newline at end of file
diff --git a/L2J_Mobius_6.0_Fafurion/dist/game/data/scripts/quests/Q10576_GlitteringWeapons/30471-08.html b/L2J_Mobius_6.0_Fafurion/dist/game/data/scripts/quests/Q10576_GlitteringWeapons/30471-08.html
new file mode 100644
index 0000000000..9403c560b0
--- /dev/null
+++ b/L2J_Mobius_6.0_Fafurion/dist/game/data/scripts/quests/Q10576_GlitteringWeapons/30471-08.html
@@ -0,0 +1,4 @@
+Blacksmith Rupio:
+Oh, you failed?! But you know, we can learn a lesson from our failures. Now you learned that Enchantment can be a double-edged sword. If you are not careful, you could lose your weapon.
+I'll give you the Enhancement Practice Long Sword and the Practice Weapon Enchant Scroll again. This time, try raising the Enhancement level to +3.
+
\ No newline at end of file
diff --git a/L2J_Mobius_6.0_Fafurion/dist/game/data/scripts/quests/Q10576_GlitteringWeapons/30471-09.html b/L2J_Mobius_6.0_Fafurion/dist/game/data/scripts/quests/Q10576_GlitteringWeapons/30471-09.html
new file mode 100644
index 0000000000..527b21f970
--- /dev/null
+++ b/L2J_Mobius_6.0_Fafurion/dist/game/data/scripts/quests/Q10576_GlitteringWeapons/30471-09.html
@@ -0,0 +1,5 @@
+Blacksmith Rupio:
+You were succesful this time! This amount of Enhancement wasn't difficult, so I knew that you would succeed! Consider this task complete!.
+Good job.
+
+
\ No newline at end of file
diff --git a/L2J_Mobius_6.0_Fafurion/dist/game/data/scripts/quests/Q10576_GlitteringWeapons/30471-10.html b/L2J_Mobius_6.0_Fafurion/dist/game/data/scripts/quests/Q10576_GlitteringWeapons/30471-10.html
new file mode 100644
index 0000000000..40d45f5f3d
--- /dev/null
+++ b/L2J_Mobius_6.0_Fafurion/dist/game/data/scripts/quests/Q10576_GlitteringWeapons/30471-10.html
@@ -0,0 +1,3 @@
+Blacksmith Rupio:
+Any time! With adventurers like you around, Blacksmiths like me have more opportunities to make weapons! It was rewarding for me. Well, I'll see you around!
+
\ No newline at end of file
diff --git a/L2J_Mobius_6.0_Fafurion/dist/game/data/scripts/quests/Q10576_GlitteringWeapons/30471-11.html b/L2J_Mobius_6.0_Fafurion/dist/game/data/scripts/quests/Q10576_GlitteringWeapons/30471-11.html
new file mode 100644
index 0000000000..1bd7769196
--- /dev/null
+++ b/L2J_Mobius_6.0_Fafurion/dist/game/data/scripts/quests/Q10576_GlitteringWeapons/30471-11.html
@@ -0,0 +1,6 @@
+Blacksmith Rupio:
+Do you want to know how to obtain the items needed for Enchantment? OK, I'll tell you again.
+You can Trade to get the item needed. The thing you desperately need, may be not that useful to others. This goes the other way around too. One man's trash is another man's treasure.
+Therefore, if you utilize the network well, you can get what you want at a minimum cost.
+
+
\ No newline at end of file
diff --git a/L2J_Mobius_6.0_Fafurion/dist/game/data/scripts/quests/Q10576_GlitteringWeapons/30471-12.html b/L2J_Mobius_6.0_Fafurion/dist/game/data/scripts/quests/Q10576_GlitteringWeapons/30471-12.html
new file mode 100644
index 0000000000..4a8df15b0d
--- /dev/null
+++ b/L2J_Mobius_6.0_Fafurion/dist/game/data/scripts/quests/Q10576_GlitteringWeapons/30471-12.html
@@ -0,0 +1,7 @@
+Blacksmith Rupio:
+But, check the item and the quantity when you are trading. Be there are those who want to deceive you while trading so be careful!
+This is the method that I mentioned before. I think you'll remember now.
+Any other questions?
+
+
+
\ No newline at end of file
diff --git a/L2J_Mobius_6.0_Fafurion/dist/game/data/scripts/quests/Q10576_GlitteringWeapons/30471-13.html b/L2J_Mobius_6.0_Fafurion/dist/game/data/scripts/quests/Q10576_GlitteringWeapons/30471-13.html
new file mode 100644
index 0000000000..7fd45aedf1
--- /dev/null
+++ b/L2J_Mobius_6.0_Fafurion/dist/game/data/scripts/quests/Q10576_GlitteringWeapons/30471-13.html
@@ -0,0 +1,6 @@
+Blacksmith Rupio:
+Now I'll talk about Enchantment Most equipment can go through Enchantment While early level Enchantment is always successful, after a certain level, there are possibilities of failure.
+If it fails, the Enhance level and the Weapon will be destroyed.
+Keep this in mind. You should have no problem with Enchantment with this knowledge at hand.
+
+
\ No newline at end of file
diff --git a/L2J_Mobius_6.0_Fafurion/dist/game/data/scripts/quests/Q10576_GlitteringWeapons/30471-14.html b/L2J_Mobius_6.0_Fafurion/dist/game/data/scripts/quests/Q10576_GlitteringWeapons/30471-14.html
new file mode 100644
index 0000000000..9212be93f5
--- /dev/null
+++ b/L2J_Mobius_6.0_Fafurion/dist/game/data/scripts/quests/Q10576_GlitteringWeapons/30471-14.html
@@ -0,0 +1,3 @@
+Blacksmith Rupio:
+Now, Enhance the Enhancement Practice Long Sword using the Practice Enchant Scroll that I gave you! Good luck!
+
\ No newline at end of file
diff --git a/L2J_Mobius_6.0_Fafurion/dist/game/data/scripts/quests/Q10576_GlitteringWeapons/30471-15.html b/L2J_Mobius_6.0_Fafurion/dist/game/data/scripts/quests/Q10576_GlitteringWeapons/30471-15.html
new file mode 100644
index 0000000000..a3ed69e849
--- /dev/null
+++ b/L2J_Mobius_6.0_Fafurion/dist/game/data/scripts/quests/Q10576_GlitteringWeapons/30471-15.html
@@ -0,0 +1,3 @@
+Blacksmith Rupio:
+Not successful yet?! Since this is your second time, you only need to raise the Enchantment level to +3. This isn't hard, so don't worry too much about it and go for it!
+
\ No newline at end of file
diff --git a/L2J_Mobius_6.0_Fafurion/dist/game/data/scripts/quests/Q10576_GlitteringWeapons/30471-16.html b/L2J_Mobius_6.0_Fafurion/dist/game/data/scripts/quests/Q10576_GlitteringWeapons/30471-16.html
new file mode 100644
index 0000000000..15022c6651
--- /dev/null
+++ b/L2J_Mobius_6.0_Fafurion/dist/game/data/scripts/quests/Q10576_GlitteringWeapons/30471-16.html
@@ -0,0 +1,3 @@
+Blacksmith Rupio:
+Oh, you still have a sword? Then, you must not have failed! Don't worry and keep going!
+
\ No newline at end of file
diff --git a/L2J_Mobius_6.0_Fafurion/dist/game/data/scripts/quests/Q10576_GlitteringWeapons/Q10576_GlitteringWeapons.java b/L2J_Mobius_6.0_Fafurion/dist/game/data/scripts/quests/Q10576_GlitteringWeapons/Q10576_GlitteringWeapons.java
new file mode 100644
index 0000000000..a1028d5f15
--- /dev/null
+++ b/L2J_Mobius_6.0_Fafurion/dist/game/data/scripts/quests/Q10576_GlitteringWeapons/Q10576_GlitteringWeapons.java
@@ -0,0 +1,222 @@
+/*
+ * 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.Q10576_GlitteringWeapons;
+
+import org.l2jmobius.gameserver.enums.QuestType;
+import org.l2jmobius.gameserver.model.actor.Npc;
+import org.l2jmobius.gameserver.model.actor.instance.PlayerInstance;
+import org.l2jmobius.gameserver.model.events.Containers;
+import org.l2jmobius.gameserver.model.events.EventType;
+import org.l2jmobius.gameserver.model.events.impl.item.OnItemEnchantAdd;
+import org.l2jmobius.gameserver.model.events.listeners.ConsumerEventListener;
+import org.l2jmobius.gameserver.model.quest.Quest;
+import org.l2jmobius.gameserver.model.quest.QuestState;
+import org.l2jmobius.gameserver.model.quest.State;
+import org.l2jmobius.gameserver.network.serverpackets.ExTutorialShowId;
+
+import quests.Q10566_BestChoice.Q10566_BestChoice;
+
+/**
+ * Glittering Weapons (10576)
+ * @URL https://l2wiki.com/Glittering_Weapons
+ * @author NightBR
+ * @html by Werum
+ */
+public final class Q10576_GlitteringWeapons extends Quest
+{
+ // NPCs
+ private static final int RUPIO = 30471;
+ // Item
+ private static final int ENHANCEMENT_PRACTICE_LONG_SWORD = 48170;
+ private static final int PRACTICE_WEAPON_ENCHANT_SCROLL = 48171;
+ // Rewards
+ private static final long XP = 597699960;
+ private static final int SP = 597690;
+ private static final int CERTIFICATE_FROM_RUPIO = 48174;
+ // Misc
+ private static final int MIN_LEVEL = 95;
+
+ public Q10576_GlitteringWeapons()
+ {
+ super(10576);
+ addStartNpc(RUPIO);
+ addTalkId(RUPIO);
+ addCondMinLevel(MIN_LEVEL, "noLevel.html");
+ registerQuestItems(ENHANCEMENT_PRACTICE_LONG_SWORD, PRACTICE_WEAPON_ENCHANT_SCROLL);
+ addCondStartedQuest(Q10566_BestChoice.class.getSimpleName(), "30471-99.html");
+ Containers.Global().addListener(new ConsumerEventListener(Containers.Global(), EventType.ON_ITEM_ENCHANT_ADD, (OnItemEnchantAdd event) -> OnItemEnchantAdd(event), this));
+ }
+
+ @Override
+ public String onAdvEvent(String event, Npc npc, PlayerInstance player)
+ {
+ final QuestState qs = getQuestState(player, false);
+ if (qs == null)
+ {
+ return getNoQuestMsg(player);
+ }
+ String htmltext = null;
+ switch (event)
+ {
+ case "30471-02.htm":
+ case "30471-05.html":
+ case "30471-07.html":
+ case "30471-12.html":
+ case "30471-14.html":
+ {
+ htmltext = event;
+ break;
+ }
+ case "30471-03.htm":
+ {
+ qs.startQuest();
+ htmltext = event;
+ break;
+ }
+ case "30471-04.html":
+ {
+ // show Service/Help/Trade page
+ player.sendPacket(new ExTutorialShowId(56));
+ htmltext = event;
+ break;
+ }
+ case "30471-06.html":
+ {
+ // show Service/Help/Enchant page
+ player.sendPacket(new ExTutorialShowId(38));
+ giveItems(player, ENHANCEMENT_PRACTICE_LONG_SWORD, 1);
+ giveItems(player, PRACTICE_WEAPON_ENCHANT_SCROLL, 7);
+ qs.setCond(2, true);
+ htmltext = event;
+ break;
+ }
+ case "30471-10.html":
+ {
+ // Rewards
+ addExpAndSp(player, XP, SP);
+ giveItems(player, CERTIFICATE_FROM_RUPIO, 1);
+ qs.exitQuest(QuestType.ONE_TIME, true);
+ htmltext = event;
+ break;
+ }
+ case "30471-08.html":
+ {
+ // check if player already have quest items
+ if (hasQuestItems(player, ENHANCEMENT_PRACTICE_LONG_SWORD, PRACTICE_WEAPON_ENCHANT_SCROLL))
+ {
+ htmltext = "30471-16.html";
+ }
+ else
+ {
+ // To make sure player does not have them already
+ removeRegisteredQuestItems(player);
+ giveItems(player, ENHANCEMENT_PRACTICE_LONG_SWORD, 1);
+ giveItems(player, PRACTICE_WEAPON_ENCHANT_SCROLL, 3);
+ qs.setCond(3, true);
+ htmltext = event;
+ }
+ break;
+ }
+ case "30471-11.html":
+ {
+ // show Service/Help/Trade page
+ player.sendPacket(new ExTutorialShowId(56));
+ htmltext = event;
+ break;
+ }
+ case "30471-13.html":
+ {
+ // show Service/Help/Enchant page
+ player.sendPacket(new ExTutorialShowId(38));
+ htmltext = event;
+ break;
+ }
+ }
+ return htmltext;
+ }
+
+ @Override
+ public String onTalk(Npc npc, PlayerInstance player)
+ {
+ final QuestState qs = getQuestState(player, true);
+ String htmltext = getNoQuestMsg(player);
+
+ switch (qs.getState())
+ {
+ case State.CREATED:
+ {
+ htmltext = "30471-01.htm";
+ break;
+ }
+ case State.STARTED:
+ {
+ if (qs.isCond(1))
+ {
+ htmltext = "30471-03.html";
+ }
+ else if (qs.isCond(2))
+ {
+ htmltext = "30471-07.html";
+ }
+ else if (qs.isCond(3))
+ {
+ htmltext = "30471-15.html";
+ }
+ else
+ {
+ htmltext = "30471-09.html";
+ }
+ break;
+ }
+ case State.COMPLETED:
+ {
+ htmltext = getAlreadyCompletedMsg(player);
+ break;
+ }
+ }
+ return htmltext;
+ }
+
+ public void OnItemEnchantAdd(OnItemEnchantAdd event)
+ {
+ final PlayerInstance player = event.getPlayer();
+ if ((player == null) || (event.getItem().getId() != ENHANCEMENT_PRACTICE_LONG_SWORD))
+ {
+ return;
+ }
+
+ final QuestState qs = getQuestState(player, false);
+ // Check if weapon has been augmented to complete the quest
+ if ((qs != null) && qs.isCond(2))
+ {
+ // Check if Item has been destroyed during enchantment process
+ if (!hasQuestItems(player, ENHANCEMENT_PRACTICE_LONG_SWORD))
+ {
+ return;
+ }
+
+ if (player.getInventory().getItemByItemId(ENHANCEMENT_PRACTICE_LONG_SWORD).getEnchantLevel() == 7)
+ {
+ qs.setCond(4, true);
+ }
+ }
+ else if ((qs != null) && qs.isCond(3) && (player.getInventory().getItemByItemId(ENHANCEMENT_PRACTICE_LONG_SWORD).getEnchantLevel() == 3))
+ {
+ qs.setCond(4, true);
+ }
+ }
+}
diff --git a/L2J_Mobius_6.0_Fafurion/dist/game/data/scripts/quests/QuestMasterHandler.java b/L2J_Mobius_6.0_Fafurion/dist/game/data/scripts/quests/QuestMasterHandler.java
index b66c041d70..18d0996940 100644
--- a/L2J_Mobius_6.0_Fafurion/dist/game/data/scripts/quests/QuestMasterHandler.java
+++ b/L2J_Mobius_6.0_Fafurion/dist/game/data/scripts/quests/QuestMasterHandler.java
@@ -308,6 +308,7 @@ import quests.Q10561_AcrossTheDeathLine.Q10561_AcrossTheDeathLine;
import quests.Q10562_TakeUpArms.Q10562_TakeUpArms;
import quests.Q10566_BestChoice.Q10566_BestChoice;
import quests.Q10575_LetsGoFishing.Q10575_LetsGoFishing;
+import quests.Q10576_GlitteringWeapons.Q10576_GlitteringWeapons;
import quests.Q10577_TemperARustingBlade.Q10577_TemperARustingBlade;
import quests.Q10578_TheSoulOfASword.Q10578_TheSoulOfASword;
import quests.Q10579_ContainingTheAttributePower.Q10579_ContainingTheAttributePower;
@@ -846,7 +847,7 @@ public class QuestMasterHandler
Q10571_StrategicReconciliation.class, // TODO: Not done.
Q10572_ToExpelTheEmbryosForces.class, // TODO: Not done.
Q10575_LetsGoFishing.class,
- Q10576_GlitteringWeapons.class, // TODO: Not done.
+ Q10576_GlitteringWeapons.class,
Q10577_TemperARustingBlade.class,
Q10578_TheSoulOfASword.class,
Q10579_ContainingTheAttributePower.class,
diff --git a/L2J_Mobius_6.0_Fafurion/dist/game/data/scripts/quests/not_done/Q10576_GlitteringWeapons.java b/L2J_Mobius_6.0_Fafurion/dist/game/data/scripts/quests/not_done/Q10576_GlitteringWeapons.java
deleted file mode 100644
index 6866cb117b..0000000000
--- a/L2J_Mobius_6.0_Fafurion/dist/game/data/scripts/quests/not_done/Q10576_GlitteringWeapons.java
+++ /dev/null
@@ -1,36 +0,0 @@
-/*
- * 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.not_done;
-
-import org.l2jmobius.Config;
-import org.l2jmobius.gameserver.model.quest.Quest;
-
-/**
- * @author Mobius
- */
-public class Q10576_GlitteringWeapons extends Quest
-{
- private static final int START_NPC = 30471;
-
- public Q10576_GlitteringWeapons()
- {
- super(10576);
- addStartNpc(START_NPC);
- addTalkId(START_NPC);
- addCondMinLevel(Config.PLAYER_MAXIMUM_LEVEL, getNoQuestMsg(null));
- }
-}
diff --git a/L2J_Mobius_6.0_Fafurion/dist/game/data/stats/items/48100-48199.xml b/L2J_Mobius_6.0_Fafurion/dist/game/data/stats/items/48100-48199.xml
index a61537f0dd..86533c82d9 100644
--- a/L2J_Mobius_6.0_Fafurion/dist/game/data/stats/items/48100-48199.xml
+++ b/L2J_Mobius_6.0_Fafurion/dist/game/data/stats/items/48100-48199.xml
@@ -902,6 +902,7 @@
+
@@ -925,6 +926,7 @@
+
@@ -941,16 +943,20 @@
+
+
+
+ 2417
@@ -972,6 +978,14 @@
+
+
+
+
+
+
+
+
diff --git a/L2J_Mobius_6.0_Fafurion/java/org/l2jmobius/gameserver/model/events/EventType.java b/L2J_Mobius_6.0_Fafurion/java/org/l2jmobius/gameserver/model/events/EventType.java
index cc88e4a987..424a7e111b 100644
--- a/L2J_Mobius_6.0_Fafurion/java/org/l2jmobius/gameserver/model/events/EventType.java
+++ b/L2J_Mobius_6.0_Fafurion/java/org/l2jmobius/gameserver/model/events/EventType.java
@@ -123,6 +123,7 @@ import org.l2jmobius.gameserver.model.events.impl.instance.OnInstanceStatusChang
import org.l2jmobius.gameserver.model.events.impl.item.OnItemAttributeAdd;
import org.l2jmobius.gameserver.model.events.impl.item.OnItemBypassEvent;
import org.l2jmobius.gameserver.model.events.impl.item.OnItemCreate;
+import org.l2jmobius.gameserver.model.events.impl.item.OnItemEnchantAdd;
import org.l2jmobius.gameserver.model.events.impl.item.OnItemSoulCrystalAdd;
import org.l2jmobius.gameserver.model.events.impl.item.OnItemTalk;
import org.l2jmobius.gameserver.model.events.impl.olympiad.OnOlympiadMatchResult;
@@ -185,6 +186,7 @@ public enum EventType
ON_ITEM_TALK(OnItemTalk.class, void.class),
ON_ITEM_ATTRIBUTE_ADD(OnItemAttributeAdd.class, void.class),
ON_ITEM_SOUL_CRYSTAL_ADD(OnItemSoulCrystalAdd.class, void.class),
+ ON_ITEM_ENCHANT_ADD(OnItemEnchantAdd.class, void.class),
// NPC events
ON_NPC_CAN_BE_SEEN(OnNpcCanBeSeen.class, void.class, TerminateReturn.class),
diff --git a/L2J_Mobius_6.0_Fafurion/java/org/l2jmobius/gameserver/model/events/impl/item/OnItemEnchantAdd.java b/L2J_Mobius_6.0_Fafurion/java/org/l2jmobius/gameserver/model/events/impl/item/OnItemEnchantAdd.java
new file mode 100644
index 0000000000..0a7d31c93d
--- /dev/null
+++ b/L2J_Mobius_6.0_Fafurion/java/org/l2jmobius/gameserver/model/events/impl/item/OnItemEnchantAdd.java
@@ -0,0 +1,53 @@
+/*
+ * 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 org.l2jmobius.gameserver.model.events.impl.item;
+
+import org.l2jmobius.gameserver.model.actor.instance.PlayerInstance;
+import org.l2jmobius.gameserver.model.events.EventType;
+import org.l2jmobius.gameserver.model.events.impl.IBaseEvent;
+import org.l2jmobius.gameserver.model.items.instance.ItemInstance;
+
+/**
+ * @author NightBR
+ */
+public class OnItemEnchantAdd implements IBaseEvent
+{
+ private final PlayerInstance _player;
+ private final ItemInstance _item;
+
+ public OnItemEnchantAdd(PlayerInstance player, ItemInstance item)
+ {
+ _player = player;
+ _item = item;
+ }
+
+ public PlayerInstance getPlayer()
+ {
+ return _player;
+ }
+
+ public ItemInstance getItem()
+ {
+ return _item;
+ }
+
+ @Override
+ public EventType getType()
+ {
+ return EventType.ON_ITEM_ENCHANT_ADD;
+ }
+}
\ No newline at end of file
diff --git a/L2J_Mobius_6.0_Fafurion/java/org/l2jmobius/gameserver/model/items/instance/ItemInstance.java b/L2J_Mobius_6.0_Fafurion/java/org/l2jmobius/gameserver/model/items/instance/ItemInstance.java
index 58c4d4b894..da65d00ca5 100644
--- a/L2J_Mobius_6.0_Fafurion/java/org/l2jmobius/gameserver/model/items/instance/ItemInstance.java
+++ b/L2J_Mobius_6.0_Fafurion/java/org/l2jmobius/gameserver/model/items/instance/ItemInstance.java
@@ -69,6 +69,7 @@ import org.l2jmobius.gameserver.model.events.impl.creature.player.OnPlayerItemDr
import org.l2jmobius.gameserver.model.events.impl.creature.player.OnPlayerItemPickup;
import org.l2jmobius.gameserver.model.events.impl.item.OnItemAttributeAdd;
import org.l2jmobius.gameserver.model.events.impl.item.OnItemBypassEvent;
+import org.l2jmobius.gameserver.model.events.impl.item.OnItemEnchantAdd;
import org.l2jmobius.gameserver.model.events.impl.item.OnItemSoulCrystalAdd;
import org.l2jmobius.gameserver.model.events.impl.item.OnItemTalk;
import org.l2jmobius.gameserver.model.instancezone.Instance;
@@ -943,6 +944,9 @@ public final class ItemInstance extends WorldObject
_enchantLevel = enchantLevel;
applyEnchantStats();
_storedInDb = false;
+
+ // Notify to Scripts
+ EventDispatcher.getInstance().notifyEventAsync(new OnItemEnchantAdd(getActingPlayer(), this));
}
/**