Additional Services' Advisor Juni:
+With our class change service you can choose a different class for your character. You need to prepare for it, however
+First, you need a Class Change Coupon that's sold in the Adena store section of the L-Coin Store.
+Second, you have to unequip all items.
+Third, you need to free up your inventory.You will need at least 30 slots.
+What's more, Heroes can't change their class, so a character with this title is ineligible for the service.
+Tell me once you're ready, I'll send you to the Additional Services Lab. Talk to the Researcher Hermin there to change class.
+
+
\ No newline at end of file
diff --git a/L2J_Mobius_Essence_4.2_DwellingOfSpirits/dist/game/data/scripts/ai/others/AdditionalServicesAdvisor/34152-3rd_class.htm b/L2J_Mobius_Essence_4.2_DwellingOfSpirits/dist/game/data/scripts/ai/others/AdditionalServicesAdvisor/34152-3rd_class.htm
new file mode 100644
index 0000000000..a53511aa02
--- /dev/null
+++ b/L2J_Mobius_Essence_4.2_DwellingOfSpirits/dist/game/data/scripts/ai/others/AdditionalServicesAdvisor/34152-3rd_class.htm
@@ -0,0 +1,6 @@
+Additional Services' Advisor Juni:
+You can change class only after the 3rd class change.
+Come back once you have your 3rd class.
+Tell me once you're ready. I'll send you to the Additional Services Lab. Talk to the Researcher Hermin there to change class.
+
+
\ No newline at end of file
diff --git a/L2J_Mobius_Essence_4.2_DwellingOfSpirits/dist/game/data/scripts/ai/others/AdditionalServicesAdvisor/34152-no_coupon.htm b/L2J_Mobius_Essence_4.2_DwellingOfSpirits/dist/game/data/scripts/ai/others/AdditionalServicesAdvisor/34152-no_coupon.htm
new file mode 100644
index 0000000000..3290459b4a
--- /dev/null
+++ b/L2J_Mobius_Essence_4.2_DwellingOfSpirits/dist/game/data/scripts/ai/others/AdditionalServicesAdvisor/34152-no_coupon.htm
@@ -0,0 +1,6 @@
+Additional Services' Advisor Juni:
+You don't have a Class Change Coupon!
+It's necessary if you want to change your class. You can buy it in the Adena store section of the L-Coin Store.
+Tell me once you're ready. I'll send you to the Additional Services Lab. Talk to the Researcher Hermin there to change class.
+
+
\ No newline at end of file
diff --git a/L2J_Mobius_Essence_4.2_DwellingOfSpirits/dist/game/data/scripts/ai/others/AdditionalServicesAdvisor/34152-no_inventory.htm b/L2J_Mobius_Essence_4.2_DwellingOfSpirits/dist/game/data/scripts/ai/others/AdditionalServicesAdvisor/34152-no_inventory.htm
new file mode 100644
index 0000000000..c4aea134ad
--- /dev/null
+++ b/L2J_Mobius_Essence_4.2_DwellingOfSpirits/dist/game/data/scripts/ai/others/AdditionalServicesAdvisor/34152-no_inventory.htm
@@ -0,0 +1,7 @@
+Additional Services' Advisor Juni:
+Please, check your inventory.
+To change class, in your inventory must be free space and weight.
+Keep unnecessary items in the warehouse, to free 50% weight and at least 30 slots.
+Tell me once you're ready. I'll send you to the Additional Services Lab. Talk to the Researcher Hermin there to change class.
+
+
\ No newline at end of file
diff --git a/L2J_Mobius_Essence_4.2_DwellingOfSpirits/dist/game/data/scripts/ai/others/AdditionalServicesAdvisor/34152-unequip_items.htm b/L2J_Mobius_Essence_4.2_DwellingOfSpirits/dist/game/data/scripts/ai/others/AdditionalServicesAdvisor/34152-unequip_items.htm
new file mode 100644
index 0000000000..3c4b9ab55d
--- /dev/null
+++ b/L2J_Mobius_Essence_4.2_DwellingOfSpirits/dist/game/data/scripts/ai/others/AdditionalServicesAdvisor/34152-unequip_items.htm
@@ -0,0 +1,6 @@
+Additional Services' Advisor Juni:
+It looks like you have an item equipped!
+To change class, you need to unequip all items.
+Tell me once you're ready. I'll send you to the Additional Services Lab. Talk to the Researcher Hermin there to change class.
+
+
\ No newline at end of file
diff --git a/L2J_Mobius_Essence_4.2_DwellingOfSpirits/dist/game/data/scripts/ai/others/AdditionalServicesAdvisor/34152.htm b/L2J_Mobius_Essence_4.2_DwellingOfSpirits/dist/game/data/scripts/ai/others/AdditionalServicesAdvisor/34152.htm
new file mode 100644
index 0000000000..d794126044
--- /dev/null
+++ b/L2J_Mobius_Essence_4.2_DwellingOfSpirits/dist/game/data/scripts/ai/others/AdditionalServicesAdvisor/34152.htm
@@ -0,0 +1,6 @@
+Additional Services' Advisor Juni:
+If you need help with additional services, ask me anytime! I'll explain it all to you.
+The Additional Services Lab provides the class change service. Would you be interested in that?
+
+
+
\ No newline at end of file
diff --git a/L2J_Mobius_Essence_4.2_DwellingOfSpirits/dist/game/data/scripts/ai/others/AdditionalServicesAdvisor/34153-1.htm b/L2J_Mobius_Essence_4.2_DwellingOfSpirits/dist/game/data/scripts/ai/others/AdditionalServicesAdvisor/34153-1.htm
new file mode 100644
index 0000000000..889075bb1a
--- /dev/null
+++ b/L2J_Mobius_Essence_4.2_DwellingOfSpirits/dist/game/data/scripts/ai/others/AdditionalServicesAdvisor/34153-1.htm
@@ -0,0 +1,8 @@
+Additional Services' Researcher Hermin:
+In order to change a class, several conditions must be met. Changing a class requires care and attention, so it is only done in this laboratory.
+First, you need Class Change Coupon, that's sold in the Adena store section of the L-Coin Store.
+Second, you have to unequip all items.
+Third, you need to free up your inventory You will need at least 30 slots.
+You should also know that only warriors can change classes, not holding the title of Hero.
+So, are you ready?
+
\ No newline at end of file
diff --git a/L2J_Mobius_Essence_4.2_DwellingOfSpirits/dist/game/data/scripts/ai/others/AdditionalServicesAdvisor/34153-3rd_class.htm b/L2J_Mobius_Essence_4.2_DwellingOfSpirits/dist/game/data/scripts/ai/others/AdditionalServicesAdvisor/34153-3rd_class.htm
new file mode 100644
index 0000000000..463776caf1
--- /dev/null
+++ b/L2J_Mobius_Essence_4.2_DwellingOfSpirits/dist/game/data/scripts/ai/others/AdditionalServicesAdvisor/34153-3rd_class.htm
@@ -0,0 +1,6 @@
+Additional Services' Researcher Hermin:
+You can change class only after the 3rd class change.
+Come back once you have your 3rd class.
+Tell me once you're ready.
+
+
\ No newline at end of file
diff --git a/L2J_Mobius_Essence_4.2_DwellingOfSpirits/dist/game/data/scripts/ai/others/AdditionalServicesAdvisor/34153-choose_gender.htm b/L2J_Mobius_Essence_4.2_DwellingOfSpirits/dist/game/data/scripts/ai/others/AdditionalServicesAdvisor/34153-choose_gender.htm
new file mode 100644
index 0000000000..03f4b41d03
--- /dev/null
+++ b/L2J_Mobius_Essence_4.2_DwellingOfSpirits/dist/game/data/scripts/ai/others/AdditionalServicesAdvisor/34153-choose_gender.htm
@@ -0,0 +1,7 @@
+Additional Services' Researcher Hermin:
+So you want to be %class_name%.
+Now choose the gender of your character. Close your eyes and imagine what you will become when you change classes.
+What gender will be your Duelist?
+
+
+
\ No newline at end of file
diff --git a/L2J_Mobius_Essence_4.2_DwellingOfSpirits/dist/game/data/scripts/ai/others/AdditionalServicesAdvisor/34153-choose_gender_confirm.htm b/L2J_Mobius_Essence_4.2_DwellingOfSpirits/dist/game/data/scripts/ai/others/AdditionalServicesAdvisor/34153-choose_gender_confirm.htm
new file mode 100644
index 0000000000..dcf2785571
--- /dev/null
+++ b/L2J_Mobius_Essence_4.2_DwellingOfSpirits/dist/game/data/scripts/ai/others/AdditionalServicesAdvisor/34153-choose_gender_confirm.htm
@@ -0,0 +1,8 @@
+Additional Services' Researcher Hermin:
+Your choice of class - %class_name%.
+The character will be %sex%. Are you sure about your decision?
+After confirmations the character will get selected race and gender, as well as will change to the class of your choice.
+After agreeing, you will be briefly disconnected from the game. Are you confirming your choice?
+
+
+
\ No newline at end of file
diff --git a/L2J_Mobius_Essence_4.2_DwellingOfSpirits/dist/game/data/scripts/ai/others/AdditionalServicesAdvisor/34153-choose_gender_unavailable.htm b/L2J_Mobius_Essence_4.2_DwellingOfSpirits/dist/game/data/scripts/ai/others/AdditionalServicesAdvisor/34153-choose_gender_unavailable.htm
new file mode 100644
index 0000000000..7c38e0d9e7
--- /dev/null
+++ b/L2J_Mobius_Essence_4.2_DwellingOfSpirits/dist/game/data/scripts/ai/others/AdditionalServicesAdvisor/34153-choose_gender_unavailable.htm
@@ -0,0 +1,6 @@
+Additional Services' Researcher Hermin:
+So you want to be %class_name%. Now you have to choose the gender of the character. Unfortunately, gender selection is not available for the %class_name%.
+ %class_name% can only be men. Now close your eyes and concentrate.
+ Imagine what it would be like to be %class_name%?
+
+
\ No newline at end of file
diff --git a/L2J_Mobius_Essence_4.2_DwellingOfSpirits/dist/game/data/scripts/ai/others/AdditionalServicesAdvisor/34153-class_darkelf.htm b/L2J_Mobius_Essence_4.2_DwellingOfSpirits/dist/game/data/scripts/ai/others/AdditionalServicesAdvisor/34153-class_darkelf.htm
new file mode 100644
index 0000000000..92ebab3f8b
--- /dev/null
+++ b/L2J_Mobius_Essence_4.2_DwellingOfSpirits/dist/game/data/scripts/ai/others/AdditionalServicesAdvisor/34153-class_darkelf.htm
@@ -0,0 +1,11 @@
+Additional Services' Researcher Hermin:
+Aha, the Dark Elf! So you want to be a Dark Elf. Now choose... class for your character.
+
+
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/L2J_Mobius_Essence_4.2_DwellingOfSpirits/dist/game/data/scripts/ai/others/AdditionalServicesAdvisor/34153-class_dwarf.htm b/L2J_Mobius_Essence_4.2_DwellingOfSpirits/dist/game/data/scripts/ai/others/AdditionalServicesAdvisor/34153-class_dwarf.htm
new file mode 100644
index 0000000000..6385e1e8b9
--- /dev/null
+++ b/L2J_Mobius_Essence_4.2_DwellingOfSpirits/dist/game/data/scripts/ai/others/AdditionalServicesAdvisor/34153-class_dwarf.htm
@@ -0,0 +1,5 @@
+Additional Services' Researcher Hermin:
+Aha, Dwarf! So you want to be a Dwarf. Now choose... class for your character.
+
+
+
\ No newline at end of file
diff --git a/L2J_Mobius_Essence_4.2_DwellingOfSpirits/dist/game/data/scripts/ai/others/AdditionalServicesAdvisor/34153-class_elf.htm b/L2J_Mobius_Essence_4.2_DwellingOfSpirits/dist/game/data/scripts/ai/others/AdditionalServicesAdvisor/34153-class_elf.htm
new file mode 100644
index 0000000000..f6d322da73
--- /dev/null
+++ b/L2J_Mobius_Essence_4.2_DwellingOfSpirits/dist/game/data/scripts/ai/others/AdditionalServicesAdvisor/34153-class_elf.htm
@@ -0,0 +1,11 @@
+Additional Services' Researcher Hermin:
+Aha, Elf! So you want to be an Elf. Now choose. class for your character.
+
+
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/L2J_Mobius_Essence_4.2_DwellingOfSpirits/dist/game/data/scripts/ai/others/AdditionalServicesAdvisor/34153-class_human.htm b/L2J_Mobius_Essence_4.2_DwellingOfSpirits/dist/game/data/scripts/ai/others/AdditionalServicesAdvisor/34153-class_human.htm
new file mode 100644
index 0000000000..1560c9c2e9
--- /dev/null
+++ b/L2J_Mobius_Essence_4.2_DwellingOfSpirits/dist/game/data/scripts/ai/others/AdditionalServicesAdvisor/34153-class_human.htm
@@ -0,0 +1,15 @@
+Additional Services' Researcher Hermin:
+Aha, a Man! So you want to be Human. Now choose class for your character.
+
+
+
+
+
+
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/L2J_Mobius_Essence_4.2_DwellingOfSpirits/dist/game/data/scripts/ai/others/AdditionalServicesAdvisor/34153-class_kamael.htm b/L2J_Mobius_Essence_4.2_DwellingOfSpirits/dist/game/data/scripts/ai/others/AdditionalServicesAdvisor/34153-class_kamael.htm
new file mode 100644
index 0000000000..f66211104d
--- /dev/null
+++ b/L2J_Mobius_Essence_4.2_DwellingOfSpirits/dist/game/data/scripts/ai/others/AdditionalServicesAdvisor/34153-class_kamael.htm
@@ -0,0 +1,6 @@
+Additional Services' Researcher Hermin:
+Aha, Kamael! So you want to be Kamael! Now choose... class for your character.
+
+
+
+
\ No newline at end of file
diff --git a/L2J_Mobius_Essence_4.2_DwellingOfSpirits/dist/game/data/scripts/ai/others/AdditionalServicesAdvisor/34153-class_orc.htm b/L2J_Mobius_Essence_4.2_DwellingOfSpirits/dist/game/data/scripts/ai/others/AdditionalServicesAdvisor/34153-class_orc.htm
new file mode 100644
index 0000000000..384c5f58ce
--- /dev/null
+++ b/L2J_Mobius_Essence_4.2_DwellingOfSpirits/dist/game/data/scripts/ai/others/AdditionalServicesAdvisor/34153-class_orc.htm
@@ -0,0 +1,8 @@
+Additional Services' Researcher Hermin:
+Aha, Orc! So you want to be an Orc. Now choose class for your character.
+
+
+
+
+
+
\ No newline at end of file
diff --git a/L2J_Mobius_Essence_4.2_DwellingOfSpirits/dist/game/data/scripts/ai/others/AdditionalServicesAdvisor/34153-class_sylph.htm b/L2J_Mobius_Essence_4.2_DwellingOfSpirits/dist/game/data/scripts/ai/others/AdditionalServicesAdvisor/34153-class_sylph.htm
new file mode 100644
index 0000000000..7ad6938192
--- /dev/null
+++ b/L2J_Mobius_Essence_4.2_DwellingOfSpirits/dist/game/data/scripts/ai/others/AdditionalServicesAdvisor/34153-class_sylph.htm
@@ -0,0 +1,4 @@
+Additional Services' Researcher Hermin:
+Sylph, that's it! So you've chosen the Sylph race. Now select class for your character, available to the Sylph race.
+
+
\ No newline at end of file
diff --git a/L2J_Mobius_Essence_4.2_DwellingOfSpirits/dist/game/data/scripts/ai/others/AdditionalServicesAdvisor/34153-no_coupon.htm b/L2J_Mobius_Essence_4.2_DwellingOfSpirits/dist/game/data/scripts/ai/others/AdditionalServicesAdvisor/34153-no_coupon.htm
new file mode 100644
index 0000000000..2b7c617055
--- /dev/null
+++ b/L2J_Mobius_Essence_4.2_DwellingOfSpirits/dist/game/data/scripts/ai/others/AdditionalServicesAdvisor/34153-no_coupon.htm
@@ -0,0 +1,6 @@
+Additional Services' Researcher Hermin:
+You don't have a Class Change Coupon!
+It's necessary if you want to change your class. You can buy it in the Adena store section of the L-Coin Store.
+Tell me once you're ready.
+
+
\ No newline at end of file
diff --git a/L2J_Mobius_Essence_4.2_DwellingOfSpirits/dist/game/data/scripts/ai/others/AdditionalServicesAdvisor/34153-no_inventory.htm b/L2J_Mobius_Essence_4.2_DwellingOfSpirits/dist/game/data/scripts/ai/others/AdditionalServicesAdvisor/34153-no_inventory.htm
new file mode 100644
index 0000000000..d5a96cd458
--- /dev/null
+++ b/L2J_Mobius_Essence_4.2_DwellingOfSpirits/dist/game/data/scripts/ai/others/AdditionalServicesAdvisor/34153-no_inventory.htm
@@ -0,0 +1,7 @@
+Additional Services' Researcher Hermin:
+Please, check your inventory.
+To change class, in your inventory must be free space and weight.
+Keep unnecessary items in the warehouse, to free 50% weight and at least 30 slots.
+Tell me once you're ready.
+
+
\ No newline at end of file
diff --git a/L2J_Mobius_Essence_4.2_DwellingOfSpirits/dist/game/data/scripts/ai/others/AdditionalServicesAdvisor/34153-race.htm b/L2J_Mobius_Essence_4.2_DwellingOfSpirits/dist/game/data/scripts/ai/others/AdditionalServicesAdvisor/34153-race.htm
new file mode 100644
index 0000000000..db8994e061
--- /dev/null
+++ b/L2J_Mobius_Essence_4.2_DwellingOfSpirits/dist/game/data/scripts/ai/others/AdditionalServicesAdvisor/34153-race.htm
@@ -0,0 +1,13 @@
+Additional Services' Researcher Hermin:
+If you are ready, let's begin the procedure for changing classes.
+Please choose carefully and calmly, weighing the pros and cons.
+Close your eyes and imagine what you will become when you change classes.
+What race will be a character?
+
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/L2J_Mobius_Essence_4.2_DwellingOfSpirits/dist/game/data/scripts/ai/others/AdditionalServicesAdvisor/34153-unequip_items.htm b/L2J_Mobius_Essence_4.2_DwellingOfSpirits/dist/game/data/scripts/ai/others/AdditionalServicesAdvisor/34153-unequip_items.htm
new file mode 100644
index 0000000000..4d3674e075
--- /dev/null
+++ b/L2J_Mobius_Essence_4.2_DwellingOfSpirits/dist/game/data/scripts/ai/others/AdditionalServicesAdvisor/34153-unequip_items.htm
@@ -0,0 +1,4 @@
+Additional Services' Researcher Hermin:
+It looks like you have an item equipped!
+To change class, you need to unequip all items.
+
\ No newline at end of file
diff --git a/L2J_Mobius_Essence_4.2_DwellingOfSpirits/dist/game/data/scripts/ai/others/AdditionalServicesAdvisor/34153.htm b/L2J_Mobius_Essence_4.2_DwellingOfSpirits/dist/game/data/scripts/ai/others/AdditionalServicesAdvisor/34153.htm
new file mode 100644
index 0000000000..0b00f1eda2
--- /dev/null
+++ b/L2J_Mobius_Essence_4.2_DwellingOfSpirits/dist/game/data/scripts/ai/others/AdditionalServicesAdvisor/34153.htm
@@ -0,0 +1,15 @@
+Additional Services' Researcher Hermin:
+Hello, my name is Hermine, and I am a researcher of value-added services..
+Now the class change service is available.When you change class, some items will be dropped. Remember.
+All previously learned skillsDistributed characteristics
+Bonuses for ranking3 vs 3 Olympiad points and rank
+All positive effects When you change classes you get Scrolls SP for each level.
+Note that all skills learned with the Spell Books and the books themselves will not return.
+When you change classes to the one you had before, all learned skills are retained, so SP Scrolls are not issued.
+The Dragon Slayer Shape, the White Guardian Transformation, the Extended Paint Potential, the Wyvern Transformation from 3 and 4 star skills, and skills gained through one-time quests will be issued as Sealed Spell Books.
+Changing classes is a very important step, so think about it carefully.
+Do you want to change classes?
+
+
+
+
\ No newline at end of file
diff --git a/L2J_Mobius_Essence_4.2_DwellingOfSpirits/dist/game/data/scripts/ai/others/AdditionalServicesAdvisor/AdditionalServicesAdvisor.java b/L2J_Mobius_Essence_4.2_DwellingOfSpirits/dist/game/data/scripts/ai/others/AdditionalServicesAdvisor/AdditionalServicesAdvisor.java
new file mode 100644
index 0000000000..0a8e2cd451
--- /dev/null
+++ b/L2J_Mobius_Essence_4.2_DwellingOfSpirits/dist/game/data/scripts/ai/others/AdditionalServicesAdvisor/AdditionalServicesAdvisor.java
@@ -0,0 +1,340 @@
+/*
+ * 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 ai.others.AdditionalServicesAdvisor;
+
+import java.sql.Connection;
+import java.sql.PreparedStatement;
+
+import org.l2jmobius.Config;
+import org.l2jmobius.commons.database.DatabaseFactory;
+import org.l2jmobius.gameserver.data.xml.ClassListData;
+import org.l2jmobius.gameserver.enums.CategoryType;
+import org.l2jmobius.gameserver.enums.SubclassInfoType;
+import org.l2jmobius.gameserver.instancemanager.InstanceManager;
+import org.l2jmobius.gameserver.model.Location;
+import org.l2jmobius.gameserver.model.actor.Npc;
+import org.l2jmobius.gameserver.model.actor.Player;
+import org.l2jmobius.gameserver.model.instancezone.Instance;
+import org.l2jmobius.gameserver.model.item.instance.Item;
+import org.l2jmobius.gameserver.model.olympiad.Hero;
+import org.l2jmobius.gameserver.model.skill.Skill;
+import org.l2jmobius.gameserver.network.serverpackets.ExSubjobInfo;
+import org.l2jmobius.gameserver.network.serverpackets.ExUserInfoInvenWeight;
+
+import ai.AbstractNpcAI;
+
+/**
+ * @author Mobius
+ */
+public class AdditionalServicesAdvisor extends AbstractNpcAI
+{
+ // NPCs
+ private static final int JUNI = 34152;
+ private static final int HERMIN = 34153;
+ // Items
+ private static final int CLASS_CHANGE_COUPON = 94828;
+ private static final int SP_SCROLL = 94829;
+ private static final int SPELLBOOK_HUMAN = 90038; // Spellbook: Mount Golden Lion
+ private static final int SPELLBOOK_ELF = 90039; // Spellbook: Mount Pegasus
+ private static final int SPELLBOOK_DELF = 90040; // Spellbook: Mount Saber Tooth Cougar
+ private static final int SPELLBOOK_ORC = 90042; // Spellbook: Mount Black Bear
+ private static final int SPELLBOOK_DWARF = 90041; // Spellbook: Mount Kukuru
+ private static final int SPELLBOOK_KAMAEL = 91946; // Spellbook: Mount Griffin
+ private static final int SPELLBOOK_DEATH_KNIGHT = 93383; // Spellbook: Mount Nightmare Steed
+ // Misc
+ private static final Location TELEPORT_ADEN_LOCATION = new Location(146856, 25803, -2008);
+ private static final Location TELEPORT_GIRAN_LOCATION = new Location(83386, 148014, -3400);
+ private static final int INSTANCE_ID = 190;
+
+ private AdditionalServicesAdvisor()
+ {
+ addStartNpc(JUNI, HERMIN);
+ addFirstTalkId(JUNI, HERMIN);
+ addTalkId(JUNI, HERMIN);
+ }
+
+ @Override
+ public String onAdvEvent(String event, Npc npc, Player player)
+ {
+ String html = null;
+ switch (npc.getId())
+ {
+ case JUNI:
+ {
+ switch (event)
+ {
+ case "34152.htm":
+ case "34152-1.htm":
+ {
+ html = event;
+ break;
+ }
+ case "teleport_inside":
+ {
+ html = checkConditions(npc, player);
+ if (html == null)
+ {
+ final Instance instance = InstanceManager.getInstance().createInstance(INSTANCE_ID, player);
+ player.teleToLocation(instance.getEnterLocation(), instance);
+ }
+ break;
+ }
+ }
+ break;
+ }
+ case HERMIN:
+ {
+ switch (event)
+ {
+ case "34153.htm":
+ case "34153-1.htm":
+ case "34153-class_darkelf.htm":
+ case "34153-class_dwarf.htm":
+ case "34153-class_elf.htm":
+ case "34153-class_human.htm":
+ case "34153-class_kamael.htm":
+ case "34153-class_orc.htm":
+ case "34153-class_sylph.htm":
+ case "34153-race.htm":
+ {
+ html = event;
+ break;
+ }
+ case "teleport_aden":
+ {
+ player.teleToLocation(TELEPORT_ADEN_LOCATION, null);
+ break;
+ }
+ case "teleport_giran":
+ {
+ player.teleToLocation(TELEPORT_GIRAN_LOCATION, null);
+ break;
+ }
+ }
+ if (event.startsWith("choose_class"))
+ {
+ final int classId = Integer.parseInt(event.split(" ")[1]);
+ if (classId > 195)
+ {
+ html = getHtm(player, "34153-choose_gender_unavailable.htm");
+ }
+ else
+ {
+ html = getHtm(player, "34153-choose_gender.htm");
+ }
+ html = html.replace("%class_id%", String.valueOf(classId));
+ html = html.replace("%class_name%", ClassListData.getInstance().getClass(classId).getClassName());
+ return html;
+ }
+ else if (event.startsWith("choose_gender"))
+ {
+ final String[] split = event.split(" ");
+ final int classId = Integer.parseInt(split[1]);
+ final boolean female = split[2].equals("female");
+ if (female && (classId > 195))
+ {
+ return null;
+ }
+
+ html = getHtm(player, "34153-choose_gender_confirm.htm");
+ html = html.replace("%class_id%", String.valueOf(classId));
+ html = html.replace("%class_name%", ClassListData.getInstance().getClass(classId).getClassName());
+ html = html.replace("%sex%", female ? "female" : "male");
+ }
+ else if (event.startsWith("choose_gender_confirm"))
+ {
+ final String[] split = event.split(" ");
+ final int classId = Integer.parseInt(split[1]);
+ final boolean female = split[2].equals("female");
+ if (female && (classId > 195))
+ {
+ break;
+ }
+
+ html = getHtm(player, "34153-choose_gender_unavailable.htm");
+ html = html.replace("%class_id%", String.valueOf(classId));
+ html = html.replace("%class_name%", ClassListData.getInstance().getClass(classId).getClassName());
+ html = html.replace("%sex%", female ? "female" : "male");
+ }
+ else if (event.startsWith("confirm_class"))
+ {
+ html = checkConditions(npc, player);
+ if (html != null)
+ {
+ break;
+ }
+
+ final String[] split = event.split(" ");
+ final int classId = Integer.parseInt(split[1]);
+ final boolean female = split[2].equals("female");
+ if (female && (classId > 195))
+ {
+ break;
+ }
+
+ if (hasQuestItems(player, CLASS_CHANGE_COUPON))
+ {
+ takeItems(player, CLASS_CHANGE_COUPON, 1);
+
+ for (Skill skill : player.getAllSkills())
+ {
+ player.removeSkill(skill);
+ }
+ player.setVitalityPoints(0, true);
+ player.setExpBeforeDeath(0);
+
+ if (female)
+ {
+ player.getAppearance().setFemale();
+ }
+ else
+ {
+ player.getAppearance().setMale();
+ }
+ player.setClassId(classId);
+ player.setBaseClass(player.getActiveClass());
+
+ giveItems(player, SP_SCROLL, 20);
+ if (player.isInCategory(CategoryType.FOURTH_CLASS_GROUP))
+ {
+ player.getVariables().set("3rdClassMountRewarded", true);
+ if (player.isDeathKnight())
+ {
+ giveItems(player, SPELLBOOK_DEATH_KNIGHT, 1);
+ }
+ else
+ {
+ switch (player.getRace())
+ {
+ case ELF:
+ {
+ giveItems(player, SPELLBOOK_ELF, 1);
+ break;
+ }
+ case DARK_ELF:
+ {
+ giveItems(player, SPELLBOOK_DELF, 1);
+ break;
+ }
+ case ORC:
+ {
+ giveItems(player, SPELLBOOK_ORC, 1);
+ break;
+ }
+ case DWARF:
+ {
+ giveItems(player, SPELLBOOK_DWARF, 1);
+ break;
+ }
+ case KAMAEL:
+ {
+ giveItems(player, SPELLBOOK_KAMAEL, 1);
+ break;
+ }
+ case HUMAN:
+ {
+ giveItems(player, SPELLBOOK_HUMAN, 1);
+ break;
+ }
+ }
+ }
+ }
+
+ player.getServitorsAndPets().forEach(s -> s.unSummon(player));
+ player.getEffectList().stopAllEffects(true);
+ player.getInventory().getItems().forEach(item ->
+ {
+ if (item.isEquipped())
+ {
+ player.getInventory().unEquipItemInSlot(item.getLocationSlot());
+ }
+ });
+
+ // Appearance after class change.
+ player.getAppearance().setHairStyle(0);
+ player.getAppearance().setHairColor(0);
+ player.getAppearance().setFace(0);
+
+ // Set new classId and reset olympiad points.
+ try (Connection con = DatabaseFactory.getConnection();
+ PreparedStatement ps = con.prepareStatement("UPDATE olympiad_nobles SET olympiad_points=?, class_id=? WHERE charId='" + player.getObjectId() + "'"))
+ {
+ ps.setInt(1, Config.ALT_OLY_START_POINTS);
+ ps.setInt(2, classId);
+ ps.executeUpdate();
+ }
+ catch (Exception e)
+ {
+ LOGGER.warning(this.getClass().getSimpleName() + ": Set new classId and reset olympiad points: " + e.getMessage());
+ }
+
+ player.store(false);
+ player.broadcastUserInfo();
+ player.sendSkillList();
+ player.sendPacket(new ExSubjobInfo(player, SubclassInfoType.CLASS_CHANGED));
+ player.sendPacket(new ExUserInfoInvenWeight(player));
+ }
+ else
+ {
+ html = "34152-no_coupon.htm";
+ }
+ }
+ break;
+ }
+ }
+ return html;
+ }
+
+ @Override
+ public String onFirstTalk(Npc npc, Player player)
+ {
+ return npc.getId() + ".htm";
+ }
+
+ private String checkConditions(Npc npc, Player player)
+ {
+ if (!hasQuestItems(player, CLASS_CHANGE_COUPON))
+ {
+ return npc.getId() + "-no_coupon.htm";
+ }
+ for (Item item : player.getInventory().getItems())
+ {
+ if (item.isEquipped())
+ {
+ return npc.getId() + "-unequip_items.htm";
+ }
+ }
+ if (!player.isInventoryUnder80(false) || (player.getWeightPenalty() >= 3))
+ {
+ return npc.getId() + "-no_inventory.htm";
+ }
+ if (!player.isInCategory(CategoryType.FOURTH_CLASS_GROUP))
+ {
+ return npc.getId() + "-3rd_class.htm";
+ }
+ if (player.isInOlympiadMode() || player.isHero() || Hero.getInstance().isHero(player.getObjectId()) || Hero.getInstance().isUnclaimedHero(player.getObjectId()))
+ {
+ return npc.getId() + "-1.htm";
+ }
+ return null;
+ }
+
+ public static void main(String[] args)
+ {
+ new AdditionalServicesAdvisor();
+ }
+}
diff --git a/L2J_Mobius_Essence_4.2_DwellingOfSpirits/dist/game/data/spawns/Aden/AdenSquareMerchants.xml b/L2J_Mobius_Essence_4.2_DwellingOfSpirits/dist/game/data/spawns/Aden/AdenSquareMerchants.xml
index 4f9ea0b8f7..8c8f3e6761 100644
--- a/L2J_Mobius_Essence_4.2_DwellingOfSpirits/dist/game/data/spawns/Aden/AdenSquareMerchants.xml
+++ b/L2J_Mobius_Essence_4.2_DwellingOfSpirits/dist/game/data/spawns/Aden/AdenSquareMerchants.xml
@@ -2,6 +2,7 @@
+
diff --git a/L2J_Mobius_Essence_4.2_DwellingOfSpirits/dist/game/data/spawns/Giran/GiranSquareMerchants.xml b/L2J_Mobius_Essence_4.2_DwellingOfSpirits/dist/game/data/spawns/Giran/GiranSquareMerchants.xml
index 1a7a868a91..71658f5849 100644
--- a/L2J_Mobius_Essence_4.2_DwellingOfSpirits/dist/game/data/spawns/Giran/GiranSquareMerchants.xml
+++ b/L2J_Mobius_Essence_4.2_DwellingOfSpirits/dist/game/data/spawns/Giran/GiranSquareMerchants.xml
@@ -8,6 +8,7 @@
+
diff --git a/L2J_Mobius_Essence_5.2_FrostLord/dist/game/data/instances/AdditionalServicesLab.xml b/L2J_Mobius_Essence_5.2_FrostLord/dist/game/data/instances/AdditionalServicesLab.xml
new file mode 100644
index 0000000000..4982ca4c33
--- /dev/null
+++ b/L2J_Mobius_Essence_5.2_FrostLord/dist/game/data/instances/AdditionalServicesLab.xml
@@ -0,0 +1,15 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/L2J_Mobius_Essence_5.2_FrostLord/dist/game/data/scripts/ai/others/AdditionalServicesAdvisor/34152-1.htm b/L2J_Mobius_Essence_5.2_FrostLord/dist/game/data/scripts/ai/others/AdditionalServicesAdvisor/34152-1.htm
new file mode 100644
index 0000000000..e8b5cfdf1e
--- /dev/null
+++ b/L2J_Mobius_Essence_5.2_FrostLord/dist/game/data/scripts/ai/others/AdditionalServicesAdvisor/34152-1.htm
@@ -0,0 +1,9 @@
+Additional Services' Advisor Juni:
+With our class change service you can choose a different class for your character. You need to prepare for it, however
+First, you need a Class Change Coupon that's sold in the Adena store section of the L-Coin Store.
+Second, you have to unequip all items.
+Third, you need to free up your inventory.You will need at least 30 slots.
+What's more, Heroes can't change their class, so a character with this title is ineligible for the service.
+Tell me once you're ready, I'll send you to the Additional Services Lab. Talk to the Researcher Hermin there to change class.
+
+
\ No newline at end of file
diff --git a/L2J_Mobius_Essence_5.2_FrostLord/dist/game/data/scripts/ai/others/AdditionalServicesAdvisor/34152-3rd_class.htm b/L2J_Mobius_Essence_5.2_FrostLord/dist/game/data/scripts/ai/others/AdditionalServicesAdvisor/34152-3rd_class.htm
new file mode 100644
index 0000000000..a53511aa02
--- /dev/null
+++ b/L2J_Mobius_Essence_5.2_FrostLord/dist/game/data/scripts/ai/others/AdditionalServicesAdvisor/34152-3rd_class.htm
@@ -0,0 +1,6 @@
+Additional Services' Advisor Juni:
+You can change class only after the 3rd class change.
+Come back once you have your 3rd class.
+Tell me once you're ready. I'll send you to the Additional Services Lab. Talk to the Researcher Hermin there to change class.
+
+
\ No newline at end of file
diff --git a/L2J_Mobius_Essence_5.2_FrostLord/dist/game/data/scripts/ai/others/AdditionalServicesAdvisor/34152-no_coupon.htm b/L2J_Mobius_Essence_5.2_FrostLord/dist/game/data/scripts/ai/others/AdditionalServicesAdvisor/34152-no_coupon.htm
new file mode 100644
index 0000000000..3290459b4a
--- /dev/null
+++ b/L2J_Mobius_Essence_5.2_FrostLord/dist/game/data/scripts/ai/others/AdditionalServicesAdvisor/34152-no_coupon.htm
@@ -0,0 +1,6 @@
+Additional Services' Advisor Juni:
+You don't have a Class Change Coupon!
+It's necessary if you want to change your class. You can buy it in the Adena store section of the L-Coin Store.
+Tell me once you're ready. I'll send you to the Additional Services Lab. Talk to the Researcher Hermin there to change class.
+
+
\ No newline at end of file
diff --git a/L2J_Mobius_Essence_5.2_FrostLord/dist/game/data/scripts/ai/others/AdditionalServicesAdvisor/34152-no_inventory.htm b/L2J_Mobius_Essence_5.2_FrostLord/dist/game/data/scripts/ai/others/AdditionalServicesAdvisor/34152-no_inventory.htm
new file mode 100644
index 0000000000..c4aea134ad
--- /dev/null
+++ b/L2J_Mobius_Essence_5.2_FrostLord/dist/game/data/scripts/ai/others/AdditionalServicesAdvisor/34152-no_inventory.htm
@@ -0,0 +1,7 @@
+Additional Services' Advisor Juni:
+Please, check your inventory.
+To change class, in your inventory must be free space and weight.
+Keep unnecessary items in the warehouse, to free 50% weight and at least 30 slots.
+Tell me once you're ready. I'll send you to the Additional Services Lab. Talk to the Researcher Hermin there to change class.
+
+
\ No newline at end of file
diff --git a/L2J_Mobius_Essence_5.2_FrostLord/dist/game/data/scripts/ai/others/AdditionalServicesAdvisor/34152-unequip_items.htm b/L2J_Mobius_Essence_5.2_FrostLord/dist/game/data/scripts/ai/others/AdditionalServicesAdvisor/34152-unequip_items.htm
new file mode 100644
index 0000000000..3c4b9ab55d
--- /dev/null
+++ b/L2J_Mobius_Essence_5.2_FrostLord/dist/game/data/scripts/ai/others/AdditionalServicesAdvisor/34152-unequip_items.htm
@@ -0,0 +1,6 @@
+Additional Services' Advisor Juni:
+It looks like you have an item equipped!
+To change class, you need to unequip all items.
+Tell me once you're ready. I'll send you to the Additional Services Lab. Talk to the Researcher Hermin there to change class.
+
+
\ No newline at end of file
diff --git a/L2J_Mobius_Essence_5.2_FrostLord/dist/game/data/scripts/ai/others/AdditionalServicesAdvisor/34152.htm b/L2J_Mobius_Essence_5.2_FrostLord/dist/game/data/scripts/ai/others/AdditionalServicesAdvisor/34152.htm
new file mode 100644
index 0000000000..d794126044
--- /dev/null
+++ b/L2J_Mobius_Essence_5.2_FrostLord/dist/game/data/scripts/ai/others/AdditionalServicesAdvisor/34152.htm
@@ -0,0 +1,6 @@
+Additional Services' Advisor Juni:
+If you need help with additional services, ask me anytime! I'll explain it all to you.
+The Additional Services Lab provides the class change service. Would you be interested in that?
+
+
+
\ No newline at end of file
diff --git a/L2J_Mobius_Essence_5.2_FrostLord/dist/game/data/scripts/ai/others/AdditionalServicesAdvisor/34153-1.htm b/L2J_Mobius_Essence_5.2_FrostLord/dist/game/data/scripts/ai/others/AdditionalServicesAdvisor/34153-1.htm
new file mode 100644
index 0000000000..889075bb1a
--- /dev/null
+++ b/L2J_Mobius_Essence_5.2_FrostLord/dist/game/data/scripts/ai/others/AdditionalServicesAdvisor/34153-1.htm
@@ -0,0 +1,8 @@
+Additional Services' Researcher Hermin:
+In order to change a class, several conditions must be met. Changing a class requires care and attention, so it is only done in this laboratory.
+First, you need Class Change Coupon, that's sold in the Adena store section of the L-Coin Store.
+Second, you have to unequip all items.
+Third, you need to free up your inventory You will need at least 30 slots.
+You should also know that only warriors can change classes, not holding the title of Hero.
+So, are you ready?
+
\ No newline at end of file
diff --git a/L2J_Mobius_Essence_5.2_FrostLord/dist/game/data/scripts/ai/others/AdditionalServicesAdvisor/34153-3rd_class.htm b/L2J_Mobius_Essence_5.2_FrostLord/dist/game/data/scripts/ai/others/AdditionalServicesAdvisor/34153-3rd_class.htm
new file mode 100644
index 0000000000..463776caf1
--- /dev/null
+++ b/L2J_Mobius_Essence_5.2_FrostLord/dist/game/data/scripts/ai/others/AdditionalServicesAdvisor/34153-3rd_class.htm
@@ -0,0 +1,6 @@
+Additional Services' Researcher Hermin:
+You can change class only after the 3rd class change.
+Come back once you have your 3rd class.
+Tell me once you're ready.
+
+
\ No newline at end of file
diff --git a/L2J_Mobius_Essence_5.2_FrostLord/dist/game/data/scripts/ai/others/AdditionalServicesAdvisor/34153-choose_gender.htm b/L2J_Mobius_Essence_5.2_FrostLord/dist/game/data/scripts/ai/others/AdditionalServicesAdvisor/34153-choose_gender.htm
new file mode 100644
index 0000000000..03f4b41d03
--- /dev/null
+++ b/L2J_Mobius_Essence_5.2_FrostLord/dist/game/data/scripts/ai/others/AdditionalServicesAdvisor/34153-choose_gender.htm
@@ -0,0 +1,7 @@
+Additional Services' Researcher Hermin:
+So you want to be %class_name%.
+Now choose the gender of your character. Close your eyes and imagine what you will become when you change classes.
+What gender will be your Duelist?
+
+
+
\ No newline at end of file
diff --git a/L2J_Mobius_Essence_5.2_FrostLord/dist/game/data/scripts/ai/others/AdditionalServicesAdvisor/34153-choose_gender_confirm.htm b/L2J_Mobius_Essence_5.2_FrostLord/dist/game/data/scripts/ai/others/AdditionalServicesAdvisor/34153-choose_gender_confirm.htm
new file mode 100644
index 0000000000..dcf2785571
--- /dev/null
+++ b/L2J_Mobius_Essence_5.2_FrostLord/dist/game/data/scripts/ai/others/AdditionalServicesAdvisor/34153-choose_gender_confirm.htm
@@ -0,0 +1,8 @@
+Additional Services' Researcher Hermin:
+Your choice of class - %class_name%.
+The character will be %sex%. Are you sure about your decision?
+After confirmations the character will get selected race and gender, as well as will change to the class of your choice.
+After agreeing, you will be briefly disconnected from the game. Are you confirming your choice?
+
+
+
\ No newline at end of file
diff --git a/L2J_Mobius_Essence_5.2_FrostLord/dist/game/data/scripts/ai/others/AdditionalServicesAdvisor/34153-choose_gender_unavailable.htm b/L2J_Mobius_Essence_5.2_FrostLord/dist/game/data/scripts/ai/others/AdditionalServicesAdvisor/34153-choose_gender_unavailable.htm
new file mode 100644
index 0000000000..7c38e0d9e7
--- /dev/null
+++ b/L2J_Mobius_Essence_5.2_FrostLord/dist/game/data/scripts/ai/others/AdditionalServicesAdvisor/34153-choose_gender_unavailable.htm
@@ -0,0 +1,6 @@
+Additional Services' Researcher Hermin:
+So you want to be %class_name%. Now you have to choose the gender of the character. Unfortunately, gender selection is not available for the %class_name%.
+ %class_name% can only be men. Now close your eyes and concentrate.
+ Imagine what it would be like to be %class_name%?
+
+
\ No newline at end of file
diff --git a/L2J_Mobius_Essence_5.2_FrostLord/dist/game/data/scripts/ai/others/AdditionalServicesAdvisor/34153-class_darkelf.htm b/L2J_Mobius_Essence_5.2_FrostLord/dist/game/data/scripts/ai/others/AdditionalServicesAdvisor/34153-class_darkelf.htm
new file mode 100644
index 0000000000..92ebab3f8b
--- /dev/null
+++ b/L2J_Mobius_Essence_5.2_FrostLord/dist/game/data/scripts/ai/others/AdditionalServicesAdvisor/34153-class_darkelf.htm
@@ -0,0 +1,11 @@
+Additional Services' Researcher Hermin:
+Aha, the Dark Elf! So you want to be a Dark Elf. Now choose... class for your character.
+
+
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/L2J_Mobius_Essence_5.2_FrostLord/dist/game/data/scripts/ai/others/AdditionalServicesAdvisor/34153-class_dwarf.htm b/L2J_Mobius_Essence_5.2_FrostLord/dist/game/data/scripts/ai/others/AdditionalServicesAdvisor/34153-class_dwarf.htm
new file mode 100644
index 0000000000..6385e1e8b9
--- /dev/null
+++ b/L2J_Mobius_Essence_5.2_FrostLord/dist/game/data/scripts/ai/others/AdditionalServicesAdvisor/34153-class_dwarf.htm
@@ -0,0 +1,5 @@
+Additional Services' Researcher Hermin:
+Aha, Dwarf! So you want to be a Dwarf. Now choose... class for your character.
+
+
+
\ No newline at end of file
diff --git a/L2J_Mobius_Essence_5.2_FrostLord/dist/game/data/scripts/ai/others/AdditionalServicesAdvisor/34153-class_elf.htm b/L2J_Mobius_Essence_5.2_FrostLord/dist/game/data/scripts/ai/others/AdditionalServicesAdvisor/34153-class_elf.htm
new file mode 100644
index 0000000000..f6d322da73
--- /dev/null
+++ b/L2J_Mobius_Essence_5.2_FrostLord/dist/game/data/scripts/ai/others/AdditionalServicesAdvisor/34153-class_elf.htm
@@ -0,0 +1,11 @@
+Additional Services' Researcher Hermin:
+Aha, Elf! So you want to be an Elf. Now choose. class for your character.
+
+
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/L2J_Mobius_Essence_5.2_FrostLord/dist/game/data/scripts/ai/others/AdditionalServicesAdvisor/34153-class_human.htm b/L2J_Mobius_Essence_5.2_FrostLord/dist/game/data/scripts/ai/others/AdditionalServicesAdvisor/34153-class_human.htm
new file mode 100644
index 0000000000..1560c9c2e9
--- /dev/null
+++ b/L2J_Mobius_Essence_5.2_FrostLord/dist/game/data/scripts/ai/others/AdditionalServicesAdvisor/34153-class_human.htm
@@ -0,0 +1,15 @@
+Additional Services' Researcher Hermin:
+Aha, a Man! So you want to be Human. Now choose class for your character.
+
+
+
+
+
+
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/L2J_Mobius_Essence_5.2_FrostLord/dist/game/data/scripts/ai/others/AdditionalServicesAdvisor/34153-class_kamael.htm b/L2J_Mobius_Essence_5.2_FrostLord/dist/game/data/scripts/ai/others/AdditionalServicesAdvisor/34153-class_kamael.htm
new file mode 100644
index 0000000000..f66211104d
--- /dev/null
+++ b/L2J_Mobius_Essence_5.2_FrostLord/dist/game/data/scripts/ai/others/AdditionalServicesAdvisor/34153-class_kamael.htm
@@ -0,0 +1,6 @@
+Additional Services' Researcher Hermin:
+Aha, Kamael! So you want to be Kamael! Now choose... class for your character.
+
+
+
+
\ No newline at end of file
diff --git a/L2J_Mobius_Essence_5.2_FrostLord/dist/game/data/scripts/ai/others/AdditionalServicesAdvisor/34153-class_orc.htm b/L2J_Mobius_Essence_5.2_FrostLord/dist/game/data/scripts/ai/others/AdditionalServicesAdvisor/34153-class_orc.htm
new file mode 100644
index 0000000000..384c5f58ce
--- /dev/null
+++ b/L2J_Mobius_Essence_5.2_FrostLord/dist/game/data/scripts/ai/others/AdditionalServicesAdvisor/34153-class_orc.htm
@@ -0,0 +1,8 @@
+Additional Services' Researcher Hermin:
+Aha, Orc! So you want to be an Orc. Now choose class for your character.
+
+
+
+
+
+
\ No newline at end of file
diff --git a/L2J_Mobius_Essence_5.2_FrostLord/dist/game/data/scripts/ai/others/AdditionalServicesAdvisor/34153-class_sylph.htm b/L2J_Mobius_Essence_5.2_FrostLord/dist/game/data/scripts/ai/others/AdditionalServicesAdvisor/34153-class_sylph.htm
new file mode 100644
index 0000000000..7ad6938192
--- /dev/null
+++ b/L2J_Mobius_Essence_5.2_FrostLord/dist/game/data/scripts/ai/others/AdditionalServicesAdvisor/34153-class_sylph.htm
@@ -0,0 +1,4 @@
+Additional Services' Researcher Hermin:
+Sylph, that's it! So you've chosen the Sylph race. Now select class for your character, available to the Sylph race.
+
+
\ No newline at end of file
diff --git a/L2J_Mobius_Essence_5.2_FrostLord/dist/game/data/scripts/ai/others/AdditionalServicesAdvisor/34153-no_coupon.htm b/L2J_Mobius_Essence_5.2_FrostLord/dist/game/data/scripts/ai/others/AdditionalServicesAdvisor/34153-no_coupon.htm
new file mode 100644
index 0000000000..2b7c617055
--- /dev/null
+++ b/L2J_Mobius_Essence_5.2_FrostLord/dist/game/data/scripts/ai/others/AdditionalServicesAdvisor/34153-no_coupon.htm
@@ -0,0 +1,6 @@
+Additional Services' Researcher Hermin:
+You don't have a Class Change Coupon!
+It's necessary if you want to change your class. You can buy it in the Adena store section of the L-Coin Store.
+Tell me once you're ready.
+
+
\ No newline at end of file
diff --git a/L2J_Mobius_Essence_5.2_FrostLord/dist/game/data/scripts/ai/others/AdditionalServicesAdvisor/34153-no_inventory.htm b/L2J_Mobius_Essence_5.2_FrostLord/dist/game/data/scripts/ai/others/AdditionalServicesAdvisor/34153-no_inventory.htm
new file mode 100644
index 0000000000..d5a96cd458
--- /dev/null
+++ b/L2J_Mobius_Essence_5.2_FrostLord/dist/game/data/scripts/ai/others/AdditionalServicesAdvisor/34153-no_inventory.htm
@@ -0,0 +1,7 @@
+Additional Services' Researcher Hermin:
+Please, check your inventory.
+To change class, in your inventory must be free space and weight.
+Keep unnecessary items in the warehouse, to free 50% weight and at least 30 slots.
+Tell me once you're ready.
+
+
\ No newline at end of file
diff --git a/L2J_Mobius_Essence_5.2_FrostLord/dist/game/data/scripts/ai/others/AdditionalServicesAdvisor/34153-race.htm b/L2J_Mobius_Essence_5.2_FrostLord/dist/game/data/scripts/ai/others/AdditionalServicesAdvisor/34153-race.htm
new file mode 100644
index 0000000000..db8994e061
--- /dev/null
+++ b/L2J_Mobius_Essence_5.2_FrostLord/dist/game/data/scripts/ai/others/AdditionalServicesAdvisor/34153-race.htm
@@ -0,0 +1,13 @@
+Additional Services' Researcher Hermin:
+If you are ready, let's begin the procedure for changing classes.
+Please choose carefully and calmly, weighing the pros and cons.
+Close your eyes and imagine what you will become when you change classes.
+What race will be a character?
+
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/L2J_Mobius_Essence_5.2_FrostLord/dist/game/data/scripts/ai/others/AdditionalServicesAdvisor/34153-unequip_items.htm b/L2J_Mobius_Essence_5.2_FrostLord/dist/game/data/scripts/ai/others/AdditionalServicesAdvisor/34153-unequip_items.htm
new file mode 100644
index 0000000000..4d3674e075
--- /dev/null
+++ b/L2J_Mobius_Essence_5.2_FrostLord/dist/game/data/scripts/ai/others/AdditionalServicesAdvisor/34153-unequip_items.htm
@@ -0,0 +1,4 @@
+Additional Services' Researcher Hermin:
+It looks like you have an item equipped!
+To change class, you need to unequip all items.
+
\ No newline at end of file
diff --git a/L2J_Mobius_Essence_5.2_FrostLord/dist/game/data/scripts/ai/others/AdditionalServicesAdvisor/34153.htm b/L2J_Mobius_Essence_5.2_FrostLord/dist/game/data/scripts/ai/others/AdditionalServicesAdvisor/34153.htm
new file mode 100644
index 0000000000..0b00f1eda2
--- /dev/null
+++ b/L2J_Mobius_Essence_5.2_FrostLord/dist/game/data/scripts/ai/others/AdditionalServicesAdvisor/34153.htm
@@ -0,0 +1,15 @@
+Additional Services' Researcher Hermin:
+Hello, my name is Hermine, and I am a researcher of value-added services..
+Now the class change service is available.When you change class, some items will be dropped. Remember.
+All previously learned skillsDistributed characteristics
+Bonuses for ranking3 vs 3 Olympiad points and rank
+All positive effects When you change classes you get Scrolls SP for each level.
+Note that all skills learned with the Spell Books and the books themselves will not return.
+When you change classes to the one you had before, all learned skills are retained, so SP Scrolls are not issued.
+The Dragon Slayer Shape, the White Guardian Transformation, the Extended Paint Potential, the Wyvern Transformation from 3 and 4 star skills, and skills gained through one-time quests will be issued as Sealed Spell Books.
+Changing classes is a very important step, so think about it carefully.
+Do you want to change classes?
+
+
+
+
\ No newline at end of file
diff --git a/L2J_Mobius_Essence_5.2_FrostLord/dist/game/data/scripts/ai/others/AdditionalServicesAdvisor/AdditionalServicesAdvisor.java b/L2J_Mobius_Essence_5.2_FrostLord/dist/game/data/scripts/ai/others/AdditionalServicesAdvisor/AdditionalServicesAdvisor.java
new file mode 100644
index 0000000000..df9caaf97e
--- /dev/null
+++ b/L2J_Mobius_Essence_5.2_FrostLord/dist/game/data/scripts/ai/others/AdditionalServicesAdvisor/AdditionalServicesAdvisor.java
@@ -0,0 +1,346 @@
+/*
+ * 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 ai.others.AdditionalServicesAdvisor;
+
+import java.sql.Connection;
+import java.sql.PreparedStatement;
+
+import org.l2jmobius.Config;
+import org.l2jmobius.commons.database.DatabaseFactory;
+import org.l2jmobius.gameserver.data.xml.ClassListData;
+import org.l2jmobius.gameserver.enums.CategoryType;
+import org.l2jmobius.gameserver.enums.SubclassInfoType;
+import org.l2jmobius.gameserver.instancemanager.InstanceManager;
+import org.l2jmobius.gameserver.model.Location;
+import org.l2jmobius.gameserver.model.actor.Npc;
+import org.l2jmobius.gameserver.model.actor.Player;
+import org.l2jmobius.gameserver.model.instancezone.Instance;
+import org.l2jmobius.gameserver.model.item.instance.Item;
+import org.l2jmobius.gameserver.model.olympiad.Hero;
+import org.l2jmobius.gameserver.model.skill.Skill;
+import org.l2jmobius.gameserver.network.serverpackets.ExSubjobInfo;
+import org.l2jmobius.gameserver.network.serverpackets.ExUserInfoInvenWeight;
+
+import ai.AbstractNpcAI;
+
+/**
+ * @author Mobius
+ */
+public class AdditionalServicesAdvisor extends AbstractNpcAI
+{
+ // NPCs
+ private static final int JUNI = 34152;
+ private static final int HERMIN = 34153;
+ // Items
+ private static final int CLASS_CHANGE_COUPON = 94828;
+ private static final int SP_SCROLL = 94829;
+ private static final int SPELLBOOK_HUMAN = 90038; // Spellbook: Mount Golden Lion
+ private static final int SPELLBOOK_ELF = 90039; // Spellbook: Mount Pegasus
+ private static final int SPELLBOOK_DELF = 90040; // Spellbook: Mount Saber Tooth Cougar
+ private static final int SPELLBOOK_ORC = 90042; // Spellbook: Mount Black Bear
+ private static final int SPELLBOOK_DWARF = 90041; // Spellbook: Mount Kukuru
+ private static final int SPELLBOOK_KAMAEL = 91946; // Spellbook: Mount Griffin
+ private static final int SPELLBOOK_DEATH_KNIGHT = 93383; // Spellbook: Mount Nightmare Steed
+ private static final int SPELLBOOK_SYLPH = 95367; // Spellbook: Mount Elemental Lyn Draco
+ // Misc
+ private static final Location TELEPORT_ADEN_LOCATION = new Location(146856, 25803, -2008);
+ private static final Location TELEPORT_GIRAN_LOCATION = new Location(83386, 148014, -3400);
+ private static final int INSTANCE_ID = 190;
+
+ private AdditionalServicesAdvisor()
+ {
+ addStartNpc(JUNI, HERMIN);
+ addFirstTalkId(JUNI, HERMIN);
+ addTalkId(JUNI, HERMIN);
+ }
+
+ @Override
+ public String onAdvEvent(String event, Npc npc, Player player)
+ {
+ String html = null;
+ switch (npc.getId())
+ {
+ case JUNI:
+ {
+ switch (event)
+ {
+ case "34152.htm":
+ case "34152-1.htm":
+ {
+ html = event;
+ break;
+ }
+ case "teleport_inside":
+ {
+ html = checkConditions(npc, player);
+ if (html == null)
+ {
+ final Instance instance = InstanceManager.getInstance().createInstance(INSTANCE_ID, player);
+ player.teleToLocation(instance.getEnterLocation(), instance);
+ }
+ break;
+ }
+ }
+ break;
+ }
+ case HERMIN:
+ {
+ switch (event)
+ {
+ case "34153.htm":
+ case "34153-1.htm":
+ case "34153-class_darkelf.htm":
+ case "34153-class_dwarf.htm":
+ case "34153-class_elf.htm":
+ case "34153-class_human.htm":
+ case "34153-class_kamael.htm":
+ case "34153-class_orc.htm":
+ case "34153-class_sylph.htm":
+ case "34153-race.htm":
+ {
+ html = event;
+ break;
+ }
+ case "teleport_aden":
+ {
+ player.teleToLocation(TELEPORT_ADEN_LOCATION, null);
+ break;
+ }
+ case "teleport_giran":
+ {
+ player.teleToLocation(TELEPORT_GIRAN_LOCATION, null);
+ break;
+ }
+ }
+ if (event.startsWith("choose_class"))
+ {
+ final int classId = Integer.parseInt(event.split(" ")[1]);
+ if (classId > 195)
+ {
+ html = getHtm(player, "34153-choose_gender_unavailable.htm");
+ }
+ else
+ {
+ html = getHtm(player, "34153-choose_gender.htm");
+ }
+ html = html.replace("%class_id%", String.valueOf(classId));
+ html = html.replace("%class_name%", ClassListData.getInstance().getClass(classId).getClassName());
+ return html;
+ }
+ else if (event.startsWith("choose_gender"))
+ {
+ final String[] split = event.split(" ");
+ final int classId = Integer.parseInt(split[1]);
+ final boolean female = split[2].equals("female");
+ if (female && (classId > 195))
+ {
+ return null;
+ }
+
+ html = getHtm(player, "34153-choose_gender_confirm.htm");
+ html = html.replace("%class_id%", String.valueOf(classId));
+ html = html.replace("%class_name%", ClassListData.getInstance().getClass(classId).getClassName());
+ html = html.replace("%sex%", female ? "female" : "male");
+ }
+ else if (event.startsWith("choose_gender_confirm"))
+ {
+ final String[] split = event.split(" ");
+ final int classId = Integer.parseInt(split[1]);
+ final boolean female = split[2].equals("female");
+ if (female && (classId > 195))
+ {
+ break;
+ }
+
+ html = getHtm(player, "34153-choose_gender_unavailable.htm");
+ html = html.replace("%class_id%", String.valueOf(classId));
+ html = html.replace("%class_name%", ClassListData.getInstance().getClass(classId).getClassName());
+ html = html.replace("%sex%", female ? "female" : "male");
+ }
+ else if (event.startsWith("confirm_class"))
+ {
+ html = checkConditions(npc, player);
+ if (html != null)
+ {
+ break;
+ }
+
+ final String[] split = event.split(" ");
+ final int classId = Integer.parseInt(split[1]);
+ final boolean female = split[2].equals("female");
+ if (female && (classId > 195))
+ {
+ break;
+ }
+
+ if (hasQuestItems(player, CLASS_CHANGE_COUPON))
+ {
+ takeItems(player, CLASS_CHANGE_COUPON, 1);
+
+ for (Skill skill : player.getAllSkills())
+ {
+ player.removeSkill(skill);
+ }
+ player.setVitalityPoints(0, true);
+ player.setExpBeforeDeath(0);
+
+ if (female)
+ {
+ player.getAppearance().setFemale();
+ }
+ else
+ {
+ player.getAppearance().setMale();
+ }
+ player.setClassId(classId);
+ player.setBaseClass(player.getActiveClass());
+
+ giveItems(player, SP_SCROLL, 20);
+ if (player.isInCategory(CategoryType.FOURTH_CLASS_GROUP))
+ {
+ player.getVariables().set("3rdClassMountRewarded", true);
+ if (player.isDeathKnight())
+ {
+ giveItems(player, SPELLBOOK_DEATH_KNIGHT, 1);
+ }
+ else
+ {
+ switch (player.getRace())
+ {
+ case ELF:
+ {
+ giveItems(player, SPELLBOOK_ELF, 1);
+ break;
+ }
+ case DARK_ELF:
+ {
+ giveItems(player, SPELLBOOK_DELF, 1);
+ break;
+ }
+ case ORC:
+ {
+ giveItems(player, SPELLBOOK_ORC, 1);
+ break;
+ }
+ case DWARF:
+ {
+ giveItems(player, SPELLBOOK_DWARF, 1);
+ break;
+ }
+ case KAMAEL:
+ {
+ giveItems(player, SPELLBOOK_KAMAEL, 1);
+ break;
+ }
+ case HUMAN:
+ {
+ giveItems(player, SPELLBOOK_HUMAN, 1);
+ break;
+ }
+ case SYLPH:
+ {
+ giveItems(player, SPELLBOOK_SYLPH, 1);
+ break;
+ }
+ }
+ }
+ }
+
+ player.getServitorsAndPets().forEach(s -> s.unSummon(player));
+ player.getEffectList().stopAllEffects(true);
+ player.getInventory().getItems().forEach(item ->
+ {
+ if (item.isEquipped())
+ {
+ player.getInventory().unEquipItemInSlot(item.getLocationSlot());
+ }
+ });
+
+ // Appearance after class change.
+ player.getAppearance().setHairStyle(0);
+ player.getAppearance().setHairColor(0);
+ player.getAppearance().setFace(0);
+
+ // Set new classId and reset olympiad points.
+ try (Connection con = DatabaseFactory.getConnection();
+ PreparedStatement ps = con.prepareStatement("UPDATE olympiad_nobles SET olympiad_points=?, class_id=? WHERE charId='" + player.getObjectId() + "'"))
+ {
+ ps.setInt(1, Config.ALT_OLY_START_POINTS);
+ ps.setInt(2, classId);
+ ps.executeUpdate();
+ }
+ catch (Exception e)
+ {
+ LOGGER.warning(this.getClass().getSimpleName() + ": Set new classId and reset olympiad points: " + e.getMessage());
+ }
+
+ player.store(false);
+ player.broadcastUserInfo();
+ player.sendSkillList();
+ player.sendPacket(new ExSubjobInfo(player, SubclassInfoType.CLASS_CHANGED));
+ player.sendPacket(new ExUserInfoInvenWeight(player));
+ }
+ else
+ {
+ html = "34152-no_coupon.htm";
+ }
+ }
+ break;
+ }
+ }
+ return html;
+ }
+
+ @Override
+ public String onFirstTalk(Npc npc, Player player)
+ {
+ return npc.getId() + ".htm";
+ }
+
+ private String checkConditions(Npc npc, Player player)
+ {
+ if (!hasQuestItems(player, CLASS_CHANGE_COUPON))
+ {
+ return npc.getId() + "-no_coupon.htm";
+ }
+ for (Item item : player.getInventory().getItems())
+ {
+ if (item.isEquipped())
+ {
+ return npc.getId() + "-unequip_items.htm";
+ }
+ }
+ if (!player.isInventoryUnder80(false) || (player.getWeightPenalty() >= 3))
+ {
+ return npc.getId() + "-no_inventory.htm";
+ }
+ if (!player.isInCategory(CategoryType.FOURTH_CLASS_GROUP))
+ {
+ return npc.getId() + "-3rd_class.htm";
+ }
+ if (player.isInOlympiadMode() || player.isHero() || Hero.getInstance().isHero(player.getObjectId()) || Hero.getInstance().isUnclaimedHero(player.getObjectId()))
+ {
+ return npc.getId() + "-1.htm";
+ }
+ return null;
+ }
+
+ public static void main(String[] args)
+ {
+ new AdditionalServicesAdvisor();
+ }
+}
diff --git a/L2J_Mobius_Essence_5.2_FrostLord/dist/game/data/spawns/Aden/AdenSquareMerchants.xml b/L2J_Mobius_Essence_5.2_FrostLord/dist/game/data/spawns/Aden/AdenSquareMerchants.xml
index c699f98c10..1a502f52bf 100644
--- a/L2J_Mobius_Essence_5.2_FrostLord/dist/game/data/spawns/Aden/AdenSquareMerchants.xml
+++ b/L2J_Mobius_Essence_5.2_FrostLord/dist/game/data/spawns/Aden/AdenSquareMerchants.xml
@@ -2,6 +2,7 @@
+
diff --git a/L2J_Mobius_Essence_5.2_FrostLord/dist/game/data/spawns/Giran/GiranSquareMerchants.xml b/L2J_Mobius_Essence_5.2_FrostLord/dist/game/data/spawns/Giran/GiranSquareMerchants.xml
index f4daa8866e..3beb23d04b 100644
--- a/L2J_Mobius_Essence_5.2_FrostLord/dist/game/data/spawns/Giran/GiranSquareMerchants.xml
+++ b/L2J_Mobius_Essence_5.2_FrostLord/dist/game/data/spawns/Giran/GiranSquareMerchants.xml
@@ -8,6 +8,7 @@
+
diff --git a/L2J_Mobius_Essence_6.2_Vanguard/dist/game/data/instances/AdditionalServicesLab.xml b/L2J_Mobius_Essence_6.2_Vanguard/dist/game/data/instances/AdditionalServicesLab.xml
new file mode 100644
index 0000000000..4982ca4c33
--- /dev/null
+++ b/L2J_Mobius_Essence_6.2_Vanguard/dist/game/data/instances/AdditionalServicesLab.xml
@@ -0,0 +1,15 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/L2J_Mobius_Essence_6.2_Vanguard/dist/game/data/scripts/ai/others/AdditionalServicesAdvisor/34152-1.htm b/L2J_Mobius_Essence_6.2_Vanguard/dist/game/data/scripts/ai/others/AdditionalServicesAdvisor/34152-1.htm
new file mode 100644
index 0000000000..e8b5cfdf1e
--- /dev/null
+++ b/L2J_Mobius_Essence_6.2_Vanguard/dist/game/data/scripts/ai/others/AdditionalServicesAdvisor/34152-1.htm
@@ -0,0 +1,9 @@
+Additional Services' Advisor Juni:
+With our class change service you can choose a different class for your character. You need to prepare for it, however
+First, you need a Class Change Coupon that's sold in the Adena store section of the L-Coin Store.
+Second, you have to unequip all items.
+Third, you need to free up your inventory.You will need at least 30 slots.
+What's more, Heroes can't change their class, so a character with this title is ineligible for the service.
+Tell me once you're ready, I'll send you to the Additional Services Lab. Talk to the Researcher Hermin there to change class.
+
+
\ No newline at end of file
diff --git a/L2J_Mobius_Essence_6.2_Vanguard/dist/game/data/scripts/ai/others/AdditionalServicesAdvisor/34152-3rd_class.htm b/L2J_Mobius_Essence_6.2_Vanguard/dist/game/data/scripts/ai/others/AdditionalServicesAdvisor/34152-3rd_class.htm
new file mode 100644
index 0000000000..a53511aa02
--- /dev/null
+++ b/L2J_Mobius_Essence_6.2_Vanguard/dist/game/data/scripts/ai/others/AdditionalServicesAdvisor/34152-3rd_class.htm
@@ -0,0 +1,6 @@
+Additional Services' Advisor Juni:
+You can change class only after the 3rd class change.
+Come back once you have your 3rd class.
+Tell me once you're ready. I'll send you to the Additional Services Lab. Talk to the Researcher Hermin there to change class.
+
+
\ No newline at end of file
diff --git a/L2J_Mobius_Essence_6.2_Vanguard/dist/game/data/scripts/ai/others/AdditionalServicesAdvisor/34152-no_coupon.htm b/L2J_Mobius_Essence_6.2_Vanguard/dist/game/data/scripts/ai/others/AdditionalServicesAdvisor/34152-no_coupon.htm
new file mode 100644
index 0000000000..3290459b4a
--- /dev/null
+++ b/L2J_Mobius_Essence_6.2_Vanguard/dist/game/data/scripts/ai/others/AdditionalServicesAdvisor/34152-no_coupon.htm
@@ -0,0 +1,6 @@
+Additional Services' Advisor Juni:
+You don't have a Class Change Coupon!
+It's necessary if you want to change your class. You can buy it in the Adena store section of the L-Coin Store.
+Tell me once you're ready. I'll send you to the Additional Services Lab. Talk to the Researcher Hermin there to change class.
+
+
\ No newline at end of file
diff --git a/L2J_Mobius_Essence_6.2_Vanguard/dist/game/data/scripts/ai/others/AdditionalServicesAdvisor/34152-no_inventory.htm b/L2J_Mobius_Essence_6.2_Vanguard/dist/game/data/scripts/ai/others/AdditionalServicesAdvisor/34152-no_inventory.htm
new file mode 100644
index 0000000000..c4aea134ad
--- /dev/null
+++ b/L2J_Mobius_Essence_6.2_Vanguard/dist/game/data/scripts/ai/others/AdditionalServicesAdvisor/34152-no_inventory.htm
@@ -0,0 +1,7 @@
+Additional Services' Advisor Juni:
+Please, check your inventory.
+To change class, in your inventory must be free space and weight.
+Keep unnecessary items in the warehouse, to free 50% weight and at least 30 slots.
+Tell me once you're ready. I'll send you to the Additional Services Lab. Talk to the Researcher Hermin there to change class.
+
+
\ No newline at end of file
diff --git a/L2J_Mobius_Essence_6.2_Vanguard/dist/game/data/scripts/ai/others/AdditionalServicesAdvisor/34152-unequip_items.htm b/L2J_Mobius_Essence_6.2_Vanguard/dist/game/data/scripts/ai/others/AdditionalServicesAdvisor/34152-unequip_items.htm
new file mode 100644
index 0000000000..3c4b9ab55d
--- /dev/null
+++ b/L2J_Mobius_Essence_6.2_Vanguard/dist/game/data/scripts/ai/others/AdditionalServicesAdvisor/34152-unequip_items.htm
@@ -0,0 +1,6 @@
+Additional Services' Advisor Juni:
+It looks like you have an item equipped!
+To change class, you need to unequip all items.
+Tell me once you're ready. I'll send you to the Additional Services Lab. Talk to the Researcher Hermin there to change class.
+
+
\ No newline at end of file
diff --git a/L2J_Mobius_Essence_6.2_Vanguard/dist/game/data/scripts/ai/others/AdditionalServicesAdvisor/34152.htm b/L2J_Mobius_Essence_6.2_Vanguard/dist/game/data/scripts/ai/others/AdditionalServicesAdvisor/34152.htm
new file mode 100644
index 0000000000..d794126044
--- /dev/null
+++ b/L2J_Mobius_Essence_6.2_Vanguard/dist/game/data/scripts/ai/others/AdditionalServicesAdvisor/34152.htm
@@ -0,0 +1,6 @@
+Additional Services' Advisor Juni:
+If you need help with additional services, ask me anytime! I'll explain it all to you.
+The Additional Services Lab provides the class change service. Would you be interested in that?
+
+
+
\ No newline at end of file
diff --git a/L2J_Mobius_Essence_6.2_Vanguard/dist/game/data/scripts/ai/others/AdditionalServicesAdvisor/34153-1.htm b/L2J_Mobius_Essence_6.2_Vanguard/dist/game/data/scripts/ai/others/AdditionalServicesAdvisor/34153-1.htm
new file mode 100644
index 0000000000..889075bb1a
--- /dev/null
+++ b/L2J_Mobius_Essence_6.2_Vanguard/dist/game/data/scripts/ai/others/AdditionalServicesAdvisor/34153-1.htm
@@ -0,0 +1,8 @@
+Additional Services' Researcher Hermin:
+In order to change a class, several conditions must be met. Changing a class requires care and attention, so it is only done in this laboratory.
+First, you need Class Change Coupon, that's sold in the Adena store section of the L-Coin Store.
+Second, you have to unequip all items.
+Third, you need to free up your inventory You will need at least 30 slots.
+You should also know that only warriors can change classes, not holding the title of Hero.
+So, are you ready?
+
\ No newline at end of file
diff --git a/L2J_Mobius_Essence_6.2_Vanguard/dist/game/data/scripts/ai/others/AdditionalServicesAdvisor/34153-3rd_class.htm b/L2J_Mobius_Essence_6.2_Vanguard/dist/game/data/scripts/ai/others/AdditionalServicesAdvisor/34153-3rd_class.htm
new file mode 100644
index 0000000000..463776caf1
--- /dev/null
+++ b/L2J_Mobius_Essence_6.2_Vanguard/dist/game/data/scripts/ai/others/AdditionalServicesAdvisor/34153-3rd_class.htm
@@ -0,0 +1,6 @@
+Additional Services' Researcher Hermin:
+You can change class only after the 3rd class change.
+Come back once you have your 3rd class.
+Tell me once you're ready.
+
+
\ No newline at end of file
diff --git a/L2J_Mobius_Essence_6.2_Vanguard/dist/game/data/scripts/ai/others/AdditionalServicesAdvisor/34153-choose_gender.htm b/L2J_Mobius_Essence_6.2_Vanguard/dist/game/data/scripts/ai/others/AdditionalServicesAdvisor/34153-choose_gender.htm
new file mode 100644
index 0000000000..03f4b41d03
--- /dev/null
+++ b/L2J_Mobius_Essence_6.2_Vanguard/dist/game/data/scripts/ai/others/AdditionalServicesAdvisor/34153-choose_gender.htm
@@ -0,0 +1,7 @@
+Additional Services' Researcher Hermin:
+So you want to be %class_name%.
+Now choose the gender of your character. Close your eyes and imagine what you will become when you change classes.
+What gender will be your Duelist?
+
+
+
\ No newline at end of file
diff --git a/L2J_Mobius_Essence_6.2_Vanguard/dist/game/data/scripts/ai/others/AdditionalServicesAdvisor/34153-choose_gender_confirm.htm b/L2J_Mobius_Essence_6.2_Vanguard/dist/game/data/scripts/ai/others/AdditionalServicesAdvisor/34153-choose_gender_confirm.htm
new file mode 100644
index 0000000000..dcf2785571
--- /dev/null
+++ b/L2J_Mobius_Essence_6.2_Vanguard/dist/game/data/scripts/ai/others/AdditionalServicesAdvisor/34153-choose_gender_confirm.htm
@@ -0,0 +1,8 @@
+Additional Services' Researcher Hermin:
+Your choice of class - %class_name%.
+The character will be %sex%. Are you sure about your decision?
+After confirmations the character will get selected race and gender, as well as will change to the class of your choice.
+After agreeing, you will be briefly disconnected from the game. Are you confirming your choice?
+
+
+
\ No newline at end of file
diff --git a/L2J_Mobius_Essence_6.2_Vanguard/dist/game/data/scripts/ai/others/AdditionalServicesAdvisor/34153-choose_gender_unavailable.htm b/L2J_Mobius_Essence_6.2_Vanguard/dist/game/data/scripts/ai/others/AdditionalServicesAdvisor/34153-choose_gender_unavailable.htm
new file mode 100644
index 0000000000..7c38e0d9e7
--- /dev/null
+++ b/L2J_Mobius_Essence_6.2_Vanguard/dist/game/data/scripts/ai/others/AdditionalServicesAdvisor/34153-choose_gender_unavailable.htm
@@ -0,0 +1,6 @@
+Additional Services' Researcher Hermin:
+So you want to be %class_name%. Now you have to choose the gender of the character. Unfortunately, gender selection is not available for the %class_name%.
+ %class_name% can only be men. Now close your eyes and concentrate.
+ Imagine what it would be like to be %class_name%?
+
+
\ No newline at end of file
diff --git a/L2J_Mobius_Essence_6.2_Vanguard/dist/game/data/scripts/ai/others/AdditionalServicesAdvisor/34153-class_darkelf.htm b/L2J_Mobius_Essence_6.2_Vanguard/dist/game/data/scripts/ai/others/AdditionalServicesAdvisor/34153-class_darkelf.htm
new file mode 100644
index 0000000000..92ebab3f8b
--- /dev/null
+++ b/L2J_Mobius_Essence_6.2_Vanguard/dist/game/data/scripts/ai/others/AdditionalServicesAdvisor/34153-class_darkelf.htm
@@ -0,0 +1,11 @@
+Additional Services' Researcher Hermin:
+Aha, the Dark Elf! So you want to be a Dark Elf. Now choose... class for your character.
+
+
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/L2J_Mobius_Essence_6.2_Vanguard/dist/game/data/scripts/ai/others/AdditionalServicesAdvisor/34153-class_dwarf.htm b/L2J_Mobius_Essence_6.2_Vanguard/dist/game/data/scripts/ai/others/AdditionalServicesAdvisor/34153-class_dwarf.htm
new file mode 100644
index 0000000000..6385e1e8b9
--- /dev/null
+++ b/L2J_Mobius_Essence_6.2_Vanguard/dist/game/data/scripts/ai/others/AdditionalServicesAdvisor/34153-class_dwarf.htm
@@ -0,0 +1,5 @@
+Additional Services' Researcher Hermin:
+Aha, Dwarf! So you want to be a Dwarf. Now choose... class for your character.
+
+
+
\ No newline at end of file
diff --git a/L2J_Mobius_Essence_6.2_Vanguard/dist/game/data/scripts/ai/others/AdditionalServicesAdvisor/34153-class_elf.htm b/L2J_Mobius_Essence_6.2_Vanguard/dist/game/data/scripts/ai/others/AdditionalServicesAdvisor/34153-class_elf.htm
new file mode 100644
index 0000000000..f6d322da73
--- /dev/null
+++ b/L2J_Mobius_Essence_6.2_Vanguard/dist/game/data/scripts/ai/others/AdditionalServicesAdvisor/34153-class_elf.htm
@@ -0,0 +1,11 @@
+Additional Services' Researcher Hermin:
+Aha, Elf! So you want to be an Elf. Now choose. class for your character.
+
+
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/L2J_Mobius_Essence_6.2_Vanguard/dist/game/data/scripts/ai/others/AdditionalServicesAdvisor/34153-class_human.htm b/L2J_Mobius_Essence_6.2_Vanguard/dist/game/data/scripts/ai/others/AdditionalServicesAdvisor/34153-class_human.htm
new file mode 100644
index 0000000000..1560c9c2e9
--- /dev/null
+++ b/L2J_Mobius_Essence_6.2_Vanguard/dist/game/data/scripts/ai/others/AdditionalServicesAdvisor/34153-class_human.htm
@@ -0,0 +1,15 @@
+Additional Services' Researcher Hermin:
+Aha, a Man! So you want to be Human. Now choose class for your character.
+
+
+
+
+
+
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/L2J_Mobius_Essence_6.2_Vanguard/dist/game/data/scripts/ai/others/AdditionalServicesAdvisor/34153-class_kamael.htm b/L2J_Mobius_Essence_6.2_Vanguard/dist/game/data/scripts/ai/others/AdditionalServicesAdvisor/34153-class_kamael.htm
new file mode 100644
index 0000000000..f66211104d
--- /dev/null
+++ b/L2J_Mobius_Essence_6.2_Vanguard/dist/game/data/scripts/ai/others/AdditionalServicesAdvisor/34153-class_kamael.htm
@@ -0,0 +1,6 @@
+Additional Services' Researcher Hermin:
+Aha, Kamael! So you want to be Kamael! Now choose... class for your character.
+
+
+
+
\ No newline at end of file
diff --git a/L2J_Mobius_Essence_6.2_Vanguard/dist/game/data/scripts/ai/others/AdditionalServicesAdvisor/34153-class_orc.htm b/L2J_Mobius_Essence_6.2_Vanguard/dist/game/data/scripts/ai/others/AdditionalServicesAdvisor/34153-class_orc.htm
new file mode 100644
index 0000000000..384c5f58ce
--- /dev/null
+++ b/L2J_Mobius_Essence_6.2_Vanguard/dist/game/data/scripts/ai/others/AdditionalServicesAdvisor/34153-class_orc.htm
@@ -0,0 +1,8 @@
+Additional Services' Researcher Hermin:
+Aha, Orc! So you want to be an Orc. Now choose class for your character.
+
+
+
+
+
+
\ No newline at end of file
diff --git a/L2J_Mobius_Essence_6.2_Vanguard/dist/game/data/scripts/ai/others/AdditionalServicesAdvisor/34153-class_sylph.htm b/L2J_Mobius_Essence_6.2_Vanguard/dist/game/data/scripts/ai/others/AdditionalServicesAdvisor/34153-class_sylph.htm
new file mode 100644
index 0000000000..7ad6938192
--- /dev/null
+++ b/L2J_Mobius_Essence_6.2_Vanguard/dist/game/data/scripts/ai/others/AdditionalServicesAdvisor/34153-class_sylph.htm
@@ -0,0 +1,4 @@
+Additional Services' Researcher Hermin:
+Sylph, that's it! So you've chosen the Sylph race. Now select class for your character, available to the Sylph race.
+
+
\ No newline at end of file
diff --git a/L2J_Mobius_Essence_6.2_Vanguard/dist/game/data/scripts/ai/others/AdditionalServicesAdvisor/34153-no_coupon.htm b/L2J_Mobius_Essence_6.2_Vanguard/dist/game/data/scripts/ai/others/AdditionalServicesAdvisor/34153-no_coupon.htm
new file mode 100644
index 0000000000..2b7c617055
--- /dev/null
+++ b/L2J_Mobius_Essence_6.2_Vanguard/dist/game/data/scripts/ai/others/AdditionalServicesAdvisor/34153-no_coupon.htm
@@ -0,0 +1,6 @@
+Additional Services' Researcher Hermin:
+You don't have a Class Change Coupon!
+It's necessary if you want to change your class. You can buy it in the Adena store section of the L-Coin Store.
+Tell me once you're ready.
+
+
\ No newline at end of file
diff --git a/L2J_Mobius_Essence_6.2_Vanguard/dist/game/data/scripts/ai/others/AdditionalServicesAdvisor/34153-no_inventory.htm b/L2J_Mobius_Essence_6.2_Vanguard/dist/game/data/scripts/ai/others/AdditionalServicesAdvisor/34153-no_inventory.htm
new file mode 100644
index 0000000000..d5a96cd458
--- /dev/null
+++ b/L2J_Mobius_Essence_6.2_Vanguard/dist/game/data/scripts/ai/others/AdditionalServicesAdvisor/34153-no_inventory.htm
@@ -0,0 +1,7 @@
+Additional Services' Researcher Hermin:
+Please, check your inventory.
+To change class, in your inventory must be free space and weight.
+Keep unnecessary items in the warehouse, to free 50% weight and at least 30 slots.
+Tell me once you're ready.
+
+
\ No newline at end of file
diff --git a/L2J_Mobius_Essence_6.2_Vanguard/dist/game/data/scripts/ai/others/AdditionalServicesAdvisor/34153-race.htm b/L2J_Mobius_Essence_6.2_Vanguard/dist/game/data/scripts/ai/others/AdditionalServicesAdvisor/34153-race.htm
new file mode 100644
index 0000000000..db8994e061
--- /dev/null
+++ b/L2J_Mobius_Essence_6.2_Vanguard/dist/game/data/scripts/ai/others/AdditionalServicesAdvisor/34153-race.htm
@@ -0,0 +1,13 @@
+Additional Services' Researcher Hermin:
+If you are ready, let's begin the procedure for changing classes.
+Please choose carefully and calmly, weighing the pros and cons.
+Close your eyes and imagine what you will become when you change classes.
+What race will be a character?
+
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/L2J_Mobius_Essence_6.2_Vanguard/dist/game/data/scripts/ai/others/AdditionalServicesAdvisor/34153-unequip_items.htm b/L2J_Mobius_Essence_6.2_Vanguard/dist/game/data/scripts/ai/others/AdditionalServicesAdvisor/34153-unequip_items.htm
new file mode 100644
index 0000000000..4d3674e075
--- /dev/null
+++ b/L2J_Mobius_Essence_6.2_Vanguard/dist/game/data/scripts/ai/others/AdditionalServicesAdvisor/34153-unequip_items.htm
@@ -0,0 +1,4 @@
+Additional Services' Researcher Hermin:
+It looks like you have an item equipped!
+To change class, you need to unequip all items.
+
\ No newline at end of file
diff --git a/L2J_Mobius_Essence_6.2_Vanguard/dist/game/data/scripts/ai/others/AdditionalServicesAdvisor/34153.htm b/L2J_Mobius_Essence_6.2_Vanguard/dist/game/data/scripts/ai/others/AdditionalServicesAdvisor/34153.htm
new file mode 100644
index 0000000000..0b00f1eda2
--- /dev/null
+++ b/L2J_Mobius_Essence_6.2_Vanguard/dist/game/data/scripts/ai/others/AdditionalServicesAdvisor/34153.htm
@@ -0,0 +1,15 @@
+Additional Services' Researcher Hermin:
+Hello, my name is Hermine, and I am a researcher of value-added services..
+Now the class change service is available.When you change class, some items will be dropped. Remember.
+All previously learned skillsDistributed characteristics
+Bonuses for ranking3 vs 3 Olympiad points and rank
+All positive effects When you change classes you get Scrolls SP for each level.
+Note that all skills learned with the Spell Books and the books themselves will not return.
+When you change classes to the one you had before, all learned skills are retained, so SP Scrolls are not issued.
+The Dragon Slayer Shape, the White Guardian Transformation, the Extended Paint Potential, the Wyvern Transformation from 3 and 4 star skills, and skills gained through one-time quests will be issued as Sealed Spell Books.
+Changing classes is a very important step, so think about it carefully.
+Do you want to change classes?
+
+
+
+
\ No newline at end of file
diff --git a/L2J_Mobius_Essence_6.2_Vanguard/dist/game/data/scripts/ai/others/AdditionalServicesAdvisor/AdditionalServicesAdvisor.java b/L2J_Mobius_Essence_6.2_Vanguard/dist/game/data/scripts/ai/others/AdditionalServicesAdvisor/AdditionalServicesAdvisor.java
new file mode 100644
index 0000000000..da711c9752
--- /dev/null
+++ b/L2J_Mobius_Essence_6.2_Vanguard/dist/game/data/scripts/ai/others/AdditionalServicesAdvisor/AdditionalServicesAdvisor.java
@@ -0,0 +1,349 @@
+/*
+ * 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 ai.others.AdditionalServicesAdvisor;
+
+import java.sql.Connection;
+import java.sql.PreparedStatement;
+
+import org.l2jmobius.Config;
+import org.l2jmobius.commons.database.DatabaseFactory;
+import org.l2jmobius.gameserver.data.xml.ClassListData;
+import org.l2jmobius.gameserver.enums.CategoryType;
+import org.l2jmobius.gameserver.enums.SubclassInfoType;
+import org.l2jmobius.gameserver.instancemanager.InstanceManager;
+import org.l2jmobius.gameserver.model.Location;
+import org.l2jmobius.gameserver.model.actor.Npc;
+import org.l2jmobius.gameserver.model.actor.Player;
+import org.l2jmobius.gameserver.model.instancezone.Instance;
+import org.l2jmobius.gameserver.model.item.instance.Item;
+import org.l2jmobius.gameserver.model.olympiad.Hero;
+import org.l2jmobius.gameserver.model.skill.Skill;
+import org.l2jmobius.gameserver.network.serverpackets.ExSubjobInfo;
+import org.l2jmobius.gameserver.network.serverpackets.ExUserInfoInvenWeight;
+
+import ai.AbstractNpcAI;
+
+/**
+ * @author Mobius
+ */
+public class AdditionalServicesAdvisor extends AbstractNpcAI
+{
+ // NPCs
+ private static final int JUNI = 34152;
+ private static final int HERMIN = 34153;
+ // Items
+ private static final int CLASS_CHANGE_COUPON = 94828;
+ private static final int SP_SCROLL = 94829;
+ private static final int SPELLBOOK_HUMAN = 90038; // Spellbook: Mount Golden Lion
+ private static final int SPELLBOOK_ELF = 90039; // Spellbook: Mount Pegasus
+ private static final int SPELLBOOK_DELF = 90040; // Spellbook: Mount Saber Tooth Cougar
+ private static final int SPELLBOOK_ORC = 90042; // Spellbook: Mount Black Bear
+ private static final int SPELLBOOK_DWARF = 90041; // Spellbook: Mount Kukuru
+ private static final int SPELLBOOK_KAMAEL = 91946; // Spellbook: Mount Griffin
+ private static final int SPELLBOOK_DEATH_KNIGHT = 93383; // Spellbook: Mount Nightmare Steed
+ private static final int SPELLBOOK_SYLPH = 95367; // Spellbook: Mount Elemental Lyn Draco
+ // Misc
+ private static final Location TELEPORT_ADEN_LOCATION = new Location(146856, 25803, -2008);
+ private static final Location TELEPORT_GIRAN_LOCATION = new Location(83386, 148014, -3400);
+ private static final int INSTANCE_ID = 190;
+
+ private AdditionalServicesAdvisor()
+ {
+ addStartNpc(JUNI, HERMIN);
+ addFirstTalkId(JUNI, HERMIN);
+ addTalkId(JUNI, HERMIN);
+ }
+
+ @Override
+ public String onAdvEvent(String event, Npc npc, Player player)
+ {
+ String html = null;
+ switch (npc.getId())
+ {
+ case JUNI:
+ {
+ switch (event)
+ {
+ case "34152.htm":
+ case "34152-1.htm":
+ {
+ html = event;
+ break;
+ }
+ case "teleport_inside":
+ {
+ html = checkConditions(npc, player);
+ if (html == null)
+ {
+ final Instance instance = InstanceManager.getInstance().createInstance(INSTANCE_ID, player);
+ player.teleToLocation(instance.getEnterLocation(), instance);
+ }
+ break;
+ }
+ }
+ break;
+ }
+ case HERMIN:
+ {
+ switch (event)
+ {
+ case "34153.htm":
+ case "34153-1.htm":
+ case "34153-class_darkelf.htm":
+ case "34153-class_dwarf.htm":
+ case "34153-class_elf.htm":
+ case "34153-class_human.htm":
+ case "34153-class_kamael.htm":
+ case "34153-class_orc.htm":
+ case "34153-class_sylph.htm":
+ case "34153-race.htm":
+ {
+ html = event;
+ break;
+ }
+ case "teleport_aden":
+ {
+ player.teleToLocation(TELEPORT_ADEN_LOCATION, null);
+ break;
+ }
+ case "teleport_giran":
+ {
+ player.teleToLocation(TELEPORT_GIRAN_LOCATION, null);
+ break;
+ }
+ }
+ if (event.startsWith("choose_class"))
+ {
+ final int classId = Integer.parseInt(event.split(" ")[1]);
+ if (classId > 195)
+ {
+ html = getHtm(player, "34153-choose_gender_unavailable.htm");
+ }
+ else
+ {
+ html = getHtm(player, "34153-choose_gender.htm");
+ }
+ html = html.replace("%class_id%", String.valueOf(classId));
+ html = html.replace("%class_name%", ClassListData.getInstance().getClass(classId).getClassName());
+ return html;
+ }
+ else if (event.startsWith("choose_gender"))
+ {
+ final String[] split = event.split(" ");
+ final int classId = Integer.parseInt(split[1]);
+ final boolean female = split[2].equals("female");
+ if (female && (classId > 195))
+ {
+ return null;
+ }
+
+ html = getHtm(player, "34153-choose_gender_confirm.htm");
+ html = html.replace("%class_id%", String.valueOf(classId));
+ html = html.replace("%class_name%", ClassListData.getInstance().getClass(classId).getClassName());
+ html = html.replace("%sex%", female ? "female" : "male");
+ }
+ else if (event.startsWith("choose_gender_confirm"))
+ {
+ final String[] split = event.split(" ");
+ final int classId = Integer.parseInt(split[1]);
+ final boolean female = split[2].equals("female");
+ if (female && (classId > 195))
+ {
+ break;
+ }
+
+ html = getHtm(player, "34153-choose_gender_unavailable.htm");
+ html = html.replace("%class_id%", String.valueOf(classId));
+ html = html.replace("%class_name%", ClassListData.getInstance().getClass(classId).getClassName());
+ html = html.replace("%sex%", female ? "female" : "male");
+ }
+ else if (event.startsWith("confirm_class"))
+ {
+ html = checkConditions(npc, player);
+ if (html != null)
+ {
+ break;
+ }
+
+ final String[] split = event.split(" ");
+ final int classId = Integer.parseInt(split[1]);
+ final boolean female = split[2].equals("female");
+ if (female && (classId > 195))
+ {
+ break;
+ }
+
+ if (hasQuestItems(player, CLASS_CHANGE_COUPON))
+ {
+ takeItems(player, CLASS_CHANGE_COUPON, 1);
+
+ for (Skill skill : player.getAllSkills())
+ {
+ player.removeSkill(skill);
+ }
+ player.setVitalityPoints(0, true);
+ player.setExpBeforeDeath(0);
+
+ if (female)
+ {
+ player.getAppearance().setFemale();
+ }
+ else
+ {
+ player.getAppearance().setMale();
+ }
+ player.setClassId(classId);
+ player.setBaseClass(player.getActiveClass());
+
+ giveItems(player, SP_SCROLL, 20);
+ if (player.isInCategory(CategoryType.FOURTH_CLASS_GROUP))
+ {
+ player.getVariables().set("3rdClassMountRewarded", true);
+ if (player.isDeathKnight())
+ {
+ giveItems(player, SPELLBOOK_DEATH_KNIGHT, 1);
+ }
+ else
+ {
+ switch (player.getRace())
+ {
+ case ELF:
+ {
+ giveItems(player, SPELLBOOK_ELF, 1);
+ break;
+ }
+ case DARK_ELF:
+ {
+ giveItems(player, SPELLBOOK_DELF, 1);
+ break;
+ }
+ case ORC:
+ {
+ if (!player.isVanguard())
+ {
+ giveItems(player, SPELLBOOK_ORC, 1);
+ }
+ break;
+ }
+ case DWARF:
+ {
+ giveItems(player, SPELLBOOK_DWARF, 1);
+ break;
+ }
+ case KAMAEL:
+ {
+ giveItems(player, SPELLBOOK_KAMAEL, 1);
+ break;
+ }
+ case HUMAN:
+ {
+ giveItems(player, SPELLBOOK_HUMAN, 1);
+ break;
+ }
+ case SYLPH:
+ {
+ giveItems(player, SPELLBOOK_SYLPH, 1);
+ break;
+ }
+ }
+ }
+ }
+
+ player.getServitorsAndPets().forEach(s -> s.unSummon(player));
+ player.getEffectList().stopAllEffects(true);
+ player.getInventory().getItems().forEach(item ->
+ {
+ if (item.isEquipped())
+ {
+ player.getInventory().unEquipItemInSlot(item.getLocationSlot());
+ }
+ });
+
+ // Appearance after class change.
+ player.getAppearance().setHairStyle(0);
+ player.getAppearance().setHairColor(0);
+ player.getAppearance().setFace(0);
+
+ // Set new classId and reset olympiad points.
+ try (Connection con = DatabaseFactory.getConnection();
+ PreparedStatement ps = con.prepareStatement("UPDATE olympiad_nobles SET olympiad_points=?, class_id=? WHERE charId='" + player.getObjectId() + "'"))
+ {
+ ps.setInt(1, Config.ALT_OLY_START_POINTS);
+ ps.setInt(2, classId);
+ ps.executeUpdate();
+ }
+ catch (Exception e)
+ {
+ LOGGER.warning(this.getClass().getSimpleName() + ": Set new classId and reset olympiad points: " + e.getMessage());
+ }
+
+ player.store(false);
+ player.broadcastUserInfo();
+ player.sendSkillList();
+ player.sendPacket(new ExSubjobInfo(player, SubclassInfoType.CLASS_CHANGED));
+ player.sendPacket(new ExUserInfoInvenWeight(player));
+ }
+ else
+ {
+ html = "34152-no_coupon.htm";
+ }
+ }
+ break;
+ }
+ }
+ return html;
+ }
+
+ @Override
+ public String onFirstTalk(Npc npc, Player player)
+ {
+ return npc.getId() + ".htm";
+ }
+
+ private String checkConditions(Npc npc, Player player)
+ {
+ if (!hasQuestItems(player, CLASS_CHANGE_COUPON))
+ {
+ return npc.getId() + "-no_coupon.htm";
+ }
+ for (Item item : player.getInventory().getItems())
+ {
+ if (item.isEquipped())
+ {
+ return npc.getId() + "-unequip_items.htm";
+ }
+ }
+ if (!player.isInventoryUnder80(false) || (player.getWeightPenalty() >= 3))
+ {
+ return npc.getId() + "-no_inventory.htm";
+ }
+ if (!player.isInCategory(CategoryType.FOURTH_CLASS_GROUP))
+ {
+ return npc.getId() + "-3rd_class.htm";
+ }
+ if (player.isInOlympiadMode() || player.isHero() || Hero.getInstance().isHero(player.getObjectId()) || Hero.getInstance().isUnclaimedHero(player.getObjectId()))
+ {
+ return npc.getId() + "-1.htm";
+ }
+ return null;
+ }
+
+ public static void main(String[] args)
+ {
+ new AdditionalServicesAdvisor();
+ }
+}
diff --git a/L2J_Mobius_Essence_6.2_Vanguard/dist/game/data/spawns/Aden/AdenSquareMerchants.xml b/L2J_Mobius_Essence_6.2_Vanguard/dist/game/data/spawns/Aden/AdenSquareMerchants.xml
index c699f98c10..1a502f52bf 100644
--- a/L2J_Mobius_Essence_6.2_Vanguard/dist/game/data/spawns/Aden/AdenSquareMerchants.xml
+++ b/L2J_Mobius_Essence_6.2_Vanguard/dist/game/data/spawns/Aden/AdenSquareMerchants.xml
@@ -2,6 +2,7 @@
+
diff --git a/L2J_Mobius_Essence_6.2_Vanguard/dist/game/data/spawns/Giran/GiranSquareMerchants.xml b/L2J_Mobius_Essence_6.2_Vanguard/dist/game/data/spawns/Giran/GiranSquareMerchants.xml
index f4daa8866e..3beb23d04b 100644
--- a/L2J_Mobius_Essence_6.2_Vanguard/dist/game/data/spawns/Giran/GiranSquareMerchants.xml
+++ b/L2J_Mobius_Essence_6.2_Vanguard/dist/game/data/spawns/Giran/GiranSquareMerchants.xml
@@ -8,6 +8,7 @@
+