diff --git a/docs/mychanges_ptbr.txt b/docs/mychanges_ptbr.txt
index 56831b2afe..7589dbdfe8 100644
--- a/docs/mychanges_ptbr.txt
+++ b/docs/mychanges_ptbr.txt
@@ -1453,4 +1453,33 @@ Refatorado packets que lidam com respostas a comandos de pets.
Corrigido drop data de Ultra Gray com item inexistente.
Corrigido quest de meteoritos mudando estado da quest mesmo quando jogador não recebe o item devido a inventário cheio.
Corrigido quest de Maker lv1 retirando mesos além da quantidade esperada, ao realizar ações da quest.
-Adicionado server flag que lida com utilização de features NPCs custom.
\ No newline at end of file
+Adicionado server flag que lida com utilização de features NPCs custom.
+
+11 Novembro 2018,
+Implementado questline para as skills Hypnotize e Time Leap.
+Corrigido um problema de deadlock envolvendo inventários e locks de status de jogadores.
+Corrigido detecção de spam de Flash Jump desconectando jogadores que tentam usá-lo em rampas.
+Corrigido mapa no 4o estágio de Tera Gate com footholds irregulares.
+
+12 - 14 Novembro 2018,
+Método de update de cupons dos jogadores agora atua de forma mais otimizada, evitando execuções desnecessárias.
+Corrigido update de mapas não atuando corretamente para jogadores de party.
+Revisado leitura de uso de skills e ataques de mobs, agora aplicando os limites para detecção de ataque/skill de uma forma mais correta.
+Corrigido caso onde registros de MaxHP e MaxMP de jogadores se tornariam inconsistentes após equipamento aumentar de nível.
+Corrigido mobs parando de ser spawnados em mapas de Dojo após diversos usos de MobSkill.
+Implementado suporte apropriado para mobs linkados. Registros de mobs base são propagados para seus links, para eventualmente ter informações sobrescritas.
+Corrigido MoveLife não lançando corretamente pacotes para outros jogadores em diversos cenários, diversas vezes tornando a jogabilidade inconstante no multiplayer.
+
+15 - 17 Novembro 2018,
+Corrigido /find não identificando canal do jogador-alvo corretamente.
+Corrigido lider de party sendo passado para outro membro no mapa ao mudar canais.
+Corrigido Echo of Hero não atuando em outros jogadores no mapa.
+Corrigido quest inicial de Mushroom Castle não levando jogadores à área diretamente.
+Corrigido comandos warp e goto não retirando jogadores corretamente de eventos/expedição ao mudar de mapas.
+Implementado script para questline de skill Aerial Strike.
+
+20 - 21 Novembro 2018,
+Corrigido limite do Cash Shop storage não atualizando corretamente quando jogador compra expansão de 8.
+Atualizado guild rank de jogadores ao resetar guildid dos mesmos, agora evitando jogadores com rank acima de 5 mesmo sem guild.
+Adicionado restrição no sistema de partilha de EXP. Jogadores que possuem uma diferença de nível com o last hitter satisfatoriamente grande não recebe este ganho.
+Modificado nome de skill Maple Hero destacados em quest e itens para Maple Warrior.
\ No newline at end of file
diff --git a/handbook/Use.txt b/handbook/Use.txt
index 36286ebc6a..4bb475df52 100644
--- a/handbook/Use.txt
+++ b/handbook/Use.txt
@@ -1181,7 +1181,7 @@
2280000 - Lava Bottle - A glass bottle that contains an actual lava, which is waiting to be spilled out. Drink this lava, and the lava will consume the body with fire, which will enable the drinker to master Fire Demon.
2280001 - Black Cloud Machine - A mechanical device that produces black clouds. Enables the character to acquire the Smokescreen skill using the clouds.
2280002 - Firm Hand - A stimulant packaged inside a bottle that resembles a clenched fist. Drinking the stimulant will allow the character to acquire The Will of a Warrior.
-2280003 - [Skill Book] Maple Hero - You can learn #cMaple Hero# with this book.rnJob : All 4th jobsrnCondition : #cMaple Hero# not acquired.
+2280003 - [Skill Book] Maple Warrior - You can learn #cMaple Warrior# with this book.rnJob : All 4th jobsrnCondition : #cMaple Warrior# not acquired.
2280004 - [Skill Book] Infinity - You can learn #Infinity# with this book.rnJob : 4th Advancement MagicianrnCondition : #cInfinity# not acquired
2280005 - [Skill Book] Dragon's Breath - You can learn #cDragon's Breath# with this book.wnJob : 4th Advancement BowmanrnCondition : #cDragon's Breath# not acquired
2280006 - [Skill Book] Taunt - You can learn #cTaunt# with this book.rnJob : 4th Advancement ThiefrnCondition : #cTaunt# not acquired
@@ -1287,7 +1287,7 @@
2290093 - [Mastery Book] Assassinate - This increases the master level of #cAssassinate# up to 30 with 50% of chance.rnClass : ShadowerrnCondition : Skill level above 15
2290094 - [Mastery Book] Smokescreen - This increases the master level of #cSmokescreen# up to 20 with 70% of chance.rnClass : ShadowerrnCondition : Skill level above 5
2290095 - [Mastery Book] Smokescreen - This increases the master level of #cSmokescreen# up to 30 with 50% of chance.rnClass : ShadowerrnCondition : Skill level above 15
-2290096 - [Mastery Book] Maple Hero 20 - This increases the master level of #cMaple Hero# up to 20 with 70% of chance.rnJob : All 4th Advancement JobsrnCondition : Skill level above 5
+2290096 - [Mastery Book] Maple Warrior 20 - This increases the master level of #cMaple Warrior# up to 20 with 70% of chance.rnJob : All 4th Advancement JobsrnCondition : Skill level above 5
2290097 - [Mastery Book] Dragon Strike - With a 70% success rate, it raises the Master Level of #cDragon Strike# to 20.nJob : BuccaneernRequirement : At least Level 5 in this skill
2290098 - [Mastery Book] Dragon Strike - With a 50% success rate, it raises the Master Level of #cDragon Strike# to 30.nJob : BuccaneernRequirement : At least Level 15 in this skill
2290099 - [Mastery Book] Energy Orb - With a 70% success rate, it raises the Master Level of #cEnergy Orb# to 20.nJob : BuccaneernRequirement : At least Level 5 in this skill
@@ -1316,7 +1316,7 @@
2290122 - [Mastery Book] Battleship Torpedo - With a 50% success rate, it raises the Master Level of #cBattleship Torpedo# to 30.nJob : CorsairnRequirement : At least Level 15 in this skill
2290123 - [Mastery Book] Hypnotize - With a 70% success rate, it raises the Master Level of #cHypnotize# to 20.nJob : CorsairnRequirement : At least Level 5 in this skill
2290124 - [Mastery Book] Bullseye - With a 70% success rate, it raises the Master Level of #cBullseye# to 20.nJob : CorsairnRequirement : At least Level 5 in this skill
-2290125 - [Mastery Book] Maple Hero 30 - This increases the master level of #cMaple Hero# up to 30 with 50% of chance.rnJob : All 4th Advancement JobsrnCondition : Skill level above 15
+2290125 - [Mastery Book] Maple Warrior 30 - This increases the master level of #cMaple Warrior# up to 30 with 50% of chance.rnJob : All 4th Advancement JobsrnCondition : Skill level above 15
2310000 - The Owl of Minerva - #cThe Owl of Minerva#, which represents wisdom, can be used to search for items sold at the Free Market. #cDisappears right after showing the results of the item search#.
2320000 - Teleport Rock - Remembers 5 maps of your choice. This rock will enable you to #cteleport to the map you remembered#. It can even allow you to #cmove to the map where a certain character is#, provided that the person is in the same channel at the same world.
2330000 - Bullet - A bullet made out of steel. A set contains numerous bullets and once they are used up, they'll need to be recharged.\nAttack + 10
diff --git a/scripts/event/4jaerial.js b/scripts/event/4jaerial.js
new file mode 100644
index 0000000000..cc86853be9
--- /dev/null
+++ b/scripts/event/4jaerial.js
@@ -0,0 +1,109 @@
+/*
+ This file is part of the HeavenMS MapleStory Server
+ Copyleft (L) 2016 - 2018 RonanLana
+
+ This program is free software: you can redistribute it and/or modify
+ it under the terms of the GNU Affero General Public License as
+ published by the Free Software Foundation version 3 as published by
+ the Free Software Foundation. You may not use, modify or distribute
+ this program under any other version of the GNU Affero General Public
+ License.
+
+ 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 Affero General Public License for more details.
+
+ You should have received a copy of the GNU Affero General Public License
+ along with this program. If not, see .
+*/
+/**
+ * @Author Ronan
+ * Event - Jonathan's Test Quest
+**/
+
+var entryMap = 912020000;
+var exitMap = 120000102;
+
+var minMapId = 912020000;
+var maxMapId = 912020000;
+
+var eventTime = 2; //2 minutes
+
+var lobbyRange = [0, 0];
+
+function setLobbyRange() {
+ return lobbyRange;
+}
+
+function init() {
+ em.setProperty("noEntry","false");
+}
+
+function setup(level, lobbyid) {
+ var eim = em.newInstance("4jaerial_" + lobbyid);
+ eim.setProperty("level", level);
+ eim.setProperty("boss", "0");
+ eim.setProperty("canLeave", "0");
+
+ eim.getInstanceMap(entryMap).resetPQ(level);
+ eim.getInstanceMap(entryMap).shuffleReactors();
+
+ respawnStages(eim);
+ eim.startEventTimer(eventTime * 60000);
+ return eim;
+}
+
+function afterSetup(eim) {}
+
+function respawnStages(eim) {}
+
+function playerEntry(eim, player) {
+ var map = eim.getMapInstance(entryMap);
+ player.changeMap(map, map.getPortal(0));
+}
+
+function playerUnregistered(eim, player) {}
+
+function playerExit(eim, player) {
+ eim.unregisterPlayer(player);
+ eim.dispose();
+ em.setProperty("noEntry","false");
+}
+
+function playerLeft(eim, player) {}
+
+function scheduledTimeout(eim) {
+ var player = eim.getPlayers().get(0);
+ playerExit(eim, player);
+ player.changeMap(exitMap);
+}
+
+function playerDisconnected(eim, player) {
+ playerExit(eim, player);
+}
+
+function changedMap(eim, chr, mapid) {
+ if(mapid < minMapId || mapid > maxMapId) playerExit(eim, chr);
+}
+
+function clearPQ(eim) {
+ eim.stopEventTimer();
+ eim.setEventCleared();
+}
+
+function monsterKilled(mob, eim) {}
+
+function leftParty(eim, player) {}
+
+function disbandParty(eim) {}
+
+function monsterValue(eim, mobId) {
+ return 1;
+}
+
+function allMonstersDead(eim) {}
+
+function cancelSchedule() {}
+
+function dispose() {}
diff --git a/scripts/event/AreaBossBamboo.js b/scripts/event/AreaBossBamboo.js
index ecf4f4ad9e..32ccf85bdb 100644
--- a/scripts/event/AreaBossBamboo.js
+++ b/scripts/event/AreaBossBamboo.js
@@ -23,7 +23,7 @@
-- Odin JavaScript --------------------------------------------------------------------------------
Bamboo Warrior Spawner
-- Edited by --------------------------------------------------------------------------------------
- Ronan (based on xQuasar's King Clang spawner)
+ Ronan - based on xQuasar's King Clang spawner
**/
function init() {
diff --git a/scripts/event/AreaBossCentipede.js b/scripts/event/AreaBossCentipede.js
index 548d992507..3a52fd76af 100644
--- a/scripts/event/AreaBossCentipede.js
+++ b/scripts/event/AreaBossCentipede.js
@@ -23,7 +23,7 @@
-- Odin JavaScript --------------------------------------------------------------------------------
Centipede Spawner
-- Edited by --------------------------------------------------------------------------------------
- Ronan (based on xQuasar's King Clang spawner)
+ Ronan - based on xQuasar's King Clang spawner
**/
function init() {
diff --git a/scripts/event/AreaBossDeo.js b/scripts/event/AreaBossDeo.js
index daf68115d9..da5bed77f5 100644
--- a/scripts/event/AreaBossDeo.js
+++ b/scripts/event/AreaBossDeo.js
@@ -23,7 +23,7 @@
-- Odin JavaScript --------------------------------------------------------------------------------
Deo Spawner
-- Edited by --------------------------------------------------------------------------------------
- ThreeStep (based on xQuasar's King Clang spawner)
+ ThreeStep - based on xQuasar's King Clang spawner
**/
function init() {
diff --git a/scripts/event/AreaBossDyle.js b/scripts/event/AreaBossDyle.js
index 192a9f6126..66b20592ee 100644
--- a/scripts/event/AreaBossDyle.js
+++ b/scripts/event/AreaBossDyle.js
@@ -23,7 +23,7 @@
-- Odin JavaScript --------------------------------------------------------------------------------
Dyle Spawner
-- Edited by --------------------------------------------------------------------------------------
- ThreeStep (based on xQuasar's King Clang spawner)
+ ThreeStep - based on xQuasar's King Clang spawner
**/
importPackage(Packages.server.life);
diff --git a/scripts/event/AreaBossEliza1.js b/scripts/event/AreaBossEliza1.js
index 4f5882064e..f969216612 100644
--- a/scripts/event/AreaBossEliza1.js
+++ b/scripts/event/AreaBossEliza1.js
@@ -23,7 +23,7 @@
-- Odin JavaScript --------------------------------------------------------------------------------
Eliza1 Spawner
-- Edited by --------------------------------------------------------------------------------------
- ThreeStep (based on xQuasar's King Clang spawner)
+ ThreeStep - based on xQuasar's King Clang spawner
**/
diff --git a/scripts/event/AreaBossFaust1.js b/scripts/event/AreaBossFaust1.js
index 70c9e72410..a5cd6265b7 100644
--- a/scripts/event/AreaBossFaust1.js
+++ b/scripts/event/AreaBossFaust1.js
@@ -23,7 +23,7 @@
-- Odin JavaScript --------------------------------------------------------------------------------
Faust1 Spawner
-- Edited by --------------------------------------------------------------------------------------
- ThreeStep (based on xQuasar's King Clang spawner)
+ ThreeStep - based on xQuasar's King Clang spawner
**/
diff --git a/scripts/event/AreaBossFaust2.js b/scripts/event/AreaBossFaust2.js
index 875f95d6a7..0c2a24ebbf 100644
--- a/scripts/event/AreaBossFaust2.js
+++ b/scripts/event/AreaBossFaust2.js
@@ -23,7 +23,7 @@
-- Odin JavaScript --------------------------------------------------------------------------------
Faust2 Spawner
-- Edited by --------------------------------------------------------------------------------------
- ThreeStep (based on xQuasar's King Clang spawner)
+ ThreeStep - based on xQuasar's King Clang spawner
**/
diff --git a/scripts/event/AreaBossKimera.js b/scripts/event/AreaBossKimera.js
index 8becb6c69c..25b7502deb 100644
--- a/scripts/event/AreaBossKimera.js
+++ b/scripts/event/AreaBossKimera.js
@@ -23,7 +23,7 @@
-- Odin JavaScript --------------------------------------------------------------------------------
Chimera/Kimera Spawner
-- Edited by --------------------------------------------------------------------------------------
- ThreeStep (based on xQuasar's King Clang spawner)
+ ThreeStep - based on xQuasar's King Clang spawner
**/
diff --git a/scripts/event/AreaBossKingClang.js b/scripts/event/AreaBossKingClang.js
index 342d9978e9..96f3445d28 100644
--- a/scripts/event/AreaBossKingClang.js
+++ b/scripts/event/AreaBossKingClang.js
@@ -23,7 +23,7 @@
-- Odin JavaScript --------------------------------------------------------------------------------
King Clang Spawner
-- Edited by --------------------------------------------------------------------------------------
- ThreeStep (based on xQuasar's King Clang spawner)
+ ThreeStep - based on xQuasar's King Clang spawner
**/
diff --git a/scripts/event/AreaBossKingSageCat.js b/scripts/event/AreaBossKingSageCat.js
index 45957d19a7..ec9ebbcde7 100644
--- a/scripts/event/AreaBossKingSageCat.js
+++ b/scripts/event/AreaBossKingSageCat.js
@@ -23,7 +23,7 @@
-- Odin JavaScript --------------------------------------------------------------------------------
King Sage Cat Spawner
-- Edited by --------------------------------------------------------------------------------------
- ThreeStep (based on xQuasar's King Clang spawner)
+ ThreeStep - based on xQuasar's King Clang spawner
**/
diff --git a/scripts/event/AreaBossLeviathan.js b/scripts/event/AreaBossLeviathan.js
index ce1a0f907d..f229804c2e 100644
--- a/scripts/event/AreaBossLeviathan.js
+++ b/scripts/event/AreaBossLeviathan.js
@@ -23,7 +23,7 @@
-- Odin JavaScript --------------------------------------------------------------------------------
Leviathan Spawner
-- Edited by --------------------------------------------------------------------------------------
- ThreeStep (based on xQuasar's King Clang spawner)
+ ThreeStep - based on xQuasar's King Clang spawner
**/
diff --git a/scripts/event/AreaBossMano.js b/scripts/event/AreaBossMano.js
index 1873b5f66f..39a3a4e23c 100644
--- a/scripts/event/AreaBossMano.js
+++ b/scripts/event/AreaBossMano.js
@@ -23,7 +23,7 @@
-- Odin JavaScript --------------------------------------------------------------------------------
Mano Spawner
-- Edited by --------------------------------------------------------------------------------------
- ThreeStep (based on xQuasar's King Clang spawner)
+ ThreeStep - based on xQuasar's King Clang spawner
**/
importPackage(Packages.client);
diff --git a/scripts/event/AreaBossNineTailedFox.js b/scripts/event/AreaBossNineTailedFox.js
index c5357863e4..941a160c4e 100644
--- a/scripts/event/AreaBossNineTailedFox.js
+++ b/scripts/event/AreaBossNineTailedFox.js
@@ -23,7 +23,7 @@
-- Odin JavaScript --------------------------------------------------------------------------------
Nine Tailed Fox (Old Fox) Spawner
-- Edited by --------------------------------------------------------------------------------------
- ThreeStep (based on xQuasar's King Clang spawner)
+ ThreeStep - based on xQuasar's King Clang spawner
**/
diff --git a/scripts/event/AreaBossSeruf.js b/scripts/event/AreaBossSeruf.js
index e20f575aa1..16a1ad4231 100644
--- a/scripts/event/AreaBossSeruf.js
+++ b/scripts/event/AreaBossSeruf.js
@@ -24,7 +24,7 @@
-- Odin JavaScript --------------------------------------------------------------------------------
Seruf Spawner
-- Edited by --------------------------------------------------------------------------------------
- ThreeStep (based on xQuasar's King Clang spawner)
+ ThreeStep - based on xQuasar's King Clang spawner
**/
diff --git a/scripts/event/AreaBossSnackBar.js b/scripts/event/AreaBossSnackBar.js
index fbb00f883c..5c51b4a183 100644
--- a/scripts/event/AreaBossSnackBar.js
+++ b/scripts/event/AreaBossSnackBar.js
@@ -23,7 +23,7 @@
-- Odin JavaScript --------------------------------------------------------------------------------
Snack Bar Spawner
-- Edited by --------------------------------------------------------------------------------------
- Ronan (based on xQuasar's King Clang spawner)
+ Ronan - based on xQuasar's King Clang spawner
**/
function init() {
diff --git a/scripts/event/AreaBossStumpy.js b/scripts/event/AreaBossStumpy.js
index 409f0c5d1b..f75494e593 100644
--- a/scripts/event/AreaBossStumpy.js
+++ b/scripts/event/AreaBossStumpy.js
@@ -23,7 +23,7 @@
-- Odin JavaScript --------------------------------------------------------------------------------
Stumpy Spawner
-- Edited by --------------------------------------------------------------------------------------
- ThreeStep (based on xQuasar's King Clang spawner)
+ ThreeStep - based on xQuasar's King Clang spawner
**/
diff --git a/scripts/event/AreaBossTaeRoon.js b/scripts/event/AreaBossTaeRoon.js
index 34a2201d60..9840ae1171 100644
--- a/scripts/event/AreaBossTaeRoon.js
+++ b/scripts/event/AreaBossTaeRoon.js
@@ -23,7 +23,7 @@
-- Odin JavaScript --------------------------------------------------------------------------------
Tae Roon Spawner
-- Edited by --------------------------------------------------------------------------------------
- ThreeStep (based on xQuasar's King Clang spawner)
+ ThreeStep - based on xQuasar's King Clang spawner
**/
diff --git a/scripts/event/AreaBossTimer1.js b/scripts/event/AreaBossTimer1.js
index 7c3670d584..c02e76dcec 100644
--- a/scripts/event/AreaBossTimer1.js
+++ b/scripts/event/AreaBossTimer1.js
@@ -23,7 +23,7 @@
-- Odin JavaScript --------------------------------------------------------------------------------
Timer1 Spawner
-- Edited by --------------------------------------------------------------------------------------
- ThreeStep (based on xQuasar's King Clang spawner)
+ ThreeStep - based on xQuasar's King Clang spawner
**/
importPackage(Packages.client);
diff --git a/scripts/event/AreaBossTimer2.js b/scripts/event/AreaBossTimer2.js
index 9a5c851a02..3e50299e3c 100644
--- a/scripts/event/AreaBossTimer2.js
+++ b/scripts/event/AreaBossTimer2.js
@@ -23,7 +23,7 @@
-- Odin JavaScript --------------------------------------------------------------------------------
Timer2 Spawner
-- Edited by --------------------------------------------------------------------------------------
- ThreeStep (based on xQuasar's King Clang spawner)
+ ThreeStep - based on xQuasar's King Clang spawner
**/
diff --git a/scripts/event/AreaBossTimer3.js b/scripts/event/AreaBossTimer3.js
index 79788c6129..7411e8edf0 100644
--- a/scripts/event/AreaBossTimer3.js
+++ b/scripts/event/AreaBossTimer3.js
@@ -24,7 +24,7 @@
-- Odin JavaScript --------------------------------------------------------------------------------
Timer3 Spawner
-- Edited by --------------------------------------------------------------------------------------
- ThreeStep (based on xQuasar's King Clang spawner)
+ ThreeStep - based on xQuasar's King Clang spawner
**/
diff --git a/scripts/event/AreaBossZeno.js b/scripts/event/AreaBossZeno.js
index 267691fd00..70d475266c 100644
--- a/scripts/event/AreaBossZeno.js
+++ b/scripts/event/AreaBossZeno.js
@@ -24,7 +24,7 @@
-- Odin JavaScript --------------------------------------------------------------------------------
Zeno Spawner
-- Edited by --------------------------------------------------------------------------------------
- ThreeStep (based on xQuasar's King Clang spawner)
+ ThreeStep - based on xQuasar's King Clang spawner
**/
function init() {
scheduleNew();
diff --git a/scripts/event/Cabin.js b/scripts/event/Cabin.js
index 68d8cd4416..e6f5d8a2a1 100644
--- a/scripts/event/Cabin.js
+++ b/scripts/event/Cabin.js
@@ -29,8 +29,8 @@
1.5 - Fix for infinity looping [Information]
1.4 - Ship/boat is now showed
- Removed temp message[Information]
- - Credit to Snow/superraz777 for old source
- - Credit to Titan/Kool for the ship/boat packet
+ - Credits to Snow, superraz777 for old source
+ - Credits to Titan, Kool for the ship/boat packet
1.3 - Removing some function since is not needed [Information]
- Remove register player menthod [Information]
1.2 - It should be 2 ships not 1 [Information]
diff --git a/scripts/event/DelliBattle.js b/scripts/event/DelliBattle.js
new file mode 100644
index 0000000000..ef3869e124
--- /dev/null
+++ b/scripts/event/DelliBattle.js
@@ -0,0 +1,209 @@
+/*
+ This file is part of the HeavenMS MapleStory Server
+ Copyleft (L) 2016 - 2018 RonanLana
+
+ This program is free software: you can redistribute it and/or modify
+ it under the terms of the GNU Affero General Public License as
+ published by the Free Software Foundation version 3 as published by
+ the Free Software Foundation. You may not use, modify or distribute
+ this program under any other version of the GNU Affero General Public
+ License.
+
+ 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 Affero General Public License for more details.
+
+ You should have received a copy of the GNU Affero General Public License
+ along with this program. If not, see .
+*/
+
+/**
+ * @author: Ronan
+ * @event: Delli Battle
+*/
+
+var isPq = true;
+var minPlayers = 1, maxPlayers = 2;
+var minLevel = 120, maxLevel = 255;
+var entryMap = 925010300;
+var exitMap = 925010200;
+var recruitMap = 925010200;
+
+var minMapId = 925010300;
+var maxMapId = 925010300;
+
+var eventTime = 6; // 6 minutes
+
+var lobbyRange = [0, 0];
+
+function init() {
+ setEventRequirements();
+}
+
+function setLobbyRange() {
+ return lobbyRange;
+}
+
+function setEventRequirements() {
+ var reqStr = "";
+
+ reqStr += "\r\n Number of players: ";
+ if(maxPlayers - minPlayers >= 1) reqStr += minPlayers + " ~ " + maxPlayers;
+ else reqStr += minPlayers;
+
+ reqStr += "\r\n Level range: ";
+ if(maxLevel - minLevel >= 1) reqStr += minLevel + " ~ " + maxLevel;
+ else reqStr += minLevel;
+
+ reqStr += "\r\n Time limit: ";
+ reqStr += eventTime + " minutes";
+
+ em.setProperty("party", reqStr);
+}
+
+function getEligibleParty(party) { //selects, from the given party, the team that is allowed to attempt this event
+ var eligible = [];
+ var hasLeader = false;
+
+ if(party.size() > 0) {
+ var partyList = party.toArray();
+
+ for(var i = 0; i < party.size(); i++) {
+ var ch = partyList[i];
+
+ if(ch.getMapId() == recruitMap && ch.getLevel() >= minLevel && ch.getLevel() <= maxLevel) {
+ if(ch.isLeader()) hasLeader = true;
+ eligible.push(ch);
+ }
+ }
+ }
+
+ if(!(hasLeader && eligible.length >= minPlayers && eligible.length <= maxPlayers)) eligible = [];
+ return eligible;
+}
+
+function setup(level, lobbyid) {
+ var eim = em.newInstance("Delli" + lobbyid);
+ eim.setProperty("level", level);
+
+ respawnStages(eim);
+ eim.startEventTimer(eventTime * 60000);
+
+ eim.getMapInstance(entryMap).toggleDrops();
+ return eim;
+}
+
+function afterSetup(eim) {}
+
+function respawnStages(eim) {
+ eim.getMapInstance(entryMap).instanceMapRespawn();
+ eim.schedule("respawnStages", 15 * 1000);
+}
+
+function playerEntry(eim, player) {
+ var map = eim.getMapInstance(entryMap);
+ player.changeMap(map, map.getPortal(0));
+}
+
+function scheduledTimeout(eim) {
+ eim.getMapInstance(entryMap).killAllMonstersNotFriendly();
+ eim.showClearEffect();
+ clearPQ(eim);
+}
+
+function playerUnregistered(eim, player) {}
+
+function playerExit(eim, player) {
+ eim.unregisterPlayer(player);
+ player.changeMap(exitMap, 0);
+}
+
+function playerLeft(eim, player) {
+ if(!eim.isEventCleared()) {
+ playerExit(eim, player);
+ }
+}
+
+function changedMap(eim, player, mapid) {
+ if (mapid < minMapId || mapid > maxMapId) {
+ if (eim.isEventTeamLackingNow(true, minPlayers, player)) {
+ eim.unregisterPlayer(player);
+ end(eim);
+ }
+ else
+ eim.unregisterPlayer(player);
+ }
+}
+
+function changedLeader(eim, leader) {
+ var mapid = leader.getMapId();
+ if (!eim.isEventCleared() && (mapid < minMapId || mapid > maxMapId)) {
+ end(eim);
+ }
+}
+
+function playerDead(eim, player) {}
+
+function playerRevive(eim, player) { // player presses ok on the death pop up.
+ if (eim.isEventTeamLackingNow(true, minPlayers, player)) {
+ eim.unregisterPlayer(player);
+ end(eim);
+ }
+ else
+ eim.unregisterPlayer(player);
+}
+
+function playerDisconnected(eim, player) {
+ if (eim.isEventTeamLackingNow(true, minPlayers, player)) {
+ eim.unregisterPlayer(player);
+ end(eim);
+ }
+ else
+ eim.unregisterPlayer(player);
+}
+
+function leftParty(eim, player) {
+ if (eim.isEventTeamLackingNow(false, minPlayers, player)) {
+ end(eim);
+ }
+ else
+ playerLeft(eim, player);
+}
+
+function disbandParty(eim) {
+ if (!eim.isEventCleared()) {
+ end(eim);
+ }
+}
+
+function monsterValue(eim, mobId) {
+ return 1;
+}
+
+function friendlyKilled(mob, eim) {
+ if (mob.getId() == 9300162) {
+ end(eim);
+ }
+}
+
+function end(eim) {
+ var party = eim.getPlayers();
+ for (var i = 0; i < party.size(); i++) {
+ playerExit(eim, party.get(i));
+ }
+ eim.dispose();
+}
+
+function clearPQ(eim) {
+ eim.stopEventTimer();
+ eim.setEventCleared();
+}
+
+function monsterKilled(mob, eim) {}
+
+function allMonstersDead(eim) {}
+
+function cancelSchedule() {}
+
+function dispose(eim) {}
diff --git a/scripts/npc/1072006.js b/scripts/npc/1072006.js
index 9f9f4b35a1..74a4c5e524 100644
--- a/scripts/npc/1072006.js
+++ b/scripts/npc/1072006.js
@@ -25,7 +25,7 @@
-- By ---------------------------------------------------------------------------------------------
Unknown
-- Version Info -----------------------------------------------------------------------------------
- 1.2 - Clean up by Moogra
+ 1.2 - Cleanup by Moogra
1.1 - Statement fix [Information]
1.0 - First Version by Unknown
---------------------------------------------------------------------------------------------------
diff --git a/scripts/npc/1090000.js b/scripts/npc/1090000.js
index dfc900e45a..8595f29c3f 100644
--- a/scripts/npc/1090000.js
+++ b/scripts/npc/1090000.js
@@ -48,7 +48,7 @@ function start() {
cm.teachSkill(5121003, 0, 10, -1);
cm.forceCompleteQuest(6330);
- cm.sendNext("Congratulations. You have managed to pass my test. I'll teach you a new skill called \"Super Transformation\".\r\n\r\n #s5221003# #b#q5221003##k");
+ cm.sendNext("Congratulations. You have managed to pass my test. I'll teach you a new skill called \"Super Transformation\".\r\n\r\n #s5121003# #b#q5121003##k");
}
} else if (cm.isQuestStarted(6370)) {
if (cm.getEventInstance() != null) {
diff --git a/scripts/npc/1092008.js b/scripts/npc/1092008.js
index 0bdbb4222d..d845f6be0a 100644
--- a/scripts/npc/1092008.js
+++ b/scripts/npc/1092008.js
@@ -38,8 +38,15 @@ function action(mode, type, selection) {
else
status--;
- if(status == 0) {
- cm.sendOk("Hey, do you have any business with me?");
+ if (status == 0) {
+ if (!cm.isQuestStarted(6410)) {
+ cm.sendOk("Hey, do you have any business with me?");
+ cm.dispose();
+ } else {
+ cm.sendYesNo("Let's go save #r#p2095000##k?");
+ }
+ } else if (status == 1) {
+ cm.warp(925010000, 0);
cm.dispose();
}
}
diff --git a/scripts/npc/1092010.js b/scripts/npc/1092010.js
index df6d2a2875..9773ef4a13 100644
--- a/scripts/npc/1092010.js
+++ b/scripts/npc/1092010.js
@@ -23,7 +23,9 @@
-- JavaScript -----------------
Jack - Nautilus' Port
-- Created By --
-Cody/Cyndicate, totally recoded by Moogra
+ Cody (Cyndicate)
+-- totally recoded By --
+ Moogra
-- Function --
No specific function, useless text.
-- GMS LIKE --
diff --git a/scripts/npc/1092019.js b/scripts/npc/1092019.js
index 40083e6cf1..f0152d9b94 100644
--- a/scripts/npc/1092019.js
+++ b/scripts/npc/1092019.js
@@ -4,6 +4,8 @@
Matthias Butz
Jan Christian Meyer
+ Copyleft (L) 2016 - 2018 RonanLana (HeavenMS)
+
This program is free software: you can redistribute it and/or modify
it under the terms of the GNU Affero General Public License version 3
as published by the Free Software Foundation. You may not use, modify
@@ -18,19 +20,97 @@
You should have received a copy of the GNU Affero General Public License
along with this program. If not, see .
*/
-
/*
-- JavaScript -----------------
Lord Jonathan - Nautilus' Port
-- Created By --
-Cody/Cyndicate
--- Totally Recreated by Moogra--
+ Cody (Cyndicate)
+-- Totally Recreated by --
+ Moogra
+-- And Quest Script by --
+ Ronan
-- Function --
No specific function, useless text.
-- GMS LIKE --
*/
+
+var status;
+
+var seagullProgress;
+var seagullIdx = -1;
+var seagullQuestion = ["One day, I went to the ocean and caught 62 Octopi for dinner. But then some kid came by and gave me 10 Octopi as a gift! How many Octopi do I have then, in total?"];
+var seagullAnswer = ["72"];
+
function start() {
- cm.sendOk("Who are you talking to me? If you're just bored, go bother somebody else.");
- cm.dispose();
+ status = -1;
+ action(1, 0, 0);
}
+function action(mode, type, selection) {
+ if (mode == -1) {
+ cm.dispose();
+ } else {
+ if (mode == 0 && type > 0) {
+ cm.dispose();
+ return;
+ }
+ if (mode == 1)
+ status++;
+ else
+ status--;
+
+ if (status == 0) { // missing script for skill test found thanks to Lost(tm)
+ if (!cm.isQuestStarted(6400)) {
+ cm.sendOk("Who are you talking to me? If you're just bored, go bother somebody else.");
+ cm.dispose();
+ } else {
+ seagullProgress = cm.getQuestProgress(6400, 0);
+
+ if (seagullProgress == 0) {
+ seagullIdx = Math.floor(Math.random() * seagullQuestion.length);
+
+ // string visibility thanks to ProXAIMeRx & Glvelturall
+ cm.sendNext("Ok then! I'll give you the first question now! You better be ready because this one's a hard one. Even the seagulls here think this one's pretty tough. It's a pretty difficult problem.");
+ } else if (seagullProgress == 1) {
+ cm.sendNext("Now~ Let's go onto the next question. This one is really difficult. I am going to have Bart help me on this one. You know Bart, right?");
+ } else {
+ cm.sendNext("Ohhhh! Now that was impressive! I considered my test quite difficult, and for you to pass that... you are indeed an integral member of the Pirate family, and a friend of seagulls. We are now bonded by the mutual friendship that will last a lifetime! And, most of all, friends are there to help you out when you are in dire straits. If you are in a state of emergency, call us seagulls.");
+ }
+ }
+ } else if (status == 1) {
+ if (seagullProgress == 0) {
+ cm.sendGetText(seagullQuestion[seagullIdx]);
+ } else if (seagullProgress == 1) {
+ cm.sendNextPrev("I'm going to send you to an empty room in The Nautilus. You will see 9 Barts there. Hahaha~ Are they twins? No, no, certainly not. I've used a bit of magic for this test of will.");
+ } else {
+ cm.sendNextPrev("Notify us using the skill Air Strike, and we will be there to help you out, because that's what friends are for.\r\n\r\n #s5221003# #b#q5221003##k");
+ }
+ } else if (status == 2) {
+ if (seagullIdx > -1) {
+ var answer = cm.getText();
+ if (answer == seagullAnswer[seagullIdx]) {
+ cm.sendNext("What! I can't believe how incredibly smart you are! Incredible! In the seagull world, that kind of intellingence would give you a Ph.D. and then some. You're really amazing... I can't believe it... I simply can't believe it!");
+ cm.setQuestProgress(6400, 0, 1);
+ cm.dispose();
+ } else {
+ cm.sendOk("Hmm, that's not quite how I recall it. Try again!");
+ cm.dispose();
+ }
+ } else if (seagullProgress != 2) {
+ cm.sendNextPrev("Anyway, only one of 9 Barts is the real Bart. You know that Pirates are known for the strength of their friendships and camaraderie with their fellow pirates. If you're a true pirate, you should be able to find your own mate with ease. Alright then, I'll send you to the room where Bart is.");
+ } else {
+ cm.gainExp(1000000);
+ cm.teachSkill(5221003, 0, 10, -1);
+ cm.forceCompleteQuest(6400);
+ cm.dispose();
+ }
+ } else if (status == 3) {
+ var em = cm.getEventManager("4jaerial");
+ if(!em.startInstance(cm.getPlayer())) {
+ cm.sendOk("Another player is already challenging the test in this channel. Please try another channel, or wait for the current player to finish.");
+ }
+
+ cm.dispose();
+ }
+ }
+}
\ No newline at end of file
diff --git a/scripts/npc/1094000.js b/scripts/npc/1094000.js
index 3cd3d172dc..386622528a 100644
--- a/scripts/npc/1094000.js
+++ b/scripts/npc/1094000.js
@@ -23,7 +23,7 @@
-- JavaScript -----------------
Bart - Nautilus' Port
-- Created By --
-Cody/Cyndicate
+ Cody (Cyndicate)
-- Function --
No specific function, useless text.
-- GMS LIKE --
diff --git a/scripts/npc/1095000.js b/scripts/npc/1095000.js
new file mode 100644
index 0000000000..153219bef8
--- /dev/null
+++ b/scripts/npc/1095000.js
@@ -0,0 +1,48 @@
+/*
+ This file is part of the HeavenMS MapleStory Server
+ Copyleft (L) 2016 - 2018 RonanLana
+
+ This program is free software: you can redistribute it and/or modify
+ it under the terms of the GNU Affero General Public License as
+ published by the Free Software Foundation version 3 as published by
+ the Free Software Foundation. You may not use, modify or distribute
+ this program under any other version of the GNU Affero General Public
+ License.
+
+ 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 Affero General Public License for more details.
+
+ You should have received a copy of the GNU Affero General Public License
+ along with this program. If not, see .
+*/
+
+var status;
+
+function start() {
+ status = -1;
+ action(1, 0, 0);
+}
+
+function action(mode, type, selection) {
+ if (mode == -1) {
+ cm.dispose();
+ } else {
+ if (mode == 0 && type > 0) {
+ cm.dispose();
+ return;
+ }
+ if (mode == 1)
+ status++;
+ else
+ status--;
+
+ if(status == 0) {
+ cm.sendYesNo("#b#p2095000##k must be some way up this cliff, according to our latest reports... Or are you saying you want to #rleave here#k?");
+ } else if (status == 1) {
+ cm.warp(120000104);
+ cm.dispose();
+ }
+ }
+}
diff --git a/scripts/npc/1100003.js b/scripts/npc/1100003.js
index 888d506e5b..9f82919619 100644
--- a/scripts/npc/1100003.js
+++ b/scripts/npc/1100003.js
@@ -4,8 +4,7 @@
1100003 Kiriru (To Victoria Island From Ereve)
--------Credits:-------------------------------------------------------------------
- *MapleSanta
+ Credits to: MapleSanta
----------------------------------------------------------------------------------
**/
diff --git a/scripts/npc/1100004.js b/scripts/npc/1100004.js
index 175ea5a9ca..7a7ef2c9c0 100644
--- a/scripts/npc/1100004.js
+++ b/scripts/npc/1100004.js
@@ -4,8 +4,7 @@
1100004 Kiru (To Orbis)
--------Credits:-------------------------------------------------------------------
- *MapleSanta
+ Credits to: MapleSanta
----------------------------------------------------------------------------------
**/
var menu = new Array("Orbis");
diff --git a/scripts/npc/1100005.js b/scripts/npc/1100005.js
index 650e810eac..be67a4de2e 100644
--- a/scripts/npc/1100005.js
+++ b/scripts/npc/1100005.js
@@ -4,8 +4,7 @@
1100005 Kiriru (On boat between Ereve and Victoria Island)
--------Credits:-------------------------------------------------------------------
- *MapleSanta
+ Credits to: MapleSanta
----------------------------------------------------------------------------------
**/
diff --git a/scripts/npc/1100006.js b/scripts/npc/1100006.js
index 02b897740e..83b8483296 100644
--- a/scripts/npc/1100006.js
+++ b/scripts/npc/1100006.js
@@ -4,8 +4,7 @@
1100006 Kiru (On boat between Ereve and Orbis)
--------Credits:-------------------------------------------------------------------
- *MapleSanta
+ Credits to: MapleSanta
----------------------------------------------------------------------------------
**/
diff --git a/scripts/npc/1100007.js b/scripts/npc/1100007.js
index c536c02194..b46180efd9 100644
--- a/scripts/npc/1100007.js
+++ b/scripts/npc/1100007.js
@@ -4,8 +4,7 @@
1100007 Kiriru (Victoria Island Station to Ereve)
--------Credits:-------------------------------------------------------------------
- *MapleSanta
+ Credits to: MapleSanta
----------------------------------------------------------------------------------
**/
diff --git a/scripts/npc/1100008.js b/scripts/npc/1100008.js
index 4db742751d..e9aa694db3 100644
--- a/scripts/npc/1100008.js
+++ b/scripts/npc/1100008.js
@@ -4,8 +4,7 @@
1100008 Kiru (Orbis Station)
--------Credits:-------------------------------------------------------------------
- *MapleSanta
+ Credits to: MapleSanta
----------------------------------------------------------------------------------
**/
diff --git a/scripts/npc/1200003.js b/scripts/npc/1200003.js
index a2ed2537b1..5c283fbcd6 100644
--- a/scripts/npc/1200003.js
+++ b/scripts/npc/1200003.js
@@ -4,8 +4,7 @@
1200003 Puro
--------Credits:-------------------------------------------------------------------
- *MapleSanta
+ Credits to: MapleSanta
----------------------------------------------------------------------------------
**/
diff --git a/scripts/npc/1200004.js b/scripts/npc/1200004.js
index accabbda1f..3a07a5354f 100644
--- a/scripts/npc/1200004.js
+++ b/scripts/npc/1200004.js
@@ -4,8 +4,7 @@
1200004 Puro
--------Credits:-------------------------------------------------------------------
- *MapleSanta
+ Credits to: MapleSanta
----------------------------------------------------------------------------------
**/
diff --git a/scripts/npc/1200005.js b/scripts/npc/1200005.js
index 933cdae54b..14d9630047 100644
--- a/scripts/npc/1200005.js
+++ b/scripts/npc/1200005.js
@@ -4,8 +4,7 @@
1200005 Puro
--------Credits:-------------------------------------------------------------------
- *MapleSanta
+ Credits to: MapleSanta
----------------------------------------------------------------------------------
**/
diff --git a/scripts/npc/1200006.js b/scripts/npc/1200006.js
index a1a5b58bc9..179d9c7f60 100644
--- a/scripts/npc/1200006.js
+++ b/scripts/npc/1200006.js
@@ -4,8 +4,7 @@
1200006 Puro
--------Credits:-------------------------------------------------------------------
- *MapleSanta
+ Credits to: MapleSanta
----------------------------------------------------------------------------------
**/
diff --git a/scripts/npc/2012014.js b/scripts/npc/2012014.js
index c509764cb3..24d434b755 100644
--- a/scripts/npc/2012014.js
+++ b/scripts/npc/2012014.js
@@ -25,7 +25,7 @@
-- By ---------------------------------------------------------------------------------------------
Unknown
-- Version Info -----------------------------------------------------------------------------------
- 1.2 - Now Official method (action(x,0,0) is weak) by Moogra.
+ 1.2 - Now Official method (action(x,0,0) is weak) by Moogra.
1.1 - Official Text and Method [Information]
1.0 - First Version by Unknown
---------------------------------------------------------------------------------------------------
diff --git a/scripts/npc/2020005.js b/scripts/npc/2020005.js
index 1904e12596..7a5ba4440c 100644
--- a/scripts/npc/2020005.js
+++ b/scripts/npc/2020005.js
@@ -23,7 +23,7 @@
-- Odin JavaScript --------------------------------------------------------------------------------
Alcaster - El Nath Market (211000100)
-- By ---------------------------------------------------------------------------------------------
- Unknown/Information/xQuasar
+ Unknown & Information & xQuasar
-- Version Info -----------------------------------------------------------------------------------
1.3 - Fixed up completely [xQuasar]
1.2 - Add a missing text part [Information]
diff --git a/scripts/npc/2030013_old.js b/scripts/npc/2030013_old.js
index 09ece3bdbf..ae98e3e482 100644
--- a/scripts/npc/2030013_old.js
+++ b/scripts/npc/2030013_old.js
@@ -20,7 +20,7 @@
*/
/*
- * @Author Stereo, xQuasar, <>
+ * @Author Stereo, xQuasar, XkelvinchiaX (Kelvin) - For make it Fully Working.
*
* Adobis - El Nath: Entrance to Zakum Altar (211042400)
*
diff --git a/scripts/npc/2040030.js b/scripts/npc/2040030.js
index 1b6352a8cc..16724ce257 100644
--- a/scripts/npc/2040030.js
+++ b/scripts/npc/2040030.js
@@ -1,4 +1,4 @@
-/* Author: aaroncsn <(MapleSea Like)(Need to add creation of minigame)>
+/* Author: aaroncsn - MapleSea Like, Need to add creation of minigame
NPC Name: Wisp
Map(s): Ludibrium: Eos Tower Entrance(220000400)
Description: Pet Master
diff --git a/scripts/npc/2043000.js b/scripts/npc/2043000.js
new file mode 100644
index 0000000000..a57b352854
--- /dev/null
+++ b/scripts/npc/2043000.js
@@ -0,0 +1,52 @@
+/*
+ This file is part of the HeavenMS MapleStory Server
+ Copyleft (L) 2016 - 2018 RonanLana
+
+ This program is free software: you can redistribute it and/or modify
+ it under the terms of the GNU Affero General Public License as
+ published by the Free Software Foundation version 3 as published by
+ the Free Software Foundation. You may not use, modify or distribute
+ this program under any other version of the GNU Affero General Public
+ License.
+
+ 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 Affero General Public License for more details.
+
+ You should have received a copy of the GNU Affero General Public License
+ along with this program. If not, see .
+*/
+/* Papulatus
+ Origin of Clock Tower (922020300)
+ Time Leap quest NPC.
+ */
+
+var status;
+
+function start() { // thanks iPunchEm for NPC visibility
+ status = -1;
+ action(1, 0, 0);
+}
+
+function action(mode, type, selection) {
+ if (mode == -1) {
+ cm.dispose();
+ } else {
+ if (mode == 0 && type > 0) {
+ cm.dispose();
+ return;
+ }
+ if (mode == 1)
+ status++;
+ else
+ status--;
+
+ if(status == 0) {
+ cm.sendNext("You don't belong to this world... Return now.");
+ } else if(status == 1) {
+ cm.warp(220080000);
+ cm.dispose();
+ }
+ }
+}
\ No newline at end of file
diff --git a/scripts/npc/2095000.js b/scripts/npc/2095000.js
new file mode 100644
index 0000000000..8d0366bd4b
--- /dev/null
+++ b/scripts/npc/2095000.js
@@ -0,0 +1,96 @@
+/*
+ This file is part of the HeavenMS MapleStory Server
+ Copyleft (L) 2016 - 2018 RonanLana
+
+ This program is free software: you can redistribute it and/or modify
+ it under the terms of the GNU Affero General Public License as
+ published by the Free Software Foundation version 3 as published by
+ the Free Software Foundation. You may not use, modify or distribute
+ this program under any other version of the GNU Affero General Public
+ License.
+
+ 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 Affero General Public License for more details.
+
+ You should have received a copy of the GNU Affero General Public License
+ along with this program. If not, see .
+*/
+/* Delli
+ Looking for Delli 3 (925010200)
+ Hypnotize skill quest NPC.
+ */
+
+var status;
+
+function start() {
+ status = -1;
+ action(1, 0, 0);
+}
+
+function action(mode, type, selection) {
+ if (mode == -1) {
+ cm.dispose();
+ } else {
+ if (mode == 0 && type > 0) {
+ cm.dispose();
+ return;
+ }
+ if (mode == 1)
+ status++;
+ else
+ status--;
+
+ if (status == 0) {
+ if (cm.getMapId() != 925010400) {
+ em = cm.getEventManager("DelliBattle");
+ if(em == null) {
+ cm.sendOk("The Delli Battle has encountered an error.");
+ cm.dispose();
+ return;
+ } else if(cm.isUsingOldPqNpcStyle()) {
+ action(1, 0, 0);
+ return;
+ }
+
+ cm.sendSimple("#e#b\r\n#k#n" + em.getProperty("party") + "\r\n\r\nAh, #r#p1095000##k sent you here? Is she worried about me? ... I'm terribly sorry to hear that, but I can't really go back just yet, some monsters are under the Black Mage's influence, and it's up to me to liberate them! ... It seems you're not going to accept that either, huh? Would you like to collaborate with party members to help me? If so, please have your #bparty leader#k talk to me.#b\r\n#L0#I want to participate in the party quest.\r\n#L1#I want to find party members.\r\n#L2#I would like to hear more details.");
+ } else {
+ cm.sendYesNo("The mission succeeded, thanks for escorting me! I can lead you to #b#m120000104##k, are you ready?");
+ }
+ } else if (status == 1) {
+ if (cm.getMapId() != 925010400) {
+ if (selection == 0) {
+ if (cm.getParty() == null) {
+ cm.sendOk("You can participate in the party quest only if you are in a party.");
+ cm.dispose();
+ } else if(!cm.isLeader()) {
+ cm.sendOk("Your party leader must talk to me to start this party quest.");
+ cm.dispose();
+ } else {
+ var eli = em.getEligibleParty(cm.getParty());
+ if(eli.size() > 0) {
+ if(!em.startInstance(cm.getParty(), cm.getPlayer().getMap(), 1)) {
+ cm.sendOk("Another party has already entered the #rParty Quest#k in this channel. Please try another channel, or wait for the current party to finish.");
+ }
+ }
+ else {
+ cm.sendOk("You cannot start this party quest yet, because either your party is not in the range size, some of your party members are not eligible to attempt it or they are not in this map. If you're having trouble finding party members, try Party Search.");
+ }
+
+ cm.dispose();
+ }
+ } else if (selection == 1) {
+ cm.sendOk("Try using a Super Megaphone or asking your buddies or guild to join!");
+ cm.dispose();
+ } else {
+ cm.sendOk("#e#b#k#n\r\n A ambush is under way! I must stand on the field for around 6 minutes to complete the liberation, please protect me during that time so that my mission is completed.");
+ cm.dispose();
+ }
+ } else {
+ cm.warp(120000104);
+ cm.dispose();
+ }
+ }
+ }
+}
\ No newline at end of file
diff --git a/scripts/npc/2100007.js b/scripts/npc/2100007.js
index baa30118f5..3fc087cbfa 100644
--- a/scripts/npc/2100007.js
+++ b/scripts/npc/2100007.js
@@ -1,4 +1,4 @@
-/* Author: aaroncsn <(MapleSea Like)(Incomplete- Needs skin id)>
+/* Author: aaroncsn - MapleSea Like, Incomplete, Needs skin id
NPC Name: Laila
Map(s): The Burning Road: Ariant(2600000000)
Description: Skin Care Specialist
diff --git a/scripts/npc/2131000.js b/scripts/npc/2131000.js
index d66fdcd8be..09beb06a21 100644
--- a/scripts/npc/2131000.js
+++ b/scripts/npc/2131000.js
@@ -1,4 +1,4 @@
-/* Author: aaroncsn <(MapleSea Like)(Incomplete)>
+/* Author: aaroncsn - MapleSea Like, Incomplete
NPC Name: Athena Pierce
Map(s): Altair Camp: Conference Hall(300000010)
Description: Unknown
diff --git a/scripts/npc/2131002.js b/scripts/npc/2131002.js
index 297be8edcf..9d32980e37 100644
--- a/scripts/npc/2131002.js
+++ b/scripts/npc/2131002.js
@@ -1,4 +1,4 @@
-/* Author: aaroncsn <(MapleSea Like)(Incomplete)>
+/* Author: aaroncsn - MapleSea Like, Incomplete
NPC Name: Euryth
Map(s): Elin Forest:Altair Camp(300000000)
Description: Unknown
diff --git a/scripts/npc/2132000.js b/scripts/npc/2132000.js
index ca0dfa95b2..d6a5376d15 100644
--- a/scripts/npc/2132000.js
+++ b/scripts/npc/2132000.js
@@ -1,4 +1,4 @@
-/* Author: aaroncsn <(MapleSea Like)(Incomplete)>
+/* Author: aaroncsn - MapleSea Like, Incomplete
NPC Name: Kanderun
Map(s): Elin Forest:Entrance to Rocky Mountain(300010400)
Description: Unknown
diff --git a/scripts/npc/9000001.js b/scripts/npc/9000001.js
index 2da75ddc4d..55eaf9a278 100644
--- a/scripts/npc/9000001.js
+++ b/scripts/npc/9000001.js
@@ -19,7 +19,7 @@
You should have received a copy of the GNU Affero General Public License
along with this program. If not, see .
*/
-/* Edited by: kevintjuh93
+/* Credits to: kevintjuh93
NPC Name: Jean
Map(s): Victoria Road : Lith Harbour (104000000)
Description: Event Assistant
diff --git a/scripts/npc/9030000.js b/scripts/npc/9030000.js
index fc60929917..1393500637 100644
--- a/scripts/npc/9030000.js
+++ b/scripts/npc/9030000.js
@@ -20,7 +20,7 @@
along with this program. If not, see .
*/
/* Fredrick NPC (9030000)
- * By kevintjuh93
+ * @author kevintjuh93
*/
var status;
diff --git a/scripts/npc/9201006.js b/scripts/npc/9201006.js
index 811054e617..2a37253361 100644
--- a/scripts/npc/9201006.js
+++ b/scripts/npc/9201006.js
@@ -23,8 +23,9 @@
Debbie
-- By ---------------------------------------------------------------------------------------------
Angel (get31720 ragezone)
--- Extra Info -------------------------------------------------------------------------------------
- Fixed by [happydud3] & [XotiCraze]
+-- Version Info -----------------------------------------------------------------------------------
+ 1.0 - First Version by Angel
+ 2.0 - Second Version by happydud3 & XotiCraze
---------------------------------------------------------------------------------------------------
**/
diff --git a/scripts/npc/9201007.js b/scripts/npc/9201007.js
index ade6b8bc6b..0e879780e8 100644
--- a/scripts/npc/9201007.js
+++ b/scripts/npc/9201007.js
@@ -23,10 +23,10 @@
Assistant Nancy
-- By ---------------------------------------------------------------------------------------------
Angel (get31720 ragezone)
--- Extra Info -------------------------------------------------------------------------------------
- Fixed by [happydud3] & [XotiCraze]
--- Content Improved by ----------------------------------------------------------------------------
- RonanLana (HeavenMS)
+-- Version Info -----------------------------------------------------------------------------------
+ 1.0 - First Version by Angel
+ 2.0 - Second Version by happydud3 & XotiCraze
+ 3.0 - Third Version by RonanLana (HeavenMS)
---------------------------------------------------------------------------------------------------
**/
diff --git a/scripts/npc/9201009.js b/scripts/npc/9201009.js
index aa88cda5e3..601d7489be 100644
--- a/scripts/npc/9201009.js
+++ b/scripts/npc/9201009.js
@@ -23,10 +23,10 @@
Assistant Nancy
-- By ---------------------------------------------------------------------------------------------
Angel (get31720 ragezone)
--- Extra Info -------------------------------------------------------------------------------------
- Fixed by [happydud3] & [XotiCraze]
--- Content Improved by ----------------------------------------------------------------------------
- RonanLana (HeavenMS)
+-- Version Info -----------------------------------------------------------------------------------
+ 1.0 - First Version by Angel
+ 2.0 - Second Version by happydud3 & XotiCraze
+ 3.0 - Third Version by RonanLana (HeavenMS)
---------------------------------------------------------------------------------------------------
**/
diff --git a/scripts/npc/9201010.js b/scripts/npc/9201010.js
index 00ce690d64..b372bccd0c 100644
--- a/scripts/npc/9201010.js
+++ b/scripts/npc/9201010.js
@@ -23,8 +23,10 @@
Assistant Travis
-- By ---------------------------------------------------------------------------------------------
Angel (get31720 ragezone)
--- Extra Info -------------------------------------------------------------------------------------
- Fixed by [happydud3] & [XotiCraze]
+-- Version Info -----------------------------------------------------------------------------------
+ 1.0 - First Version by Angel
+ 2.0 - Second Version by happydud3 & XotiCraze
+ 3.0 - Third Version by RonanLana (HeavenMS)
---------------------------------------------------------------------------------------------------
**/
diff --git a/scripts/npc/9201014.js b/scripts/npc/9201014.js
index 24d16259b8..6713b15fcf 100644
--- a/scripts/npc/9201014.js
+++ b/scripts/npc/9201014.js
@@ -23,9 +23,10 @@
Pila Present
-- By ---------------------------------------------------------------------------------------------
Angel (get31720 ragezone)
--- Extra Info -------------------------------------------------------------------------------------
- Fixed by [happydud3] & [XotiCraze]
- Improved by [RonanLana]
+-- Version Info -----------------------------------------------------------------------------------
+ 1.0 - First Version by Angel
+ 2.0 - Second Version by happydud3 & XotiCraze
+ 3.0 - Third Version by RonanLana (HeavenMS)
---------------------------------------------------------------------------------------------------
**/
diff --git a/scripts/npc/9201096.js b/scripts/npc/9201096.js
index 49fc8ff7bc..3ced465fdb 100644
--- a/scripts/npc/9201096.js
+++ b/scripts/npc/9201096.js
@@ -1,9 +1,25 @@
-/* Jack
- Refining NPC:
- * ITEMMAKE
- *
- * By RonanLana
+/*
+ This file is part of the HeavenMS MapleStory Server
+ Copyleft (L) 2016 - 2018 RonanLana
+
+ This program is free software: you can redistribute it and/or modify
+ it under the terms of the GNU Affero General Public License as
+ published by the Free Software Foundation version 3 as published by
+ the Free Software Foundation. You may not use, modify or distribute
+ this program under any other version of the GNU Affero General Public
+ License.
+
+ 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 Affero General Public License for more details.
+
+ You should have received a copy of the GNU Affero General Public License
+ along with this program. If not, see .
*/
+/* Jack - Refining NPC
+ @author RonanLana
+ */
var status = 0;
var selectedType = -1;
diff --git a/scripts/npc/9270023.js b/scripts/npc/9270023.js
index a376184a51..60263714da 100644
--- a/scripts/npc/9270023.js
+++ b/scripts/npc/9270023.js
@@ -21,7 +21,7 @@
*/
/* Noel
Singapore Random Face Changer
- Credits to aaron and cody
+ @Author AAron (aaroncsn), Cody
Side note by aaron [If there is something wrong PM me on fMS]
*/
var status = 0;
diff --git a/scripts/npc/9270024.js b/scripts/npc/9270024.js
index e633bb9686..0ede90abf7 100644
--- a/scripts/npc/9270024.js
+++ b/scripts/npc/9270024.js
@@ -21,7 +21,7 @@
*/
/* Kelvin
SingaPore VIP Face changer
- Made by aaron and cody
+ @Author AAron (aaroncsn), Cody
*/
var status = 0;
var beauty = 0;
diff --git a/scripts/npc/9270036.js b/scripts/npc/9270036.js
index da6812c8c4..f997c1ea79 100644
--- a/scripts/npc/9270036.js
+++ b/scripts/npc/9270036.js
@@ -21,7 +21,7 @@
*/
/* Eric
Singapore VIP Hair/Color Changer
- MADE BY AAron and Cody from the FlowsionMS Forums
+ @Author AAron, Cody (FlowsionMS) Forums
*/
var status = 0;
var beauty = 0;
diff --git a/scripts/npc/9270037.js b/scripts/npc/9270037.js
index 40560af9cc..2c26b2bd5f 100644
--- a/scripts/npc/9270037.js
+++ b/scripts/npc/9270037.js
@@ -21,7 +21,8 @@
*/
/* Jimmy
Singa Random Hair/Color Changer
- Credits to Cody and AAron from FlowsionMS
+ @Author Cody (FlowsionMS)
+ @Author AAron (FlowsionMS)
*/
var status = 0;
var beauty = 0;
diff --git a/scripts/npc/credits.js b/scripts/npc/credits.js
index 7544ede3f7..04da15ab89 100644
--- a/scripts/npc/credits.js
+++ b/scripts/npc/credits.js
@@ -98,6 +98,7 @@ function writeServerStaff_Contributors() {
addPerson("xQuasar", "Contributor");
addPerson("Xterminator", "Contributor");
addPerson("XoticStory", "Contributor");
+ addPerson("Masterrulax", "Contributor");
}
function writeAllServerStaffs() {
diff --git a/scripts/portal/Populatus00.js b/scripts/portal/Populatus00.js
index 8e5e4cb764..20c64ee7bb 100644
--- a/scripts/portal/Populatus00.js
+++ b/scripts/portal/Populatus00.js
@@ -23,28 +23,34 @@
/* @author RonanLana */
function enter(pi) {
- var em = pi.getEventManager("PapulatusBattle");
+ if (!((pi.isQuestStarted(6361) && pi.haveItem(4031870, 1)) || (pi.isQuestCompleted(6361) && !pi.isQuestCompleted(6363)))) {
+ var em = pi.getEventManager("PapulatusBattle");
- if (pi.getParty() == null) {
- pi.playerMessage(5, "You are currently not in a party, create one to attempt the boss.");
- return false;
- } else if(!pi.isLeader()) {
- pi.playerMessage(5, "Your party leader must enter the portal to start the battle.");
- return false;
- } else {
- var eli = em.getEligibleParty(pi.getParty());
- if(eli.size() > 0) {
- if(!em.startInstance(pi.getParty(), pi.getPlayer().getMap(), 1)) {
- pi.playerMessage(5, "The battle against the boss has already begun, so you may not enter this place yet.");
+ if (pi.getParty() == null) {
+ pi.playerMessage(5, "You are currently not in a party, create one to attempt the boss.");
+ return false;
+ } else if(!pi.isLeader()) {
+ pi.playerMessage(5, "Your party leader must enter the portal to start the battle.");
+ return false;
+ } else {
+ var eli = em.getEligibleParty(pi.getParty());
+ if(eli.size() > 0) {
+ if(!em.startInstance(pi.getParty(), pi.getPlayer().getMap(), 1)) {
+ pi.playerMessage(5, "The battle against the boss has already begun, so you may not enter this place yet.");
+ return false;
+ }
+ }
+ else { //this should never appear
+ pi.playerMessage(5, "You cannot start this battle yet, because either your party is not in the range size, some of your party members are not eligible to attempt it or they are not in this map. If you're having trouble finding party members, try Party Search.");
return false;
}
- }
- else { //this should never appear
- pi.playerMessage(5, "You cannot start this battle yet, because either your party is not in the range size, some of your party members are not eligible to attempt it or they are not in this map. If you're having trouble finding party members, try Party Search.");
- return false;
- }
+ pi.playPortalSound();
+ return true;
+ }
+ } else {
pi.playPortalSound();
+ pi.warp(922020300);
return true;
- }
+ }
}
\ No newline at end of file
diff --git a/scripts/portal/aranTutorArrow0.js b/scripts/portal/aranTutorArrow0.js
index 578ba659d4..0378679430 100644
--- a/scripts/portal/aranTutorArrow0.js
+++ b/scripts/portal/aranTutorArrow0.js
@@ -20,7 +20,7 @@
along with this program. If not, see .
*/
/*
-By kevintjuh93
+@author kevintjuh93
*/
function enter(pi) {
pi.blockPortal();
diff --git a/scripts/portal/aranTutorArrow1.js b/scripts/portal/aranTutorArrow1.js
index 2d8e19ab62..6385f645d5 100644
--- a/scripts/portal/aranTutorArrow1.js
+++ b/scripts/portal/aranTutorArrow1.js
@@ -20,7 +20,7 @@
along with this program. If not, see .
*/
/*
-By kevintjuh93
+@author kevintjuh93
*/
function enter(pi) {
pi.blockPortal();
diff --git a/scripts/portal/aranTutorArrow2.js b/scripts/portal/aranTutorArrow2.js
index 8c640372fb..11dc2e2fa5 100644
--- a/scripts/portal/aranTutorArrow2.js
+++ b/scripts/portal/aranTutorArrow2.js
@@ -20,7 +20,7 @@
along with this program. If not, see .
*/
/*
-By kevintjuh93
+@author kevintjuh93
*/
function enter(pi) {
pi.blockPortal();
diff --git a/scripts/portal/aranTutorArrow3.js b/scripts/portal/aranTutorArrow3.js
index c4549c4c6d..e4e7fdd5ab 100644
--- a/scripts/portal/aranTutorArrow3.js
+++ b/scripts/portal/aranTutorArrow3.js
@@ -20,7 +20,7 @@
along with this program. If not, see .
*/
/*
-By kevintjuh93
+@author kevintjuh93
*/
function enter(pi) {
pi.blockPortal();
diff --git a/scripts/portal/aranTutorGuide0.js b/scripts/portal/aranTutorGuide0.js
index 6d73bcee23..021057f726 100644
--- a/scripts/portal/aranTutorGuide0.js
+++ b/scripts/portal/aranTutorGuide0.js
@@ -20,7 +20,7 @@
along with this program. If not, see .
*/
/*
-By kevintjuh93
+@author kevintjuh93
*/
function enter(pi) {
pi.blockPortal();
diff --git a/scripts/portal/aranTutorGuide1.js b/scripts/portal/aranTutorGuide1.js
index b7931bb679..c674dd9f2b 100644
--- a/scripts/portal/aranTutorGuide1.js
+++ b/scripts/portal/aranTutorGuide1.js
@@ -20,7 +20,7 @@
along with this program. If not, see .
*/
/*
-By kevintjuh93
+@author kevintjuh93
*/
function enter(pi) {
pi.blockPortal();
diff --git a/scripts/portal/aranTutorGuide2.js b/scripts/portal/aranTutorGuide2.js
index 7612383cb5..5e8c157853 100644
--- a/scripts/portal/aranTutorGuide2.js
+++ b/scripts/portal/aranTutorGuide2.js
@@ -20,7 +20,7 @@
along with this program. If not, see .
*/
/*
-By kevintjuh93
+@author kevintjuh93
*/
function enter(pi) {
pi.blockPortal();
diff --git a/scripts/portal/aranTutorLost.js b/scripts/portal/aranTutorLost.js
index 6a21905230..a38f0e2191 100644
--- a/scripts/portal/aranTutorLost.js
+++ b/scripts/portal/aranTutorLost.js
@@ -20,7 +20,7 @@
along with this program. If not, see .
*/
/*
-By kevintjuh93
+@author kevintjuh93
*/
function enter(pi) {
pi.blockPortal();
diff --git a/scripts/portal/aranTutorMono0.js b/scripts/portal/aranTutorMono0.js
index 87d57dc264..d214d14d08 100644
--- a/scripts/portal/aranTutorMono0.js
+++ b/scripts/portal/aranTutorMono0.js
@@ -20,7 +20,7 @@
along with this program. If not, see .
*/
/*
-By kevintjuh93
+@author kevintjuh93
*/
function enter(pi) {
pi.blockPortal();
diff --git a/scripts/portal/aranTutorMono1.js b/scripts/portal/aranTutorMono1.js
index 025466aa8b..a8509e9581 100644
--- a/scripts/portal/aranTutorMono1.js
+++ b/scripts/portal/aranTutorMono1.js
@@ -20,7 +20,7 @@
along with this program. If not, see .
*/
/*
-By kevintjuh93
+@author kevintjuh93
*/
function enter(pi) {
pi.blockPortal();
diff --git a/scripts/portal/aranTutorMono2.js b/scripts/portal/aranTutorMono2.js
index 9e01844043..2b06feae4b 100644
--- a/scripts/portal/aranTutorMono2.js
+++ b/scripts/portal/aranTutorMono2.js
@@ -20,7 +20,7 @@
along with this program. If not, see .
*/
/*
-By kevintjuh93
+@author kevintjuh93
*/
function enter(pi) {
pi.blockPortal();
diff --git a/scripts/portal/aranTutorMono3.js b/scripts/portal/aranTutorMono3.js
index f3059917ec..cefbdfdd90 100644
--- a/scripts/portal/aranTutorMono3.js
+++ b/scripts/portal/aranTutorMono3.js
@@ -20,7 +20,7 @@
along with this program. If not, see .
*/
/*
-By kevintjuh93
+@author kevintjuh93
*/
function enter(pi) {
pi.blockPortal();
diff --git a/scripts/portal/enterMagiclibrar.js b/scripts/portal/enterMagiclibrar.js
index c8df1a2818..73c5a7dd01 100644
--- a/scripts/portal/enterMagiclibrar.js
+++ b/scripts/portal/enterMagiclibrar.js
@@ -16,7 +16,7 @@
You should have received a copy of the GNU Affero General Public License
along with this program. If not, see .
- Edited by: Kevin
+ Credits to: Kevin
*/
function enter(pi) {
if(pi.isQuestStarted(20718)){
diff --git a/scripts/portal/glTutoMsg0.js b/scripts/portal/glTutoMsg0.js
index 12d0e149b0..654801f495 100644
--- a/scripts/portal/glTutoMsg0.js
+++ b/scripts/portal/glTutoMsg0.js
@@ -20,7 +20,7 @@
along with this program. If not, see .
*/
/*
-By kevintjuh93
+@author kevintjuh93
*/
function enter(pi) {
pi.showInstruction("Once you leave this area you won't be able to return.", 150, 5);
diff --git a/scripts/portal/infoMinimap.js b/scripts/portal/infoMinimap.js
index e48498e4e6..2ebd0275ce 100644
--- a/scripts/portal/infoMinimap.js
+++ b/scripts/portal/infoMinimap.js
@@ -20,7 +20,7 @@
along with this program. If not, see .
*/
/*
-By kevintjuh93
+@author kevintjuh93
*/
function enter(pi) {
if (pi.isQuestStarted(1031))
diff --git a/scripts/portal/infoPickup.js b/scripts/portal/infoPickup.js
index 519b38e6a3..04698dba20 100644
--- a/scripts/portal/infoPickup.js
+++ b/scripts/portal/infoPickup.js
@@ -20,7 +20,7 @@
along with this program. If not, see .
*/
/*
-By kevintjuh93
+@author kevintjuh93
*/
function enter(pi) {
if (pi.isQuestStarted(1035))
diff --git a/scripts/portal/infoReactor.js b/scripts/portal/infoReactor.js
index 60f71d3f7d..5796725da2 100644
--- a/scripts/portal/infoReactor.js
+++ b/scripts/portal/infoReactor.js
@@ -20,7 +20,7 @@
along with this program. If not, see .
*/
/*
-By kevintjuh93
+@author kevintjuh93
*/
function enter(pi) {
if (pi.isQuestCompleted(1008))
diff --git a/scripts/portal/infoSkill.js b/scripts/portal/infoSkill.js
index f4ef8ba00c..c9c09ab073 100644
--- a/scripts/portal/infoSkill.js
+++ b/scripts/portal/infoSkill.js
@@ -20,7 +20,7 @@
along with this program. If not, see .
*/
/*
-By kevintjuh93
+@author kevintjuh93
*/
function enter(pi) {
if (pi.isQuestCompleted(1035))
diff --git a/scripts/portal/s4mind_end.js b/scripts/portal/s4mind_end.js
new file mode 100644
index 0000000000..39007482c2
--- /dev/null
+++ b/scripts/portal/s4mind_end.js
@@ -0,0 +1,33 @@
+/*
+ This file is part of the HeavenMS MapleStory Server
+ Copyleft (L) 2016 - 2018 RonanLana
+
+ This program is free software: you can redistribute it and/or modify
+ it under the terms of the GNU Affero General Public License as
+ published by the Free Software Foundation version 3 as published by
+ the Free Software Foundation. You may not use, modify or distribute
+ this program under any other version of the GNU Affero General Public
+ License.
+
+ 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 Affero General Public License for more details.
+
+ You should have received a copy of the GNU Affero General Public License
+ along with this program. If not, see .
+*/
+function enter(pi) {
+ if (!pi.getEventInstance().isEventCleared()) {
+ pi.message("You have to clear this mission before entering this portal.");
+ return false;
+ } else {
+ if (pi.isQuestStarted(6410)) {
+ pi.setQuestProgress(6410, 0, 1);
+ }
+
+ pi.playPortalSound();
+ pi.warp(925010400);
+ return true;
+ }
+}
\ No newline at end of file
diff --git a/scripts/portal/s4ship_out.js b/scripts/portal/s4ship_out.js
index b24830505b..0400da3c62 100644
--- a/scripts/portal/s4ship_out.js
+++ b/scripts/portal/s4ship_out.js
@@ -23,9 +23,11 @@ function enter(pi) {
pi.message("You have to wait one minute before you can leave this place.");
return false;
} else if (exit == 2) {
+ pi.playPortalSound();
pi.warp(912010200);
return true;
} else {
+ pi.playPortalSound();
pi.warp(120000101);
return true;
}
diff --git a/scripts/portal/s4super_out.js b/scripts/portal/s4super_out.js
index b24830505b..0400da3c62 100644
--- a/scripts/portal/s4super_out.js
+++ b/scripts/portal/s4super_out.js
@@ -23,9 +23,11 @@ function enter(pi) {
pi.message("You have to wait one minute before you can leave this place.");
return false;
} else if (exit == 2) {
+ pi.playPortalSound();
pi.warp(912010200);
return true;
} else {
+ pi.playPortalSound();
pi.warp(120000101);
return true;
}
diff --git a/scripts/quest/10940.js b/scripts/quest/10940.js
index d7a5ca2b59..67c8cc0408 100644
--- a/scripts/quest/10940.js
+++ b/scripts/quest/10940.js
@@ -1,4 +1,4 @@
-//credits to kevintjuh93
+//@author kevintjuh93
var status = -1;
diff --git a/scripts/quest/20710.js b/scripts/quest/20710.js
index 6e6bdd7486..059c4b8279 100644
--- a/scripts/quest/20710.js
+++ b/scripts/quest/20710.js
@@ -1,5 +1,5 @@
/*
- Author: DietStory dev team
+ Author: DietStory v1.02 dev team
NPC: Matthias
Quest: Hidden Inside the Trash Can
*/
diff --git a/scripts/quest/2230.js b/scripts/quest/2230.js
index 36467071cf..7aa7e5d5f9 100644
--- a/scripts/quest/2230.js
+++ b/scripts/quest/2230.js
@@ -76,7 +76,7 @@ function end(mode, type, selection) {
} else if (status == 5) {
qm.sendYesNo("Now do you understand? Every action comes with consequences, and pets are no exception. The egg of the snail shall hatch soon.");
} else if (status == 6) {
- qm.gainItem(5000054, 1, false, true, 5 * 60 * 60 * 1000); // rune snail (5hrs)
+ qm.gainItem(5000054, 1, false, true, 5 * 60 * 60 * 1000); // rune snail (5hrs), missing expiration time detected thanks to cljnilsson
qm.gainItem(4032086, -1); // Mysterious Egg * -1
qm.forceCompleteQuest();
diff --git a/scripts/quest/2300.js b/scripts/quest/2300.js
index ecf094dc08..9efd61d7f4 100644
--- a/scripts/quest/2300.js
+++ b/scripts/quest/2300.js
@@ -4,62 +4,101 @@
Description: Quest - Kingdom of Mushroom in Danger
=============================================================
Version 1.0 - Script Done.(17/7/2010)
+Version 2.0 - Script Reworked by Ronan.(16/11/2018)
=============================================================
*/
var status = -1;
function start(mode, type, selection) {
- status++;
- if (mode != 1) {
- if(type == 1 && mode == 0)
- status -= 2;
- else{
- if(status == 0){
- qm.sendOk("Really? It's an urgent matter, so if you have some time, please see me.");
- qm.dispose();
- return;
- } else if(status == 3){
- qm.sendNext("Okay. In that case, I'll just give you the routes to the Kingdom of Mushroom. #bNear the west entrance of Henesys,#k you'll find an #bempty house#k. Enter the house, and turn left to enter#b#k. That's the entrance to the Kingdom of Mushroom. There's not much time!");
- qm.forceStartQuest();
- return;
- }
- }
- }
- if(status == 0)
- qm.sendAcceptDecline("Now that you have made the job advancement, you look like you're ready for this. I have something I'd like to ask you for help. Are you willing to listen?");
- if(status == 1)
- qm.sendNext("What happened is that the #bKingdom of Mushroom#k is currently in disarray. Kingdom of Mushroom is located near Henesys, featuring the peace-loving, intelligent King Mush. Recently, he began to feel ill, so he decided to appoint his only daughter #bPrincess Violetta#k. Something must have happened since then for the kingdom to be in its current state.");
- if(status == 2)
- qm.sendNext("I am not aware of the exact details, but it's obvious something terrible had taken place, so I think it'll be better if you go there and assess the damage yourself. An explorer like you seem more than capable of saving Kingdom of Mushroom. I have just written you a #brecommendation letter#k, so I suggest you head over to Kingdom of Mushroom immediately and look for the #bHead Patrol Officer#k.\r\n\r\n#fUI/UIWindow.img/QuestIcon/4/0#\r\n#v4032375# #t4032375#");
- if(status == 3)
- qm.sendYesNo("By the way, do you know where Kingdom of Mushroom is located? It'll be okay if you can find your way there, but if you don't mind, I can take you straight to the entrance.");
- if(status == 4){
- qm.gainItem(4032375, 1);
- qm.forceStartQuest();
- qm.dispose();
- }
+ if (mode == -1) {
+ qm.dispose();
+ } else {
+ if(mode == 0 && type > 0) {
+ if (status != 3) {
+ qm.sendOk("Really? It's an urgent matter, so if you have some time, please see me.");
+ qm.dispose();
+ } else {
+ if (qm.canHold(4032375, 1)) {
+ qm.sendNext("Okay. In that case, I'll just give you the routes to the Kingdom of Mushroom. #bNear the west entrance of Henesys,#k you'll find an #bempty house#k. Enter the house, and turn left to enter#b#k. That's the entrance to the Kingdom of Mushroom. There's not much time!");
+ } else {
+ qm.sendOk("Please have a slot available in your Etc inventory.");
+ qm.dispose();
+ }
+ }
+
+ status++;
+ } else {
+ if (mode == 1)
+ status++;
+ else
+ status--;
+
+ if (status == 0) {
+ qm.sendAcceptDecline("Now that you have made the job advancement, you look like you're ready for this. I have something I'd like to ask you for help. Are you willing to listen?");
+ } else if (status == 1) {
+ qm.sendNext("What happened is that the #bKingdom of Mushroom#k is currently in disarray. Kingdom of Mushroom is located near Henesys, featuring the peace-loving, intelligent King Mush. Recently, he began to feel ill, so he decided to appoint his only daughter #bPrincess Violetta#k. Something must have happened since then for the kingdom to be in its current state.");
+ } else if (status == 2) {
+ qm.sendNext("I am not aware of the exact details, but it's obvious something terrible had taken place, so I think it'll be better if you go there and assess the damage yourself. An explorer like you seem more than capable of saving Kingdom of Mushroom. I have just written you a #brecommendation letter#k, so I suggest you head over to Kingdom of Mushroom immediately and look for the #bHead Patrol Officer#k.\r\n\r\n#fUI/UIWindow.img/QuestIcon/4/0#\r\n#v4032375# #t4032375#");
+ } else if (status == 3) {
+ qm.sendYesNo("By the way, do you know where Kingdom of Mushroom is located? It'll be okay if you can find your way there, but if you don't mind, I can take you straight to the entrance.");
+ } else if (status == 4) {
+ if (qm.canHold(4032375, 1)) {
+ if (!qm.haveItem(4032375, 1)) {
+ qm.gainItem(4032375, 1);
+ }
+
+ qm.warp(106020000, 0);
+ qm.forceStartQuest();
+ } else {
+ qm.sendOk("Please have a slot available in your Etc inventory.");
+ }
+
+ qm.dispose();
+ return;
+ } else if (status == 5) {
+ if (!qm.haveItem(4032375, 1)) {
+ qm.gainItem(4032375, 1);
+ }
+
+ qm.forceStartQuest();
+ qm.dispose();
+ return;
+ }
+ }
+ }
}
function end(mode, type, selection) {
- status++;
- if (mode != 1) {
- if(type == 1 && mode == 0)
- status -= 2;
- else{
- qm.dispose();
- return;
- }
- }
- if(status == 0)
- qm.sendNext("Hmmm? Is that a #brecommendation letter from the job instructor#k??! What is this, are you the one that came to save us, the Kingdom of Mushroom?");
- if(status == 1)
- qm.sendNextPrev("Hmmm... okay. Since the letter is from the job instructor, I suppose you are really the one. I apologize for not introducing myself to you earlier. I'm the #bHead Security Officer#k in charge of protecting King Mush. As you can see, this temporary hideout is protected by the team of security and soldiers. Our situation may be dire, but nevertheless, welcome to Kingdom of Mushroom.");
- if(status == 2){
- qm.gainItem(4032375, -1);
- qm.gainExp(6000);
- qm.forceCompleteQuest();
- qm.forceStartQuest(2312);
- qm.dispose();
- }
+ if (mode == -1) {
+ qm.dispose();
+ } else {
+ if(mode == 0 && type > 0) {
+ qm.dispose();
+ return;
+ }
+
+ if (mode == 1)
+ status++;
+ else
+ status--;
+
+ if (status == 0) {
+ if (!qm.haveItem(4032375, 1)) {
+ qm.sendNext("What do you want, hmmm?");
+ qm.dispose();
+ return;
+ }
+
+ qm.sendNext("Hmmm? Is that a #brecommendation letter from the job instructor#k??! What is this, are you the one that came to save us, the Kingdom of Mushroom?");
+ } else if (status == 1) {
+ qm.sendNextPrev("Hmmm... okay. Since the letter is from the job instructor, I suppose you are really the one. I apologize for not introducing myself to you earlier. I'm the #bHead Security Officer#k in charge of protecting King Mush. As you can see, this temporary hideout is protected by the team of security and soldiers. Our situation may be dire, but nevertheless, welcome to Kingdom of Mushroom.");
+ } else if (status == 2) {
+ qm.gainItem(4032375, -1);
+ qm.gainExp(6000);
+ qm.forceCompleteQuest();
+ qm.forceStartQuest(2312);
+ qm.dispose();
+ }
+ }
}
\ No newline at end of file
diff --git a/scripts/quest/2301.js b/scripts/quest/2301.js
index 6973579675..9efd61d7f4 100644
--- a/scripts/quest/2301.js
+++ b/scripts/quest/2301.js
@@ -4,61 +4,101 @@
Description: Quest - Kingdom of Mushroom in Danger
=============================================================
Version 1.0 - Script Done.(17/7/2010)
+Version 2.0 - Script Reworked by Ronan.(16/11/2018)
=============================================================
*/
var status = -1;
function start(mode, type, selection) {
- status++;
- if (mode != 1) {
- if(type == 1 && mode == 0)
- status -= 2;
- else{
- //if(status == 0){
- qm.sendOk("Really? It's an urgent matter, so if you have some time, please see me.");
- qm.dispose();
- return;
- //} else if(status == 3){
- //qm.sendNext("Okay. In that case, I'll just give you the routes to the Kingdom of Mushroom. #bNear the west entrance of Henesys,#k you'll find an #bempty house#k. Enter the house, and turn left to enter#b#k. That's the entrance to the Kingdom of Mushroom. There's not much time!");
- //qm.forceStartQuest();
- //return;
- }
- }
- //}
- if(status == 0)
- qm.sendAcceptDecline("Now that you have made the job advancement, you look like you're ready for this. I have something I'd like to ask you for help. Are you willing to listen?");
- if(status == 1)
- qm.sendNext("What happened is that the #bKingdom of Mushroom#k is currently in disarray. Kingdom of Mushroom is located near Henesys, featuring the peace-loving, intelligent King Mush. Recently, he began to feel ill, so he decided to appoint his only daughter #bPrincess Violetta#k. Something must have happened since then for the kingdom to be in its current state.");
- if(status == 2)
- qm.sendNext("I am not aware of the exact details, but it's obvious something terrible had taken place, so I think it'll be better if you go there and assess the damage yourself. An explorer like you seem more than capable of saving Kingdom of Mushroom. I have just written you a #brecommendation letter#k, so I suggest you head over to Kingdom of Mushroom immediately and look for the #bHead Patrol Officer#k.\r\n\r\n#fUI/UIWindow.img/QuestIcon/4/0#\r\n#v4032375# #t4032375#");
- if(status == 3)
- qm.sendYesNo("By the way, do you know where Kingdom of Mushroom is located? It'll be okay if you can find your way there, but if you don't mind, I can take you straight to the entrance.");
- if(status == 4){
- qm.gainItem(4032375, 1);
- qm.forceStartQuest();
- qm.dispose();
- }
+ if (mode == -1) {
+ qm.dispose();
+ } else {
+ if(mode == 0 && type > 0) {
+ if (status != 3) {
+ qm.sendOk("Really? It's an urgent matter, so if you have some time, please see me.");
+ qm.dispose();
+ } else {
+ if (qm.canHold(4032375, 1)) {
+ qm.sendNext("Okay. In that case, I'll just give you the routes to the Kingdom of Mushroom. #bNear the west entrance of Henesys,#k you'll find an #bempty house#k. Enter the house, and turn left to enter#b#k. That's the entrance to the Kingdom of Mushroom. There's not much time!");
+ } else {
+ qm.sendOk("Please have a slot available in your Etc inventory.");
+ qm.dispose();
+ }
+ }
+
+ status++;
+ } else {
+ if (mode == 1)
+ status++;
+ else
+ status--;
+
+ if (status == 0) {
+ qm.sendAcceptDecline("Now that you have made the job advancement, you look like you're ready for this. I have something I'd like to ask you for help. Are you willing to listen?");
+ } else if (status == 1) {
+ qm.sendNext("What happened is that the #bKingdom of Mushroom#k is currently in disarray. Kingdom of Mushroom is located near Henesys, featuring the peace-loving, intelligent King Mush. Recently, he began to feel ill, so he decided to appoint his only daughter #bPrincess Violetta#k. Something must have happened since then for the kingdom to be in its current state.");
+ } else if (status == 2) {
+ qm.sendNext("I am not aware of the exact details, but it's obvious something terrible had taken place, so I think it'll be better if you go there and assess the damage yourself. An explorer like you seem more than capable of saving Kingdom of Mushroom. I have just written you a #brecommendation letter#k, so I suggest you head over to Kingdom of Mushroom immediately and look for the #bHead Patrol Officer#k.\r\n\r\n#fUI/UIWindow.img/QuestIcon/4/0#\r\n#v4032375# #t4032375#");
+ } else if (status == 3) {
+ qm.sendYesNo("By the way, do you know where Kingdom of Mushroom is located? It'll be okay if you can find your way there, but if you don't mind, I can take you straight to the entrance.");
+ } else if (status == 4) {
+ if (qm.canHold(4032375, 1)) {
+ if (!qm.haveItem(4032375, 1)) {
+ qm.gainItem(4032375, 1);
+ }
+
+ qm.warp(106020000, 0);
+ qm.forceStartQuest();
+ } else {
+ qm.sendOk("Please have a slot available in your Etc inventory.");
+ }
+
+ qm.dispose();
+ return;
+ } else if (status == 5) {
+ if (!qm.haveItem(4032375, 1)) {
+ qm.gainItem(4032375, 1);
+ }
+
+ qm.forceStartQuest();
+ qm.dispose();
+ return;
+ }
+ }
+ }
}
function end(mode, type, selection) {
- status++;
- if (mode != 1) {
- if(type == 1 && mode == 0)
- status -= 2;
- else{
- qm.dispose();
- return;
- }
- }
- if(status == 0)
- qm.sendNext("Hmmm? Is that a #brecommendation letter from the job instructor#k??! What is this, are you the one that came to save us, the Kingdom of Mushroom?");
- if(status == 1)
- qm.sendNextPrev("Hmmm... okay. Since the letter is from the job instructor, I suppose you are really the one. I apologize for not introducing myself to you earlier. I'm the #bHead Security Officer#k in charge of protecting King Mush. As you can see, this temporary hideout is protected by the team of security and soldiers. Our situation may be dire, but nevertheless, welcome to Kingdom of Mushroom.");
- if(status == 2){
- qm.forceCompleteQuest();
- qm.gainItem(4032375, -1);
- qm.forceStartQuest(2312);
- qm.dispose();
- }
-}
+ if (mode == -1) {
+ qm.dispose();
+ } else {
+ if(mode == 0 && type > 0) {
+ qm.dispose();
+ return;
+ }
+
+ if (mode == 1)
+ status++;
+ else
+ status--;
+
+ if (status == 0) {
+ if (!qm.haveItem(4032375, 1)) {
+ qm.sendNext("What do you want, hmmm?");
+ qm.dispose();
+ return;
+ }
+
+ qm.sendNext("Hmmm? Is that a #brecommendation letter from the job instructor#k??! What is this, are you the one that came to save us, the Kingdom of Mushroom?");
+ } else if (status == 1) {
+ qm.sendNextPrev("Hmmm... okay. Since the letter is from the job instructor, I suppose you are really the one. I apologize for not introducing myself to you earlier. I'm the #bHead Security Officer#k in charge of protecting King Mush. As you can see, this temporary hideout is protected by the team of security and soldiers. Our situation may be dire, but nevertheless, welcome to Kingdom of Mushroom.");
+ } else if (status == 2) {
+ qm.gainItem(4032375, -1);
+ qm.gainExp(6000);
+ qm.forceCompleteQuest();
+ qm.forceStartQuest(2312);
+ qm.dispose();
+ }
+ }
+}
\ No newline at end of file
diff --git a/scripts/quest/2302.js b/scripts/quest/2302.js
index 244a97bc18..9efd61d7f4 100644
--- a/scripts/quest/2302.js
+++ b/scripts/quest/2302.js
@@ -4,61 +4,101 @@
Description: Quest - Kingdom of Mushroom in Danger
=============================================================
Version 1.0 - Script Done.(17/7/2010)
+Version 2.0 - Script Reworked by Ronan.(16/11/2018)
=============================================================
*/
var status = -1;
function start(mode, type, selection) {
- status++;
- if (mode != 1) {
- if(type == 1 && mode == 0)
- status -= 2;
- else{
- //if(status == 0){
- qm.sendOk("Really? It's an urgent matter, so if you have some time, please see me.");
- qm.dispose();
- return;
- //} else if(status == 3){
- //qm.sendNext("Okay. In that case, I'll just give you the routes to the Kingdom of Mushroom. #bNear the west entrance of Henesys,#k you'll find an #bempty house#k. Enter the house, and turn left to enter#b#k. That's the entrance to the Kingdom of Mushroom. There's not much time!");
- //qm.forceStartQuest();
- //return;
- }
- }
- //}
- if(status == 0)
- qm.sendAcceptDecline("Now that you have made the job advancement, you look like you're ready for this. I have something I'd like to ask you for help. Are you willing to listen?");
- if(status == 1)
- qm.sendNext("What happened is that the #bKingdom of Mushroom#k is currently in disarray. Kingdom of Mushroom is located near Henesys, featuring the peace-loving, intelligent King Mush. Recently, he began to feel ill, so he decided to appoint his only daughter #bPrincess Violetta#k. Something must have happened since then for the kingdom to be in its current state.");
- if(status == 2)
- qm.sendNext("I am not aware of the exact details, but it's obvious something terrible had taken place, so I think it'll be better if you go there and assess the damage yourself. An explorer like you seem more than capable of saving Kingdom of Mushroom. I have just written you a #brecommendation letter#k, so I suggest you head over to Kingdom of Mushroom immediately and look for the #bHead Patrol Officer#k.\r\n\r\n#fUI/UIWindow.img/QuestIcon/4/0#\r\n#v4032375# #t4032375#");
- if(status == 3)
- qm.sendYesNo("By the way, do you know where Kingdom of Mushroom is located? It'll be okay if you can find your way there, but if you don't mind, I can take you straight to the entrance.");
- if(status == 4){
- qm.gainItem(4032375, 1);
- qm.forceStartQuest();
- qm.dispose();
- }
+ if (mode == -1) {
+ qm.dispose();
+ } else {
+ if(mode == 0 && type > 0) {
+ if (status != 3) {
+ qm.sendOk("Really? It's an urgent matter, so if you have some time, please see me.");
+ qm.dispose();
+ } else {
+ if (qm.canHold(4032375, 1)) {
+ qm.sendNext("Okay. In that case, I'll just give you the routes to the Kingdom of Mushroom. #bNear the west entrance of Henesys,#k you'll find an #bempty house#k. Enter the house, and turn left to enter#b#k. That's the entrance to the Kingdom of Mushroom. There's not much time!");
+ } else {
+ qm.sendOk("Please have a slot available in your Etc inventory.");
+ qm.dispose();
+ }
+ }
+
+ status++;
+ } else {
+ if (mode == 1)
+ status++;
+ else
+ status--;
+
+ if (status == 0) {
+ qm.sendAcceptDecline("Now that you have made the job advancement, you look like you're ready for this. I have something I'd like to ask you for help. Are you willing to listen?");
+ } else if (status == 1) {
+ qm.sendNext("What happened is that the #bKingdom of Mushroom#k is currently in disarray. Kingdom of Mushroom is located near Henesys, featuring the peace-loving, intelligent King Mush. Recently, he began to feel ill, so he decided to appoint his only daughter #bPrincess Violetta#k. Something must have happened since then for the kingdom to be in its current state.");
+ } else if (status == 2) {
+ qm.sendNext("I am not aware of the exact details, but it's obvious something terrible had taken place, so I think it'll be better if you go there and assess the damage yourself. An explorer like you seem more than capable of saving Kingdom of Mushroom. I have just written you a #brecommendation letter#k, so I suggest you head over to Kingdom of Mushroom immediately and look for the #bHead Patrol Officer#k.\r\n\r\n#fUI/UIWindow.img/QuestIcon/4/0#\r\n#v4032375# #t4032375#");
+ } else if (status == 3) {
+ qm.sendYesNo("By the way, do you know where Kingdom of Mushroom is located? It'll be okay if you can find your way there, but if you don't mind, I can take you straight to the entrance.");
+ } else if (status == 4) {
+ if (qm.canHold(4032375, 1)) {
+ if (!qm.haveItem(4032375, 1)) {
+ qm.gainItem(4032375, 1);
+ }
+
+ qm.warp(106020000, 0);
+ qm.forceStartQuest();
+ } else {
+ qm.sendOk("Please have a slot available in your Etc inventory.");
+ }
+
+ qm.dispose();
+ return;
+ } else if (status == 5) {
+ if (!qm.haveItem(4032375, 1)) {
+ qm.gainItem(4032375, 1);
+ }
+
+ qm.forceStartQuest();
+ qm.dispose();
+ return;
+ }
+ }
+ }
}
function end(mode, type, selection) {
- status++;
- if (mode != 1) {
- if(type == 1 && mode == 0)
- status -= 2;
- else{
- qm.dispose();
- return;
- }
- }
- if(status == 0)
- qm.sendNext("Hmmm? Is that a #brecommendation letter from the job instructor#k??! What is this, are you the one that came to save us, the Kingdom of Mushroom?");
- if(status == 1)
- qm.sendNextPrev("Hmmm... okay. Since the letter is from the job instructor, I suppose you are really the one. I apologize for not introducing myself to you earlier. I'm the #bHead Security Officer#k in charge of protecting King Mush. As you can see, this temporary hideout is protected by the team of security and soldiers. Our situation may be dire, but nevertheless, welcome to Kingdom of Mushroom.");
- if(status == 2){
- qm.forceCompleteQuest();
- qm.gainItem(4032375, -1);
- qm.forceStartQuest(2312);
- qm.dispose();
- }
-}
+ if (mode == -1) {
+ qm.dispose();
+ } else {
+ if(mode == 0 && type > 0) {
+ qm.dispose();
+ return;
+ }
+
+ if (mode == 1)
+ status++;
+ else
+ status--;
+
+ if (status == 0) {
+ if (!qm.haveItem(4032375, 1)) {
+ qm.sendNext("What do you want, hmmm?");
+ qm.dispose();
+ return;
+ }
+
+ qm.sendNext("Hmmm? Is that a #brecommendation letter from the job instructor#k??! What is this, are you the one that came to save us, the Kingdom of Mushroom?");
+ } else if (status == 1) {
+ qm.sendNextPrev("Hmmm... okay. Since the letter is from the job instructor, I suppose you are really the one. I apologize for not introducing myself to you earlier. I'm the #bHead Security Officer#k in charge of protecting King Mush. As you can see, this temporary hideout is protected by the team of security and soldiers. Our situation may be dire, but nevertheless, welcome to Kingdom of Mushroom.");
+ } else if (status == 2) {
+ qm.gainItem(4032375, -1);
+ qm.gainExp(6000);
+ qm.forceCompleteQuest();
+ qm.forceStartQuest(2312);
+ qm.dispose();
+ }
+ }
+}
\ No newline at end of file
diff --git a/scripts/quest/2303.js b/scripts/quest/2303.js
index b48ba6a804..9efd61d7f4 100644
--- a/scripts/quest/2303.js
+++ b/scripts/quest/2303.js
@@ -4,60 +4,101 @@
Description: Quest - Kingdom of Mushroom in Danger
=============================================================
Version 1.0 - Script Done.(17/7/2010)
+Version 2.0 - Script Reworked by Ronan.(16/11/2018)
=============================================================
*/
var status = -1;
function start(mode, type, selection) {
- status++;
- if (mode != 1) {
- if(type == 1 && mode == 0)
- status -= 2;
- else{
- //if(status == 0){
- qm.sendOk("Really? It's an urgent matter, so if you have some time, please see me.");
- qm.dispose();
- return;
- //} else if(status == 3){
- //qm.sendNext("Okay. In that case, I'll just give you the routes to the Kingdom of Mushroom. #bNear the west entrance of Henesys,#k you'll find an #bempty house#k. Enter the house, and turn left to enter#b#k. That's the entrance to the Kingdom of Mushroom. There's not much time!");
- //qm.forceStartQuest();
- //return;
- }
- }
- //}
- if(status == 0)
- qm.sendAcceptDecline("Now that you have made the job advancement, you look like you're ready for this. I have something I'd like to ask you for help. Are you willing to listen?");
- if(status == 1)
- qm.sendNext("What happened is that the #bKingdom of Mushroom#k is currently in disarray. Kingdom of Mushroom is located near Henesys, featuring the peace-loving, intelligent King Mush. Recently, he began to feel ill, so he decided to appoint his only daughter #bPrincess Violetta#k. Something must have happened since then for the kingdom to be in its current state.");
- if(status == 2)
- qm.sendNext("I am not aware of the exact details, but it's obvious something terrible had taken place, so I think it'll be better if you go there and assess the damage yourself. An explorer like you seem more than capable of saving Kingdom of Mushroom. I have just written you a #brecommendation letter#k, so I suggest you head over to Kingdom of Mushroom immediately and look for the #bHead Patrol Officer#k.\r\n\r\n#fUI/UIWindow.img/QuestIcon/4/0#\r\n#v4032375# #t4032375#");
- if(status == 3)
- qm.sendYesNo("By the way, do you know where Kingdom of Mushroom is located? It'll be okay if you can find your way there, but if you don't mind, I can take you straight to the entrance.");
- if(status == 4){
- qm.gainItem(4032375, 1);
- qm.forceStartQuest();
- qm.dispose();
- }
+ if (mode == -1) {
+ qm.dispose();
+ } else {
+ if(mode == 0 && type > 0) {
+ if (status != 3) {
+ qm.sendOk("Really? It's an urgent matter, so if you have some time, please see me.");
+ qm.dispose();
+ } else {
+ if (qm.canHold(4032375, 1)) {
+ qm.sendNext("Okay. In that case, I'll just give you the routes to the Kingdom of Mushroom. #bNear the west entrance of Henesys,#k you'll find an #bempty house#k. Enter the house, and turn left to enter#b#k. That's the entrance to the Kingdom of Mushroom. There's not much time!");
+ } else {
+ qm.sendOk("Please have a slot available in your Etc inventory.");
+ qm.dispose();
+ }
+ }
+
+ status++;
+ } else {
+ if (mode == 1)
+ status++;
+ else
+ status--;
+
+ if (status == 0) {
+ qm.sendAcceptDecline("Now that you have made the job advancement, you look like you're ready for this. I have something I'd like to ask you for help. Are you willing to listen?");
+ } else if (status == 1) {
+ qm.sendNext("What happened is that the #bKingdom of Mushroom#k is currently in disarray. Kingdom of Mushroom is located near Henesys, featuring the peace-loving, intelligent King Mush. Recently, he began to feel ill, so he decided to appoint his only daughter #bPrincess Violetta#k. Something must have happened since then for the kingdom to be in its current state.");
+ } else if (status == 2) {
+ qm.sendNext("I am not aware of the exact details, but it's obvious something terrible had taken place, so I think it'll be better if you go there and assess the damage yourself. An explorer like you seem more than capable of saving Kingdom of Mushroom. I have just written you a #brecommendation letter#k, so I suggest you head over to Kingdom of Mushroom immediately and look for the #bHead Patrol Officer#k.\r\n\r\n#fUI/UIWindow.img/QuestIcon/4/0#\r\n#v4032375# #t4032375#");
+ } else if (status == 3) {
+ qm.sendYesNo("By the way, do you know where Kingdom of Mushroom is located? It'll be okay if you can find your way there, but if you don't mind, I can take you straight to the entrance.");
+ } else if (status == 4) {
+ if (qm.canHold(4032375, 1)) {
+ if (!qm.haveItem(4032375, 1)) {
+ qm.gainItem(4032375, 1);
+ }
+
+ qm.warp(106020000, 0);
+ qm.forceStartQuest();
+ } else {
+ qm.sendOk("Please have a slot available in your Etc inventory.");
+ }
+
+ qm.dispose();
+ return;
+ } else if (status == 5) {
+ if (!qm.haveItem(4032375, 1)) {
+ qm.gainItem(4032375, 1);
+ }
+
+ qm.forceStartQuest();
+ qm.dispose();
+ return;
+ }
+ }
+ }
}
+
function end(mode, type, selection) {
- status++;
- if (mode != 1) {
- if(type == 1 && mode == 0)
- status -= 2;
- else{
- qm.dispose();
- return;
- }
- }
- if(status == 0)
- qm.sendNext("Hmmm? Is that a #brecommendation letter from the job instructor#k??! What is this, are you the one that came to save us, the Kingdom of Mushroom?");
- if(status == 1)
- qm.sendNextPrev("Hmmm... okay. Since the letter is from the job instructor, I suppose you are really the one. I apologize for not introducing myself to you earlier. I'm the #bHead Security Officer#k in charge of protecting King Mush. As you can see, this temporary hideout is protected by the team of security and soldiers. Our situation may be dire, but nevertheless, welcome to Kingdom of Mushroom.");
- if(status == 2){
- qm.forceCompleteQuest();
- qm.gainItem(4032375, -1);
- qm.forceStartQuest(2312);
- qm.dispose();
- }
+ if (mode == -1) {
+ qm.dispose();
+ } else {
+ if(mode == 0 && type > 0) {
+ qm.dispose();
+ return;
+ }
+
+ if (mode == 1)
+ status++;
+ else
+ status--;
+
+ if (status == 0) {
+ if (!qm.haveItem(4032375, 1)) {
+ qm.sendNext("What do you want, hmmm?");
+ qm.dispose();
+ return;
+ }
+
+ qm.sendNext("Hmmm? Is that a #brecommendation letter from the job instructor#k??! What is this, are you the one that came to save us, the Kingdom of Mushroom?");
+ } else if (status == 1) {
+ qm.sendNextPrev("Hmmm... okay. Since the letter is from the job instructor, I suppose you are really the one. I apologize for not introducing myself to you earlier. I'm the #bHead Security Officer#k in charge of protecting King Mush. As you can see, this temporary hideout is protected by the team of security and soldiers. Our situation may be dire, but nevertheless, welcome to Kingdom of Mushroom.");
+ } else if (status == 2) {
+ qm.gainItem(4032375, -1);
+ qm.gainExp(6000);
+ qm.forceCompleteQuest();
+ qm.forceStartQuest(2312);
+ qm.dispose();
+ }
+ }
}
\ No newline at end of file
diff --git a/scripts/quest/2304.js b/scripts/quest/2304.js
index 244a97bc18..9efd61d7f4 100644
--- a/scripts/quest/2304.js
+++ b/scripts/quest/2304.js
@@ -4,61 +4,101 @@
Description: Quest - Kingdom of Mushroom in Danger
=============================================================
Version 1.0 - Script Done.(17/7/2010)
+Version 2.0 - Script Reworked by Ronan.(16/11/2018)
=============================================================
*/
var status = -1;
function start(mode, type, selection) {
- status++;
- if (mode != 1) {
- if(type == 1 && mode == 0)
- status -= 2;
- else{
- //if(status == 0){
- qm.sendOk("Really? It's an urgent matter, so if you have some time, please see me.");
- qm.dispose();
- return;
- //} else if(status == 3){
- //qm.sendNext("Okay. In that case, I'll just give you the routes to the Kingdom of Mushroom. #bNear the west entrance of Henesys,#k you'll find an #bempty house#k. Enter the house, and turn left to enter#b#k. That's the entrance to the Kingdom of Mushroom. There's not much time!");
- //qm.forceStartQuest();
- //return;
- }
- }
- //}
- if(status == 0)
- qm.sendAcceptDecline("Now that you have made the job advancement, you look like you're ready for this. I have something I'd like to ask you for help. Are you willing to listen?");
- if(status == 1)
- qm.sendNext("What happened is that the #bKingdom of Mushroom#k is currently in disarray. Kingdom of Mushroom is located near Henesys, featuring the peace-loving, intelligent King Mush. Recently, he began to feel ill, so he decided to appoint his only daughter #bPrincess Violetta#k. Something must have happened since then for the kingdom to be in its current state.");
- if(status == 2)
- qm.sendNext("I am not aware of the exact details, but it's obvious something terrible had taken place, so I think it'll be better if you go there and assess the damage yourself. An explorer like you seem more than capable of saving Kingdom of Mushroom. I have just written you a #brecommendation letter#k, so I suggest you head over to Kingdom of Mushroom immediately and look for the #bHead Patrol Officer#k.\r\n\r\n#fUI/UIWindow.img/QuestIcon/4/0#\r\n#v4032375# #t4032375#");
- if(status == 3)
- qm.sendYesNo("By the way, do you know where Kingdom of Mushroom is located? It'll be okay if you can find your way there, but if you don't mind, I can take you straight to the entrance.");
- if(status == 4){
- qm.gainItem(4032375, 1);
- qm.forceStartQuest();
- qm.dispose();
- }
+ if (mode == -1) {
+ qm.dispose();
+ } else {
+ if(mode == 0 && type > 0) {
+ if (status != 3) {
+ qm.sendOk("Really? It's an urgent matter, so if you have some time, please see me.");
+ qm.dispose();
+ } else {
+ if (qm.canHold(4032375, 1)) {
+ qm.sendNext("Okay. In that case, I'll just give you the routes to the Kingdom of Mushroom. #bNear the west entrance of Henesys,#k you'll find an #bempty house#k. Enter the house, and turn left to enter#b#k. That's the entrance to the Kingdom of Mushroom. There's not much time!");
+ } else {
+ qm.sendOk("Please have a slot available in your Etc inventory.");
+ qm.dispose();
+ }
+ }
+
+ status++;
+ } else {
+ if (mode == 1)
+ status++;
+ else
+ status--;
+
+ if (status == 0) {
+ qm.sendAcceptDecline("Now that you have made the job advancement, you look like you're ready for this. I have something I'd like to ask you for help. Are you willing to listen?");
+ } else if (status == 1) {
+ qm.sendNext("What happened is that the #bKingdom of Mushroom#k is currently in disarray. Kingdom of Mushroom is located near Henesys, featuring the peace-loving, intelligent King Mush. Recently, he began to feel ill, so he decided to appoint his only daughter #bPrincess Violetta#k. Something must have happened since then for the kingdom to be in its current state.");
+ } else if (status == 2) {
+ qm.sendNext("I am not aware of the exact details, but it's obvious something terrible had taken place, so I think it'll be better if you go there and assess the damage yourself. An explorer like you seem more than capable of saving Kingdom of Mushroom. I have just written you a #brecommendation letter#k, so I suggest you head over to Kingdom of Mushroom immediately and look for the #bHead Patrol Officer#k.\r\n\r\n#fUI/UIWindow.img/QuestIcon/4/0#\r\n#v4032375# #t4032375#");
+ } else if (status == 3) {
+ qm.sendYesNo("By the way, do you know where Kingdom of Mushroom is located? It'll be okay if you can find your way there, but if you don't mind, I can take you straight to the entrance.");
+ } else if (status == 4) {
+ if (qm.canHold(4032375, 1)) {
+ if (!qm.haveItem(4032375, 1)) {
+ qm.gainItem(4032375, 1);
+ }
+
+ qm.warp(106020000, 0);
+ qm.forceStartQuest();
+ } else {
+ qm.sendOk("Please have a slot available in your Etc inventory.");
+ }
+
+ qm.dispose();
+ return;
+ } else if (status == 5) {
+ if (!qm.haveItem(4032375, 1)) {
+ qm.gainItem(4032375, 1);
+ }
+
+ qm.forceStartQuest();
+ qm.dispose();
+ return;
+ }
+ }
+ }
}
function end(mode, type, selection) {
- status++;
- if (mode != 1) {
- if(type == 1 && mode == 0)
- status -= 2;
- else{
- qm.dispose();
- return;
- }
- }
- if(status == 0)
- qm.sendNext("Hmmm? Is that a #brecommendation letter from the job instructor#k??! What is this, are you the one that came to save us, the Kingdom of Mushroom?");
- if(status == 1)
- qm.sendNextPrev("Hmmm... okay. Since the letter is from the job instructor, I suppose you are really the one. I apologize for not introducing myself to you earlier. I'm the #bHead Security Officer#k in charge of protecting King Mush. As you can see, this temporary hideout is protected by the team of security and soldiers. Our situation may be dire, but nevertheless, welcome to Kingdom of Mushroom.");
- if(status == 2){
- qm.forceCompleteQuest();
- qm.gainItem(4032375, -1);
- qm.forceStartQuest(2312);
- qm.dispose();
- }
-}
+ if (mode == -1) {
+ qm.dispose();
+ } else {
+ if(mode == 0 && type > 0) {
+ qm.dispose();
+ return;
+ }
+
+ if (mode == 1)
+ status++;
+ else
+ status--;
+
+ if (status == 0) {
+ if (!qm.haveItem(4032375, 1)) {
+ qm.sendNext("What do you want, hmmm?");
+ qm.dispose();
+ return;
+ }
+
+ qm.sendNext("Hmmm? Is that a #brecommendation letter from the job instructor#k??! What is this, are you the one that came to save us, the Kingdom of Mushroom?");
+ } else if (status == 1) {
+ qm.sendNextPrev("Hmmm... okay. Since the letter is from the job instructor, I suppose you are really the one. I apologize for not introducing myself to you earlier. I'm the #bHead Security Officer#k in charge of protecting King Mush. As you can see, this temporary hideout is protected by the team of security and soldiers. Our situation may be dire, but nevertheless, welcome to Kingdom of Mushroom.");
+ } else if (status == 2) {
+ qm.gainItem(4032375, -1);
+ qm.gainExp(6000);
+ qm.forceCompleteQuest();
+ qm.forceStartQuest(2312);
+ qm.dispose();
+ }
+ }
+}
\ No newline at end of file
diff --git a/scripts/quest/2305.js b/scripts/quest/2305.js
index 244a97bc18..9efd61d7f4 100644
--- a/scripts/quest/2305.js
+++ b/scripts/quest/2305.js
@@ -4,61 +4,101 @@
Description: Quest - Kingdom of Mushroom in Danger
=============================================================
Version 1.0 - Script Done.(17/7/2010)
+Version 2.0 - Script Reworked by Ronan.(16/11/2018)
=============================================================
*/
var status = -1;
function start(mode, type, selection) {
- status++;
- if (mode != 1) {
- if(type == 1 && mode == 0)
- status -= 2;
- else{
- //if(status == 0){
- qm.sendOk("Really? It's an urgent matter, so if you have some time, please see me.");
- qm.dispose();
- return;
- //} else if(status == 3){
- //qm.sendNext("Okay. In that case, I'll just give you the routes to the Kingdom of Mushroom. #bNear the west entrance of Henesys,#k you'll find an #bempty house#k. Enter the house, and turn left to enter#b#k. That's the entrance to the Kingdom of Mushroom. There's not much time!");
- //qm.forceStartQuest();
- //return;
- }
- }
- //}
- if(status == 0)
- qm.sendAcceptDecline("Now that you have made the job advancement, you look like you're ready for this. I have something I'd like to ask you for help. Are you willing to listen?");
- if(status == 1)
- qm.sendNext("What happened is that the #bKingdom of Mushroom#k is currently in disarray. Kingdom of Mushroom is located near Henesys, featuring the peace-loving, intelligent King Mush. Recently, he began to feel ill, so he decided to appoint his only daughter #bPrincess Violetta#k. Something must have happened since then for the kingdom to be in its current state.");
- if(status == 2)
- qm.sendNext("I am not aware of the exact details, but it's obvious something terrible had taken place, so I think it'll be better if you go there and assess the damage yourself. An explorer like you seem more than capable of saving Kingdom of Mushroom. I have just written you a #brecommendation letter#k, so I suggest you head over to Kingdom of Mushroom immediately and look for the #bHead Patrol Officer#k.\r\n\r\n#fUI/UIWindow.img/QuestIcon/4/0#\r\n#v4032375# #t4032375#");
- if(status == 3)
- qm.sendYesNo("By the way, do you know where Kingdom of Mushroom is located? It'll be okay if you can find your way there, but if you don't mind, I can take you straight to the entrance.");
- if(status == 4){
- qm.gainItem(4032375, 1);
- qm.forceStartQuest();
- qm.dispose();
- }
+ if (mode == -1) {
+ qm.dispose();
+ } else {
+ if(mode == 0 && type > 0) {
+ if (status != 3) {
+ qm.sendOk("Really? It's an urgent matter, so if you have some time, please see me.");
+ qm.dispose();
+ } else {
+ if (qm.canHold(4032375, 1)) {
+ qm.sendNext("Okay. In that case, I'll just give you the routes to the Kingdom of Mushroom. #bNear the west entrance of Henesys,#k you'll find an #bempty house#k. Enter the house, and turn left to enter#b#k. That's the entrance to the Kingdom of Mushroom. There's not much time!");
+ } else {
+ qm.sendOk("Please have a slot available in your Etc inventory.");
+ qm.dispose();
+ }
+ }
+
+ status++;
+ } else {
+ if (mode == 1)
+ status++;
+ else
+ status--;
+
+ if (status == 0) {
+ qm.sendAcceptDecline("Now that you have made the job advancement, you look like you're ready for this. I have something I'd like to ask you for help. Are you willing to listen?");
+ } else if (status == 1) {
+ qm.sendNext("What happened is that the #bKingdom of Mushroom#k is currently in disarray. Kingdom of Mushroom is located near Henesys, featuring the peace-loving, intelligent King Mush. Recently, he began to feel ill, so he decided to appoint his only daughter #bPrincess Violetta#k. Something must have happened since then for the kingdom to be in its current state.");
+ } else if (status == 2) {
+ qm.sendNext("I am not aware of the exact details, but it's obvious something terrible had taken place, so I think it'll be better if you go there and assess the damage yourself. An explorer like you seem more than capable of saving Kingdom of Mushroom. I have just written you a #brecommendation letter#k, so I suggest you head over to Kingdom of Mushroom immediately and look for the #bHead Patrol Officer#k.\r\n\r\n#fUI/UIWindow.img/QuestIcon/4/0#\r\n#v4032375# #t4032375#");
+ } else if (status == 3) {
+ qm.sendYesNo("By the way, do you know where Kingdom of Mushroom is located? It'll be okay if you can find your way there, but if you don't mind, I can take you straight to the entrance.");
+ } else if (status == 4) {
+ if (qm.canHold(4032375, 1)) {
+ if (!qm.haveItem(4032375, 1)) {
+ qm.gainItem(4032375, 1);
+ }
+
+ qm.warp(106020000, 0);
+ qm.forceStartQuest();
+ } else {
+ qm.sendOk("Please have a slot available in your Etc inventory.");
+ }
+
+ qm.dispose();
+ return;
+ } else if (status == 5) {
+ if (!qm.haveItem(4032375, 1)) {
+ qm.gainItem(4032375, 1);
+ }
+
+ qm.forceStartQuest();
+ qm.dispose();
+ return;
+ }
+ }
+ }
}
function end(mode, type, selection) {
- status++;
- if (mode != 1) {
- if(type == 1 && mode == 0)
- status -= 2;
- else{
- qm.dispose();
- return;
- }
- }
- if(status == 0)
- qm.sendNext("Hmmm? Is that a #brecommendation letter from the job instructor#k??! What is this, are you the one that came to save us, the Kingdom of Mushroom?");
- if(status == 1)
- qm.sendNextPrev("Hmmm... okay. Since the letter is from the job instructor, I suppose you are really the one. I apologize for not introducing myself to you earlier. I'm the #bHead Security Officer#k in charge of protecting King Mush. As you can see, this temporary hideout is protected by the team of security and soldiers. Our situation may be dire, but nevertheless, welcome to Kingdom of Mushroom.");
- if(status == 2){
- qm.forceCompleteQuest();
- qm.gainItem(4032375, -1);
- qm.forceStartQuest(2312);
- qm.dispose();
- }
-}
+ if (mode == -1) {
+ qm.dispose();
+ } else {
+ if(mode == 0 && type > 0) {
+ qm.dispose();
+ return;
+ }
+
+ if (mode == 1)
+ status++;
+ else
+ status--;
+
+ if (status == 0) {
+ if (!qm.haveItem(4032375, 1)) {
+ qm.sendNext("What do you want, hmmm?");
+ qm.dispose();
+ return;
+ }
+
+ qm.sendNext("Hmmm? Is that a #brecommendation letter from the job instructor#k??! What is this, are you the one that came to save us, the Kingdom of Mushroom?");
+ } else if (status == 1) {
+ qm.sendNextPrev("Hmmm... okay. Since the letter is from the job instructor, I suppose you are really the one. I apologize for not introducing myself to you earlier. I'm the #bHead Security Officer#k in charge of protecting King Mush. As you can see, this temporary hideout is protected by the team of security and soldiers. Our situation may be dire, but nevertheless, welcome to Kingdom of Mushroom.");
+ } else if (status == 2) {
+ qm.gainItem(4032375, -1);
+ qm.gainExp(6000);
+ qm.forceCompleteQuest();
+ qm.forceStartQuest(2312);
+ qm.dispose();
+ }
+ }
+}
\ No newline at end of file
diff --git a/scripts/quest/2306.js b/scripts/quest/2306.js
index 244a97bc18..9efd61d7f4 100644
--- a/scripts/quest/2306.js
+++ b/scripts/quest/2306.js
@@ -4,61 +4,101 @@
Description: Quest - Kingdom of Mushroom in Danger
=============================================================
Version 1.0 - Script Done.(17/7/2010)
+Version 2.0 - Script Reworked by Ronan.(16/11/2018)
=============================================================
*/
var status = -1;
function start(mode, type, selection) {
- status++;
- if (mode != 1) {
- if(type == 1 && mode == 0)
- status -= 2;
- else{
- //if(status == 0){
- qm.sendOk("Really? It's an urgent matter, so if you have some time, please see me.");
- qm.dispose();
- return;
- //} else if(status == 3){
- //qm.sendNext("Okay. In that case, I'll just give you the routes to the Kingdom of Mushroom. #bNear the west entrance of Henesys,#k you'll find an #bempty house#k. Enter the house, and turn left to enter#b#k. That's the entrance to the Kingdom of Mushroom. There's not much time!");
- //qm.forceStartQuest();
- //return;
- }
- }
- //}
- if(status == 0)
- qm.sendAcceptDecline("Now that you have made the job advancement, you look like you're ready for this. I have something I'd like to ask you for help. Are you willing to listen?");
- if(status == 1)
- qm.sendNext("What happened is that the #bKingdom of Mushroom#k is currently in disarray. Kingdom of Mushroom is located near Henesys, featuring the peace-loving, intelligent King Mush. Recently, he began to feel ill, so he decided to appoint his only daughter #bPrincess Violetta#k. Something must have happened since then for the kingdom to be in its current state.");
- if(status == 2)
- qm.sendNext("I am not aware of the exact details, but it's obvious something terrible had taken place, so I think it'll be better if you go there and assess the damage yourself. An explorer like you seem more than capable of saving Kingdom of Mushroom. I have just written you a #brecommendation letter#k, so I suggest you head over to Kingdom of Mushroom immediately and look for the #bHead Patrol Officer#k.\r\n\r\n#fUI/UIWindow.img/QuestIcon/4/0#\r\n#v4032375# #t4032375#");
- if(status == 3)
- qm.sendYesNo("By the way, do you know where Kingdom of Mushroom is located? It'll be okay if you can find your way there, but if you don't mind, I can take you straight to the entrance.");
- if(status == 4){
- qm.gainItem(4032375, 1);
- qm.forceStartQuest();
- qm.dispose();
- }
+ if (mode == -1) {
+ qm.dispose();
+ } else {
+ if(mode == 0 && type > 0) {
+ if (status != 3) {
+ qm.sendOk("Really? It's an urgent matter, so if you have some time, please see me.");
+ qm.dispose();
+ } else {
+ if (qm.canHold(4032375, 1)) {
+ qm.sendNext("Okay. In that case, I'll just give you the routes to the Kingdom of Mushroom. #bNear the west entrance of Henesys,#k you'll find an #bempty house#k. Enter the house, and turn left to enter#b#k. That's the entrance to the Kingdom of Mushroom. There's not much time!");
+ } else {
+ qm.sendOk("Please have a slot available in your Etc inventory.");
+ qm.dispose();
+ }
+ }
+
+ status++;
+ } else {
+ if (mode == 1)
+ status++;
+ else
+ status--;
+
+ if (status == 0) {
+ qm.sendAcceptDecline("Now that you have made the job advancement, you look like you're ready for this. I have something I'd like to ask you for help. Are you willing to listen?");
+ } else if (status == 1) {
+ qm.sendNext("What happened is that the #bKingdom of Mushroom#k is currently in disarray. Kingdom of Mushroom is located near Henesys, featuring the peace-loving, intelligent King Mush. Recently, he began to feel ill, so he decided to appoint his only daughter #bPrincess Violetta#k. Something must have happened since then for the kingdom to be in its current state.");
+ } else if (status == 2) {
+ qm.sendNext("I am not aware of the exact details, but it's obvious something terrible had taken place, so I think it'll be better if you go there and assess the damage yourself. An explorer like you seem more than capable of saving Kingdom of Mushroom. I have just written you a #brecommendation letter#k, so I suggest you head over to Kingdom of Mushroom immediately and look for the #bHead Patrol Officer#k.\r\n\r\n#fUI/UIWindow.img/QuestIcon/4/0#\r\n#v4032375# #t4032375#");
+ } else if (status == 3) {
+ qm.sendYesNo("By the way, do you know where Kingdom of Mushroom is located? It'll be okay if you can find your way there, but if you don't mind, I can take you straight to the entrance.");
+ } else if (status == 4) {
+ if (qm.canHold(4032375, 1)) {
+ if (!qm.haveItem(4032375, 1)) {
+ qm.gainItem(4032375, 1);
+ }
+
+ qm.warp(106020000, 0);
+ qm.forceStartQuest();
+ } else {
+ qm.sendOk("Please have a slot available in your Etc inventory.");
+ }
+
+ qm.dispose();
+ return;
+ } else if (status == 5) {
+ if (!qm.haveItem(4032375, 1)) {
+ qm.gainItem(4032375, 1);
+ }
+
+ qm.forceStartQuest();
+ qm.dispose();
+ return;
+ }
+ }
+ }
}
function end(mode, type, selection) {
- status++;
- if (mode != 1) {
- if(type == 1 && mode == 0)
- status -= 2;
- else{
- qm.dispose();
- return;
- }
- }
- if(status == 0)
- qm.sendNext("Hmmm? Is that a #brecommendation letter from the job instructor#k??! What is this, are you the one that came to save us, the Kingdom of Mushroom?");
- if(status == 1)
- qm.sendNextPrev("Hmmm... okay. Since the letter is from the job instructor, I suppose you are really the one. I apologize for not introducing myself to you earlier. I'm the #bHead Security Officer#k in charge of protecting King Mush. As you can see, this temporary hideout is protected by the team of security and soldiers. Our situation may be dire, but nevertheless, welcome to Kingdom of Mushroom.");
- if(status == 2){
- qm.forceCompleteQuest();
- qm.gainItem(4032375, -1);
- qm.forceStartQuest(2312);
- qm.dispose();
- }
-}
+ if (mode == -1) {
+ qm.dispose();
+ } else {
+ if(mode == 0 && type > 0) {
+ qm.dispose();
+ return;
+ }
+
+ if (mode == 1)
+ status++;
+ else
+ status--;
+
+ if (status == 0) {
+ if (!qm.haveItem(4032375, 1)) {
+ qm.sendNext("What do you want, hmmm?");
+ qm.dispose();
+ return;
+ }
+
+ qm.sendNext("Hmmm? Is that a #brecommendation letter from the job instructor#k??! What is this, are you the one that came to save us, the Kingdom of Mushroom?");
+ } else if (status == 1) {
+ qm.sendNextPrev("Hmmm... okay. Since the letter is from the job instructor, I suppose you are really the one. I apologize for not introducing myself to you earlier. I'm the #bHead Security Officer#k in charge of protecting King Mush. As you can see, this temporary hideout is protected by the team of security and soldiers. Our situation may be dire, but nevertheless, welcome to Kingdom of Mushroom.");
+ } else if (status == 2) {
+ qm.gainItem(4032375, -1);
+ qm.gainExp(6000);
+ qm.forceCompleteQuest();
+ qm.forceStartQuest(2312);
+ qm.dispose();
+ }
+ }
+}
\ No newline at end of file
diff --git a/scripts/quest/2307.js b/scripts/quest/2307.js
index 244a97bc18..9efd61d7f4 100644
--- a/scripts/quest/2307.js
+++ b/scripts/quest/2307.js
@@ -4,61 +4,101 @@
Description: Quest - Kingdom of Mushroom in Danger
=============================================================
Version 1.0 - Script Done.(17/7/2010)
+Version 2.0 - Script Reworked by Ronan.(16/11/2018)
=============================================================
*/
var status = -1;
function start(mode, type, selection) {
- status++;
- if (mode != 1) {
- if(type == 1 && mode == 0)
- status -= 2;
- else{
- //if(status == 0){
- qm.sendOk("Really? It's an urgent matter, so if you have some time, please see me.");
- qm.dispose();
- return;
- //} else if(status == 3){
- //qm.sendNext("Okay. In that case, I'll just give you the routes to the Kingdom of Mushroom. #bNear the west entrance of Henesys,#k you'll find an #bempty house#k. Enter the house, and turn left to enter#b#k. That's the entrance to the Kingdom of Mushroom. There's not much time!");
- //qm.forceStartQuest();
- //return;
- }
- }
- //}
- if(status == 0)
- qm.sendAcceptDecline("Now that you have made the job advancement, you look like you're ready for this. I have something I'd like to ask you for help. Are you willing to listen?");
- if(status == 1)
- qm.sendNext("What happened is that the #bKingdom of Mushroom#k is currently in disarray. Kingdom of Mushroom is located near Henesys, featuring the peace-loving, intelligent King Mush. Recently, he began to feel ill, so he decided to appoint his only daughter #bPrincess Violetta#k. Something must have happened since then for the kingdom to be in its current state.");
- if(status == 2)
- qm.sendNext("I am not aware of the exact details, but it's obvious something terrible had taken place, so I think it'll be better if you go there and assess the damage yourself. An explorer like you seem more than capable of saving Kingdom of Mushroom. I have just written you a #brecommendation letter#k, so I suggest you head over to Kingdom of Mushroom immediately and look for the #bHead Patrol Officer#k.\r\n\r\n#fUI/UIWindow.img/QuestIcon/4/0#\r\n#v4032375# #t4032375#");
- if(status == 3)
- qm.sendYesNo("By the way, do you know where Kingdom of Mushroom is located? It'll be okay if you can find your way there, but if you don't mind, I can take you straight to the entrance.");
- if(status == 4){
- qm.gainItem(4032375, 1);
- qm.forceStartQuest();
- qm.dispose();
- }
+ if (mode == -1) {
+ qm.dispose();
+ } else {
+ if(mode == 0 && type > 0) {
+ if (status != 3) {
+ qm.sendOk("Really? It's an urgent matter, so if you have some time, please see me.");
+ qm.dispose();
+ } else {
+ if (qm.canHold(4032375, 1)) {
+ qm.sendNext("Okay. In that case, I'll just give you the routes to the Kingdom of Mushroom. #bNear the west entrance of Henesys,#k you'll find an #bempty house#k. Enter the house, and turn left to enter#b#k. That's the entrance to the Kingdom of Mushroom. There's not much time!");
+ } else {
+ qm.sendOk("Please have a slot available in your Etc inventory.");
+ qm.dispose();
+ }
+ }
+
+ status++;
+ } else {
+ if (mode == 1)
+ status++;
+ else
+ status--;
+
+ if (status == 0) {
+ qm.sendAcceptDecline("Now that you have made the job advancement, you look like you're ready for this. I have something I'd like to ask you for help. Are you willing to listen?");
+ } else if (status == 1) {
+ qm.sendNext("What happened is that the #bKingdom of Mushroom#k is currently in disarray. Kingdom of Mushroom is located near Henesys, featuring the peace-loving, intelligent King Mush. Recently, he began to feel ill, so he decided to appoint his only daughter #bPrincess Violetta#k. Something must have happened since then for the kingdom to be in its current state.");
+ } else if (status == 2) {
+ qm.sendNext("I am not aware of the exact details, but it's obvious something terrible had taken place, so I think it'll be better if you go there and assess the damage yourself. An explorer like you seem more than capable of saving Kingdom of Mushroom. I have just written you a #brecommendation letter#k, so I suggest you head over to Kingdom of Mushroom immediately and look for the #bHead Patrol Officer#k.\r\n\r\n#fUI/UIWindow.img/QuestIcon/4/0#\r\n#v4032375# #t4032375#");
+ } else if (status == 3) {
+ qm.sendYesNo("By the way, do you know where Kingdom of Mushroom is located? It'll be okay if you can find your way there, but if you don't mind, I can take you straight to the entrance.");
+ } else if (status == 4) {
+ if (qm.canHold(4032375, 1)) {
+ if (!qm.haveItem(4032375, 1)) {
+ qm.gainItem(4032375, 1);
+ }
+
+ qm.warp(106020000, 0);
+ qm.forceStartQuest();
+ } else {
+ qm.sendOk("Please have a slot available in your Etc inventory.");
+ }
+
+ qm.dispose();
+ return;
+ } else if (status == 5) {
+ if (!qm.haveItem(4032375, 1)) {
+ qm.gainItem(4032375, 1);
+ }
+
+ qm.forceStartQuest();
+ qm.dispose();
+ return;
+ }
+ }
+ }
}
function end(mode, type, selection) {
- status++;
- if (mode != 1) {
- if(type == 1 && mode == 0)
- status -= 2;
- else{
- qm.dispose();
- return;
- }
- }
- if(status == 0)
- qm.sendNext("Hmmm? Is that a #brecommendation letter from the job instructor#k??! What is this, are you the one that came to save us, the Kingdom of Mushroom?");
- if(status == 1)
- qm.sendNextPrev("Hmmm... okay. Since the letter is from the job instructor, I suppose you are really the one. I apologize for not introducing myself to you earlier. I'm the #bHead Security Officer#k in charge of protecting King Mush. As you can see, this temporary hideout is protected by the team of security and soldiers. Our situation may be dire, but nevertheless, welcome to Kingdom of Mushroom.");
- if(status == 2){
- qm.forceCompleteQuest();
- qm.gainItem(4032375, -1);
- qm.forceStartQuest(2312);
- qm.dispose();
- }
-}
+ if (mode == -1) {
+ qm.dispose();
+ } else {
+ if(mode == 0 && type > 0) {
+ qm.dispose();
+ return;
+ }
+
+ if (mode == 1)
+ status++;
+ else
+ status--;
+
+ if (status == 0) {
+ if (!qm.haveItem(4032375, 1)) {
+ qm.sendNext("What do you want, hmmm?");
+ qm.dispose();
+ return;
+ }
+
+ qm.sendNext("Hmmm? Is that a #brecommendation letter from the job instructor#k??! What is this, are you the one that came to save us, the Kingdom of Mushroom?");
+ } else if (status == 1) {
+ qm.sendNextPrev("Hmmm... okay. Since the letter is from the job instructor, I suppose you are really the one. I apologize for not introducing myself to you earlier. I'm the #bHead Security Officer#k in charge of protecting King Mush. As you can see, this temporary hideout is protected by the team of security and soldiers. Our situation may be dire, but nevertheless, welcome to Kingdom of Mushroom.");
+ } else if (status == 2) {
+ qm.gainItem(4032375, -1);
+ qm.gainExp(6000);
+ qm.forceCompleteQuest();
+ qm.forceStartQuest(2312);
+ qm.dispose();
+ }
+ }
+}
\ No newline at end of file
diff --git a/scripts/quest/2308.js b/scripts/quest/2308.js
index 244a97bc18..9efd61d7f4 100644
--- a/scripts/quest/2308.js
+++ b/scripts/quest/2308.js
@@ -4,61 +4,101 @@
Description: Quest - Kingdom of Mushroom in Danger
=============================================================
Version 1.0 - Script Done.(17/7/2010)
+Version 2.0 - Script Reworked by Ronan.(16/11/2018)
=============================================================
*/
var status = -1;
function start(mode, type, selection) {
- status++;
- if (mode != 1) {
- if(type == 1 && mode == 0)
- status -= 2;
- else{
- //if(status == 0){
- qm.sendOk("Really? It's an urgent matter, so if you have some time, please see me.");
- qm.dispose();
- return;
- //} else if(status == 3){
- //qm.sendNext("Okay. In that case, I'll just give you the routes to the Kingdom of Mushroom. #bNear the west entrance of Henesys,#k you'll find an #bempty house#k. Enter the house, and turn left to enter#b#k. That's the entrance to the Kingdom of Mushroom. There's not much time!");
- //qm.forceStartQuest();
- //return;
- }
- }
- //}
- if(status == 0)
- qm.sendAcceptDecline("Now that you have made the job advancement, you look like you're ready for this. I have something I'd like to ask you for help. Are you willing to listen?");
- if(status == 1)
- qm.sendNext("What happened is that the #bKingdom of Mushroom#k is currently in disarray. Kingdom of Mushroom is located near Henesys, featuring the peace-loving, intelligent King Mush. Recently, he began to feel ill, so he decided to appoint his only daughter #bPrincess Violetta#k. Something must have happened since then for the kingdom to be in its current state.");
- if(status == 2)
- qm.sendNext("I am not aware of the exact details, but it's obvious something terrible had taken place, so I think it'll be better if you go there and assess the damage yourself. An explorer like you seem more than capable of saving Kingdom of Mushroom. I have just written you a #brecommendation letter#k, so I suggest you head over to Kingdom of Mushroom immediately and look for the #bHead Patrol Officer#k.\r\n\r\n#fUI/UIWindow.img/QuestIcon/4/0#\r\n#v4032375# #t4032375#");
- if(status == 3)
- qm.sendYesNo("By the way, do you know where Kingdom of Mushroom is located? It'll be okay if you can find your way there, but if you don't mind, I can take you straight to the entrance.");
- if(status == 4){
- qm.gainItem(4032375, 1);
- qm.forceStartQuest();
- qm.dispose();
- }
+ if (mode == -1) {
+ qm.dispose();
+ } else {
+ if(mode == 0 && type > 0) {
+ if (status != 3) {
+ qm.sendOk("Really? It's an urgent matter, so if you have some time, please see me.");
+ qm.dispose();
+ } else {
+ if (qm.canHold(4032375, 1)) {
+ qm.sendNext("Okay. In that case, I'll just give you the routes to the Kingdom of Mushroom. #bNear the west entrance of Henesys,#k you'll find an #bempty house#k. Enter the house, and turn left to enter#b#k. That's the entrance to the Kingdom of Mushroom. There's not much time!");
+ } else {
+ qm.sendOk("Please have a slot available in your Etc inventory.");
+ qm.dispose();
+ }
+ }
+
+ status++;
+ } else {
+ if (mode == 1)
+ status++;
+ else
+ status--;
+
+ if (status == 0) {
+ qm.sendAcceptDecline("Now that you have made the job advancement, you look like you're ready for this. I have something I'd like to ask you for help. Are you willing to listen?");
+ } else if (status == 1) {
+ qm.sendNext("What happened is that the #bKingdom of Mushroom#k is currently in disarray. Kingdom of Mushroom is located near Henesys, featuring the peace-loving, intelligent King Mush. Recently, he began to feel ill, so he decided to appoint his only daughter #bPrincess Violetta#k. Something must have happened since then for the kingdom to be in its current state.");
+ } else if (status == 2) {
+ qm.sendNext("I am not aware of the exact details, but it's obvious something terrible had taken place, so I think it'll be better if you go there and assess the damage yourself. An explorer like you seem more than capable of saving Kingdom of Mushroom. I have just written you a #brecommendation letter#k, so I suggest you head over to Kingdom of Mushroom immediately and look for the #bHead Patrol Officer#k.\r\n\r\n#fUI/UIWindow.img/QuestIcon/4/0#\r\n#v4032375# #t4032375#");
+ } else if (status == 3) {
+ qm.sendYesNo("By the way, do you know where Kingdom of Mushroom is located? It'll be okay if you can find your way there, but if you don't mind, I can take you straight to the entrance.");
+ } else if (status == 4) {
+ if (qm.canHold(4032375, 1)) {
+ if (!qm.haveItem(4032375, 1)) {
+ qm.gainItem(4032375, 1);
+ }
+
+ qm.warp(106020000, 0);
+ qm.forceStartQuest();
+ } else {
+ qm.sendOk("Please have a slot available in your Etc inventory.");
+ }
+
+ qm.dispose();
+ return;
+ } else if (status == 5) {
+ if (!qm.haveItem(4032375, 1)) {
+ qm.gainItem(4032375, 1);
+ }
+
+ qm.forceStartQuest();
+ qm.dispose();
+ return;
+ }
+ }
+ }
}
function end(mode, type, selection) {
- status++;
- if (mode != 1) {
- if(type == 1 && mode == 0)
- status -= 2;
- else{
- qm.dispose();
- return;
- }
- }
- if(status == 0)
- qm.sendNext("Hmmm? Is that a #brecommendation letter from the job instructor#k??! What is this, are you the one that came to save us, the Kingdom of Mushroom?");
- if(status == 1)
- qm.sendNextPrev("Hmmm... okay. Since the letter is from the job instructor, I suppose you are really the one. I apologize for not introducing myself to you earlier. I'm the #bHead Security Officer#k in charge of protecting King Mush. As you can see, this temporary hideout is protected by the team of security and soldiers. Our situation may be dire, but nevertheless, welcome to Kingdom of Mushroom.");
- if(status == 2){
- qm.forceCompleteQuest();
- qm.gainItem(4032375, -1);
- qm.forceStartQuest(2312);
- qm.dispose();
- }
-}
+ if (mode == -1) {
+ qm.dispose();
+ } else {
+ if(mode == 0 && type > 0) {
+ qm.dispose();
+ return;
+ }
+
+ if (mode == 1)
+ status++;
+ else
+ status--;
+
+ if (status == 0) {
+ if (!qm.haveItem(4032375, 1)) {
+ qm.sendNext("What do you want, hmmm?");
+ qm.dispose();
+ return;
+ }
+
+ qm.sendNext("Hmmm? Is that a #brecommendation letter from the job instructor#k??! What is this, are you the one that came to save us, the Kingdom of Mushroom?");
+ } else if (status == 1) {
+ qm.sendNextPrev("Hmmm... okay. Since the letter is from the job instructor, I suppose you are really the one. I apologize for not introducing myself to you earlier. I'm the #bHead Security Officer#k in charge of protecting King Mush. As you can see, this temporary hideout is protected by the team of security and soldiers. Our situation may be dire, but nevertheless, welcome to Kingdom of Mushroom.");
+ } else if (status == 2) {
+ qm.gainItem(4032375, -1);
+ qm.gainExp(6000);
+ qm.forceCompleteQuest();
+ qm.forceStartQuest(2312);
+ qm.dispose();
+ }
+ }
+}
\ No newline at end of file
diff --git a/scripts/quest/2309.js b/scripts/quest/2309.js
index 244a97bc18..9efd61d7f4 100644
--- a/scripts/quest/2309.js
+++ b/scripts/quest/2309.js
@@ -4,61 +4,101 @@
Description: Quest - Kingdom of Mushroom in Danger
=============================================================
Version 1.0 - Script Done.(17/7/2010)
+Version 2.0 - Script Reworked by Ronan.(16/11/2018)
=============================================================
*/
var status = -1;
function start(mode, type, selection) {
- status++;
- if (mode != 1) {
- if(type == 1 && mode == 0)
- status -= 2;
- else{
- //if(status == 0){
- qm.sendOk("Really? It's an urgent matter, so if you have some time, please see me.");
- qm.dispose();
- return;
- //} else if(status == 3){
- //qm.sendNext("Okay. In that case, I'll just give you the routes to the Kingdom of Mushroom. #bNear the west entrance of Henesys,#k you'll find an #bempty house#k. Enter the house, and turn left to enter#b#k. That's the entrance to the Kingdom of Mushroom. There's not much time!");
- //qm.forceStartQuest();
- //return;
- }
- }
- //}
- if(status == 0)
- qm.sendAcceptDecline("Now that you have made the job advancement, you look like you're ready for this. I have something I'd like to ask you for help. Are you willing to listen?");
- if(status == 1)
- qm.sendNext("What happened is that the #bKingdom of Mushroom#k is currently in disarray. Kingdom of Mushroom is located near Henesys, featuring the peace-loving, intelligent King Mush. Recently, he began to feel ill, so he decided to appoint his only daughter #bPrincess Violetta#k. Something must have happened since then for the kingdom to be in its current state.");
- if(status == 2)
- qm.sendNext("I am not aware of the exact details, but it's obvious something terrible had taken place, so I think it'll be better if you go there and assess the damage yourself. An explorer like you seem more than capable of saving Kingdom of Mushroom. I have just written you a #brecommendation letter#k, so I suggest you head over to Kingdom of Mushroom immediately and look for the #bHead Patrol Officer#k.\r\n\r\n#fUI/UIWindow.img/QuestIcon/4/0#\r\n#v4032375# #t4032375#");
- if(status == 3)
- qm.sendYesNo("By the way, do you know where Kingdom of Mushroom is located? It'll be okay if you can find your way there, but if you don't mind, I can take you straight to the entrance.");
- if(status == 4){
- qm.gainItem(4032375, 1);
- qm.forceStartQuest();
- qm.dispose();
- }
+ if (mode == -1) {
+ qm.dispose();
+ } else {
+ if(mode == 0 && type > 0) {
+ if (status != 3) {
+ qm.sendOk("Really? It's an urgent matter, so if you have some time, please see me.");
+ qm.dispose();
+ } else {
+ if (qm.canHold(4032375, 1)) {
+ qm.sendNext("Okay. In that case, I'll just give you the routes to the Kingdom of Mushroom. #bNear the west entrance of Henesys,#k you'll find an #bempty house#k. Enter the house, and turn left to enter#b#k. That's the entrance to the Kingdom of Mushroom. There's not much time!");
+ } else {
+ qm.sendOk("Please have a slot available in your Etc inventory.");
+ qm.dispose();
+ }
+ }
+
+ status++;
+ } else {
+ if (mode == 1)
+ status++;
+ else
+ status--;
+
+ if (status == 0) {
+ qm.sendAcceptDecline("Now that you have made the job advancement, you look like you're ready for this. I have something I'd like to ask you for help. Are you willing to listen?");
+ } else if (status == 1) {
+ qm.sendNext("What happened is that the #bKingdom of Mushroom#k is currently in disarray. Kingdom of Mushroom is located near Henesys, featuring the peace-loving, intelligent King Mush. Recently, he began to feel ill, so he decided to appoint his only daughter #bPrincess Violetta#k. Something must have happened since then for the kingdom to be in its current state.");
+ } else if (status == 2) {
+ qm.sendNext("I am not aware of the exact details, but it's obvious something terrible had taken place, so I think it'll be better if you go there and assess the damage yourself. An explorer like you seem more than capable of saving Kingdom of Mushroom. I have just written you a #brecommendation letter#k, so I suggest you head over to Kingdom of Mushroom immediately and look for the #bHead Patrol Officer#k.\r\n\r\n#fUI/UIWindow.img/QuestIcon/4/0#\r\n#v4032375# #t4032375#");
+ } else if (status == 3) {
+ qm.sendYesNo("By the way, do you know where Kingdom of Mushroom is located? It'll be okay if you can find your way there, but if you don't mind, I can take you straight to the entrance.");
+ } else if (status == 4) {
+ if (qm.canHold(4032375, 1)) {
+ if (!qm.haveItem(4032375, 1)) {
+ qm.gainItem(4032375, 1);
+ }
+
+ qm.warp(106020000, 0);
+ qm.forceStartQuest();
+ } else {
+ qm.sendOk("Please have a slot available in your Etc inventory.");
+ }
+
+ qm.dispose();
+ return;
+ } else if (status == 5) {
+ if (!qm.haveItem(4032375, 1)) {
+ qm.gainItem(4032375, 1);
+ }
+
+ qm.forceStartQuest();
+ qm.dispose();
+ return;
+ }
+ }
+ }
}
function end(mode, type, selection) {
- status++;
- if (mode != 1) {
- if(type == 1 && mode == 0)
- status -= 2;
- else{
- qm.dispose();
- return;
- }
- }
- if(status == 0)
- qm.sendNext("Hmmm? Is that a #brecommendation letter from the job instructor#k??! What is this, are you the one that came to save us, the Kingdom of Mushroom?");
- if(status == 1)
- qm.sendNextPrev("Hmmm... okay. Since the letter is from the job instructor, I suppose you are really the one. I apologize for not introducing myself to you earlier. I'm the #bHead Security Officer#k in charge of protecting King Mush. As you can see, this temporary hideout is protected by the team of security and soldiers. Our situation may be dire, but nevertheless, welcome to Kingdom of Mushroom.");
- if(status == 2){
- qm.forceCompleteQuest();
- qm.gainItem(4032375, -1);
- qm.forceStartQuest(2312);
- qm.dispose();
- }
-}
+ if (mode == -1) {
+ qm.dispose();
+ } else {
+ if(mode == 0 && type > 0) {
+ qm.dispose();
+ return;
+ }
+
+ if (mode == 1)
+ status++;
+ else
+ status--;
+
+ if (status == 0) {
+ if (!qm.haveItem(4032375, 1)) {
+ qm.sendNext("What do you want, hmmm?");
+ qm.dispose();
+ return;
+ }
+
+ qm.sendNext("Hmmm? Is that a #brecommendation letter from the job instructor#k??! What is this, are you the one that came to save us, the Kingdom of Mushroom?");
+ } else if (status == 1) {
+ qm.sendNextPrev("Hmmm... okay. Since the letter is from the job instructor, I suppose you are really the one. I apologize for not introducing myself to you earlier. I'm the #bHead Security Officer#k in charge of protecting King Mush. As you can see, this temporary hideout is protected by the team of security and soldiers. Our situation may be dire, but nevertheless, welcome to Kingdom of Mushroom.");
+ } else if (status == 2) {
+ qm.gainItem(4032375, -1);
+ qm.gainExp(6000);
+ qm.forceCompleteQuest();
+ qm.forceStartQuest(2312);
+ qm.dispose();
+ }
+ }
+}
\ No newline at end of file
diff --git a/scripts/quest/2310.js b/scripts/quest/2310.js
index 295d1776a2..9efd61d7f4 100644
--- a/scripts/quest/2310.js
+++ b/scripts/quest/2310.js
@@ -4,61 +4,101 @@
Description: Quest - Kingdom of Mushroom in Danger
=============================================================
Version 1.0 - Script Done.(17/7/2010)
+Version 2.0 - Script Reworked by Ronan.(16/11/2018)
=============================================================
*/
var status = -1;
function start(mode, type, selection) {
- status++;
- if (mode != 1) {
- if(type == 1 && mode == 0)
- status -= 2;
- else {
- //if(status == 0){
- qm.sendOk("Really? It's an urgent matter, so if you have some time, please see me.");
- qm.dispose();
- return;
- //} else if(status == 3){
- //qm.sendNext("Okay. In that case, I'll just give you the routes to the Kingdom of Mushroom. #bNear the west entrance of Henesys,#k you'll find an #bempty house#k. Enter the house, and turn left to enter#b#k. That's the entrance to the Kingdom of Mushroom. There's not much time!");
- //qm.forceStartQuest();
- //return;
+ if (mode == -1) {
+ qm.dispose();
+ } else {
+ if(mode == 0 && type > 0) {
+ if (status != 3) {
+ qm.sendOk("Really? It's an urgent matter, so if you have some time, please see me.");
+ qm.dispose();
+ } else {
+ if (qm.canHold(4032375, 1)) {
+ qm.sendNext("Okay. In that case, I'll just give you the routes to the Kingdom of Mushroom. #bNear the west entrance of Henesys,#k you'll find an #bempty house#k. Enter the house, and turn left to enter#b#k. That's the entrance to the Kingdom of Mushroom. There's not much time!");
+ } else {
+ qm.sendOk("Please have a slot available in your Etc inventory.");
+ qm.dispose();
}
+ }
+
+ status++;
+ } else {
+ if (mode == 1)
+ status++;
+ else
+ status--;
+
+ if (status == 0) {
+ qm.sendAcceptDecline("Now that you have made the job advancement, you look like you're ready for this. I have something I'd like to ask you for help. Are you willing to listen?");
+ } else if (status == 1) {
+ qm.sendNext("What happened is that the #bKingdom of Mushroom#k is currently in disarray. Kingdom of Mushroom is located near Henesys, featuring the peace-loving, intelligent King Mush. Recently, he began to feel ill, so he decided to appoint his only daughter #bPrincess Violetta#k. Something must have happened since then for the kingdom to be in its current state.");
+ } else if (status == 2) {
+ qm.sendNext("I am not aware of the exact details, but it's obvious something terrible had taken place, so I think it'll be better if you go there and assess the damage yourself. An explorer like you seem more than capable of saving Kingdom of Mushroom. I have just written you a #brecommendation letter#k, so I suggest you head over to Kingdom of Mushroom immediately and look for the #bHead Patrol Officer#k.\r\n\r\n#fUI/UIWindow.img/QuestIcon/4/0#\r\n#v4032375# #t4032375#");
+ } else if (status == 3) {
+ qm.sendYesNo("By the way, do you know where Kingdom of Mushroom is located? It'll be okay if you can find your way there, but if you don't mind, I can take you straight to the entrance.");
+ } else if (status == 4) {
+ if (qm.canHold(4032375, 1)) {
+ if (!qm.haveItem(4032375, 1)) {
+ qm.gainItem(4032375, 1);
+ }
+
+ qm.warp(106020000, 0);
+ qm.forceStartQuest();
+ } else {
+ qm.sendOk("Please have a slot available in your Etc inventory.");
+ }
+
+ qm.dispose();
+ return;
+ } else if (status == 5) {
+ if (!qm.haveItem(4032375, 1)) {
+ qm.gainItem(4032375, 1);
+ }
+
+ qm.forceStartQuest();
+ qm.dispose();
+ return;
+ }
}
- //}
- if(status == 0)
- qm.sendAcceptDecline("Now that you have made the job advancement, you look like you're ready for this. I have something I'd like to ask you for help. Are you willing to listen?");
- if(status == 1)
- qm.sendNext("What happened is that the #bKingdom of Mushroom#k is currently in disarray. Kingdom of Mushroom is located near Henesys, featuring the peace-loving, intelligent King Mush. Recently, he began to feel ill, so he decided to appoint his only daughter #bPrincess Violetta#k. Something must have happened since then for the kingdom to be in its current state.");
- if(status == 2)
- qm.sendNext("I am not aware of the exact details, but it's obvious something terrible had taken place, so I think it'll be better if you go there and assess the damage yourself. An explorer like you seem more than capable of saving Kingdom of Mushroom. I have just written you a #brecommendation letter#k, so I suggest you head over to Kingdom of Mushroom immediately and look for the #bHead Patrol Officer#k.\r\n\r\n#fUI/UIWindow.img/QuestIcon/4/0#\r\n#v4032375# #t4032375#");
- if(status == 3)
- qm.sendYesNo("By the way, do you know where Kingdom of Mushroom is located? It'll be okay if you can find your way there, but if you don't mind, I can take you straight to the entrance.");
- if(status == 4){
- qm.gainItem(4032375, 1);
- qm.forceStartQuest();
- qm.dispose();
- }
+ }
}
function end(mode, type, selection) {
- status++;
- if (mode != 1) {
- if(type == 1 && mode == 0)
- status -= 2;
- else{
- qm.dispose();
- return;
- }
- }
- if(status == 0)
- qm.sendNext("Hmmm? Is that a #brecommendation letter from the job instructor#k??! What is this, are you the one that came to save us, the Kingdom of Mushroom?");
- if(status == 1)
- qm.sendNextPrev("Hmmm... okay. Since the letter is from the job instructor, I suppose you are really the one. I apologize for not introducing myself to you earlier. I'm the #bHead Security Officer#k in charge of protecting King Mush. As you can see, this temporary hideout is protected by the team of security and soldiers. Our situation may be dire, but nevertheless, welcome to Kingdom of Mushroom.");
- if(status == 2){
- qm.forceCompleteQuest();
- qm.gainItem(4032375, -1);
- qm.forceStartQuest(2312);
- qm.dispose();
- }
+ if (mode == -1) {
+ qm.dispose();
+ } else {
+ if(mode == 0 && type > 0) {
+ qm.dispose();
+ return;
+ }
+
+ if (mode == 1)
+ status++;
+ else
+ status--;
+
+ if (status == 0) {
+ if (!qm.haveItem(4032375, 1)) {
+ qm.sendNext("What do you want, hmmm?");
+ qm.dispose();
+ return;
+ }
+
+ qm.sendNext("Hmmm? Is that a #brecommendation letter from the job instructor#k??! What is this, are you the one that came to save us, the Kingdom of Mushroom?");
+ } else if (status == 1) {
+ qm.sendNextPrev("Hmmm... okay. Since the letter is from the job instructor, I suppose you are really the one. I apologize for not introducing myself to you earlier. I'm the #bHead Security Officer#k in charge of protecting King Mush. As you can see, this temporary hideout is protected by the team of security and soldiers. Our situation may be dire, but nevertheless, welcome to Kingdom of Mushroom.");
+ } else if (status == 2) {
+ qm.gainItem(4032375, -1);
+ qm.gainExp(6000);
+ qm.forceCompleteQuest();
+ qm.forceStartQuest(2312);
+ qm.dispose();
+ }
+ }
}
\ No newline at end of file
diff --git a/scripts/quest/6410.js b/scripts/quest/6410.js
new file mode 100644
index 0000000000..cf9ae4054a
--- /dev/null
+++ b/scripts/quest/6410.js
@@ -0,0 +1,57 @@
+/*
+ This file is part of the HeavenMS MapleStory Server
+ Copyleft (L) 2016 - 2018 RonanLana
+
+ This program is free software: you can redistribute it and/or modify
+ it under the terms of the GNU Affero General Public License as
+ published by the Free Software Foundation version 3 as published by
+ the Free Software Foundation. You may not use, modify or distribute
+ this program under any other version of the GNU Affero General Public
+ License.
+
+ 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 Affero General Public License for more details.
+
+ You should have received a copy of the GNU Affero General Public License
+ along with this program. If not, see .
+*/
+/*
+ Hypnotize skill quest
+ */
+
+var status = -1;
+
+function end(mode, type, selection) {
+ if (mode == -1) {
+ qm.dispose();
+ } else {
+ if(mode == 0 && type > 0) {
+ qm.dispose();
+ return;
+ }
+
+ if (mode == 1)
+ status++;
+ else
+ status--;
+
+ if (status == 0) {
+ if (qm.getQuestProgress(6410, 0) == 0) {
+ qm.sendOk("You must save #r#p2095000##k first!");
+ qm.dispose();
+ } else {
+ qm.sendNext("Again, thank you so much for rescuing me. I don't know how to repay you for all this... both Shulynch and you are the nicest people I have encountered. If you approach the mobs the same way you approached me, they may all end up becoming friends with you, as well. Please never lose the kindness you have in you.");
+ }
+ } else if (status == 1) {
+ qm.sendNext("(Friends with the mobs... never lose the kindness.)\r\n\r\n #s5221009# #b#q5221009##k");
+ } else if (status == 2) {
+ qm.gainExp(1200000);
+ qm.teachSkill(5221009, 0, 10, -1);
+
+ qm.forceCompleteQuest();
+ qm.dispose();
+ }
+ }
+}
\ No newline at end of file
diff --git a/scripts/reactor/1200000.js b/scripts/reactor/1200000.js
new file mode 100644
index 0000000000..948fb8c383
--- /dev/null
+++ b/scripts/reactor/1200000.js
@@ -0,0 +1,29 @@
+/*
+ This file is part of the HeavenMS MapleStory Server
+ Copyleft (L) 2016 - 2018 RonanLana
+
+ This program is free software: you can redistribute it and/or modify
+ it under the terms of the GNU Affero General Public License as
+ published by the Free Software Foundation version 3 as published by
+ the Free Software Foundation. You may not use, modify or distribute
+ this program under any other version of the GNU Affero General Public
+ License.
+
+ 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 Affero General Public License for more details.
+
+ You should have received a copy of the GNU Affero General Public License
+ along with this program. If not, see .
+*/
+
+/* @Author Ronan
+ *
+ * 1200000.js: Bart reactor, Aerial Strike skill
+*/
+
+function act() { // string visibility thanks to ProXAIMeRx & Glvelturall
+ rm.message("Failed to find Bart. Returning to the original location.");
+ rm.warp(120000102);
+}
\ No newline at end of file
diff --git a/scripts/reactor/1209000.js b/scripts/reactor/1209000.js
new file mode 100644
index 0000000000..4f830d783f
--- /dev/null
+++ b/scripts/reactor/1209000.js
@@ -0,0 +1,29 @@
+/*
+ This file is part of the HeavenMS MapleStory Server
+ Copyleft (L) 2016 - 2018 RonanLana
+
+ This program is free software: you can redistribute it and/or modify
+ it under the terms of the GNU Affero General Public License as
+ published by the Free Software Foundation version 3 as published by
+ the Free Software Foundation. You may not use, modify or distribute
+ this program under any other version of the GNU Affero General Public
+ License.
+
+ 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 Affero General Public License for more details.
+
+ You should have received a copy of the GNU Affero General Public License
+ along with this program. If not, see .
+*/
+
+/* @Author Ronan
+ *
+ * 1200000.js: Bart reactor, Aerial Strike skill
+*/
+
+function act() { // string visibility thanks to ProXAIMeRx & Glvelturall
+ if (rm.isQuestStarted(6400)) rm.setQuestProgress(6400, 0, 2);
+ rm.message("Real Bart has found. Return to Jonathan through portal.");
+}
\ No newline at end of file
diff --git a/scripts/reactor/2001.js b/scripts/reactor/2001.js
index 713f23b1bc..b0262c7978 100644
--- a/scripts/reactor/2001.js
+++ b/scripts/reactor/2001.js
@@ -19,7 +19,7 @@
You should have received a copy of the GNU Affero General Public License
along with this program. If not, see .
*/
-/* @Author Lerk Hi :()
+/* @Author Lerk - Hi :()
*
* 2001.js: Maple Island Box - drops various items, notably quest items Old Wooden Board and Rusty Screw
*/
diff --git a/scripts/reactor/8098000.js b/scripts/reactor/8098000.js
index 231b5f174a..1e9927cf16 100644
--- a/scripts/reactor/8098000.js
+++ b/scripts/reactor/8098000.js
@@ -20,8 +20,8 @@
along with this program. If not, see .
*/
/*
- * @author RMZero213 (base)
- * @author Moogra (fixed, clean up)
+ * @author RMZero213 - base
+ * @author Moogra - fixed, clean up
*/
function act() {
var map = rm.getPlayer().getMapId();
diff --git a/sql/db_drops.sql b/sql/db_drops.sql
index 804a387284..afdd3df648 100644
--- a/sql/db_drops.sql
+++ b/sql/db_drops.sql
@@ -20300,7 +20300,8 @@ USE `heavenms`;
(6130102, 2022001, 1, 1, 0, 20000),
(6130103, 2022001, 1, 1, 0, 20000),
(6130200, 2022001, 1, 1, 0, 20000),
-(6130201, 2022001, 1, 1, 0, 20000);
+(6130201, 2022001, 1, 1, 0, 20000),
+(2220000, 1322001, 1, 1, 0, 8000);
# (dropperid, itemid, minqty, maxqty, questid, chance)
@@ -21534,7 +21535,7 @@ USE `heavenms`;
INSERT IGNORE INTO drop_data (`dropperid`, `itemid`, `minimum_quantity`, `maximum_quantity`, `questid`, `chance`)
SELECT 3000004, `itemid`, `minimum_quantity`, `maximum_quantity`, `questid`, `chance` FROM drop_data WHERE dropperid = 3000001;
- -- Thanks to DietStory dev team
+ -- Thanks to DietStory v1.02 dev team
-- There are two Jr. Boogies mob ids for some unknown reason. 3230301 had no drops, but 3230300 had all the correct drops.
-- Just copying the drops from the one with the correct drop data.
INSERT IGNORE INTO drop_data (`dropperid`, `itemid`, `minimum_quantity`, `maximum_quantity`, `questid`, `chance`)
diff --git a/sql/db_shopupdate.sql b/sql/db_shopupdate.sql
index de52860336..fbf4e67d08 100644
--- a/sql/db_shopupdate.sql
+++ b/sql/db_shopupdate.sql
@@ -165,10 +165,10 @@ INSERT IGNORE INTO `shopitems` (`shopid`, `itemid`, `price`, `pitch`, `position`
(9270065, 2030100, 450, 0, 3),
(9270022, 2030100, 450, 0, 118);
-# Thanks to Vcoc
-# GMShop: Sacks, GmEquip, Cheese & Onyx, Utils,
-# Arrows, Bullets, Throwings and Capsules,
-# Others, Equips, Mounts, Scrolls.
+-- Thanks to Vcoc
+-- GMShop: Sacks, GmEquip, Cheese & Onyx, Utils,
+-- Arrows, Bullets, Throwings and Capsules,
+-- Others, Equips, Mounts, Scrolls.
DELETE FROM `shopitems` WHERE `shopid`=1337;
INSERT INTO `shopitems` ( `shopid`, `itemid`, `price`, `position`) VALUES
@@ -258,7 +258,7 @@ INSERT INTO `shopitems` ( `shopid`, `itemid`, `price`, `position`) VALUES
(1337, 2210032, 1, 84),
(1337, 2050004, 1, 85);
-# Thanks to DietStory dev team
+-- Thanks to DietStory v1.02 dev team
INSERT INTO `shopitems` ( `shopid`, `itemid`, `price`, `pitch`, `position`) VALUES
(1200001, 3010001, 1000, 0, 1),
(1200001, 1092003, 2000, 0, 2),
diff --git a/src/client/MapleCharacter.java b/src/client/MapleCharacter.java
index 5f1f93ab9d..b1ec0630d8 100644
--- a/src/client/MapleCharacter.java
+++ b/src/client/MapleCharacter.java
@@ -192,7 +192,6 @@ public class MapleCharacter extends AbstractMapleCharacterObject {
private int mesosTraded = 0;
private int possibleReports = 10;
private int dojoPoints, vanquisherStage, dojoStage, dojoEnergy, vanquisherKills;
- private int warpToId;
private int expRate = 1, mesoRate = 1, dropRate = 1, expCoupon = 1, mesoCoupon = 1, dropCoupon = 1;
private int omokwins, omokties, omoklosses, matchcardwins, matchcardties, matchcardlosses;
private int owlSearch;
@@ -277,6 +276,7 @@ public class MapleCharacter extends AbstractMapleCharacterObject {
private Lock evtLock = MonitoredReentrantLockFactory.createLock(MonitoredLockType.CHARACTER_EVT, true);
private Lock petLock = MonitoredReentrantLockFactory.createLock(MonitoredLockType.CHARACTER_PET, true); // for meso & quest tasks as well
private Lock prtLock = MonitoredReentrantLockFactory.createLock(MonitoredLockType.CHARACTER_PRT);
+ private Lock cpnLock = MonitoredReentrantLockFactory.createLock(MonitoredLockType.CHARACTER_CPN);
private Map> excluded = new LinkedHashMap<>();
private Set excludedItems = new LinkedHashSet<>();
private static String[] ariantroomleader = new String[3];
@@ -1593,7 +1593,6 @@ public class MapleCharacter extends AbstractMapleCharacterObject {
map.addPlayer(this);
visitMap(map);
- silentPartyUpdateInternal(getParty()); // EIM script calls inside
prtLock.lock();
try {
if (party != null) {
@@ -1604,6 +1603,7 @@ public class MapleCharacter extends AbstractMapleCharacterObject {
} finally {
prtLock.unlock();
}
+ silentPartyUpdateInternal(getParty()); // EIM script calls inside
if (getMap().getHPDec() > 0) resetHpDecreaseTask();
} else {
@@ -3029,10 +3029,6 @@ public class MapleCharacter extends AbstractMapleCharacterObject {
return allianceRank;
}
- public int getAllowWarpToId() {
- return warpToId;
- }
-
public static String getAriantRoomLeaderName(int room) {
return ariantroomleader[room];
}
@@ -6064,8 +6060,23 @@ public class MapleCharacter extends AbstractMapleCharacterObject {
}
public void updateCouponRates() {
- revertCouponRates();
- setCouponRates();
+ if (cpnLock.tryLock()) {
+ MapleInventory cashInv = this.getInventory(MapleInventoryType.CASH);
+
+ effLock.lock();
+ chrLock.lock();
+ cashInv.lockInventory();
+ try {
+ revertCouponRates();
+ setCouponRates();
+ } finally {
+ cpnLock.unlock();
+
+ cashInv.unlockInventory();
+ chrLock.unlock();
+ effLock.unlock();
+ }
+ }
}
public void resetPlayerRates() {
@@ -8011,10 +8022,6 @@ public class MapleCharacter extends AbstractMapleCharacterObject {
}
}
- public void setAllowWarpToId(int id) {
- this.warpToId = id;
- }
-
public static void setAriantRoomLeader(int room, String charname) {
ariantroomleader[room] = charname;
}
diff --git a/src/client/MapleClient.java b/src/client/MapleClient.java
index 341577b9f5..b6c3c4108a 100644
--- a/src/client/MapleClient.java
+++ b/src/client/MapleClient.java
@@ -850,7 +850,7 @@ public class MapleClient {
}
}
- private void removePlayer(World wserv) {
+ private void removePlayer(World wserv, boolean serverTransition) {
try {
player.setDisconnectedFromChannelWorld();
player.notifyMapTransferToPartner(-1);
@@ -859,12 +859,14 @@ public class MapleClient {
player.closePlayerInteractions();
QuestScriptManager.getInstance().dispose(this);
- removePartyPlayer(wserv);
-
- EventInstanceManager eim = player.getEventInstance();
- if (eim != null) {
- eim.playerDisconnected(player);
- }
+ if (!serverTransition) { // thanks MedicOP for detecting an issue with party leader change on changing channels
+ removePartyPlayer(wserv);
+
+ EventInstanceManager eim = player.getEventInstance();
+ if (eim != null) {
+ eim.playerDisconnected(player);
+ }
+ }
if (player.getMap() != null) {
int mapId = player.getMapId();
@@ -918,7 +920,7 @@ public class MapleClient {
final World wserv = getWorldServer(); // obviously wserv is NOT null if this player was online on it
try {
- removePlayer(wserv);
+ removePlayer(wserv, this.serverTransition);
if (!(channel == -1 || shutdown)) {
if (!cashshop) {
diff --git a/src/client/MapleFamily.java b/src/client/MapleFamily.java
index 903c06b77e..51eb441159 100644
--- a/src/client/MapleFamily.java
+++ b/src/client/MapleFamily.java
@@ -31,7 +31,7 @@ import tools.DatabaseConnection;
/**
*
- * @author Jay Estrella :3 (Mr.Trash)
+ * @author Jay Estrella - Mr.Trash :3
*/
public class MapleFamily {
private static int id;
diff --git a/src/client/command/CommandsExecutor.java b/src/client/command/CommandsExecutor.java
index a762f25b3a..5b167d65f3 100644
--- a/src/client/command/CommandsExecutor.java
+++ b/src/client/command/CommandsExecutor.java
@@ -331,6 +331,7 @@ public class CommandsExecutor {
addCommand("debug", 5, DebugCommand.class);
addCommand("set", 5, SetCommand.class);
addCommand("showpackets", 5, ShowPacketsCommand.class);
+ addCommand("showmovelife", 5, ShowMoveLifeCommand.class);
commandsNameDesc.add(levelCommandsCursor);
}
diff --git a/src/client/command/commands/gm1/GotoCommand.java b/src/client/command/commands/gm1/GotoCommand.java
index 1c93a3207d..845dead6a4 100644
--- a/src/client/command/commands/gm1/GotoCommand.java
+++ b/src/client/command/commands/gm1/GotoCommand.java
@@ -48,13 +48,12 @@ public class GotoCommand extends Command {
}
if (gotomaps.containsKey(params[0])) {
MapleMap target = c.getChannelServer().getMapFactory().getMap(gotomaps.get(params[0]));
- MaplePortal targetPortal = target.getPortal(0);
- if (player.getEventInstance() != null) {
- player.getEventInstance().removePlayer(player);
- }
+
+ // expedition issue with this command detected thanks to Masterrulax
+ MaplePortal targetPortal = target.getRandomPlayerSpawnpoint();
player.changeMap(target, targetPortal);
} else {
- player.dropMessage(5, "That map does not exist.");
+ player.dropMessage(5, "Area '" + params[0] + "' is not registered.");
}
}
}
diff --git a/src/client/command/commands/gm2/WarpCommand.java b/src/client/command/commands/gm2/WarpCommand.java
index e3eaef060e..6e123bcc50 100644
--- a/src/client/command/commands/gm2/WarpCommand.java
+++ b/src/client/command/commands/gm2/WarpCommand.java
@@ -47,9 +47,8 @@ public class WarpCommand extends Command {
player.yellowMessage("Map ID " + params[0] + " is invalid.");
return;
}
- if (player.getEventInstance() != null) {
- player.getEventInstance().leftParty(player);
- }
+
+ // expedition issue with this command detected thanks to Masterrulax
player.changeMap(target, target.getRandomPlayerSpawnpoint());
} catch (Exception ex) {
player.yellowMessage("Map ID " + params[0] + " is invalid.");
diff --git a/src/client/command/commands/gm5/ShowMoveLifeCommand.java b/src/client/command/commands/gm5/ShowMoveLifeCommand.java
new file mode 100644
index 0000000000..291c1f63ab
--- /dev/null
+++ b/src/client/command/commands/gm5/ShowMoveLifeCommand.java
@@ -0,0 +1,39 @@
+/*
+ This file is part of the HeavenMS MapleStory Server, commands OdinMS-based
+ Copyleft (L) 2016 - 2018 RonanLana
+
+ This program is free software: you can redistribute it and/or modify
+ it under the terms of the GNU Affero General Public License as
+ published by the Free Software Foundation version 3 as published by
+ the Free Software Foundation. You may not use, modify or distribute
+ this program under any other version of the GNU Affero General Public
+ License.
+
+ 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 Affero General Public License for more details.
+
+ You should have received a copy of the GNU Affero General Public License
+ along with this program. If not, see .
+*/
+
+/*
+ @Author: Arthur L - Refactored command content into modules
+*/
+package client.command.commands.gm5;
+
+import client.command.Command;
+import client.MapleClient;
+import constants.ServerConstants;
+
+public class ShowMoveLifeCommand extends Command {
+ {
+ setDescription("");
+ }
+
+ @Override
+ public void execute(MapleClient c, String[] params) {
+ ServerConstants.USE_DEBUG_SHOW_RCVD_MVLIFE = !ServerConstants.USE_DEBUG_SHOW_RCVD_MVLIFE;
+ }
+}
diff --git a/src/client/inventory/Equip.java b/src/client/inventory/Equip.java
index 2959774f18..6b6824852b 100644
--- a/src/client/inventory/Equip.java
+++ b/src/client/inventory/Equip.java
@@ -487,20 +487,22 @@ public class Equip extends Item {
String lvupStr = "'" + MapleItemInformationProvider.getInstance().getName(this.getItemId()) + "' is now level " + itemLevel + "! ";
String showStr = "#e'" + MapleItemInformationProvider.getInstance().getName(this.getItemId()) + "'#b is now #elevel #r" + itemLevel + "#k#b!";
- Pair> res = gainStats(stats);
+ Pair> res = this.gainStats(stats);
lvupStr += res.getLeft();
boolean gotSlot = res.getRight().getLeft();
boolean gotVicious = res.getRight().getRight();
- if(gotVicious) {
+ if (gotVicious) {
//c.getPlayer().dropMessage(6, "A new Vicious Hammer opportunity has been found on the '" + MapleItemInformationProvider.getInstance().getName(getItemId()) + "'!");
lvupStr += "+VICIOUS ";
}
- if(gotSlot) {
+ if (gotSlot) {
//c.getPlayer().dropMessage(6, "A new upgrade slot has been found on the '" + MapleItemInformationProvider.getInstance().getName(getItemId()) + "'!");
lvupStr += "+UPGSLOT ";
}
+ c.getPlayer().equipChanged();
+
showLevelupMessage(showStr, c); // thanks to Polaris dev team !
c.getPlayer().dropMessage(6, lvupStr);
diff --git a/src/client/inventory/MapleInventory.java b/src/client/inventory/MapleInventory.java
index 457c3d2568..3ebb08e710 100644
--- a/src/client/inventory/MapleInventory.java
+++ b/src/client/inventory/MapleInventory.java
@@ -42,6 +42,7 @@ import server.MapleItemInformationProvider;
import client.inventory.manipulator.MapleInventoryManipulator;
import tools.FilePrinter;
import net.server.audit.locks.MonitoredLockType;
+import server.ThreadManager;
/**
*
@@ -320,7 +321,12 @@ public class MapleInventory implements Iterable- {
}
if (ItemConstants.isRateCoupon(item.getItemId())) {
- owner.updateCouponRates();
+ ThreadManager.getInstance().newTask(new Runnable() { // deadlocks with coupons rates found thanks to GabrielSin & Masterrulax
+ @Override
+ public void run() {
+ owner.updateCouponRates();
+ }
+ });
}
return slotId;
@@ -335,7 +341,12 @@ public class MapleInventory implements Iterable
- {
}
if (ItemConstants.isRateCoupon(item.getItemId())) {
- owner.updateCouponRates();
+ ThreadManager.getInstance().newTask(new Runnable() {
+ @Override
+ public void run() {
+ owner.updateCouponRates();
+ }
+ });
}
}
@@ -349,7 +360,12 @@ public class MapleInventory implements Iterable
- {
}
if (item != null && ItemConstants.isRateCoupon(item.getItemId())) {
- owner.updateCouponRates();
+ ThreadManager.getInstance().newTask(new Runnable() {
+ @Override
+ public void run() {
+ owner.updateCouponRates();
+ }
+ });
}
}
diff --git a/src/client/inventory/manipulator/MapleInventoryManipulator.java b/src/client/inventory/manipulator/MapleInventoryManipulator.java
index c70d133bfb..4e4bdd0c06 100644
--- a/src/client/inventory/manipulator/MapleInventoryManipulator.java
+++ b/src/client/inventory/manipulator/MapleInventoryManipulator.java
@@ -47,7 +47,7 @@ import tools.MaplePacketCreator;
/**
*
* @author Matze
- * @author Ronan (improved check space feature & removed redundant object calls)
+ * @author Ronan - improved check space feature & removed redundant object calls
*/
public class MapleInventoryManipulator {
diff --git a/src/client/newyear/NewYearCardRecord.java b/src/client/newyear/NewYearCardRecord.java
index 987c5ceb78..676b94ef96 100644
--- a/src/client/newyear/NewYearCardRecord.java
+++ b/src/client/newyear/NewYearCardRecord.java
@@ -35,7 +35,7 @@ import tools.MaplePacketCreator;
/**
*
- * @author Ronan (credits to Eric for showing the New Year opcodes and handler layout)
+ * @author Ronan - credits to Eric for showing the New Year opcodes and handler layout
*/
public class NewYearCardRecord {
private int id;
diff --git a/src/client/processor/AssignAPProcessor.java b/src/client/processor/AssignAPProcessor.java
index c563bbc49c..a37bf8961b 100644
--- a/src/client/processor/AssignAPProcessor.java
+++ b/src/client/processor/AssignAPProcessor.java
@@ -50,7 +50,7 @@ import tools.data.input.SeekableLittleEndianAccessor;
/**
*
- * @author RonanLana (synchronization of AP transaction modules)
+ * @author RonanLana - synchronization of AP transaction modules
*/
public class AssignAPProcessor {
diff --git a/src/client/processor/AssignSPProcessor.java b/src/client/processor/AssignSPProcessor.java
index 7c8d868a88..111ed8ade4 100644
--- a/src/client/processor/AssignSPProcessor.java
+++ b/src/client/processor/AssignSPProcessor.java
@@ -36,7 +36,7 @@ import tools.MaplePacketCreator;
/**
*
- * @author RonanLana (synchronization of SP transaction modules)
+ * @author RonanLana - synchronization of SP transaction modules
*/
public class AssignSPProcessor {
diff --git a/src/client/processor/DueyProcessor.java b/src/client/processor/DueyProcessor.java
index 653a1ee155..42b4e005ac 100644
--- a/src/client/processor/DueyProcessor.java
+++ b/src/client/processor/DueyProcessor.java
@@ -48,7 +48,7 @@ import tools.MaplePacketCreator;
/**
*
- * @author RonanLana (synchronization of Duey modules)
+ * @author RonanLana - synchronization of Duey modules
*/
public class DueyProcessor {
diff --git a/src/client/processor/FredrickProcessor.java b/src/client/processor/FredrickProcessor.java
index 780a19bab9..96813f6711 100644
--- a/src/client/processor/FredrickProcessor.java
+++ b/src/client/processor/FredrickProcessor.java
@@ -43,7 +43,7 @@ import tools.Pair;
/**
*
- * @author RonanLana (synchronization of Fredrick modules)
+ * @author RonanLana - synchronization of Fredrick modules
*/
public class FredrickProcessor {
private static boolean canRetrieveFromFredrick(MapleCharacter chr, List> items) {
diff --git a/src/client/processor/SpawnPetProcessor.java b/src/client/processor/SpawnPetProcessor.java
index 997af5acec..8264cbee8c 100644
--- a/src/client/processor/SpawnPetProcessor.java
+++ b/src/client/processor/SpawnPetProcessor.java
@@ -34,7 +34,7 @@ import tools.MaplePacketCreator;
/**
*
- * @author RonanLana (just added locking on OdinMS' SpawnPetHandler method body)
+ * @author RonanLana - just added locking on OdinMS' SpawnPetHandler method body
*/
public class SpawnPetProcessor {
private static MapleDataProvider dataRoot = MapleDataProviderFactory.getDataProvider(new File(System.getProperty("wzpath") + "/Item.wz"));
diff --git a/src/constants/GameConstants.java b/src/constants/GameConstants.java
index 37e9074548..01a485bd02 100644
--- a/src/constants/GameConstants.java
+++ b/src/constants/GameConstants.java
@@ -97,6 +97,7 @@ public class GameConstants {
put("square", 103040000);
put("neo", 240070000);
put("mushking", 106020000);
+ put("dojo", 925020001);
put("bosspq", 970030000);
put("fm", 910000000);
}};
diff --git a/src/constants/ServerConstants.java b/src/constants/ServerConstants.java
index 2f3c64c057..777e9f5f61 100644
--- a/src/constants/ServerConstants.java
+++ b/src/constants/ServerConstants.java
@@ -51,12 +51,15 @@ public class ServerConstants {
//Other Configuration
public static boolean JAVA_8;
public static boolean SHUTDOWNHOOK;
+ // JAVA_8: every static function in AbstractPlayerInteraction are to be made non-static, and code comment sections uncommented after enabling this functionality.
+
//Server Flags
public static final boolean USE_CUSTOM_KEYSET = true; //Enables auto-setup of the HeavenMS's custom keybindings when creating characters.
public static final boolean USE_DEBUG = false; //Will enable some text prints on the client, oriented for debugging purposes.
public static final boolean USE_DEBUG_SHOW_INFO_EQPEXP = false; //Prints on the cmd all equip exp gain info.
public static boolean USE_DEBUG_SHOW_RCVD_PACKET = false; //Prints on the cmd all received packet ids.
+ public static boolean USE_DEBUG_SHOW_RCVD_MVLIFE = false; //Prints on the cmd all received move life content.
public static boolean USE_SUPPLY_RATE_COUPONS = true; //Allows rate coupons to be sold through the Cash Shop.
public static final boolean USE_MAXRANGE = true; //Will send and receive packets from all events on a map, rather than those of only view range.
@@ -141,6 +144,7 @@ public class ServerConstants {
public static boolean USE_DISPLAY_NUMBERS_WITH_COMMA = true; //Enforce comma on displayed strings (use this when USE_UNITPRICE_WITH_COMMA is active and you still want to display comma-separated values).
public static boolean USE_UNITPRICE_WITH_COMMA = true; //Set this accordingly with the layout of the unitPrices on Item.wz XML's, whether it's using commas or dots to represent fractions.
public static final byte MIN_UNDERLEVEL_TO_EXP_GAIN = 20; //Characters are unable to get EXP from a mob if their level are under this threshold, only if "USE_ENFORCE_MOB_LEVEL_RANGE" is enabled. For bosses, this attribute is doubled.
+ public static final byte MIN_UNDERLEVEL_TO_EXP_LEECH = 40; //Characters are unable to leech EXP from party member kills whose level difference are past this limit.
public static final byte MAX_MONITORED_BUFFSTATS = 5; //Limits accounting for "dormant" buff effects, that should take place when stronger stat buffs expires.
public static final int MAX_AP = 32767; //Max AP allotted on the auto-assigner.
public static final int MAX_EVENT_LEVELS = 8; //Event has different levels of rewarding system.
@@ -172,7 +176,7 @@ public class ServerConstants {
public static final boolean USE_ENHANCED_CHSCROLL = true; //Equips even more powerful with chaos upgrade.
public static final boolean USE_ENHANCED_CRAFTING = true; //Apply chaos scroll on every equip crafted.
public static final boolean USE_ENHANCED_CLNSLATE = true; //Clean slates can be applied to recover successfully used slots as well.
- public static final int SCROLL_CHANCE_RATE = 10; //Number of rolls for success on a scroll, set 0 for default.
+ public static final int SCROLL_CHANCE_RATE = 10; //Number of rolls for success on a scroll, set 1 for default.
public static final int CHSCROLL_STAT_RATE = 3; //Number of rolls of stat upgrade on a successfully applied chaos scroll, set 1 for default.
public static final int CHSCROLL_STAT_RANGE = 6; //Stat upgrade range (-N, N) on chaos scrolls.
diff --git a/src/constants/skills/NightWalker.java b/src/constants/skills/NightWalker.java
index c65075a213..48b991130e 100644
--- a/src/constants/skills/NightWalker.java
+++ b/src/constants/skills/NightWalker.java
@@ -39,6 +39,7 @@ public class NightWalker {
public static final int SHADOW_PARTNER = 14111000;
public static final int SHADOW_WEB = 14111001;
public static final int VANISH = 14100005;
+ public static final int FLASH_JUMP = 14101004;
public static final int VAMPIRE = 14101006;
public static final int VENOM = 14110004;
}
diff --git a/src/net/server/audit/locks/MonitoredLockType.java b/src/net/server/audit/locks/MonitoredLockType.java
index 1df11369c1..bcf84b12de 100644
--- a/src/net/server/audit/locks/MonitoredLockType.java
+++ b/src/net/server/audit/locks/MonitoredLockType.java
@@ -27,6 +27,7 @@ package net.server.audit.locks;
public enum MonitoredLockType {
UNDEFINED,
CHARACTER_CHR,
+ CHARACTER_CPN,
CHARACTER_EFF,
CHARACTER_PET,
CHARACTER_PRT,
diff --git a/src/net/server/channel/handlers/AutoAggroHandler.java b/src/net/server/channel/handlers/AutoAggroHandler.java
index 622f7ef75c..ffb1124803 100644
--- a/src/net/server/channel/handlers/AutoAggroHandler.java
+++ b/src/net/server/channel/handlers/AutoAggroHandler.java
@@ -32,8 +32,7 @@ public final class AutoAggroHandler extends AbstractMaplePacketHandler {
@Override
public final void handlePacket(SeekableLittleEndianAccessor slea, MapleClient c) {
- if(c.getPlayer().isHidden())
- return; // Don't auto aggro GM's in hide...
+ if (c.getPlayer().isHidden()) return; // Don't auto aggro GM's in hide...
MapleMap map = c.getPlayer().getMap();
int oid = slea.readInt();
diff --git a/src/net/server/channel/handlers/CashOperationHandler.java b/src/net/server/channel/handlers/CashOperationHandler.java
index 7e51b218ff..a4d6a01aad 100644
--- a/src/net/server/channel/handlers/CashOperationHandler.java
+++ b/src/net/server/channel/handlers/CashOperationHandler.java
@@ -63,7 +63,7 @@ public final class CashOperationHandler extends AbstractMaplePacketHandler {
final int snCS = slea.readInt();
CashItem cItem = CashItemFactory.getItem(snCS);
if (!canBuy(cItem, cs.getCash(useNX))) {
- FilePrinter.printError(FilePrinter.ITEM, "Denied to sell cash item with SN " + cItem.getSN());
+ FilePrinter.printError(FilePrinter.ITEM, "Denied to sell cash item with SN " + snCS); // preventing NPE here thanks to MedicOP
c.enableCSActions();
return;
}
@@ -185,7 +185,10 @@ public final class CashOperationHandler extends AbstractMaplePacketHandler {
c.enableCSActions();
return;
}
- if (chr.getStorage().gainSlots(8)) {
+ if (chr.getStorage().gainSlots(8)) { // thanks ABaldParrot & Thora for detecting storage issues here
+ FilePrinter.print(FilePrinter.STORAGE + c.getAccountName() + ".txt", c.getPlayer().getName() + " bought 8 slots to their account storage.\r\n");
+ chr.setUsedStorage();
+
c.announce(MaplePacketCreator.showBoughtStorageSlots(chr.getStorage().getSlots()));
cs.gainCash(cash, cItem, chr.getWorld());
c.announce(MaplePacketCreator.showCash(chr));
diff --git a/src/net/server/channel/handlers/GuildOperationHandler.java b/src/net/server/channel/handlers/GuildOperationHandler.java
index ccb354f373..dbfbf39572 100644
--- a/src/net/server/channel/handlers/GuildOperationHandler.java
+++ b/src/net/server/channel/handlers/GuildOperationHandler.java
@@ -194,14 +194,15 @@ public final class GuildOperationHandler extends AbstractMaplePacketHandler {
restancePlayer(mc);
break;
case 0x07:
- allianceId = mc.getGuild().getAllianceId();
-
cid = slea.readInt();
name = slea.readMapleAsciiString();
if (cid != mc.getId() || !name.equals(mc.getName()) || mc.getGuildId() <= 0) {
System.out.println("[hax] " + mc.getName() + " tried to quit guild under the name \"" + name + "\" and current guild id of " + mc.getGuildId() + ".");
return;
}
+
+ allianceId = mc.getGuild().getAllianceId();
+
c.announce(MaplePacketCreator.updateGP(mc.getGuildId(), 0));
Server.getInstance().leaveGuild(mc.getMGC());
@@ -209,6 +210,7 @@ public final class GuildOperationHandler extends AbstractMaplePacketHandler {
if(allianceId > 0) Server.getInstance().getAlliance(allianceId).updateAlliancePackets(mc);
mc.getMGC().setGuildId(0);
+ mc.getMGC().setGuildRank(5);
mc.saveGuildStatus();
restancePlayer(mc);
break;
diff --git a/src/net/server/channel/handlers/InventorySortHandler.java b/src/net/server/channel/handlers/InventorySortHandler.java
index 8d6e30505d..6ee4afb592 100644
--- a/src/net/server/channel/handlers/InventorySortHandler.java
+++ b/src/net/server/channel/handlers/InventorySortHandler.java
@@ -216,8 +216,8 @@ public final class InventorySortHandler extends AbstractMaplePacketHandler {
}
for (Item item : itemarray) {
- inventory.removeSlot(item.getPosition());
- mods.add(new ModifyInventory(3, item));
+ inventory.removeSlot(item.getPosition());
+ mods.add(new ModifyInventory(3, item));
}
int invTypeCriteria = (MapleInventoryType.getByType(invType) == MapleInventoryType.EQUIP) ? 3 : 1;
diff --git a/src/net/server/channel/handlers/ItemRewardHandler.java b/src/net/server/channel/handlers/ItemRewardHandler.java
index a4da7b00d3..1d4f7c1ac8 100644
--- a/src/net/server/channel/handlers/ItemRewardHandler.java
+++ b/src/net/server/channel/handlers/ItemRewardHandler.java
@@ -37,7 +37,8 @@ import tools.Randomizer;
import tools.data.input.SeekableLittleEndianAccessor;
/**
- * @author Jay Estrella/ Modified by kevintjuh93
+ * @author Jay Estrella
+ * @author kevintjuh93
*/
public final class ItemRewardHandler extends AbstractMaplePacketHandler {
@Override
diff --git a/src/net/server/channel/handlers/MobDamageMobFriendlyHandler.java b/src/net/server/channel/handlers/MobDamageMobFriendlyHandler.java
index 47c03e443b..672c2496f9 100644
--- a/src/net/server/channel/handlers/MobDamageMobFriendlyHandler.java
+++ b/src/net/server/channel/handlers/MobDamageMobFriendlyHandler.java
@@ -47,8 +47,7 @@ public final class MobDamageMobFriendlyHandler extends AbstractMaplePacketHandle
}
int damage = Randomizer.nextInt(((monster.getMaxHp() / 13 + monster.getPADamage() * 10)) * 2 + 500) / 10; //Beng's formula.
- // int damage = monster.getStats().getPADamage() + monster.getStats().getPDDamage() - 1;
-
+
if (monster.getHp() - damage < 1) { // friendly dies
if(monster.getId() == 9300102) {
monster.getMap().broadcastMessage(MaplePacketCreator.serverNotice(6, "The Watch Hog has been injured by the aliens. Better luck next time..."));
@@ -60,8 +59,10 @@ public final class MobDamageMobFriendlyHandler extends AbstractMaplePacketHandle
monster.getMap().broadcastMessage(MaplePacketCreator.serverNotice(6, "Juliet has fainted in the middle of the combat."));
} else if(monster.getId() == 9300138) { //romeo
monster.getMap().broadcastMessage(MaplePacketCreator.serverNotice(6, "Romeo has fainted in the middle of the combat."));
- } else if(monster.getId() == 9400322 || monster.getId() == 9400327 || monster.getId() == 9400332) {
+ } else if(monster.getId() == 9400322 || monster.getId() == 9400327 || monster.getId() == 9400332) { //snowman
monster.getMap().broadcastMessage(MaplePacketCreator.serverNotice(6, "The Snowman has melted on the heat of the battle."));
+ } else if(monster.getId() == 9300162) { //delli
+ monster.getMap().broadcastMessage(MaplePacketCreator.serverNotice(6, "Delli vanished after the ambush, sheets still laying on the ground..."));
}
c.getPlayer().getMap().killFriendlies(monster);
diff --git a/src/net/server/channel/handlers/MoveLifeHandler.java b/src/net/server/channel/handlers/MoveLifeHandler.java
index 1bc1acb6bb..4ee2f0a88b 100644
--- a/src/net/server/channel/handlers/MoveLifeHandler.java
+++ b/src/net/server/channel/handlers/MoveLifeHandler.java
@@ -26,6 +26,7 @@ import client.MapleClient;
import java.awt.Point;
import java.util.LinkedList;
import java.util.List;
+import constants.ServerConstants;
import server.life.MapleMonster;
import server.life.MapleMonsterInformationProvider;
//import server.life.MobAttackInfo;
@@ -63,10 +64,10 @@ public final class MoveLifeHandler extends AbstractMovementPacketHandler {
MapleMonster monster = (MapleMonster) mmo;
List banishPlayers = null;
- byte pNibbles = slea.readByte();
+ byte pNibbles = slea.readByte();
byte rawActivity = slea.readByte();
- slea.readByte();
- slea.readByte();
+ int skillId = slea.readByte() & 0xff;
+ int skillLv = slea.readByte() & 0xff;
short pOption = slea.readShort();
slea.skip(8);
@@ -74,65 +75,69 @@ public final class MoveLifeHandler extends AbstractMovementPacketHandler {
rawActivity = (byte) (rawActivity & 0xFF >> 1);
}
- boolean isAttack = inRangeInclusive(rawActivity, 12, 20);
- boolean isSkill = inRangeInclusive(rawActivity, 21, 25);
-
- byte attackId = (byte) (isAttack ? rawActivity - 12 : -1);
- isSkill |= (pNibbles != 0);
-
- boolean nextMovementCouldBeSkill = true;
- boolean pUnk = (pNibbles & 0xF0) != 0;
-
+ boolean isAttack = inRangeInclusive(rawActivity, 24, 41);
+ boolean isSkill = inRangeInclusive(rawActivity, 42, 59);
+
boolean currentController = (monster.getController() == player);
MobSkill toUse = null;
int useSkillId = 0, useSkillLevel = 0;
- int rnd = 0;
+ MobSkill nextUse = null;
+ int nextSkillId = 0, nextSkillLevel = 0;
+
+ boolean nextMovementCouldBeSkill = !(isSkill || (pNibbles != 0));
+
+ int castPos;
if (isSkill) {
- int noSkills = monster.getNoSkills();
- if (noSkills > 0) {
- int rndSkill = Randomizer.nextInt(noSkills);
-
- Pair skillToUse = monster.getSkills().get(rndSkill);
- useSkillId = skillToUse.getLeft();
- useSkillLevel = skillToUse.getRight();
+ useSkillId = skillId;
+ useSkillLevel = skillLv;
+
+ castPos = monster.getSkillPos(useSkillId, useSkillLevel);
+ if (castPos != -1) {
toUse = MobSkillFactory.getMobSkill(useSkillId, useSkillLevel);
- rnd = rndSkill;
- nextMovementCouldBeSkill = false;
- }
- }
-
- int mobMp;
- if (toUse != null && toUse.getHP() >= (int) (((float) monster.getHp() / monster.getMaxHp()) * 100) && monster.canUseSkill(toUse)) {
- mobMp = monster.getMp();
-
- int animationTime = MapleMonsterInformationProvider.getInstance().getMobSkillAnimationTime(toUse);
- if(animationTime > 0 && toUse.getSkillId() != 129) {
- toUse.applyDelayedEffect(player, monster, true, animationTime);
- } else {
- banishPlayers = new LinkedList<>();
- toUse.applyEffect(player, monster, true, banishPlayers);
+ if (monster.canUseSkill(toUse)) {
+ int animationTime = MapleMonsterInformationProvider.getInstance().getMobSkillAnimationTime(toUse);
+ if(animationTime > 0 && toUse.getSkillId() != 129) {
+ toUse.applyDelayedEffect(player, monster, true, animationTime);
+ } else {
+ banishPlayers = new LinkedList<>();
+ toUse.applyEffect(player, monster, true, banishPlayers);
+ }
+ }
}
} else {
- int atkStatus = monster.canUseAttack((attackId - 13) / 2);
+ castPos = (rawActivity - 24) / 2;
+
+ int atkStatus = monster.canUseAttack(castPos, isSkill);
if (atkStatus < 1) {
if (!currentController) {
return;
}
- mobMp = atkStatus < 0 ? 0 : monster.getMp();
- } else {
- mobMp = monster.getMp();
+ rawActivity = -1;
+ pOption = 0;
+ }
+ }
+
+ int mobMp = monster.getMp();
+ if (nextMovementCouldBeSkill) {
+ int noSkills = monster.getNoSkills();
+ if (noSkills > 0) {
+ int rndSkill = Randomizer.nextInt(noSkills);
+
+ Pair skillToUse = monster.getSkills().get(rndSkill);
+ nextSkillId = skillToUse.getLeft();
+ nextSkillLevel = skillToUse.getRight();
+ nextUse = MobSkillFactory.getMobSkill(nextSkillId, nextSkillLevel);
+
+ if (!(nextUse != null && nextUse.getHP() >= (int) (((float) monster.getHp() / monster.getMaxHp()) * 100) && mobMp >= nextUse.getMpCon())) {
+ nextSkillId = 0;
+ nextSkillLevel = 0;
+ nextUse = null;
+ }
}
-
- useSkillId = 0;
- useSkillLevel = 0;
- rawActivity = -1;
- pOption = 0;
-
- toUse = null;
}
slea.readByte();
@@ -151,9 +156,6 @@ public final class MoveLifeHandler extends AbstractMovementPacketHandler {
} else {
return;
}
- } else if (rawActivity == -1 && monster.isControllerKnowsAboutAggro() && !monster.isMobile() && !monster.isFirstAttack()) {
- monster.setControllerHasAggro(false);
- monster.setControllerKnowsAboutAggro(false);
}
aggro = monster.isControllerHasAggro();
@@ -164,13 +166,17 @@ public final class MoveLifeHandler extends AbstractMovementPacketHandler {
monster.unlockMonster();
}
- if (toUse != null) {
- c.announce(MaplePacketCreator.moveMonsterResponse(objectid, moveid, mobMp, aggro, toUse.getSkillId(), toUse.getSkillLevel()));
+ if (nextUse != null) {
+ c.announce(MaplePacketCreator.moveMonsterResponse(objectid, moveid, mobMp, aggro, nextSkillId, nextSkillLevel));
} else {
c.announce(MaplePacketCreator.moveMonsterResponse(objectid, moveid, mobMp, aggro));
}
if (res != null) {
+ if (ServerConstants.USE_DEBUG_SHOW_RCVD_MVLIFE) {
+ System.out.println((isSkill ? "SKILL " : (isAttack ? "ATTCK " : " ")) + "castPos: " + castPos + " rawAct: " + rawActivity + " opt: " + pOption + " skillID: " + useSkillId + " skillLV: " + useSkillLevel + " " + "allowSkill: " + nextMovementCouldBeSkill);
+ }
+
map.broadcastMessage(player, MaplePacketCreator.moveMonster(objectid, nextMovementCouldBeSkill, rawActivity, useSkillId, useSkillLevel, pOption, startPos, res), monster.getPosition());
updatePosition(res, monster, -2);
map.moveMonster(monster, monster.getPosition());
diff --git a/src/net/server/channel/handlers/PetAutoPotHandler.java b/src/net/server/channel/handlers/PetAutoPotHandler.java
index 70c35111e9..c86151dc62 100644
--- a/src/net/server/channel/handlers/PetAutoPotHandler.java
+++ b/src/net/server/channel/handlers/PetAutoPotHandler.java
@@ -37,7 +37,7 @@ import java.util.List;
/**
*
- * @author Ronan (multi-pot consumption feature)
+ * @author Ronan - multi-pot consumption feature
*/
public final class PetAutoPotHandler extends AbstractMaplePacketHandler {
short slot;
diff --git a/src/net/server/channel/handlers/PlayerInteractionHandler.java b/src/net/server/channel/handlers/PlayerInteractionHandler.java
index ae32614516..44a70242ab 100644
--- a/src/net/server/channel/handlers/PlayerInteractionHandler.java
+++ b/src/net/server/channel/handlers/PlayerInteractionHandler.java
@@ -49,7 +49,7 @@ import tools.data.input.SeekableLittleEndianAccessor;
/**
*
* @author Matze
- * @author Ronan (concurrency safety & reviewed minigames)
+ * @author Ronan - concurrency safety & reviewed minigames
*/
public final class PlayerInteractionHandler extends AbstractMaplePacketHandler {
public enum Action {
diff --git a/src/net/server/channel/handlers/PlayerLoggedinHandler.java b/src/net/server/channel/handlers/PlayerLoggedinHandler.java
index 84483ac4c9..f8b3ea62b6 100644
--- a/src/net/server/channel/handlers/PlayerLoggedinHandler.java
+++ b/src/net/server/channel/handlers/PlayerLoggedinHandler.java
@@ -224,6 +224,7 @@ public final class PlayerLoggedinHandler extends AbstractMaplePacketHandler {
if (playerGuild == null) {
player.deleteGuild(player.getGuildId());
player.getMGC().setGuildId(0);
+ player.getMGC().setGuildRank(5);
} else {
playerGuild.getMGC(player.getId()).setCharacter(player);
player.setMGC(playerGuild.getMGC(player.getId()));
diff --git a/src/net/server/channel/handlers/RingActionHandler.java b/src/net/server/channel/handlers/RingActionHandler.java
index 338ad0dc7d..aaab19a914 100644
--- a/src/net/server/channel/handlers/RingActionHandler.java
+++ b/src/net/server/channel/handlers/RingActionHandler.java
@@ -51,7 +51,7 @@ import client.inventory.Item;
/**
* @author Jvlaple
- * @author Ronan (major overhaul on Ring handling mechanics)
+ * @author Ronan - major overhaul on Ring handling mechanics
*/
public final class RingActionHandler extends AbstractMaplePacketHandler {
private static int getBoxId(int useItemId) {
diff --git a/src/net/server/channel/handlers/SpecialMoveHandler.java b/src/net/server/channel/handlers/SpecialMoveHandler.java
index 6b72dbcd76..1ad186209f 100644
--- a/src/net/server/channel/handlers/SpecialMoveHandler.java
+++ b/src/net/server/channel/handlers/SpecialMoveHandler.java
@@ -48,7 +48,7 @@ public final class SpecialMoveHandler extends AbstractMaplePacketHandler {
public final void handlePacket(SeekableLittleEndianAccessor slea, MapleClient c) {
MapleCharacter chr = c.getPlayer();
slea.readInt();
- chr.getAutobanManager().setTimestamp(4, Server.getInstance().getCurrentTimestamp(), 5);
+ chr.getAutobanManager().setTimestamp(4, Server.getInstance().getCurrentTimestamp(), 28);
int skillid = slea.readInt();
/*
@@ -132,7 +132,11 @@ public final class SpecialMoveHandler extends AbstractMaplePacketHandler {
}
if (chr.isAlive()) {
if (skill.getId() != Priest.MYSTIC_DOOR) {
- skill.getEffect(skillLevel).applyTo(chr, pos);
+ if (skill.getId() % 10000000 != 1005) {
+ skill.getEffect(skillLevel).applyTo(chr, pos);
+ } else {
+ skill.getEffect(skillLevel).applyEchoOfHero(chr);
+ }
} else if(chr.canDoor()) {
//update door lists
chr.cancelMagicDoor();
diff --git a/src/net/server/channel/handlers/WhisperHandler.java b/src/net/server/channel/handlers/WhisperHandler.java
index 02ded22631..91f9ad3e6a 100644
--- a/src/net/server/channel/handlers/WhisperHandler.java
+++ b/src/net/server/channel/handlers/WhisperHandler.java
@@ -83,12 +83,14 @@ public final class WhisperHandler extends AbstractMaplePacketHandler {
c.getPlayer().getAutobanManager().spam(7);
} else if (mode == 5) { // - /find
String recipient = slea.readMapleAsciiString();
- MapleCharacter victim = c.getChannelServer().getPlayerStorage().getCharacterByName(recipient);
+ MapleCharacter victim = c.getWorldServer().getPlayerStorage().getCharacterByName(recipient);
if (victim != null && c.getPlayer().gmLevel() >= victim.gmLevel()) {
- if (victim.getCashShop().isOpened()) {
+ if (victim.getCashShop().isOpened()) { // in CashShop
c.announce(MaplePacketCreator.getFindReply(victim.getName(), -1, 2));
- //} else if (victim.inMTS()) {
- // c.announce(MaplePacketCreator.getFindReply(victim.getName(), -1, 0));
+ } else if (victim.isAwayFromWorld()) { // in MTS
+ c.announce(MaplePacketCreator.getFindReply(victim.getName(), -1, 0));
+ } else if (victim.getClient().getChannel() != c.getChannel()) { // in another channel, issue detected thanks to MedicOP
+ c.announce(MaplePacketCreator.getFindReply(victim.getName(), victim.getClient().getChannel() - 1, 3));
} else {
c.announce(MaplePacketCreator.getFindReply(victim.getName(), victim.getMap().getId(), 1));
}
diff --git a/src/net/server/world/World.java b/src/net/server/world/World.java
index 13017a5a17..13f4afee49 100644
--- a/src/net/server/world/World.java
+++ b/src/net/server/world/World.java
@@ -90,7 +90,7 @@ import net.server.audit.locks.factory.MonitoredReentrantLockFactory;
/**
*
* @author kevintjuh93
- * @author Ronan (thread-oriented world schedules, guild queue, marriages & party chars)
+ * @author Ronan - thread-oriented world schedules, guild queue, marriages & party chars
*/
public class World {
diff --git a/src/scripting/event/EventManager.java b/src/scripting/event/EventManager.java
index 9b365e95dd..ce87183b7f 100644
--- a/src/scripting/event/EventManager.java
+++ b/src/scripting/event/EventManager.java
@@ -174,7 +174,21 @@ public class EventManager {
private List getLobbyRange() {
try {
- return convertToIntegerArray((List)iv.invokeFunction("setLobbyRange", (Object) null));
+ if (!ServerConstants.JAVA_8) {
+ return convertToIntegerArray((List)iv.invokeFunction("setLobbyRange", (Object) null));
+ } else { // java 8 support here thanks to MedicOP
+ /*
+ ScriptObjectMirror object = (ScriptObjectMirror) iv.invokeFunction("setLobbyRange", (Object) null);
+ int[] to = object.to(int[].class);
+ List list = new ArrayList<>();
+ for (int i : to) {
+ list.add(i);
+ }
+ return list;
+ */
+
+ throw new NoSuchMethodException();
+ }
} catch (ScriptException | NoSuchMethodException ex) { // they didn't define a lobby range
List defaultRange = new ArrayList<>();
defaultRange.add(0);
diff --git a/src/server/MapleItemInformationProvider.java b/src/server/MapleItemInformationProvider.java
index 6b729d6c8a..a80e791c8b 100644
--- a/src/server/MapleItemInformationProvider.java
+++ b/src/server/MapleItemInformationProvider.java
@@ -645,8 +645,8 @@ public class MapleItemInformationProvider {
return Math.pow(1.0 - prop, dices);
}
- public static boolean rollSuccessChance(double prop) {
- return Math.random() >= testYourLuck(prop / 100.0, ServerConstants.SCROLL_CHANCE_RATE);
+ public static boolean rollSuccessChance(double propPercent) {
+ return Math.random() >= testYourLuck(propPercent / 100.0, ServerConstants.SCROLL_CHANCE_RATE);
}
private static short getMaximumShortMaxIfOverflow(int value1, int value2) {
diff --git a/src/server/MapleStatEffect.java b/src/server/MapleStatEffect.java
index 8bf876c817..f40ec72a07 100644
--- a/src/server/MapleStatEffect.java
+++ b/src/server/MapleStatEffect.java
@@ -717,6 +717,18 @@ public class MapleStatEffect {
}
}
+ public boolean applyEchoOfHero(MapleCharacter applyfrom) {
+ Map mapPlayers = applyfrom.getMap().getMapPlayers();
+ mapPlayers.remove(applyfrom.getId());
+
+ boolean hwResult = applyTo(applyfrom);
+ for (MapleCharacter chr : mapPlayers.values()) { // Echo of Hero not buffing players in the map detected thanks to Masterrulax
+ applyTo(applyfrom, chr, false, null, false, 1);
+ }
+
+ return hwResult;
+ }
+
public boolean applyTo(MapleCharacter chr) {
return applyTo(chr, chr, true, null, false, 1);
}
@@ -886,11 +898,11 @@ public class MapleStatEffect {
applyto.cancelBuffStats(MapleBuffStat.SOULARROW); // cancel door buff
}
- } else if (isMist()) {
+ } else if (isMist()) {
Rectangle bounds = calculateBoundingBox(sourceid == NightWalker.POISON_BOMB ? pos : applyfrom.getPosition(), applyfrom.isFacingLeft());
MapleMist mist = new MapleMist(bounds, applyfrom, this);
applyfrom.getMap().spawnMist(mist, getDuration(), mist.isPoisonMist(), false, mist.isRecoveryMist());
- } else if(isTimeLeap()) {
+ } else if (isTimeLeap()) {
applyto.removeAllCooldownsExcept(Buccaneer.TIME_LEAP, true);
}
diff --git a/src/server/MapleTrade.java b/src/server/MapleTrade.java
index ebce040a57..b6a9ec82e3 100644
--- a/src/server/MapleTrade.java
+++ b/src/server/MapleTrade.java
@@ -41,7 +41,7 @@ import tools.Pair;
/**
*
* @author Matze
- * @author Ronan (concurrency safety & check available slots)
+ * @author Ronan - concurrency safety & check available slots
*/
public class MapleTrade {
private MapleTrade partner = null;
diff --git a/src/server/life/MapleLifeFactory.java b/src/server/life/MapleLifeFactory.java
index 072fd5f689..0869588060 100644
--- a/src/server/life/MapleLifeFactory.java
+++ b/src/server/life/MapleLifeFactory.java
@@ -54,130 +54,179 @@ public class MapleLifeFactory {
}
}
+ private static class MobAttackInfoHolder {
+ protected int attackPos;
+ protected int mpCon;
+ protected int coolTime;
+ protected int animationTime;
+
+ protected MobAttackInfoHolder(int attackPos, int mpCon, int coolTime, int animationTime) {
+ this.attackPos = attackPos;
+ this.mpCon = mpCon;
+ this.coolTime = coolTime;
+ this.animationTime = animationTime;
+ }
+ }
+
+ private static void setMonsterAttackInfo(int mid, List attackInfos) {
+ if (!attackInfos.isEmpty()) {
+ MapleMonsterInformationProvider mi = MapleMonsterInformationProvider.getInstance();
+
+ for (MobAttackInfoHolder attackInfo : attackInfos) {
+ mi.setMobAttackInfo(mid, attackInfo.attackPos, attackInfo.mpCon, attackInfo.coolTime);
+ mi.setMobAttackAnimationTime(mid, attackInfo.attackPos, attackInfo.animationTime);
+ }
+ }
+ }
+
+ private static Pair> getMonsterStats(int mid) {
+ MapleData monsterData = data.getData(StringUtil.getLeftPaddedStr(Integer.toString(mid) + ".img", '0', 11));
+ if (monsterData == null) {
+ return null;
+ }
+ MapleData monsterInfoData = monsterData.getChildByPath("info");
+
+ List attackInfos = new LinkedList<>();
+ MapleMonsterStats stats;
+
+ int linkMid = MapleDataTool.getIntConvert("link", monsterInfoData, 0);
+ if (linkMid == 0) {
+ stats = new MapleMonsterStats();
+ } else {
+ Pair> linkStats = getMonsterStats(linkMid);
+ if (linkStats == null) {
+ return null;
+ }
+
+ stats = linkStats.getLeft();
+ attackInfos.addAll(linkStats.getRight());
+ }
+
+ stats.setHp(MapleDataTool.getIntConvert("maxHP", monsterInfoData));
+ stats.setFriendly(MapleDataTool.getIntConvert("damagedByMob", monsterInfoData, stats.isFriendly() ? 1 : 0) == 1);
+ stats.setPADamage(MapleDataTool.getIntConvert("PADamage", monsterInfoData));
+ stats.setPDDamage(MapleDataTool.getIntConvert("PDDamage", monsterInfoData));
+ stats.setMADamage(MapleDataTool.getIntConvert("MADamage", monsterInfoData));
+ stats.setMDDamage(MapleDataTool.getIntConvert("MDDamage", monsterInfoData));
+ stats.setMp(MapleDataTool.getIntConvert("maxMP", monsterInfoData, stats.getMp()));
+ stats.setExp(MapleDataTool.getIntConvert("exp", monsterInfoData, stats.getExp()));
+ stats.setLevel(MapleDataTool.getIntConvert("level", monsterInfoData));
+ stats.setRemoveAfter(MapleDataTool.getIntConvert("removeAfter", monsterInfoData, stats.removeAfter()));
+ stats.setBoss(MapleDataTool.getIntConvert("boss", monsterInfoData, stats.isBoss() ? 1 : 0) > 0);
+ stats.setExplosiveReward(MapleDataTool.getIntConvert("explosiveReward", monsterInfoData, stats.isExplosiveReward() ? 1 : 0) > 0);
+ stats.setFfaLoot(MapleDataTool.getIntConvert("publicReward", monsterInfoData, stats.isFfaLoot() ? 1 : 0) > 0);
+ stats.setUndead(MapleDataTool.getIntConvert("undead", monsterInfoData, stats.isUndead() ? 1 : 0) > 0);
+ stats.setName(MapleDataTool.getString(mid + "/name", mobStringData, "MISSINGNO"));
+ stats.setBuffToGive(MapleDataTool.getIntConvert("buff", monsterInfoData, stats.getBuffToGive()));
+ stats.setCP(MapleDataTool.getIntConvert("getCP", monsterInfoData, stats.getCP()));
+ stats.setRemoveOnMiss(MapleDataTool.getIntConvert("removeOnMiss", monsterInfoData, stats.removeOnMiss() ? 1 : 0) > 0);
+
+ MapleData special = monsterInfoData.getChildByPath("coolDamage");
+ if (special != null) {
+ int coolDmg = MapleDataTool.getIntConvert("coolDamage", monsterInfoData);
+ int coolProb = MapleDataTool.getIntConvert("coolDamageProb", monsterInfoData, 0);
+ stats.setCool(new Pair<>(coolDmg, coolProb));
+ }
+ special = monsterInfoData.getChildByPath("loseItem");
+ if (special != null) {
+ for (MapleData liData : special.getChildren()) {
+ stats.addLoseItem(new loseItem(MapleDataTool.getInt(liData.getChildByPath("id")), (byte) MapleDataTool.getInt(liData.getChildByPath("prop")), (byte) MapleDataTool.getInt(liData.getChildByPath("x"))));
+ }
+ }
+ special = monsterInfoData.getChildByPath("selfDestruction");
+ if (special != null) {
+ stats.setSelfDestruction(new selfDestruction((byte) MapleDataTool.getInt(special.getChildByPath("action")), MapleDataTool.getIntConvert("removeAfter", special, -1), MapleDataTool.getIntConvert("hp", special, -1)));
+ }
+ MapleData firstAttackData = monsterInfoData.getChildByPath("firstAttack");
+ int firstAttack = 0;
+ if (firstAttackData != null) {
+ if (firstAttackData.getType() == MapleDataType.FLOAT) {
+ firstAttack = Math.round(MapleDataTool.getFloat(firstAttackData));
+ } else {
+ firstAttack = MapleDataTool.getInt(firstAttackData);
+ }
+ }
+ stats.setFirstAttack(firstAttack > 0);
+ stats.setDropPeriod(MapleDataTool.getIntConvert("dropItemPeriod", monsterInfoData, stats.getDropPeriod() / 10000) * 10000);
+
+ stats.setTagColor(MapleDataTool.getIntConvert("hpTagColor", monsterInfoData, 0));
+ stats.setTagBgColor(MapleDataTool.getIntConvert("hpTagBgcolor", monsterInfoData, 0));
+
+ for (MapleData idata : monsterData) {
+ if (!idata.getName().equals("info")) {
+ int delay = 0;
+ for (MapleData pic : idata.getChildren()) {
+ delay += MapleDataTool.getIntConvert("delay", pic, 0);
+ }
+ stats.setAnimationTime(idata.getName(), delay);
+ }
+ }
+ MapleData reviveInfo = monsterInfoData.getChildByPath("revive");
+ if (reviveInfo != null) {
+ List revives = new LinkedList<>();
+ for (MapleData data_ : reviveInfo) {
+ revives.add(MapleDataTool.getInt(data_));
+ }
+ stats.setRevives(revives);
+ }
+ decodeElementalString(stats, MapleDataTool.getString("elemAttr", monsterInfoData, ""));
+
+ MapleMonsterInformationProvider mi = MapleMonsterInformationProvider.getInstance();
+ MapleData monsterSkillInfoData = monsterInfoData.getChildByPath("skill");
+ if (monsterSkillInfoData != null) {
+ int i = 0;
+ List> skills = new ArrayList<>();
+ while (monsterSkillInfoData.getChildByPath(Integer.toString(i)) != null) {
+ int skillId = MapleDataTool.getInt(i + "/skill", monsterSkillInfoData, 0);
+ int skillLv = MapleDataTool.getInt(i + "/level", monsterSkillInfoData, 0);
+ skills.add(new Pair<>(skillId, skillLv));
+
+ MapleData monsterSkillData = monsterData.getChildByPath("skill" + (i + 1));
+ if (monsterSkillData != null) {
+ int animationTime = 0;
+ for (MapleData effectEntry : monsterSkillData.getChildren()) {
+ animationTime += MapleDataTool.getIntConvert("delay", effectEntry, 0);
+ }
+
+ MobSkill skill = MobSkillFactory.getMobSkill(skillId, skillLv);
+ mi.setMobSkillAnimationTime(skill, animationTime);
+ }
+
+ i++;
+ }
+ stats.setSkills(skills);
+ }
+
+ int i = 0;
+ MapleData monsterAttackData;
+ while ((monsterAttackData = monsterData.getChildByPath("attack" + (i + 1))) != null) {
+ int animationTime = 0;
+ for (MapleData effectEntry : monsterAttackData.getChildren()) {
+ animationTime += MapleDataTool.getIntConvert("delay", effectEntry, 0);
+ }
+
+ int mpCon = MapleDataTool.getIntConvert("info/conMP", monsterAttackData, 0);
+ int coolTime = MapleDataTool.getIntConvert("info/attackAfter", monsterAttackData, 0);
+ attackInfos.add(new MobAttackInfoHolder(i, mpCon, coolTime, animationTime));
+ i++;
+ }
+
+ MapleData banishData = monsterInfoData.getChildByPath("ban");
+ if (banishData != null) {
+ stats.setBanishInfo(new BanishInfo(MapleDataTool.getString("banMsg", banishData), MapleDataTool.getInt("banMap/0/field", banishData, -1), MapleDataTool.getString("banMap/0/portal", banishData, "sp")));
+ }
+
+ return new Pair<>(stats, attackInfos);
+ }
+
public static MapleMonster getMonster(int mid) {
try {
MapleMonsterStats stats = monsterStats.get(Integer.valueOf(mid));
if (stats == null) {
- MapleData monsterData = data.getData(StringUtil.getLeftPaddedStr(Integer.toString(mid) + ".img", '0', 11));
- if (monsterData == null) {
- return null;
- }
- MapleData monsterInfoData = monsterData.getChildByPath("info");
- stats = new MapleMonsterStats();
- stats.setHp(MapleDataTool.getIntConvert("maxHP", monsterInfoData));
- stats.setFriendly(MapleDataTool.getIntConvert("damagedByMob", monsterInfoData, 0) == 1);
- stats.setPADamage(MapleDataTool.getIntConvert("PADamage", monsterInfoData));
- stats.setPDDamage(MapleDataTool.getIntConvert("PDDamage", monsterInfoData));
- stats.setMADamage(MapleDataTool.getIntConvert("MADamage", monsterInfoData));
- stats.setMDDamage(MapleDataTool.getIntConvert("MDDamage", monsterInfoData));
- stats.setMp(MapleDataTool.getIntConvert("maxMP", monsterInfoData, 0));
- stats.setExp(MapleDataTool.getIntConvert("exp", monsterInfoData, 0));
- stats.setLevel(MapleDataTool.getIntConvert("level", monsterInfoData));
- stats.setRemoveAfter(MapleDataTool.getIntConvert("removeAfter", monsterInfoData, 0));
- stats.setBoss(MapleDataTool.getIntConvert("boss", monsterInfoData, 0) > 0);
- stats.setExplosiveReward(MapleDataTool.getIntConvert("explosiveReward", monsterInfoData, 0) > 0);
- stats.setFfaLoot(MapleDataTool.getIntConvert("publicReward", monsterInfoData, 0) > 0);
- stats.setUndead(MapleDataTool.getIntConvert("undead", monsterInfoData, 0) > 0);
- stats.setName(MapleDataTool.getString(mid + "/name", mobStringData, "MISSINGNO"));
- stats.setBuffToGive(MapleDataTool.getIntConvert("buff", monsterInfoData, -1));
- stats.setCP(MapleDataTool.getIntConvert("getCP", monsterInfoData, 0));
- stats.setRemoveOnMiss(MapleDataTool.getIntConvert("removeOnMiss", monsterInfoData, 0) > 0);
-
- MapleData special = monsterInfoData.getChildByPath("coolDamage");
- if (special != null) {
- int coolDmg = MapleDataTool.getIntConvert("coolDamage", monsterInfoData);
- int coolProb = MapleDataTool.getIntConvert("coolDamageProb", monsterInfoData, 0);
- stats.setCool(new Pair<>(coolDmg, coolProb));
- }
- special = monsterInfoData.getChildByPath("loseItem");
- if (special != null) {
- for (MapleData liData : special.getChildren()) {
- stats.addLoseItem(new loseItem(MapleDataTool.getInt(liData.getChildByPath("id")), (byte) MapleDataTool.getInt(liData.getChildByPath("prop")), (byte) MapleDataTool.getInt(liData.getChildByPath("x"))));
- }
- }
- special = monsterInfoData.getChildByPath("selfDestruction");
- if (special != null) {
- stats.setSelfDestruction(new selfDestruction((byte) MapleDataTool.getInt(special.getChildByPath("action")), MapleDataTool.getIntConvert("removeAfter", special, -1), MapleDataTool.getIntConvert("hp", special, -1)));
- }
- MapleData firstAttackData = monsterInfoData.getChildByPath("firstAttack");
- int firstAttack = 0;
- if (firstAttackData != null) {
- if (firstAttackData.getType() == MapleDataType.FLOAT) {
- firstAttack = Math.round(MapleDataTool.getFloat(firstAttackData));
- } else {
- firstAttack = MapleDataTool.getInt(firstAttackData);
- }
- }
- stats.setFirstAttack(firstAttack > 0);
- stats.setDropPeriod(MapleDataTool.getIntConvert("dropItemPeriod", monsterInfoData, 0) * 10000);
-
- stats.setTagColor(MapleDataTool.getIntConvert("hpTagColor", monsterInfoData, 0));
- stats.setTagBgColor(MapleDataTool.getIntConvert("hpTagBgcolor", monsterInfoData, 0));
-
- for (MapleData idata : monsterData) {
- if (!idata.getName().equals("info")) {
- int delay = 0;
- for (MapleData pic : idata.getChildren()) {
- delay += MapleDataTool.getIntConvert("delay", pic, 0);
- }
- stats.setAnimationTime(idata.getName(), delay);
- }
- }
- MapleData reviveInfo = monsterInfoData.getChildByPath("revive");
- if (reviveInfo != null) {
- List revives = new LinkedList<>();
- for (MapleData data_ : reviveInfo) {
- revives.add(MapleDataTool.getInt(data_));
- }
- stats.setRevives(revives);
- }
- decodeElementalString(stats, MapleDataTool.getString("elemAttr", monsterInfoData, ""));
+ Pair> mobStats = getMonsterStats(mid);
+ stats = mobStats.getLeft();
+ setMonsterAttackInfo(mid, mobStats.getRight());
- MapleMonsterInformationProvider mi = MapleMonsterInformationProvider.getInstance();
- MapleData monsterSkillInfoData = monsterInfoData.getChildByPath("skill");
- if (monsterSkillInfoData != null) {
- int i = 0;
- List> skills = new ArrayList<>();
- while (monsterSkillInfoData.getChildByPath(Integer.toString(i)) != null) {
- int skillId = MapleDataTool.getInt(i + "/skill", monsterSkillInfoData, 0);
- int skillLv = MapleDataTool.getInt(i + "/level", monsterSkillInfoData, 0);
- skills.add(new Pair<>(skillId, skillLv));
-
- MapleData monsterSkillData = monsterData.getChildByPath("skill" + (i + 1));
- if (monsterSkillData != null) {
- int animationTime = 0;
- for (MapleData effectEntry : monsterSkillData.getChildren()) {
- animationTime += MapleDataTool.getIntConvert("delay", effectEntry, 0);
- }
-
- MobSkill skill = MobSkillFactory.getMobSkill(skillId, skillLv);
- mi.setMobSkillAnimationTime(skill, animationTime);
- }
-
- i++;
- }
- stats.setSkills(skills);
- }
-
- int i = 0;
- MapleData monsterAttackData;
- while ((monsterAttackData = monsterData.getChildByPath("attack" + (i + 1))) != null) {
- int animationTime = 0;
- for (MapleData effectEntry : monsterAttackData.getChildren()) {
- animationTime += MapleDataTool.getIntConvert("delay", effectEntry, 0);
- }
-
- int mpCon = MapleDataTool.getIntConvert("info/conMP", monsterAttackData, 0);
- int coolTime = MapleDataTool.getIntConvert("info/attackAfter", monsterAttackData, 0);
- mi.setMobAttackInfo(mid, i, mpCon, coolTime);
- mi.setMobAttackAnimationTime(mid, i, animationTime);
- i++;
- }
-
- MapleData banishData = monsterInfoData.getChildByPath("ban");
- if (banishData != null) {
- stats.setBanishInfo(new BanishInfo(MapleDataTool.getString("banMsg", banishData), MapleDataTool.getInt("banMap/0/field", banishData, -1), MapleDataTool.getString("banMap/0/portal", banishData, "sp")));
- }
monsterStats.put(Integer.valueOf(mid), stats);
}
MapleMonster ret = new MapleMonster(mid, stats);
diff --git a/src/server/life/MapleMonster.java b/src/server/life/MapleMonster.java
index 58af15616e..ce83d11348 100644
--- a/src/server/life/MapleMonster.java
+++ b/src/server/life/MapleMonster.java
@@ -402,7 +402,7 @@ public class MapleMonster extends AbstractLoadedMapleLife {
return takenDamage.containsKey(chr.getId());
}
- private void distributeExperienceToParty(int pid, float exp, int killer, Set underleveled, int minThresholdLevel) {
+ private void distributeExperienceToParty(int pid, float exp, int killer, int killerLevel, Set underleveled, int minThresholdLevel) {
List members = new LinkedList<>();
MapleCharacter pchar = getMap().getAnyCharacterFromParty(pid);
if(pchar != null) {
@@ -415,13 +415,17 @@ public class MapleMonster extends AbstractLoadedMapleLife {
members.add(chr);
}
-
- int partyLevel = 0;
- int leechCount = 0;
+
+ List expSharers = new LinkedList<>();
+ int expSharersLevel = 0;
for (MapleCharacter mc : members) {
if (mc.getLevel() >= minThresholdLevel) { //NO EXP WILL BE GIVEN for those who are underleveled!
- partyLevel += mc.getLevel();
- leechCount++;
+ if (Math.abs(killerLevel - mc.getLevel()) < ServerConstants.MIN_UNDERLEVEL_TO_EXP_LEECH) {
+ // thanks Thora for pointing out leech level limitation
+
+ expSharersLevel += mc.getLevel();
+ expSharers.add(mc);
+ }
} else {
underleveled.add(mc);
}
@@ -429,18 +433,15 @@ public class MapleMonster extends AbstractLoadedMapleLife {
final int mostDamageCid = getHighestDamagerId();
- for (MapleCharacter mc : members) {
+ for (MapleCharacter mc : expSharers) {
int id = mc.getId();
- int level = mc.getLevel();
- if (level >= minThresholdLevel) {
- boolean isKiller = killer == id;
- boolean mostDamage = mostDamageCid == id;
- float xp = ((0.80f * exp * level) / partyLevel);
- if (mostDamage) {
- xp += (0.20f * exp);
- }
- giveExpToCharacter(mc, xp, isKiller, leechCount);
+ boolean isKiller = killer == id;
+ boolean mostDamage = mostDamageCid == id;
+ float xp = ((0.80f * exp * mc.getLevel()) / expSharersLevel);
+ if (mostDamage) {
+ xp += (0.20f * exp);
}
+ giveExpToCharacter(mc, xp, isKiller, expSharers.size());
}
}
@@ -464,7 +465,7 @@ public class MapleMonster extends AbstractLoadedMapleLife {
}
EventInstanceManager eim = getMap().getEventInstance();
- int minThresholdLevel = calcThresholdLevel(eim != null);
+ int minThresholdLevel = calcThresholdLevel(eim != null), killerLevel = Integer.MAX_VALUE;
int exp = getExp();
long totalHealth = maxHpPlusHeal.get();
Map expDist = new HashMap<>();
@@ -482,15 +483,14 @@ public class MapleMonster extends AbstractLoadedMapleLife {
for (MapleCharacter mc : mapChrs) {
Float mcExp = expDist.remove(mc.getId());
if (mcExp != null) {
+ float xp = mcExp;
boolean isKiller = (mc.getId() == killerId);
if (isKiller) {
if (eim != null) {
eim.monsterKilled(mc, this);
}
- }
-
- float xp = mcExp;
- if (isKiller) {
+
+ killerLevel = mc.getLevel();
xp += exp2;
}
@@ -529,7 +529,7 @@ public class MapleMonster extends AbstractLoadedMapleLife {
}
for (Entry party : partyExp.entrySet()) {
- distributeExperienceToParty(party.getKey(), party.getValue(), killerId, underleveled, minThresholdLevel);
+ distributeExperienceToParty(party.getKey(), party.getValue(), killerId, killerLevel, underleveled, minThresholdLevel);
}
for(MapleCharacter mc : underleveled) {
@@ -573,10 +573,12 @@ public class MapleMonster extends AbstractLoadedMapleLife {
}
}
- private void removeController() {
+ private Pair removeController() {
this.lockMonster();
try {
MapleCharacter chrController = getController();
+ boolean hadAggro = isControllerHasAggro();
+
if (chrController != null) { // this can/should only happen when a hidden gm attacks the monster
chrController.announce(MaplePacketCreator.stopControllingMonster(this.getObjectId()));
chrController.stopControllingMonster(this);
@@ -585,6 +587,8 @@ public class MapleMonster extends AbstractLoadedMapleLife {
setController(null);
setControllerHasAggro(false);
setControllerKnowsAboutAggro(false);
+
+ return new Pair<>(chrController, hadAggro);
} finally {
this.unlockMonster();
}
@@ -593,9 +597,8 @@ public class MapleMonster extends AbstractLoadedMapleLife {
public MapleCharacter killBy(final MapleCharacter killer) {
distributeExperience(killer != null ? killer.getId() : 0);
- removeController();
-
- final List toSpawn = this.getRevives(); // this doesn't work (?)
+ final Pair lastController = removeController();
+ final List toSpawn = this.getRevives();
if (toSpawn != null) {
final MapleMap reviveMap = map;
if (toSpawn.contains(9300216) && reviveMap.getId() > 925000000 && reviveMap.getId() < 926000000) {
@@ -630,6 +633,9 @@ public class MapleMonster extends AbstractLoadedMapleLife {
TimerManager.getInstance().schedule(new Runnable() {
@Override
public void run() {
+ MapleCharacter controller = lastController.getLeft();
+ boolean aggro = lastController.getRight();
+
for (Integer mid : toSpawn) {
final MapleMonster mob = MapleLifeFactory.getMonster(mid);
mob.setPosition(getPosition());
@@ -641,7 +647,7 @@ public class MapleMonster extends AbstractLoadedMapleLife {
}
reviveMap.spawnMonster(mob);
- if(mob.getId() >= 8810010 && mob.getId() <= 8810017 && reviveMap.isHorntailDefeated()) {
+ if (mob.getId() >= 8810010 && mob.getId() <= 8810017 && reviveMap.isHorntailDefeated()) {
boolean htKilled = false;
MapleMonster ht = reviveMap.getMonsterById(8810018);
@@ -663,6 +669,8 @@ public class MapleMonster extends AbstractLoadedMapleLife {
for(int i = 8810017; i >= 8810010; i--) {
reviveMap.killMonster(reviveMap.getMonsterById(i), killer, true);
}
+ } else if (controller != null) {
+ mob.switchController(controller, aggro);
}
if(eim != null) {
@@ -1176,10 +1184,10 @@ public class MapleMonster extends AbstractLoadedMapleLife {
}
public void refreshMobPosition() {
- updateMobPosition(getPosition());
+ resetMobPosition(getPosition());
}
- public void updateMobPosition(Point newPoint) {
+ public void resetMobPosition(Point newPoint) {
removeController();
setPosition(newPoint);
map.broadcastMessage(MaplePacketCreator.moveMonster(this.getObjectId(), false, -1, 0, 0, 0, this.getPosition(), this.getIdleMovement()));
@@ -1276,11 +1284,25 @@ public class MapleMonster extends AbstractLoadedMapleLife {
return stats.hasSkill(skillId, level);
}
+ public int getSkillPos(int skillId, int level) {
+ int pos = 0;
+ for (Pair ms : this.getSkills()) {
+ if (ms.getLeft() == skillId && ms.getRight() == level) {
+ return pos;
+ }
+
+ pos++;
+ }
+
+ return -1;
+ }
+
public boolean canUseSkill(MobSkill toUse) {
if (toUse == null) {
return false;
}
+ int useLimit = toUse.getLimit();
if (toUse.getSkillId() == 200) {
int i = 0;
for (MapleMapObject mo : getMap().getMapObjects()) {
@@ -1291,13 +1313,16 @@ public class MapleMonster extends AbstractLoadedMapleLife {
if (i > 100) {
return false;
}
+ if (map.isDojoMap()) { // spawns in dojo should be unlimited
+ useLimit = 0;
+ }
}
- if (toUse.getLimit() > 0) {
+ if (useLimit > 0) {
monsterLock.lock();
try {
Integer times = this.skillsUsed.get(new Pair<>(toUse.getSkillId(), toUse.getSkillLevel()));
- if (times != null && times >= toUse.getLimit()) {
+ if (times != null && times >= useLimit) {
return false;
}
} finally {
@@ -1307,20 +1332,24 @@ public class MapleMonster extends AbstractLoadedMapleLife {
monsterLock.lock();
try {
+ /*
for (Pair skill : usedSkills) {
if (skill.getLeft() == toUse.getSkillId() && skill.getRight() == toUse.getSkillLevel()) {
return false;
}
}
+ */
int mpCon = toUse.getMpCon();
if (mp < mpCon) {
return false;
}
+ /*
if (!this.applyAnimationIfRoaming(-1, toUse)) {
return false;
}
+ */
this.usedSkill(toUse);
} finally {
@@ -1380,16 +1409,18 @@ public class MapleMonster extends AbstractLoadedMapleLife {
}
}
- public int canUseAttack(int attackPos) {
+ public int canUseAttack(int attackPos, boolean isSkill) {
monsterLock.lock();
try {
+ /*
if (usedAttacks.contains(attackPos)) {
return -1;
}
+ */
Pair attackInfo = MapleMonsterInformationProvider.getInstance().getMobAttackInfo(this.getId(), attackPos);
if (attackInfo == null) {
- return usedAttacks.isEmpty() ? 0 : -1;
+ return -1;
}
int mpCon = attackInfo.getLeft();
@@ -1397,9 +1428,11 @@ public class MapleMonster extends AbstractLoadedMapleLife {
return -1;
}
+ /*
if (!this.applyAnimationIfRoaming(attackPos, null)) {
return -1;
}
+ */
usedAttack(attackPos, mpCon, attackInfo.getRight());
return 1;
diff --git a/src/server/life/MapleMonsterStats.java b/src/server/life/MapleMonsterStats.java
index 2d7c5738c6..bc97e2794c 100644
--- a/src/server/life/MapleMonsterStats.java
+++ b/src/server/life/MapleMonsterStats.java
@@ -37,7 +37,7 @@ import tools.Pair;
*/
public class MapleMonsterStats {
private boolean changeable;
- private int exp, hp, mp, level, PADamage, PDDamage, MADamage, MDDamage, dropPeriod, cp, buffToGive, removeAfter;
+ private int exp, hp, mp, level, PADamage, PDDamage, MADamage, MDDamage, dropPeriod, cp, buffToGive = -1, removeAfter;
private boolean boss, undead, ffaLoot, isExplosiveReward, firstAttack, removeOnMiss;
private String name;
private Map animationTimes = new HashMap();
@@ -151,7 +151,7 @@ public class MapleMonsterStats {
this.undead = undead;
}
- public boolean getUndead() {
+ public boolean isUndead() {
return undead;
}
@@ -193,8 +193,12 @@ public class MapleMonsterStats {
}
public void setSkills(List> skills) {
- for (Pair skill : skills) {
- this.skills.add(skill);
+ for (int i = this.skills.size(); i < skills.size(); i++) {
+ this.skills.add(null);
+ }
+
+ for (int i = 0; i < skills.size(); i++) {
+ this.skills.set(i, skills.get(i));
}
}
diff --git a/src/server/maps/MapleHiredMerchant.java b/src/server/maps/MapleHiredMerchant.java
index 4db00db6d0..0c1e8ce759 100644
--- a/src/server/maps/MapleHiredMerchant.java
+++ b/src/server/maps/MapleHiredMerchant.java
@@ -51,7 +51,7 @@ import net.server.audit.locks.MonitoredLockType;
/**
*
* @author XoticStory
- * @author Ronan (concurrency protection)
+ * @author Ronan - concurrency protection
*/
public class MapleHiredMerchant extends AbstractMapleMapObject {
private int ownerId, itemId, mesos = 0;
diff --git a/src/server/maps/MapleMap.java b/src/server/maps/MapleMap.java
index 086b72f63f..9c078e9a7e 100644
--- a/src/server/maps/MapleMap.java
+++ b/src/server/maps/MapleMap.java
@@ -1539,7 +1539,40 @@ public class MapleMap {
mr.setPosition(points.remove(points.size() - 1));
}
}
-
+
+ private MapleCharacter getNextControllerCandidate() {
+ int mincontrolled = Integer.MAX_VALUE;
+ MapleCharacter newController = null;
+
+ int mincontrolleddead = Integer.MAX_VALUE;
+ MapleCharacter newControllerDead = null;
+
+ chrRLock.lock();
+ try {
+ for (MapleCharacter chr : characters) {
+ if (!chr.isHidden()) {
+ int ctrlMonsSize = chr.getControlledMonsters().size();
+
+ if (chr.isAlive()) {
+ if (ctrlMonsSize < mincontrolled) {
+ mincontrolled = ctrlMonsSize;
+ newController = chr;
+ }
+ } else {
+ if (ctrlMonsSize < mincontrolleddead) {
+ mincontrolleddead = ctrlMonsSize;
+ newControllerDead = chr;
+ }
+ }
+ }
+ }
+ } finally {
+ chrRLock.unlock();
+ }
+
+ return newController != null ? newController : newControllerDead;
+ }
+
/**
* Automagically finds a new controller for the given monster from the chars
* on the map...
@@ -1553,29 +1586,28 @@ public class MapleMap {
return;
}
+ MapleCharacter newController;
MapleCharacter chrController = monster.getController();
if (chrController != null) {
if (chrController.getMap() != this) {
chrController.stopControllingMonster(monster);
+ newController = getNextControllerCandidate();
} else {
- return;
- }
- }
- int mincontrolled = -1;
- MapleCharacter newController = null;
- chrRLock.lock();
- try {
- for (MapleCharacter chr : characters) {
- int ctrlMonsSize = chr.getControlledMonsters().size();
-
- if (!chr.isHidden() && (ctrlMonsSize < mincontrolled || mincontrolled == -1)) {
- mincontrolled = ctrlMonsSize;
- newController = chr;
+ if (chrController.isAlive()) {
+ return;
}
+
+ newController = getNextControllerCandidate();
+ if (newController == null || !newController.isAlive()) {
+ return;
+ }
+
+ chrController.stopControllingMonster(monster);
}
- } finally {
- chrRLock.unlock();
+ } else {
+ newController = getNextControllerCandidate();
}
+
if (newController != null) { // was a new controller found? (if not no one is on the map)
if (monster.isFirstAttack()) {
newController.controlMonster(monster, true);
@@ -2364,11 +2396,8 @@ public class MapleMap {
chr.cancelEffectFromBuffStat(MapleBuffStat.MONSTER_RIDING);
chr.cancelBuffStats(MapleBuffStat.MONSTER_RIDING);
}
- if (mapid == 923010000) { // Kenta's Mount Quest
- if(getMonsterById(9300102) == null) {
- spawnMonsterOnGroundBelow(MapleLifeFactory.getMonster(9300102), new Point(77, 426));
- }
- } else if (mapid == 200090060) { // To Rien
+
+ if (mapid == 200090060) { // To Rien
int travelTime = getWorldServer().getTransportationTime(1 * 60 * 1000);
chr.announce(MaplePacketCreator.getClock(travelTime / 1000));
TimerManager.getInstance().schedule(new Runnable() {
diff --git a/src/server/maps/MaplePlayerShop.java b/src/server/maps/MaplePlayerShop.java
index 32c8544da7..1233fce37d 100644
--- a/src/server/maps/MaplePlayerShop.java
+++ b/src/server/maps/MaplePlayerShop.java
@@ -46,7 +46,7 @@ import net.server.audit.locks.factory.MonitoredReentrantLockFactory;
/**
*
* @author Matze
- * @author Ronan (concurrency protection)
+ * @author Ronan - concurrency protection
*/
public class MaplePlayerShop extends AbstractMapleMapObject {
private AtomicBoolean open = new AtomicBoolean(false);
diff --git a/src/server/maps/MapleTVEffect.java b/src/server/maps/MapleTVEffect.java
index 4868f0a783..3e87d53c5e 100644
--- a/src/server/maps/MapleTVEffect.java
+++ b/src/server/maps/MapleTVEffect.java
@@ -30,7 +30,7 @@ import tools.MaplePacketCreator;
/*
* MapleTVEffect
* @author MrXotic
- * @author Ronan (made MapleTV mechanics synchronous)
+ * @author Ronan - made MapleTV mechanics synchronous
*/
public class MapleTVEffect {
diff --git a/src/server/quest/MapleQuest.java b/src/server/quest/MapleQuest.java
index e1b964c9f9..65f7c4c4b6 100644
--- a/src/server/quest/MapleQuest.java
+++ b/src/server/quest/MapleQuest.java
@@ -45,7 +45,7 @@ import tools.StringUtil;
/**
*
* @author Matze
- * @author Ronan (support for medal quests)
+ * @author Ronan - support for medal quests
*/
public class MapleQuest {
diff --git a/src/tools/DatabaseConnection.java b/src/tools/DatabaseConnection.java
index d38f429d29..802c2ef47f 100644
--- a/src/tools/DatabaseConnection.java
+++ b/src/tools/DatabaseConnection.java
@@ -11,9 +11,9 @@ import com.zaxxer.hikari.HikariDataSource;
import constants.ServerConstants;
/**
- * @author Frz (Big Daddy)
- * @author The Real Spookster (some modifications to this beautiful code)
- * @author Ronan (some connection pool to this beautiful code)
+ * @author Frz - Big Daddy
+ * @author The Real Spookster - some modifications to this beautiful code
+ * @author Ronan - some connection pool to this beautiful code
*/
public class DatabaseConnection {
private static HikariDataSource ds;
diff --git a/src/tools/MaplePacketCreator.java b/src/tools/MaplePacketCreator.java
index 56de91e59d..1d4955637d 100644
--- a/src/tools/MaplePacketCreator.java
+++ b/src/tools/MaplePacketCreator.java
@@ -2293,24 +2293,6 @@ public class MaplePacketCreator {
return mplew.getPacket();
}
- /*
- public static byte[] moveMonster(int useskill, int skill, int skill_1, int skill_2, int skill_3, int skill_4, int oid, Point startPos, List moves) {
- final MaplePacketLittleEndianWriter mplew = new MaplePacketLittleEndianWriter();
- mplew.writeShort(SendOpcode.MOVE_MONSTER.getValue());
- mplew.writeInt(oid);
- mplew.write(0);
- mplew.write(useskill);
- mplew.write(skill);
- mplew.write(skill_1);
- mplew.write(skill_2);
- mplew.write(skill_3);
- mplew.write(skill_4);
- mplew.writePos(startPos);
- serializeMovementList(mplew, moves);
- return mplew.getPacket();
- }
- */
-
public static byte[] summonAttack(int cid, int summonOid, byte direction, List allDamage) {
final MaplePacketLittleEndianWriter mplew = new MaplePacketLittleEndianWriter();
//b2 00 29 f7 00 00 9a a3 04 00 c8 04 01 94 a3 04 00 06 ff 2b 00
diff --git a/tools/MapleIdRetriever/handbook/Use.txt b/tools/MapleIdRetriever/handbook/Use.txt
index 714aa06303..0fcd125a84 100644
--- a/tools/MapleIdRetriever/handbook/Use.txt
+++ b/tools/MapleIdRetriever/handbook/Use.txt
@@ -1177,7 +1177,7 @@
2280000 - Lava Bottle - A glass bottle that contains an actual lava, which is waiting to be spilled out. Drink this lava, and the lava will consume the body with fire, which will enable the drinker to master Fire Demon.
2280001 - Black Cloud Machine - A mechanical device that produces black clouds. Enables the character to acquire the Smokescreen skill using the clouds.
2280002 - Firm Hand - A stimulant packaged inside a bottle that resembles a clenched fist. Drinking the stimulant will allow the character to acquire The Will of a Warrior.
-2280003 - [Skill Book] Maple Hero - You can learn #cMaple Hero# with this book.rnJob : All 4th jobsrnCondition : #cMaple Hero# not acquired.
+2280003 - [Skill Book] Maple Warrior - You can learn #cMaple Warrior# with this book.rnJob : All 4th jobsrnCondition : #cMaple Warrior# not acquired.
2280004 - [Skill Book] Infinity - You can learn #Infinity# with this book.rnJob : 4th Advancement MagicianrnCondition : #cInfinity# not acquired
2280005 - [Skill Book] Dragon's Breath - You can learn #cDragon's Breath# with this book.wnJob : 4th Advancement BowmanrnCondition : #cDragon's Breath# not acquired
2280006 - [Skill Book] Taunt - You can learn #cTaunt# with this book.rnJob : 4th Advancement ThiefrnCondition : #cTaunt# not acquired
@@ -1283,7 +1283,7 @@
2290093 - [Mastery Book] Assassinate - This increases the master level of #cAssassinate# up to 30 with 50% of chance.rnClass : ShadowerrnCondition : Skill level above 15
2290094 - [Mastery Book] Smokescreen - This increases the master level of #cSmokescreen# up to 20 with 70% of chance.rnClass : ShadowerrnCondition : Skill level above 5
2290095 - [Mastery Book] Smokescreen - This increases the master level of #cSmokescreen# up to 30 with 50% of chance.rnClass : ShadowerrnCondition : Skill level above 15
-2290096 - [Mastery Book] Maple Hero 20 - This increases the master level of #cMaple Hero# up to 20 with 70% of chance.rnJob : All 4th Advancement JobsrnCondition : Skill level above 5
+2290096 - [Mastery Book] Maple Warrior 20 - This increases the master level of #cMaple Warrior# up to 20 with 70% of chance.rnJob : All 4th Advancement JobsrnCondition : Skill level above 5
2290097 - [Mastery Book] Dragon Strike - With a 70% success rate, it raises the Master Level of #cDragon Strike# to 20.nJob : BuccaneernRequirement : At least Level 5 in this skill
2290098 - [Mastery Book] Dragon Strike - With a 50% success rate, it raises the Master Level of #cDragon Strike# to 30.nJob : BuccaneernRequirement : At least Level 15 in this skill
2290099 - [Mastery Book] Energy Orb - With a 70% success rate, it raises the Master Level of #cEnergy Orb# to 20.nJob : BuccaneernRequirement : At least Level 5 in this skill
@@ -1312,7 +1312,7 @@
2290122 - [Mastery Book] Battleship Torpedo - With a 50% success rate, it raises the Master Level of #cBattleship Torpedo# to 30.nJob : CorsairnRequirement : At least Level 15 in this skill
2290123 - [Mastery Book] Hypnotize - With a 70% success rate, it raises the Master Level of #cHypnotize# to 20.nJob : CorsairnRequirement : At least Level 5 in this skill
2290124 - [Mastery Book] Bullseye - With a 70% success rate, it raises the Master Level of #cBullseye# to 20.nJob : CorsairnRequirement : At least Level 5 in this skill
-2290125 - [Mastery Book] Maple Hero 30 - This increases the master level of #cMaple Hero# up to 30 with 50% of chance.rnJob : All 4th Advancement JobsrnCondition : Skill level above 15
+2290125 - [Mastery Book] Maple Warrior 30 - This increases the master level of #cMaple Warrior# up to 30 with 50% of chance.rnJob : All 4th Advancement JobsrnCondition : Skill level above 15
2310000 - The Owl of Minerva - #cThe Owl of Minerva#, which represents wisdom, can be used to search for items sold at the Free Market. #cDisappears right after showing the results of the item search#.
2320000 - Teleport Rock - Remembers 5 maps of your choice. This rock will enable you to #cteleport to the map you remembered#. It can even allow you to #cmove to the map where a certain character is#, provided that the person is in the same channel at the same world.
2330000 - Bullet - A bullet made out of steel. A set contains numerous bullets and once they are used up, they'll need to be recharged.\nAttack + 10
diff --git a/wz/Map.wz/Map/Map2/240070502.img.xml b/wz/Map.wz/Map/Map2/240070502.img.xml
index 13c3995939..c160084925 100644
--- a/wz/Map.wz/Map/Map2/240070502.img.xml
+++ b/wz/Map.wz/Map/Map2/240070502.img.xml
@@ -1,2166 +1,27 @@
-
-
-
-
-
-
-
+
+
+
+
+
+
+
+
-
-
-
-
-
-
-
+
+
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
-
-
+
+
-
-
+
-
+
+
+
-
-
-
+
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/wz/Map.wz/Map/Map9/925010300.img.xml b/wz/Map.wz/Map/Map9/925010300.img.xml
index da91c172b7..d5b771cefe 100644
--- a/wz/Map.wz/Map/Map9/925010300.img.xml
+++ b/wz/Map.wz/Map/Map9/925010300.img.xml
@@ -6,7 +6,7 @@
-
+
diff --git a/wz/Quest.wz/Check.img.xml b/wz/Quest.wz/Check.img.xml
index 96f9965669..7472564108 100644
--- a/wz/Quest.wz/Check.img.xml
+++ b/wz/Quest.wz/Check.img.xml
@@ -59883,12 +59883,6 @@
-
-
-
-
-
-
@@ -60008,12 +60002,7 @@
-
-
-
-
-
-
+
diff --git a/wz/Quest.wz/Say.img.xml b/wz/Quest.wz/Say.img.xml
index ec6f82b9ea..acfbca680f 100644
--- a/wz/Quest.wz/Say.img.xml
+++ b/wz/Quest.wz/Say.img.xml
@@ -57476,7 +57476,7 @@
-
+
@@ -57491,7 +57491,7 @@
-
+
diff --git a/wz/String.wz/Consume.img.xml b/wz/String.wz/Consume.img.xml
index 010b4255ca..3025495d16 100644
--- a/wz/String.wz/Consume.img.xml
+++ b/wz/String.wz/Consume.img.xml
@@ -4704,8 +4704,8 @@
-
-
+
+
@@ -9085,8 +9085,8 @@
-
-
+
+
@@ -9201,8 +9201,8 @@
-
-
+
+