diff --git a/.gitignore b/.gitignore index c635df16b3..480e5c0c55 100644 --- a/.gitignore +++ b/.gitignore @@ -31,6 +31,10 @@ /tools/MapleInvalidItemIdFetcher/dist/ /tools/MapleInvalidItemIdFetcher/nbproject/ +/tools/MapleInvalidItemWithNoNameFetcher/build/ +/tools/MapleInvalidItemWithNoNameFetcher/dist/ +/tools/MapleInvalidItemWithNoNameFetcher/nbproject/ + /tools/MapleMapInfoRetriever/build/ /tools/MapleMapInfoRetriever/dist/ /tools/MapleMapInfoRetriever/nbproject/ diff --git a/README.md b/README.md index 187491f2ef..8c249a1c77 100644 --- a/README.md +++ b/README.md @@ -51,7 +51,7 @@ Recommended localhost: https://hostr.co/m2bVtnizCtmD --- ### Development status -Status: __Released__. +Status: __In development (4th round)__. HeavenMS development achieved an acceptable state-of-the-art and will get into a halt. A heartfelt thanks for everyone that contributed in some way for the progress of this server! diff --git a/docs/feature_list.md b/docs/feature_list.md index 9354192e89..4c32821c70 100644 --- a/docs/feature_list.md +++ b/docs/feature_list.md @@ -60,20 +60,24 @@ Player Social Network: * Implemented Marriage system from the ground-up (excluding character packet encoding parts that were already present, proper credits given throughout the source files). * Beginners can create and join a "beginner-only" party (characters up to level 10). * Enhanced synchronization on Player Shops and Hired Merchants. Transactions made are instantly informed to the owner. -* Game minirooms such as match cards and omok now has semi-functional password system. +* Game minirooms such as match cards and omok now has a functional password system. * Item pickup cooldown on non-owned/non-partyowned items functional. * Further improved the server's ranking system, now displaying properly daily player ranking movement. * Automated support for Player NPCs and Hall of Fame. +* Protected concurrently and improved the face expression system, guarding from trivial packet spam and exploits. Cash & Items: * EXP/DROP/Cosmetic Coupons. * EXP/DROP coupons now appears as a buff effect when on active time. * Great deal of cash items functional. +* MapleTV mechanics stabilized and separated by world. +* GMS-esque omok/match card drop chances. * New scroll: antibanish. For use only in cases where bosses send a player back to town. * Inventory system properly checks for item slot free space and ownership. * Storage with "Arrange Items" feature functional. * Close-quarters evaluation mode for items (sandbox). +* Further improved Karma scissors mechanics. * Spikes on shoes. * Vega's spell. * Owl of Minerva. @@ -91,11 +95,11 @@ Monsters, Maps & Reactors: * Every skill/mastery book is now droppable by mobs. * Mobs now can drop more than one of the same equipment (number of possible drops defined at droptime, uses the minimum/maximum quantity fields on DB). * Redesigned HT mechanics for spawn and linked damage to the sponge. -* Improved map bounding checks for item drop points, assuring most of the items dropped will be available to pickup inside the accessible map area. * Limited item count on maps, smartly expiring oldest registered items, preventing potential item flooding. * Implemented Zombify disease status. * Added Boss HP Bar for dozens of bosses (needs provided custom wz). * If multiple bosses are on the same area, client will prioritize Boss HP bar of the target of the player. +* Improved map bounding checks for item drop points, assuring most of the items dropped will be available to pickup inside the accessible map area. * Boats, elevator and other travelling mechanics fully working. * HP decreasing overtime on maps and mechanics to prevent them (consumables, equips) fully functional. * Crimson Balrog boat approaching visual effect made functional. @@ -131,7 +135,9 @@ Server potentials: * Enhanced buff system: smartly checks for the best available buff effects to be active on the player. * Enhanced AP auto-assigner: exactly matches AP with the needed for the player's current level, surplus assigned to the primary attribute. * Tweaked pet/mount hunger: calculations for fullness/tiredness takes active time of the subject into account. +* Consistent experience gain system. * NPC crafters (equips, plates/jewels, etc) now won't take items freely if the requirement conditions are not properly met. +* Improved Duey mechanics: package received popup and reviewed many delivery mechanics. * Pet item pickup now gives preference to player attacks rather than forcing attack disables when automatically picking up. * Channel capacity bar functional and world servers with max capacity checks. * Disease status are now visible for other players, even when changing maps. @@ -140,6 +146,8 @@ Server potentials: * Custom jail system (needs provided custom wz). * Custom buyback system. * Delete Character (requires ENABLE_PIC activated). +* Smoothed up view-all-char feature, now showing properly all available characters and not disconnecting players too often. +* Centralized getcurrenttime throughout several server handlers, boosting it's performance overall. * Autosaver (periodically saves on DB current state of every player in-game). * Both fixed and randomized versions of HP/MP growth rate available, regarding player job (enable one at ServerConstants). Placeholder for HP/MP washing feature. * Reallocated mapobjectids utilization throughout the source, preventing issues such as "NPC disappearing mysteriously after some server time" from happening. @@ -150,6 +158,7 @@ Server potentials: Custom NPCs: * Spiegelmann: automatized rock-refiner. +* Asia: scroll & rarities shop NPC. * Abdula: lists droppers of needed skill/mastery books. * Agent E: accessory crafter. * Donation Box: automatized item-buyer. @@ -169,6 +178,7 @@ External tools: * MapleCouponInstaller - Retrieves coupon info from the WZ and makes a SQL table with it. The server will use that table to gather info regarding rates and intervals. * MapleIdRetriever - Two behaviors: generates a SQL table with relation (id, name) of the handbook given as input. Given a file with names, outputs a file with ids. * MapleInvalidItemIdFetcher - Generates a file listing all inexistent itemid's currently laying on the DB. +* MapleInvalidItemWithNoNameFetcher - Generates two files: one listing all itemid's with inexistent name and "cash" property. And other with a prepared XML to solve the name issue. * MapleMapInfoRetriever - Basic tool for detecting missing info nodes on the map field structures (maps failing to have an info node on the WZ is an critical issue). * MapleMesoFetcher - Creates meso drop data for mobs with more than 4 items (thus overworld mobs), calculations based on mob level and whether it's a boss or not. * MapleMobBookIndexer - Generates a SQL table with all relations of cardid and mobid present in the mob book. @@ -190,8 +200,11 @@ Project: * Uncovered many Send/Recv opcodes throughout the source. * Reviewed many Java object aspects that needed concurrency protection. * Reviewed SQL data, eliminating duplicated entries on the tables. +* Improved login phase, using cache over DB queries. * Usage of HikariCP to improve the DB connection management. +* Developed many survey tools for content profiling. * Protected many flaws with login management system. +* Channel, World and Server-wide timer management. * Heavily reviewed future task management inside the project. Way less trivial schedules are spawned now, relieving task overload on the TimerManager. * ThreadTracker: embedded auditing tool for run-time deadlock scanning throughout the server source (relies heavily on memory usage, designed only for debugging purposes). diff --git a/docs/mychanges_ptbr.txt b/docs/mychanges_ptbr.txt index 2f2affb4f8..9e4be79cc6 100644 --- a/docs/mychanges_ptbr.txt +++ b/docs/mychanges_ptbr.txt @@ -1129,4 +1129,18 @@ Corrigido função monsterValue dos scripts de eventos sendo processado múltipl Corrigido pinkbean nao dropando itens dentro da expedição. 14 Julho 2018, -Movido "recharge" de Donator para JrGM. \ No newline at end of file +Movido "recharge" de Donator para JrGM. +Otimizado busca por currenttimemillis, agora buscando do objeto do servidor ao invés de verificar pelo ambiente JVM. +Corrigido handlers de organização de inventários não protegendo concorrentemente inventários antes de realizar a ordenação. + +15 - 16 Julho 2018, +Implementado parte da questline level 120+ de Cygnus Knights. +Corrigido itens de cash sendo vendidos em player shop/hired merchant. +Corrigido login atribuindo sempre conta de GM (limitando ações como trade) quando há pelo menos um char GM naquela conta - isso pode até ser mesmo necessário, criado um flag pra continuar enforcando o "GM account". +Estabilizado mecânicas de MapleTV e separado atividade da MapleTV pra cada world. +Normalizado Character.wz: agora todos os equipamentos que precisam ter "cash" o tem. +Normalizado String.wz: agora todos os itens sem "name" o tem. +Nova ferramenta: MapleInvalidItemWithNoNameFetcher. Busca por itemids sem as propriedades "cash" e "name" nos conjuntos de wz.xml. + +17 Julho 2018, +Corrigido problema crítico no novo sistema de login, que impedia contas recém-criadas de logar no jogo. \ No newline at end of file diff --git a/scripts/npc/1103000.js b/scripts/npc/1103000.js new file mode 100644 index 0000000000..67e606791f --- /dev/null +++ b/scripts/npc/1103000.js @@ -0,0 +1,46 @@ +/* + 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.sendOk("I am Advanced Knight #b#p1103000##k. Thanks to your bravery I and all of Ereve have been rescued from the grasps of Eleanor. By the kindness of our Empress, well battled!"); + cm.dispose(); + } + } +} diff --git a/scripts/npc/1104002.js b/scripts/npc/1104002.js new file mode 100644 index 0000000000..2624091578 --- /dev/null +++ b/scripts/npc/1104002.js @@ -0,0 +1,61 @@ +/* + 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 { + var mapobj = cm.getMap(); + + if (mode == 0 && type > 0) { + cm.getPlayer().dropMessage(5, "Eleanor: Oh, lost the Empress and still challenging us? Now you've done it! Prepare yourself!!!"); + + mapobj.spawnMonsterOnGroundBelow(Packages.server.life.MapleLifeFactory.getMonster(9001010), new Packages.java.awt.Point(850, 0)); + mapobj.destroyNPC(1104002); + + cm.dispose(); + return; + } + if (mode == 1) + status++; + else + status--; + + if(status == 0) { + if(!cm.isQuestStarted(20407)) { + cm.sendOk("... Knight, you still #bseem unsure to face this fight#k, don't you? There's no grace in challenging someone when they are still not mentally ready for the battle. Talk your peace to that big clumsy bird of yours, maybe it'll put some guts on you."); + cm.dispose(); + return; + } + + cm.sendAcceptDecline("Hahahahaha! This place's Empress is already under my domain, that's surely a great advance on the #bBlack Wings#k' overthrow towards Maple World... And you, there? Still wants to face us? Or, better yet, #rfeel fancy to join us#k since there's nothing more you can do?"); + } else if (status == 1) { + cm.sendOk("Heh, cowards have no place on the #rBlack Mage's#k army. Begone!"); + cm.dispose(); + } + } +} diff --git a/scripts/npc/1104200.js b/scripts/npc/1104200.js new file mode 100644 index 0000000000..46fe5a106d --- /dev/null +++ b/scripts/npc/1104200.js @@ -0,0 +1,55 @@ +/* + 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.sendNext("#b#p1104002##k... The black witch... Trapped me here... There's no time now, she's already on her way to #rattack Ereve#k!"); + } else if (status == 1) { + cm.sendYesNo("Fellow Knight, you must reach to #rEreve#k right now, #rthe Empress is in danger#k!! Even in this condition, I can still Magic Warp you there. When you're ready talk to me. #bAre you ready to face Eleanor?#k"); + } else if (status == 2) { + if(cm.getWarpMap(913030000).countPlayers() == 0) { + cm.warp(913030000, 0); + } else { + cm.sendOk("There's someone already challenging her. Please wait awhile."); + } + + cm.dispose(); + } + } +} \ No newline at end of file diff --git a/scripts/npc/1104201.js b/scripts/npc/1104201.js new file mode 100644 index 0000000000..38b68df694 --- /dev/null +++ b/scripts/npc/1104201.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 . +*/ + +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.isQuestCompleted(20407) || cm.isQuestStarted(20407) && cm.getQuestProgress(20407, 9001010) != 0) && cm.getMap().countMonster(9001010) == 0 && cm.getMap().getNPCById(1104002) == null) { + cm.sendOk("... Hnngh... #b#h0##k, is that you...? #r#p1104002##k... She's already here... #b#h0##k, I'm truly sorry I can't help you right now in this state, just when a bigger threat appeared I could do nothing for my people.... Please I beg you, please defeat her, #b#h0##k!! ...."); + cm.spawnNpc(1104002, new java.awt.Point(850, 0), cm.getMap()); + } else { + cm.sendOk("..."); + } + + cm.dispose(); + } + } +} diff --git a/scripts/npc/1104202.js b/scripts/npc/1104202.js new file mode 100644 index 0000000000..e5600f02ab --- /dev/null +++ b/scripts/npc/1104202.js @@ -0,0 +1,46 @@ +/* + 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.sendOk("..."); + cm.dispose(); + } + } +} diff --git a/scripts/npc/1104203.js b/scripts/npc/1104203.js new file mode 100644 index 0000000000..e5600f02ab --- /dev/null +++ b/scripts/npc/1104203.js @@ -0,0 +1,46 @@ +/* + 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.sendOk("..."); + cm.dispose(); + } + } +} diff --git a/scripts/npc/1104204.js b/scripts/npc/1104204.js new file mode 100644 index 0000000000..e5600f02ab --- /dev/null +++ b/scripts/npc/1104204.js @@ -0,0 +1,46 @@ +/* + 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.sendOk("..."); + cm.dispose(); + } + } +} diff --git a/scripts/npc/1104205.js b/scripts/npc/1104205.js new file mode 100644 index 0000000000..e5600f02ab --- /dev/null +++ b/scripts/npc/1104205.js @@ -0,0 +1,46 @@ +/* + 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.sendOk("..."); + cm.dispose(); + } + } +} diff --git a/scripts/npc/1104206.js b/scripts/npc/1104206.js new file mode 100644 index 0000000000..e5600f02ab --- /dev/null +++ b/scripts/npc/1104206.js @@ -0,0 +1,46 @@ +/* + 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.sendOk("..."); + cm.dispose(); + } + } +} diff --git a/scripts/npc/1104207.js b/scripts/npc/1104207.js new file mode 100644 index 0000000000..e5600f02ab --- /dev/null +++ b/scripts/npc/1104207.js @@ -0,0 +1,46 @@ +/* + 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.sendOk("..."); + cm.dispose(); + } + } +} diff --git a/scripts/npc/2100002.js b/scripts/npc/2100002.js index c6d032441f..2cbe7b96f0 100644 --- a/scripts/npc/2100002.js +++ b/scripts/npc/2100002.js @@ -6,6 +6,6 @@ function start() { } function action(mode, type, selection) { - cm.openShopNPC(48); + cm.openShopNPC(2100002); cm.dispose(); } \ No newline at end of file diff --git a/scripts/npc/2100003.js b/scripts/npc/2100003.js index 8e20e05d1b..2abc59d8aa 100644 --- a/scripts/npc/2100003.js +++ b/scripts/npc/2100003.js @@ -6,6 +6,6 @@ function start() { } function action(mode, type, selection) { - cm.openShopNPC(52); + cm.openShopNPC(2100003); cm.dispose(); } \ No newline at end of file diff --git a/scripts/npc/2103002.js b/scripts/npc/2103002.js index f9a51575b0..eaf066d340 100644 --- a/scripts/npc/2103002.js +++ b/scripts/npc/2103002.js @@ -43,7 +43,7 @@ function action(mode, type, selection) { if(status == 0) { if(cm.isQuestStarted(3923) && !cm.haveItem(4031578, 1)) { if(cm.canHold(4031578, 1)) { - cm.sendOk("You have just swiped the ring. Clear the area asap.", 2); + cm.sendOk("You have just swiped the ring. Clear the area asap!", 2); cm.gainItem(4031578, 1); } else { cm.sendOk("You don't have a ETC slot available.", 2); diff --git a/scripts/npc/9977777.js b/scripts/npc/9977777.js index 6d30fe0578..47fddf1b35 100644 --- a/scripts/npc/9977777.js +++ b/scripts/npc/9977777.js @@ -73,9 +73,10 @@ function writeFeatureTab_PlayerSocialNetwork() { addFeature("Party for novices-only."); addFeature("Thoroughly reviewed P. Shops and H. Merchants."); addFeature("Transactions on Merchs instantly announced to owner."); - addFeature("Game minirooms with semi-functional pw system."); + addFeature("Game minirooms with functional pw system."); addFeature("Proper item pickup cooldown on non-owned items."); addFeature("Improved ranking system, with daily movement."); + addFeature("Protected and improved face expression system."); addFeature("Automated support for Player NPCs and Hall of Fame."); addFeature("Engagement & Wedding system."); } @@ -84,6 +85,7 @@ function writeFeatureTab_CashItems() { addFeature("EXP/DROP/Cosmetic Coupons."); addFeature("EXP/DROP Coupon as buff effect during active time."); addFeature("Great deal of cash items functional."); + addFeature("MapleTV mechanics stabilized and split by world."); addFeature("GMS-esque omok/match card drop chances."); addFeature("New town scroll: antibanish. Counters boss banishes."); addFeature("Inventory system checks for free slot & stack space."); @@ -112,6 +114,7 @@ function writeFeatureTab_MonstersMapsReactors() { addFeature("Added Boss HP Bar for dozens of bosses."); addFeature("Game will favor showing the targeted boss HPbar."); addFeature("Dmg overtime on maps and neutralizers functional."); + addFeature("Items will consistently stay within the walking area."); addFeature("Boats, elevator and other travel mechanics functional."); addFeature("C. Balrog's boat approaching visual effect functional."); addFeature("Maps having everlasting items no longer expires them."); @@ -119,6 +122,7 @@ function writeFeatureTab_MonstersMapsReactors() { addFeature("Uncovered missing portal SFX on scripted portals."); addFeature("PQ boxes sprays items when opened, GMS-like."); addFeature("Reactors pick items up smartly from the field."); + addFeature("Updated scripted portals now with proper portal SFX."); addFeature("Reviewed Masteria, W. Tour, N. Desert and Neo City."); addFeature("Giant Cake boss drops s. bags and Maple items."); } @@ -145,6 +149,7 @@ function writeFeatureTab_Serverpotentials() { addFeature("Enhanced auto-pot system: smart pet potion handle."); addFeature("Enhanced buff system: best buffs effects takes place."); addFeature("Enhanced AP auto-assigner: focus on eqp demands."); + addFeature("Tweaked pet/mount hunger to a balanced growth rate."); addFeature("Consistent experience gain system."); addFeature("NPC crafters won't take items freely anymore."); addFeature("Duey: pkg rcvd popup and many delivery mechanics."); @@ -157,9 +162,11 @@ function writeFeatureTab_Serverpotentials() { addFeature("Custom buyback system, uses mesos / NX, via MTS."); addFeature("Delete Character."); addFeature("Smooth view-all-char, now showing all account chars."); + addFeature("Centralized servertime, boosting handler performance."); addFeature("Autosaver (periodically saves player's data on DB)."); addFeature("Fixed and randomized HP/MP growth rate available."); addFeature("Prevented 'NPC gone after some uptime' issue."); + addFeature("Implemented starters' AP assigning for under level 11."); addFeature("AP assigning available for novices level 10 or below."); addFeature("Automatic account registration - thanks shavit!"); } @@ -202,6 +209,7 @@ function writeFeatureTab_Project() { addFeature("Reviewed SQL data, eliminating duplicated entries."); addFeature("Improved login phase, using cache over DB queries."); addFeature("Protected many flaws with login management system."); + addFeature("Usage of HikariCP to improve DB connection calls."); addFeature("Developed many survey tools for content profiling."); addFeature("ThreadTracker: runtime tool for deadlock detection."); addFeature("Channel, World and Server-wide timer management."); diff --git a/scripts/portal/elevator.js b/scripts/portal/elevator.js index 72bddbe0bd..d793d9b1b8 100644 --- a/scripts/portal/elevator.js +++ b/scripts/portal/elevator.js @@ -1,12 +1,11 @@ function enter(pi) { try { - var elevator = pi.getEventManager("Elevator"); + var elevator = pi.getEventManager("elevator"); if (elevator == null) { pi.getPlayer().dropMessage(5, "The elevator is under maintenance."); } else if (elevator.getProperty(pi.getMapId() == 222020100 ? ("goingUp") : ("goingDown")).equals("false")) { pi.playPortalSound(); pi.warp(pi.getMapId() == 222020100 ? 222020110 : 222020210, 0); - //elevator.getIv().invokeFunction(pi.getMapId() == 222020110 ? "goUp" : "goDown"); - return true; + return true; } else if (elevator.getProperty(pi.getMapId() == 222020100 ? ("goingUp") : ("goingDown")).equals("true")) { pi.getPlayer().dropMessage(5, "The elevator is currently moving."); } diff --git a/scripts/portal/enterWitch.js b/scripts/portal/enterWitch.js index f4e3770f05..e21cb9dd55 100644 --- a/scripts/portal/enterWitch.js +++ b/scripts/portal/enterWitch.js @@ -1,13 +1,20 @@ function enter(pi) { - if (pi.getQuestStatus(20407) == 2) { - pi.playPortalSound(); pi.warp(924010200,0); - return true; - } else if (pi.getQuestStatus(20406) == 2) { - pi.playPortalSound(); pi.warp(924010100,0); - return true; - } else if (pi.getQuestStatus(20404) == 2) { - pi.playPortalSound(); pi.warp(924010000,0); + if (pi.isQuestCompleted(20404)) { + var warpMap; + + if (pi.isQuestCompleted(20407)) { + warpMap = 924010200; + } else if (pi.isQuestCompleted(20406)) { + warpMap = 924010100; + } else { + warpMap = 924010000; + } + + pi.playPortalSound(); + pi.warp(warpMap, 1); return true; + + } else { pi.playerMessage(5, "I shouldn't go here.. it's creepy!"); return false; diff --git a/scripts/portal/outDarkEreb.js b/scripts/portal/outDarkEreb.js new file mode 100644 index 0000000000..b56ce8f2ae --- /dev/null +++ b/scripts/portal/outDarkEreb.js @@ -0,0 +1,27 @@ +/* + This file is part of the OdinMS Maple Story Server + Copyright (C) 2008 Patrick Huy + Matthias Butz + Jan Christian Meyer + + 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) { + var warpMap = pi.isQuestCompleted(20407) ? 924010200 : 924010100; + + pi.playPortalSound(); pi.warp(warpMap, 0); + return true; +} \ No newline at end of file diff --git a/scripts/quest/1021.js b/scripts/quest/1021.js index 434a2b6c34..cf5140b563 100644 --- a/scripts/quest/1021.js +++ b/scripts/quest/1021.js @@ -29,68 +29,81 @@ importPackage(Packages.client); var status = -1; function start(mode, type, selection) { - status++; - if (mode != 1) { - if(type == 1 && mode == 0) - status -= 2; - else{ + if (mode == -1) { + qm.dispose(); + } else { + if(mode == 0 && type > 0) { qm.dispose(); return; } - } - if (status == 0) - qm.sendNext("Hey, Man~ What's up? Haha! I am Roger who can teach you adorable new Maplers lots of information."); - else if (status == 1) - qm.sendNextPrev("You are asking who made me do this? Ahahahaha!\r\nMyself! I wanted to do this and just be kind to you new travellers."); - else if (status == 2) - qm.sendAcceptDecline("So..... Let me just do this for fun! Abaracadabra~!"); - else if (status == 3) { - if (qm.c.getPlayer().getHp() >= 50) { - qm.c.getPlayer().setHp(25); - qm.c.getPlayer().updateSingleStat(MapleStat.HP, 25); - } - if (!qm.haveItem(2010007)) - qm.gainItem(2010007, 1); + + if (mode == 1) + status++; + else + status--; + + if (status == 0) + qm.sendNext("Hey, Man~ What's up? Haha! I am Roger who can teach you adorable new Maplers lots of information."); + else if (status == 1) + qm.sendNextPrev("You are asking who made me do this? Ahahahaha!\r\nMyself! I wanted to do this and just be kind to you new travellers."); + else if (status == 2) + qm.sendAcceptDecline("So..... Let me just do this for fun! Abaracadabra~!"); + else if (status == 3) { + if (qm.c.getPlayer().getHp() >= 50) { + qm.c.getPlayer().setHp(25); + qm.c.getPlayer().updateSingleStat(MapleStat.HP, 25); + } + + if (!qm.haveItem(2010007)) { + qm.gainItem(2010007, 1); + } + qm.forceStartQuest(); qm.sendNext("Surprised? If HP becomes 0, then you are in trouble. Now, I will give you #rRoger's Apple#k. Please take it. You will feel stronger. Open the Item window and double click to consume. Hey, it's very simple to open the Item window. Just press #bI#k on your keyboard."); - } else if (status == 4) { - qm.sendNextPrev("Please take all Roger's Apples that I gave you. You will be able to see the HP bar increasing. Please talk to me again when you recover your HP 100%."); - } else if (status == 5) { - qm.showInfo("UI/tutorial.img/28"); - qm.dispose(); + } else if (status == 4) { + qm.sendNextPrev("Please take all Roger's Apples that I gave you. You will be able to see the HP bar increasing. Please talk to me again when you recover your HP 100%."); + } else if (status == 5) { + qm.showInfo("UI/tutorial.img/28"); + qm.dispose(); + } } } function end(mode, type, selection) { - status++; - if (mode != 1) { - if(type == 1 && mode == 0) - status -= 2; - else{ + if (mode == -1) { + qm.dispose(); + } else { + if(mode == 0 && type > 0) { qm.dispose(); return; } - } - if (status == 0) - if (qm.c.getPlayer().getHp() < 50) { - qm.sendNext("Hey, your HP is not fully recovered yet. Did you take all the Roger's Apple that I gave you? Are you sure?"); + + if (mode == 1) + status++; + else + status--; + + if (status == 0) + if (qm.c.getPlayer().getHp() < 50) { + qm.sendNext("Hey, your HP is not fully recovered yet. Did you take all the Roger's Apple that I gave you? Are you sure?"); + qm.dispose(); + } else + qm.sendNext("How easy is it to consume the item? Simple, right? You can set a #bhotkey#k on the right bottom slot. Haha you didn't know that! right? Oh, and if you are a beginner, HP will automatically recover itself as time goes by. Well it takes time but this is one of the strategies for the beginners."); + else if (status == 1) + qm.sendNextPrev("Alright! Now that you have learned alot, I will give you a present. This is a must for your travel in Maple World, so thank me! Please use this under emergency cases!"); + else if (status == 2) + qm.sendNextPrev("Okay, this is all I can teach you. I know it's sad but it is time to say good bye. Well take care if yourself and Good luck my friend!\r\n\r\n#fUI/UIWindow.img/QuestIcon/4/0#\r\n#v2010000# 3 #t2010000#\r\n#v2010009# 3 #t2010009#\r\n\r\n#fUI/UIWindow.img/QuestIcon/8/0# 10 exp"); + else if (status == 3) { + if(qm.isQuestCompleted(1021)) + qm.dropMessage(1,"Unknown Error"); + else if(qm.canHold(2010000) && qm.canHold(2010009)){ + qm.gainExp(10); + qm.gainItem(2010000, 3); + qm.gainItem(2010009, 3); + qm.forceCompleteQuest(); + }else + qm.dropMessage(1,"Your inventory is full"); qm.dispose(); - } else - qm.sendNext("How easy is it to consume the item? Simple, right? You can set a #bhotkey#k on the right bottom slot. Haha you didn't know that! right? Oh, and if you are a beginner, HP will automatically recover itself as time goes by. Well it takes time but this is one of the strategies for the beginners."); - else if (status == 1) - qm.sendNextPrev("Alright! Now that you have learned alot, I will give you a present. This is a must for your travel in Maple World, so thank me! Please use this under emergency cases!"); - else if (status == 2) - qm.sendNextPrev("Okay, this is all I can teach you. I know it's sad but it is time to say good bye. Well take care if yourself and Good luck my friend!\r\n\r\n#fUI/UIWindow.img/QuestIcon/4/0#\r\n#v2010000# 3 #t2010000#\r\n#v2010009# 3 #t2010009#\r\n\r\n#fUI/UIWindow.img/QuestIcon/8/0# 10 exp"); - else if (status == 3) { - if(qm.isQuestCompleted(1021)) - qm.dropMessage(1,"Unknown Error"); - else if(qm.canHold(2010000) && qm.canHold(2010009)){ - qm.gainExp(10); - qm.gainItem(2010000, 3); - qm.gainItem(2010009, 3); - qm.forceCompleteQuest(); - }else - qm.dropMessage(1,"Your inventory is full"); - qm.dispose(); + } } } \ No newline at end of file diff --git a/scripts/quest/20400.js b/scripts/quest/20400.js new file mode 100644 index 0000000000..461973890c --- /dev/null +++ b/scripts/quest/20400.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 . +*/ +/* + Chasing the Knight's Target + + */ + +var status = -1; + +function start(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) { + qm.sendNext("Not long ago, we received a distress signal of #bAdvanced Knight #p1103000##k, currently stationed somewhere in #rEl Nath#k. His Your job is to find him, first go talk to #b#p1101002##k and receive further instructions on your mission."); + } else if (status == 1) { + qm.forceCompleteQuest(); + qm.dispose(); + } + } +} diff --git a/scripts/quest/20401.js b/scripts/quest/20401.js new file mode 100644 index 0000000000..c69c702155 --- /dev/null +++ b/scripts/quest/20401.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 . +*/ +/* + Chasing the Knight's Target + + */ + +var status = -1; + +function start(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) { + qm.sendNext("Last time #bAdvanced Knight #p1103000##k was seen, he was investigating the surging increase on #rzombies#k lately on the #rhigh-grounds of El Nath#k. You should get yourself there to see if you can find any clue of what could have happened."); + } else if (status == 1) { + qm.forceCompleteQuest(); + qm.dispose(); + } + } +} diff --git a/scripts/quest/20405.js b/scripts/quest/20405.js new file mode 100644 index 0000000000..e61bf79baf --- /dev/null +++ b/scripts/quest/20405.js @@ -0,0 +1,50 @@ +/* + 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 . +*/ +/* + Chasing the Knight's Target + + */ + +var status = -1; + +function start(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) { + qm.sendNext("There's a note on the wall: 'The source of the curse still goes missing, but a strange device, that I suppose has been used by #rthem#k was found here.'", 3); + } else if (status == 1) { + qm.sendNextPrev("'The machine was sent to #rEreve#k for avaliation, I'll now set out to continue my mission. Let the Empress bless me on my journey.'", 3); + } else if (status == 2) { + qm.forceCompleteQuest(); + qm.dispose(); + } + } +} diff --git a/scripts/quest/20406.js b/scripts/quest/20406.js new file mode 100644 index 0000000000..98e0fcc3fb --- /dev/null +++ b/scripts/quest/20406.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 . +*/ +/* + Chasing the Knight's Target + + */ + +var status = -1; + +function start(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) { + qm.sendNext("Is that so? All there was was a saying that #p1103000# set out to continue his journey? That can't be, there were further instructions for him to detail the progress of his mission until then. #rReturn to the cave#k and report again if it really has nothing more there."); + } else if (status == 1) { + qm.forceCompleteQuest(); + qm.dispose(); + } + } +} diff --git a/scripts/quest/3927.js b/scripts/quest/3927.js index d3d3fa14a8..a1627dee23 100644 --- a/scripts/quest/3927.js +++ b/scripts/quest/3927.js @@ -53,14 +53,18 @@ function end(mode, type, selection) { } else if (status == 2) { if(selection == 0) { qm.sendOk("If I had an iron hammer and a dagger... a bow and an arrow... what does that mean? Do you want me to tell you? I don't know myself. It's something you should think about. If you need a clue... it would go something like... a weapon is just an item... until someone uses it...?"); - qm.gainExp(1000 * qm.getPlayer().getExpRate()); - qm.forceCompleteQuest(); } else if(selection == 1) { qm.sendOk("Man, Jiyur wrote on the wall again! Arrgh!!"); + qm.dispose(); + return; } else { qm.sendOk("What? You forgot? Do you remember where it was written?"); + qm.dispose(); + return; } - + } else if (status == 3) { + qm.gainExp(1000 * qm.getPlayer().getExpRate()); + qm.forceCompleteQuest(); qm.dispose(); } } diff --git a/scripts/quest/3953.js b/scripts/quest/3953.js index 78f7af11d8..f68cb68d4d 100644 --- a/scripts/quest/3953.js +++ b/scripts/quest/3953.js @@ -42,8 +42,7 @@ function end(mode, type, selection) { qm.sendSimple("Ehh... Yeah, the city is not really doing well because of the currently ruling govern, that's indeed a fact. If only the Guardians of the Deserts returned to put order on this mess...\r\n\r\n#L0##bWhat is the Guardian of the Deserts doing when we're under the Queen's tyranny?#k"); } else if (status == 3) { qm.sendSimple("They have departed on an expedition to get rid of some major threats in the desert that were ravaging Ariant, for quite some time now... It's strange, they should have already returned... Thinking about it now, the last attack on the merchants was around the direction the Guardians departed... No, that can't be... Can it?\r\n\r\n#L0##bPerhaps Deo has already turned into a monster.#k"); - } - else if (status == 4) { + } else if (status == 4) { qm.gainItem(4011008, -1); qm.sendNext("We're in great trouble, if it is like this. And it really seems like it. If the Royal Cactus Deo has gone insane, Ariant is done for. You, can you do something to defeat Deo? We really need your help now."); diff --git a/sql/db_drops.sql b/sql/db_drops.sql index 4998b029af..3c076c7164 100644 --- a/sql/db_drops.sql +++ b/sql/db_drops.sql @@ -20264,6 +20264,8 @@ USE `heavenms`; (4300008, 4032521, 1, 1, 2291, 120000), (4300009, 4032521, 1, 1, 2291, 120000), (4300010, 4032521, 1, 1, 2291, 120000), +(5130107, 4001207, 1, 1, 0, 2285), +(5130108, 4001207, 1, 1, 0, 2285), (9400506, 2020020, 1, 1, 0, 100000), (9400506, 4031217, 1, 1, 0, 40000), (9400507, 2020020, 1, 1, 0, 100000), diff --git a/src/client/MapleCharacter.java b/src/client/MapleCharacter.java index 38b1600f35..5774b13b99 100644 --- a/src/client/MapleCharacter.java +++ b/src/client/MapleCharacter.java @@ -199,7 +199,7 @@ public class MapleCharacter extends AbstractAnimatedMapleMapObject { 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; - private long lastfametime, lastUsedCashItem, lastHealed, lastBuyback = 0, lastDeathtime, lastMesoDrop = -1, jailExpiration = -1; + private long lastfametime, lastUsedCashItem, lastExpression = 0, lastHealed, lastBuyback = 0, lastDeathtime, lastMesoDrop = -1, jailExpiration = -1; private transient int localmaxhp, localmaxmp, localstr, localdex, localluk, localint_, magic, watk; private boolean hidden, canDoor = true, berserk, hasMerchant, hasSandboxItem = false, whiteChat = false; private int linkedLevel = 0; @@ -2369,7 +2369,7 @@ public class MapleCharacter extends AbstractAnimatedMapleMapObject { } } - private boolean dispelSkills(int skillid) { + private static boolean dispelSkills(int skillid) { switch (skillid) { case DarkKnight.BEHOLDER: case FPArchMage.ELQUINES: @@ -2386,6 +2386,14 @@ public class MapleCharacter extends AbstractAnimatedMapleMapObject { return false; } } + + public void changeFaceExpression(int emote) { + long timeNow = Server.getInstance().getCurrentTime(); + if(timeNow - lastExpression > 2000) { + lastExpression = timeNow; + client.getChannelServer().registerFaceExpression(map, this, emote); + } + } private void doHurtHp() { if (!(this.getInventory(MapleInventoryType.EQUIPPED).findById(getMap().getHPDecProtect()) != null || buffMapProtection())) { diff --git a/src/client/MapleClient.java b/src/client/MapleClient.java index f8181b6b65..8b294a4ea3 100644 --- a/src/client/MapleClient.java +++ b/src/client/MapleClient.java @@ -956,6 +956,7 @@ public class MapleClient { Server.getInstance().unregisterLoginState(this); + this.session.setAttribute(MapleClient.CLIENT_KEY, null); this.accountName = null; this.macs = null; this.hwid = null; @@ -1153,6 +1154,10 @@ public class MapleClient { lock.unlock(); } + public boolean trylockClient() { + return lock.tryLock(); + } + public void lockEncoder() { encoderLock.lock(); } @@ -1356,12 +1361,16 @@ public class MapleClient { this.sessionId = sessionId; } + public boolean canRequestCharlist(){ + return lastNpcClick + 877 < Server.getInstance().getCurrentTime(); + } + public boolean canClickNPC(){ - return lastNpcClick + 500 < System.currentTimeMillis(); + return lastNpcClick + 500 < Server.getInstance().getCurrentTime(); } public void setClickedNPC(){ - lastNpcClick = System.currentTimeMillis(); + lastNpcClick = Server.getInstance().getCurrentTime(); } public void removeClickedNPC(){ diff --git a/src/client/command/Commands.java b/src/client/command/Commands.java index 37c93969db..69d5fc4887 100644 --- a/src/client/command/Commands.java +++ b/src/client/command/Commands.java @@ -607,33 +607,40 @@ public class Commands { case "dex": case "int": case "luk": - int amount = (sub.length > 1) ? Integer.parseInt(sub[1]) : player.getRemainingAp(); + int remainingAp = player.getRemainingAp(); + + int amount = (sub.length > 1) ? Math.min(Integer.parseInt(sub[1]), remainingAp) : remainingAp; boolean str = sub[0].equalsIgnoreCase("str"); boolean Int = sub[0].equalsIgnoreCase("int"); boolean luk = sub[0].equalsIgnoreCase("luk"); boolean dex = sub[0].equalsIgnoreCase("dex"); - if (amount > 0 && amount <= player.getRemainingAp() && amount <= 32763 || amount < 0 && amount >= -32763 && Math.abs(amount) + player.getRemainingAp() <= 32767) { - if (str && amount + player.getStr() <= 32767 && amount + player.getStr() >= 4) { - player.setStr(player.getStr() + amount); - player.updateSingleStat(MapleStat.STR, player.getStr()); - player.setRemainingAp(player.getRemainingAp() - amount); - player.updateSingleStat(MapleStat.AVAILABLEAP, player.getRemainingAp()); - } else if (Int && amount + player.getInt() <= 32767 && amount + player.getInt() >= 4) { - player.setInt(player.getInt() + amount); - player.updateSingleStat(MapleStat.INT, player.getInt()); - player.setRemainingAp(player.getRemainingAp() - amount); - player.updateSingleStat(MapleStat.AVAILABLEAP, player.getRemainingAp()); - } else if (luk && amount + player.getLuk() <= 32767 && amount + player.getLuk() >= 4) { - player.setLuk(player.getLuk() + amount); - player.updateSingleStat(MapleStat.LUK, player.getLuk()); - player.setRemainingAp(player.getRemainingAp() - amount); - player.updateSingleStat(MapleStat.AVAILABLEAP, player.getRemainingAp()); - } else if (dex && amount + player.getDex() <= 32767 && amount + player.getDex() >= 4) { - player.setDex(player.getDex() + amount); - player.updateSingleStat(MapleStat.DEX, player.getDex()); - player.setRemainingAp(player.getRemainingAp() - amount); - player.updateSingleStat(MapleStat.AVAILABLEAP, player.getRemainingAp()); + if (amount > 0 && amount <= remainingAp && amount <= 32763) { + int playerStr = player.getStr(); + int playerDex = player.getDex(); + int playerInt = player.getInt(); + int playerLuk = player.getLuk(); + + if (str && amount + playerStr <= 32767 && amount + playerStr >= 4) { + player.setStr(playerStr + amount); + player.updateSingleStat(MapleStat.STR, playerStr); + player.setRemainingAp(remainingAp - amount); + player.updateSingleStat(MapleStat.AVAILABLEAP, remainingAp); + } else if (Int && amount + playerInt <= 32767 && amount + playerInt >= 4) { + player.setInt(playerInt + amount); + player.updateSingleStat(MapleStat.INT, playerInt); + player.setRemainingAp(remainingAp - amount); + player.updateSingleStat(MapleStat.AVAILABLEAP, remainingAp); + } else if (luk && amount + playerLuk <= 32767 && amount + playerLuk >= 4) { + player.setLuk(playerLuk + amount); + player.updateSingleStat(MapleStat.LUK, playerLuk); + player.setRemainingAp(remainingAp - amount); + player.updateSingleStat(MapleStat.AVAILABLEAP, remainingAp); + } else if (dex && amount + playerDex <= 32767 && amount + playerDex >= 4) { + player.setDex(playerDex + amount); + player.updateSingleStat(MapleStat.DEX, playerDex); + player.setRemainingAp(remainingAp - amount); + player.updateSingleStat(MapleStat.AVAILABLEAP, remainingAp); } else { player.dropMessage("Please make sure the stat you are trying to raise is not over 32,767 or under 4."); } diff --git a/src/client/creator/CharacterFactory.java b/src/client/creator/CharacterFactory.java index ba84b0e296..bbba6d86c2 100644 --- a/src/client/creator/CharacterFactory.java +++ b/src/client/creator/CharacterFactory.java @@ -56,7 +56,7 @@ public abstract class CharacterFactory { MapleItemInformationProvider ii = MapleItemInformationProvider.getInstance(); int top = recipe.getTop(), bottom = recipe.getBottom(), shoes = recipe.getShoes(), weapon = recipe.getWeapon(); - + if(top > 0) { Item eq_top = ii.getEquipById(top); eq_top.setPosition((byte) -5); @@ -85,7 +85,7 @@ public abstract class CharacterFactory { return -2; } c.announce(MaplePacketCreator.addNewCharEntry(newchar)); - + Server.getInstance().createCharacterEntry(newchar); Server.getInstance().broadcastGMMessage(c.getWorld(), MaplePacketCreator.sendYellowTip("[NEW CHAR]: " + c.getAccountName() + " has created a new character with IGN " + name)); diff --git a/src/client/processor/BuybackProcessor.java b/src/client/processor/BuybackProcessor.java index 6ee8819189..8011121d1c 100644 --- a/src/client/processor/BuybackProcessor.java +++ b/src/client/processor/BuybackProcessor.java @@ -41,7 +41,7 @@ public class BuybackProcessor { public static void processBuyback(MapleClient c) { MapleCharacter chr = c.getPlayer(); boolean buyback; - + c.lockClient(); try { buyback = !chr.isAlive() && chr.couldBuyback(); diff --git a/src/constants/ItemConstants.java b/src/constants/ItemConstants.java index a49234a84c..418506fe33 100644 --- a/src/constants/ItemConstants.java +++ b/src/constants/ItemConstants.java @@ -126,6 +126,11 @@ public final class ItemConstants { return itemId >= 1110000 && itemId < 1140000; } + public static boolean isTaming(int itemId) { + int itemType = itemId / 1000; + return itemType == 1902 || itemType == 1912; + } + public static boolean isTownScroll(int itemId) { return itemId >= 2030000 && itemId < 2030100; } @@ -164,7 +169,15 @@ public final class ItemConstants { public static boolean isPartyAllcure(int itemId) { return itemId == 2022433; } - + + public static boolean isHiredMerchant(int itemId) { + return itemId / 10000 == 503; + } + + public static boolean isPlayerShop(int itemId) { + return itemId / 10000 == 514; + } + public static MapleInventoryType getInventoryType(final int itemId) { if (inventoryTypeCache.containsKey(itemId)) { return inventoryTypeCache.get(itemId); diff --git a/src/constants/ServerConstants.java b/src/constants/ServerConstants.java index 0f366cc88c..33bae6a4ec 100644 --- a/src/constants/ServerConstants.java +++ b/src/constants/ServerConstants.java @@ -23,7 +23,7 @@ public class ServerConstants { public static final long PURGING_INTERVAL = 5 * 60 * 1000; public static final long RANKING_INTERVAL = 60 * 60 * 1000; //60 minutes, 3600000. public static final long COUPON_INTERVAL = 60 * 60 * 1000; //60 minutes, 3600000. - public static final long UPDATE_INTERVAL = 777; + public static final long UPDATE_INTERVAL = 777; //Dictates the frequency on which the "centralized server time" is updated. public static final boolean ENABLE_PIC = false; //Pick true/false to enable or disable Pic. Delete character needs this feature ENABLED. public static final boolean ENABLE_PIN = false; //Pick true/false to enable or disable Pin. @@ -62,10 +62,12 @@ public class ServerConstants { public static final boolean USE_AUTOSAVE = true; //Enables server autosaving feature (saves characters to DB each 1 hour). public static final boolean USE_SERVER_AUTOASSIGNER = true; //HeavenMS-builtin autoassigner, uses algorithm based on distributing AP accordingly with required secondary stat on equipments. public static final boolean USE_REFRESH_RANK_MOVE = true; + public static final boolean USE_ENFORCE_ADMIN_ACCOUNT = false; //Forces accounts having GM characters to be treated as a "GM account" by the client (localhost). Some of the GM account perks is the ability to FLY, but unable to TRADE. public static final boolean USE_ENFORCE_HPMP_SWAP = false; //Forces players to reuse stats (via AP Resetting) located on HP/MP pool only inside the HP/MP stats. public static final boolean USE_ENFORCE_MOB_LEVEL_RANGE = true; //Players N levels below the killed mob will gain no experience from defeating it. public static final boolean USE_ENFORCE_JOB_LEVEL_RANGE = false;//Caps the player level on the minimum required to advance their current jobs. public static final boolean USE_ENFORCE_OWL_SUGGESTIONS = false;//Forces the Owl of Minerva to always display the defined item array on GameConstants.OWL_DATA instead of those featured by the players. + public static final boolean USE_ENFORCE_UNMERCHABLE_CASH = true;//Forces players to not sell CASH items via merchants. public static final boolean USE_ENFORCE_UNMERCHABLE_PET = true; //Forces players to not sell pets via merchants. (since non-named pets gets dirty name and other possible DB-related issues) public static final boolean USE_ENFORCE_MDOOR_POSITION = false; //Forces mystic door to be spawned near spawnpoints. public static final boolean USE_ERASE_PERMIT_ON_OPENSHOP = true;//Forces "shop permit" item to be consumed when player deploy his/her player shop. diff --git a/src/dropspider/DataTool.java b/src/dropspider/DataTool.java deleted file mode 100644 index cb71379b82..0000000000 --- a/src/dropspider/DataTool.java +++ /dev/null @@ -1,129 +0,0 @@ -/* - * To change this template, choose Tools | Templates - * and open the template in the editor. - */ -package dropspider; - -import java.io.File; -import java.util.ArrayList; -import java.util.HashMap; -import java.util.HashSet; -import java.util.LinkedList; -import java.util.List; -import java.util.Map; -import provider.MapleData; -import provider.MapleDataDirectoryEntry; -import provider.MapleDataFileEntry; -import provider.MapleDataProvider; -import provider.MapleDataProviderFactory; -import provider.MapleDataTool; -import server.MapleItemInformationProvider; -import tools.Pair; - -/** - * - * @author Simon - */ -public class DataTool { - private static Map hardcodedMobs = new HashMap<>(); - - private static ArrayList> npc_list = null; - private static LinkedList> mob_pairs = null; - private static MapleDataProvider data = MapleDataProviderFactory.getDataProvider(MapleDataProviderFactory.fileInWZPath("Mob.wz")); - private static HashSet bosses = null; - - public static void setHardcodedMobNames() { - hardcodedMobs.put("Red Slime [2]", 7120103); - hardcodedMobs.put("Gold Slime", 7120105); - hardcodedMobs.put("Nibelung [3]", 8220015); - } - - public static void addMonsterIdsFromHardcodedName(List monster_ids, String monster_name) { - Integer id = hardcodedMobs.get(monster_name); - if(id != null) { - monster_ids.add(id); - } - } - - public static ArrayList monsterIdsFromName(String name) { - MapleData data = null; - MapleDataProvider dataProvider = MapleDataProviderFactory.getDataProvider(new File(System.getProperty("wzpath") + "/" + "String.wz")); - ArrayList ret = new ArrayList<>(); - data = dataProvider.getData("Mob.img"); - if (mob_pairs == null) { - mob_pairs = new LinkedList<>(); - for (MapleData mobIdData : data.getChildren()) { - int mobIdFromData = Integer.parseInt(mobIdData.getName()); - String mobNameFromData = MapleDataTool.getString(mobIdData.getChildByPath("name"), "NO-NAME"); - mob_pairs.add(new Pair<>(mobIdFromData, mobNameFromData)); - } - } - for (Pair mobPair : mob_pairs) { - if (mobPair.getRight().toLowerCase().equals(name.toLowerCase())) { - ret.add(mobPair.getLeft()); - } - } - return ret; - } - - private static void populateBossList() { - bosses = new HashSet<>(); - MapleDataDirectoryEntry mob_data = data.getRoot(); - for (MapleDataFileEntry mdfe : mob_data.getFiles()) { - MapleData boss_candidate = data.getData(mdfe.getName()); - MapleData monsterInfoData = boss_candidate.getChildByPath("info"); - int mid = Integer.valueOf(boss_candidate.getName().replaceAll("[^0-9]", "")); - boolean boss = MapleDataTool.getIntConvert("boss", monsterInfoData, 0) > 0 || mid == 8810018 || mid == 9410066; - if (boss) { - bosses.add(mid); - } - } - } - - public static boolean isBoss(int mid) { - if (bosses == null) { - populateBossList(); - } - return bosses.contains(mid); - } - - public static ArrayList itemIdsFromName(String name) { - - ArrayList ret = new ArrayList<>(); - for (Pair itemPair : MapleItemInformationProvider.getInstance().getAllItems()) { - String item_name = itemPair.getRight().toLowerCase().replaceAll("\\"", ""); - item_name = item_name.replaceAll("'", ""); - item_name = item_name.replaceAll("\\'", ""); - - name = name.toLowerCase().replaceAll("\\"", ""); - name = name.replaceAll("'", ""); - name = name.replaceAll("\\'", ""); - - if (item_name.equals(name)) { - ret.add(itemPair.getLeft()); - return ret; - } - } - return ret; - } - - public static ArrayList npcIdsFromName(String name) { - MapleDataProvider dataProvider = MapleDataProviderFactory.getDataProvider(new File(System.getProperty("wzpath") + "/" + "String.wz")); - ArrayList ret = new ArrayList<>(); - if (npc_list == null) { - ArrayList> searchList = new ArrayList<>(); - for (MapleData searchData : dataProvider.getData("Npc.img").getChildren()) { - int searchFromData = Integer.parseInt(searchData.getName()); - String infoFromData = MapleDataTool.getString(searchData.getChildByPath("name"), "NO-NAME"); - searchList.add(new Pair<>(searchFromData, infoFromData)); - } - npc_list = searchList; - } - for (Pair searched : npc_list) { - if (searched.getRight().toLowerCase().contains(name.toLowerCase())) { - ret.add(searched.getLeft()); - } - } - return ret; - } -} diff --git a/src/dropspider/DropEntry.java b/src/dropspider/DropEntry.java deleted file mode 100644 index 9dc5457d87..0000000000 --- a/src/dropspider/DropEntry.java +++ /dev/null @@ -1,177 +0,0 @@ -/* - * To change this template, choose Tools | Templates - * and open the template in the editor. - */ -package dropspider; - -import client.inventory.MapleInventoryType; -import constants.ItemConstants; - -/** - * - * @author Simon - */ -public class DropEntry { - private int version; - private int item_id; - private int monster_id; - private int chance; - private int mindrop; - private int maxdrop; - - public DropEntry(int item_id, int monster_id, int version) { - this.item_id = item_id; - this.monster_id = monster_id; - mindrop = 1; - maxdrop = 1; - chance = calculateChance(item_id); - this.version = version; - } - - private int calculateChance(int item_id) { - MapleInventoryType mit = ItemConstants.getInventoryType(item_id); - boolean boss = DataTool.isBoss(monster_id); - int number = (item_id / 1000) % 1000; - switch (mit) { - case EQUIP: - if (boss) { - return 40000; - } - return 700; - case USE: - if (boss) { - mindrop = 1; - maxdrop = 4; - } - switch (number) { - case 0: // normal potions - mindrop = 1; - if (version > 98) { - maxdrop = 5; - } - return 40000; - case 1: // watermelons, pills, speed potions, etc - case 2: // same thing - return 10000; - case 3: // advanced potions from crafting (should not drop) - case 4: // same thing - case 11: // poison mushroom - case 28: // cool items - case 30: // return scrolls - case 46: // gallant scrolls - return 0; - case 10: // strange potions like apples, eggs - case 12: // drakes blood, sap of ancient tree (rare use) - case 20: // salad, fried chicken, dews - case 22: // air bubbles and stuff. ALSO nependeath honey but oh well - case 50: // antidotes and stuff - return 3000; - case 290: // mastery books - if(boss) - return 40000; - else - return 1000; - case 40: // Scrolls - case 41: // Scrolls - case 43: // Scrolls - case 44: // Scrolls - case 48: // pet scrolls - if(boss) - return 10000; - else - return 750; - case 100: // summon bags - case 101: // summon bags - case 102: // summon bags - case 109: // summon bags - case 120: // pet food - case 211: // cliffs special potion - case 240: // rings - case 270: // pheromone, additional weird stuff - case 310: // teleport rock - case 320: // weird drops - case 390: // weird - case 430: // Scripted items - case 440: // jukebox - case 460: // magnifying glass - case 470: // golden hammer - case 490: // crystanol - case 500: // sp reset - return 0; - case 47: // tablets from dragon rider - return 220000; - case 49: // clean slats, potential scroll, ees - case 70: // throwing stars - case 210: // rare monster piece drops - case 330: // bullets - if(boss) - return 2500; - else - return 400; - case 60: // bow arrows - case 61: // crossbow arrows - mindrop = 10; - maxdrop = 50; - return 10000; - case 213: // boss transfrom - return 100000; - case 280: // skill books - if(boss) - return 20000; - else - return 1000; - case 381: // monster book things - case 382: - case 383: - case 384: - case 385: - case 386: - case 387: - case 388: - return 20000; - case 510: // recipes - case 511: - case 512: - return 10000; - default: - return 0; - - } - case ETC: - switch (number) { - case 0: // monster pieces - return 200000; - case 4: // crystal ores - case 130: // simulators - case 131: // manuals - return 3000; - case 30: // game pieces - return 10000; - case 32: // misc items - return 10000; - default: - return 7000; - } - default: - return 7000; - } - } - - public String getQuerySegment() { - StringBuilder sb = new StringBuilder(); - sb.append("("); - sb.append(monster_id); - sb.append(", "); - sb.append(item_id); - sb.append(", "); - sb.append(mindrop);//min - sb.append(", "); - sb.append(maxdrop);//max - sb.append(", "); - sb.append(0);//quest - sb.append(", "); - sb.append(chance); - sb.append(")"); - return sb.toString(); - } -} \ No newline at end of file diff --git a/src/dropspider/Errors.java b/src/dropspider/Errors.java deleted file mode 100644 index a54b8543ab..0000000000 --- a/src/dropspider/Errors.java +++ /dev/null @@ -1,19 +0,0 @@ -package dropspider; - -import java.util.LinkedList; - -public class Errors { - - public String mobName; - public LinkedList wrong = new LinkedList<>(); - - public String createErrorLog() { - StringBuilder sb = new StringBuilder(); - - for (String w : wrong) { - sb.append(mobName).append(" : ").append(w).append("\r\n"); - } - - return sb.toString(); - } -} diff --git a/src/dropspider/Main.java b/src/dropspider/Main.java deleted file mode 100644 index 22499e9b79..0000000000 --- a/src/dropspider/Main.java +++ /dev/null @@ -1,329 +0,0 @@ -/* - * To change this template, choose Tools | Templates - * and open the template in the editor. - */ -package dropspider; - -import java.io.BufferedWriter; -import java.io.File; -import java.io.FileWriter; -import java.io.IOException; -import java.io.InputStream; -import java.io.PrintWriter; -import java.net.MalformedURLException; -import java.net.URL; -import java.util.ArrayList; -import java.util.HashMap; -import java.util.Iterator; -import java.util.Scanner; - -/** - * - * @author Simon - */ -public class Main { - - private static ArrayList drop_entries = new ArrayList<>(); - private static HashMap problems = new HashMap<>(); -// private static final String TEST_STRING = " Ligator Skin, The Magic Rock, Witch Grass Leaves "; - private static final String BASE_URL = "http://bbb.hidden-street.net"; - private static final int VERSION = 83; - private static String[] pages = {"1-10", "11-20", "21-30", "31-40", "41-50", "51-60", "61-70", "71-80", "81-90", "91-100"}; - private static String[] additionalPages88 = {"101-150", "151-200"}; - private static String[] additionalPagesBB = {"101-120,", "121-140", "141-160", "161-180", "181-200"}; - - public static void main(String[] args) { - System.setProperty("wzpath", "wz"); - - //DataTool.setHardcodedMobNames(); - //parsePage("http://bbb.hidden-street.net/monster/nibelung-3"); - - crawlProgram(); - - dumpQuery(); - dumpErrors(); - } - - private static void crawlProgram() { - //parseMonsterSection(TEST_STRING); - for (String s : pages) { - crawlPage("http://bbb.hidden-street.net/monster/" + s); - } - if (VERSION > 92) { // big bang - for (String s : additionalPagesBB) { - crawlPage("http://bbb.hidden-street.net/monster/" + s); - } - crawlPage("http://bbb.hidden-street.net/monster/101-120?page=1"); //page 1's bugged - } else { - for (String s : additionalPages88) { - crawlPage("http://bbb.hidden-street.net/monster/" + s); - } - } - } - - private static void crawlPage(String url) { //recursive method - try { - URL page = new URL(url); - InputStream is = page.openStream(); - Scanner s = new Scanner(is); - String temp_data = ""; - while (s.hasNext()) { - temp_data += s.nextLine() + "\n"; - } - s.close(); - is.close(); - while (temp_data.contains("class=\"monster\">")) { - String monster_section = getStringBetween(temp_data, "class=\"monster\">", ""); - parseMonsterSection(monster_section); - temp_data = trimUntil(temp_data, ""); - } - if (temp_data.contains("Go to next page")) { - String next_url_segment = getStringBetween(temp_data, "
  • ")) { - String monster_section = getStringBetween(temp_data, "class=\"monster\">", ""); - parseMonsterSection(monster_section); - temp_data = trimUntil(temp_data, ""); - } - if (temp_data.contains("Go to next page")) { - String next_url_segment = getStringBetween(temp_data, "
  • ", ""), monster_name); - - //parse useable drop - parseItemSection(getStringBetween(html_data, "Useable drop:", ""), monster_name); - - //parse ore drop - parseItemSection(getStringBetween(html_data, "Ore drop:", ""), monster_name); - - //parse equips - parseItemSection(getStringBetween(html_data, "Common equipment:", ""), monster_name); - parseItemSection(getStringBetween(html_data, "Warrior equipment:", ""), monster_name); - parseItemSection(getStringBetween(html_data, "Magician equipment:", ""), monster_name); - parseItemSection(getStringBetween(html_data, "Bowman equipment:", ""), monster_name); - parseItemSection(getStringBetween(html_data, "Thief equipment:", ""), monster_name); - parseItemSection(getStringBetween(html_data, "Pirate equipment:", ""), monster_name); - - //System.out.println(monster_name); - } - - private static void parseItemSection(String html_data, String monster_name) { - String temp_data = html_data; - while (temp_data.contains(""); - String item_name = getStringBetween(s1, "", ""); - temp_data = trimUntil(temp_data, ""); - - boolean gender_equip = false; - if (item_name.contains("(M)") || item_name.contains("(F)")) { - item_name = item_name.replaceAll("(\\(M\\))|(\\(F\\))", ""); - gender_equip = true; - } - item_name = item_name.replaceAll("Throwing-Star", "Throwing-Stars").trim(); - item_name = item_name.replaceAll("for Magic Attack", "for Magic Att.").trim(); - item_name = item_name.replaceAll("\\(50%\\)", "").trim(); - item_name = item_name.replaceAll("\\(70%\\)", "").trim(); - item_name = item_name.replaceAll("\\'s", "").trim(); - - - monster_name = monster_name.replaceAll("Horntail\\'s Head B", "Horntail"); - // Process scrolls, nexon doesn't have the % on most of the scrolls. So we need to remove it - // Unfortunately they do for some, so we have to handle that too. - boolean scroll = false; - int scrollType = 0; - - if(item_name.contains("100%")) { - scroll = true; - item_name = item_name.replaceAll("100%", "").trim(); - item_name = item_name.replaceAll("\\(\\)", "").trim(); // Hidden Street has a few scroll %'s with ()s around them.. sigh - } else if(item_name.contains("60%")) { - scroll = true; - scrollType = 1; - item_name = item_name.replaceAll("60%", "").trim(); - item_name = item_name.replaceAll("\\(\\)", "").trim(); - } else if(item_name.contains("10%")) { - scroll = true; - scrollType = 2; - item_name = item_name.replaceAll("10%", "").trim(); - item_name = item_name.replaceAll("\\(\\)", "").trim(); - //f(item_name.contains(" ()")) item_name = item_name.substring(0, item_name.lastIndexOf(" (")); - } else if(item_name.contains("70%")) { - scroll = true; - scrollType = 4; - item_name = item_name.replaceAll("70%", "").trim(); - item_name = item_name.replaceAll("\\(\\)", "").trim(); - } else if(item_name.contains("30%")) { - scroll = true; - scrollType = 5; - item_name = item_name.replaceAll("30%", "").trim(); - item_name = item_name.replaceAll("\\(\\)", "").trim(); - } - - -// System.out.println("Item name: " + item_name); - - //drop entry - ArrayList monster_ids = DataTool.monsterIdsFromName(monster_name); - //DataTool.addMonsterIdsFromHardcodedName(monster_ids, monster_name); - - ArrayList item_ids = DataTool.itemIdsFromName(item_name); - - if(scroll && item_ids.isEmpty()) { - // Try adding on the % again. Thanks nexon... - if(scrollType == 0) item_name += " 100%"; - if(scrollType == 1) item_name += " 60%"; - if(scrollType == 2) item_name += " 10%"; - if(scrollType == 4) item_name += " 70%"; - if(scrollType == 5) item_name += " 30%"; - - item_ids = DataTool.itemIdsFromName(item_name); - } - - if (!monster_ids.isEmpty() && !item_ids.isEmpty()) { - int item_id = item_ids.get(0); - if(scroll) { - item_id += scrollType; - } - int item_id_2 = -1; - for (Integer mob_id : monster_ids) { - System.out.println("Monster ID: " + mob_id + ", Item ID: " + item_id); - drop_entries.add(new DropEntry(item_id, mob_id, VERSION)); - if (gender_equip && item_ids.size() > 1) { - item_id_2 = item_ids.get(1); - drop_entries.add(new DropEntry(item_id_2, mob_id, VERSION)); - - } - } - } else { - System.out.println("Error parsing item " + item_name + " dropped by " + monster_name + "."); - - if (!monster_ids.isEmpty()) { - if (!problems.containsKey(monster_name)) { - Errors e = new Errors(); - e.mobName = monster_name; - - problems.put(monster_name, e); - } - - problems.get(monster_name).wrong.add(item_name); - } - //System.out.println("Monster ids size: " + monster_ids.size() + ", Item IDs size: " + item_ids.size()); - } - - } - } - - /** - * Returns the string lying between the two specified strings. - * - * @param line The string to parse - * @param start The first string - * @param end The last string - * @return The string between the two specified strings - */ - public static String getStringBetween(String line, String start, String end) { - int start_offset = line.indexOf(start) + start.length(); - return line.substring(start_offset, line.substring(start_offset).indexOf(end) + start_offset); - } - - public static String trimUntil(String line, String until) { - int until_pos = line.indexOf(until); - if (until_pos == -1) { - return null; - } else { - return line.substring(until_pos + until.length()); - } - } - - public static void dumpErrors() { - String file = "errors.txt"; - try { - File f = new File(file); - BufferedWriter bw = new BufferedWriter(new FileWriter(f)); - PrintWriter pw = new PrintWriter(bw); - - for (Errors err : problems.values()) { - pw.write(err.createErrorLog()); - } - - pw.flush(); - - pw.close(); - bw.close(); - } catch (Exception e) { - e.printStackTrace(); - } - } - - public static void dumpQuery() { - String filename = "drops.sql"; - try { - File output = new File(filename); - BufferedWriter bw = new BufferedWriter(new FileWriter(output)); - PrintWriter pw = new PrintWriter(bw); - StringBuilder sb = new StringBuilder(); - pw.write("TRUNCATE TABLE `drop_data`;\r\n"); - pw.write("INSERT INTO `drop_data` (`dropperid`, `itemid`, `minimum_quantity`, `maximum_quantity`, `questid`, `chance`) VALUES "); - for (Iterator i = drop_entries.iterator(); i.hasNext();) { - DropEntry de = i.next(); - pw.write(de.getQuerySegment()); - if (i.hasNext()) { - pw.write(", \r\n"); - } - } - pw.write(sb.toString()); - pw.close(); - bw.close(); - } catch (IOException ioe) { - ioe.printStackTrace(); - System.out.println("Error writing to file: " + ioe.getLocalizedMessage()); - } - } -} diff --git a/src/net/AbstractMaplePacketHandler.java b/src/net/AbstractMaplePacketHandler.java index e604f6b905..6117b81174 100644 --- a/src/net/AbstractMaplePacketHandler.java +++ b/src/net/AbstractMaplePacketHandler.java @@ -22,10 +22,15 @@ package net; import client.MapleClient; +import net.server.Server; public abstract class AbstractMaplePacketHandler implements MaplePacketHandler { @Override public boolean validateState(MapleClient c) { return c.isLoggedIn(); } + + protected static long currentServerTime() { + return Server.getInstance().getCurrentTime(); + } } \ No newline at end of file diff --git a/src/net/server/Server.java b/src/net/server/Server.java index d87b65d383..13a64d8847 100644 --- a/src/net/server/Server.java +++ b/src/net/server/Server.java @@ -114,6 +114,7 @@ public class Server { private final List registeredDiseaseAnnouncePlayers = new LinkedList<>(); private final AtomicLong currentTime = new AtomicLong(0); + private long serverCurrentTime = 0; private boolean availableDeveloperRoom = false; private boolean online = false; @@ -126,20 +127,22 @@ public class Server { return instance; } + public long getCurrentTime() { // returns a slightly delayed time value, under frequency of UPDATE_INTERVAL + return serverCurrentTime; + } + public void updateCurrentTime() { - currentTime.addAndGet(ServerConstants.UPDATE_INTERVAL); + serverCurrentTime = currentTime.addAndGet(ServerConstants.UPDATE_INTERVAL); } public long forceUpdateCurrentTime() { long timeNow = System.currentTimeMillis(); + serverCurrentTime = timeNow; currentTime.set(timeNow); + return timeNow; } - public long getCurrentTime() { // returns a slightly delayed time value - return currentTime.get(); - } - public boolean isOnline() { return online; } @@ -953,6 +956,34 @@ public class Server { } */ + public Pair>, List>>> loadAccountCharlist(Integer accountId) { + List wlist = worlds; + List>> accChars = new ArrayList<>(wlist.size() + 1); + int chrTotal = 0; + List lastwchars = null; + + lgnRLock.lock(); + try { + for(World w : wlist) { + List wchars = w.getAccountCharactersView(accountId); + if(wchars == null) { + if(!accountChars.containsKey(accountId)) { + accountChars.put(accountId, new HashSet()); // not advisable at all to write on the map on a read-protected environment + } // yet it's known there's no problem since no other point in the source does + } else if(!wchars.isEmpty()) { // this action. + lastwchars = wchars; + + accChars.add(new Pair<>(w.getId(), wchars)); + chrTotal += wchars.size(); + } + } + } finally { + lgnRLock.unlock(); + } + + return new Pair<>(new Pair<>(chrTotal, lastwchars), accChars); + } + private static List> loadAccountCharactersViewFromDb(MapleClient c, int wlen) { List> wchars = new ArrayList<>(wlen); for(int i = 0; i < wlen; i++) wchars.add(i, new LinkedList()); @@ -1003,8 +1034,8 @@ public class Server { return wchars; } - public void loadAccountCharactersView(MapleClient c) { - int accId = c.getAccID(); + public void loadAccountCharacters(MapleClient c) { + Integer accId = c.getAccID(); int gmLevel = 0; boolean firstAccountLogin; diff --git a/src/net/server/channel/Channel.java b/src/net/server/channel/Channel.java index 9ae7c78f5b..8141da42f6 100644 --- a/src/net/server/channel/Channel.java +++ b/src/net/server/channel/Channel.java @@ -89,6 +89,7 @@ public final class Channel { private EventScriptManager eventSM; private MobStatusScheduler mobStatusSchedulers[] = new MobStatusScheduler[4]; private MobAnimationScheduler mobAnimationSchedulers[] = new MobAnimationScheduler[4]; + private FaceExpressionScheduler faceExpressionSchedulers[] = new FaceExpressionScheduler[4]; private OverallScheduler channelSchedulers[] = new OverallScheduler[4]; private Map hiredMerchants = new HashMap<>(); private final Map storedVars = new HashMap<>(); @@ -120,6 +121,8 @@ public final class Channel { private ReadLock merchRlock = merchantLock.readLock(); private WriteLock merchWlock = merchantLock.writeLock(); + private Lock faceLock[] = new MonitoredReentrantLock[4]; + private Lock lock = new MonitoredReentrantLock(MonitoredLockType.CHANNEL, true); public Channel(final int world, final int channel, long startTime) { @@ -157,8 +160,11 @@ public final class Channel { } for(int i = 0; i < 4; i++) { + faceLock[i] = new MonitoredReentrantLock(MonitoredLockType.CHANNEL_FACEEXPRS, true); + mobStatusSchedulers[i] = new MobStatusScheduler(); mobAnimationSchedulers[i] = new MobAnimationScheduler(); + faceExpressionSchedulers[i] = new FaceExpressionScheduler(faceLock[i]); channelSchedulers[i] = new OverallScheduler(); } @@ -870,6 +876,40 @@ public final class Channel { channelSchedulers[getChannelSchedulerIndex(mapid)].forceRunDelayedAction(runAction); } + public void registerFaceExpression(final MapleMap map, final MapleCharacter chr, int emote) { + int lockid = getChannelSchedulerIndex(map.getId()); + + Runnable cancelAction = new Runnable() { + @Override + public void run() { + if(chr.isLoggedinWorld()) { + map.broadcastMessage(chr, MaplePacketCreator.facialExpression(chr, 0), false); + } + } + }; + + faceLock[lockid].lock(); + try { + if(chr.isLoggedinWorld()) { + faceExpressionSchedulers[lockid].registerFaceExpression(chr.getId(), cancelAction); + map.broadcastMessage(chr, MaplePacketCreator.facialExpression(chr, emote), false); + } + } finally { + faceLock[lockid].unlock(); + } + } + + public void unregisterFaceExpression(int mapid, MapleCharacter chr) { + int lockid = getChannelSchedulerIndex(mapid); + + faceLock[lockid].lock(); + try { + faceExpressionSchedulers[lockid].unregisterFaceExpression(chr.getId()); + } finally { + faceLock[lockid].unlock(); + } + } + public void debugMarriageStatus() { System.out.println(" ----- WORLD DATA -----"); Server.getInstance().getWorld(world).debugMarriageStatus(); diff --git a/src/net/server/channel/handlers/AranComboHandler.java b/src/net/server/channel/handlers/AranComboHandler.java index c129be99ae..5490843b6a 100644 --- a/src/net/server/channel/handlers/AranComboHandler.java +++ b/src/net/server/channel/handlers/AranComboHandler.java @@ -36,7 +36,7 @@ public class AranComboHandler extends AbstractMaplePacketHandler { final MapleCharacter player = c.getPlayer(); int skillLevel = player.getSkillLevel(SkillFactory.getSkill(Aran.COMBO_ABILITY)); if (GameConstants.isAran(player.getJob().getId()) && (skillLevel > 0 || player.getJob().getId() == 2000)) { - final long currentTime = System.currentTimeMillis(); + final long currentTime = currentServerTime(); short combo = player.getCombo(); if ((currentTime - player.getLastCombo()) > 3000 && combo > 0) { combo = 0; diff --git a/src/net/server/channel/handlers/BBSOperationHandler.java b/src/net/server/channel/handlers/BBSOperationHandler.java index 3983388fff..38310e4aa3 100644 --- a/src/net/server/channel/handlers/BBSOperationHandler.java +++ b/src/net/server/channel/handlers/BBSOperationHandler.java @@ -133,7 +133,7 @@ public final class BBSOperationHandler extends AbstractMaplePacketHandler { ps = con.prepareStatement("INSERT INTO bbs_replies " + "(`threadid`, `postercid`, `timestamp`, `content`) VALUES " + "(?, ?, ?, ?)"); ps.setInt(1, threadid); ps.setInt(2, c.getPlayer().getId()); - ps.setLong(3, System.currentTimeMillis()); + ps.setLong(3, currentServerTime()); ps.setString(4, text); ps.execute(); ps.close(); @@ -157,7 +157,7 @@ public final class BBSOperationHandler extends AbstractMaplePacketHandler { Connection con = DatabaseConnection.getConnection(); try (PreparedStatement ps = con.prepareStatement("UPDATE bbs_threads SET `name` = ?, `timestamp` = ?, " + "`icon` = ?, " + "`startpost` = ? WHERE guildid = ? AND localthreadid = ? AND (postercid = ? OR ?)")) { ps.setString(1, title); - ps.setLong(2, System.currentTimeMillis()); + ps.setLong(2, currentServerTime()); ps.setInt(3, icon); ps.setString(4, text); ps.setInt(5, c.getGuildId()); @@ -194,7 +194,7 @@ public final class BBSOperationHandler extends AbstractMaplePacketHandler { ps = con.prepareStatement("INSERT INTO bbs_threads " + "(`postercid`, `name`, `timestamp`, `icon`, `startpost`, " + "`guildid`, `localthreadid`) " + "VALUES(?, ?, ?, ?, ?, ?, ?)"); ps.setInt(1, c.getId()); ps.setString(2, title); - ps.setLong(3, System.currentTimeMillis()); + ps.setLong(3, currentServerTime()); ps.setInt(4, icon); ps.setString(5, text); ps.setInt(6, c.getGuildId()); diff --git a/src/net/server/channel/handlers/ChangeMapSpecialHandler.java b/src/net/server/channel/handlers/ChangeMapSpecialHandler.java index 292a6dd1b9..b376e7867e 100644 --- a/src/net/server/channel/handlers/ChangeMapSpecialHandler.java +++ b/src/net/server/channel/handlers/ChangeMapSpecialHandler.java @@ -35,7 +35,7 @@ public final class ChangeMapSpecialHandler extends AbstractMaplePacketHandler { String startwp = slea.readMapleAsciiString(); slea.readShort(); MaplePortal portal = c.getPlayer().getMap().getPortal(startwp); - if (portal == null || c.getPlayer().portalDelay() > System.currentTimeMillis() || c.getPlayer().getBlockedPortals().contains(portal.getScriptName())) { + if (portal == null || c.getPlayer().portalDelay() > currentServerTime() || c.getPlayer().getBlockedPortals().contains(portal.getScriptName())) { c.announce(MaplePacketCreator.enableActions()); return; } diff --git a/src/net/server/channel/handlers/CloseRangeDamageHandler.java b/src/net/server/channel/handlers/CloseRangeDamageHandler.java index f9b60158a7..6b07e25232 100644 --- a/src/net/server/channel/handlers/CloseRangeDamageHandler.java +++ b/src/net/server/channel/handlers/CloseRangeDamageHandler.java @@ -50,9 +50,9 @@ public final class CloseRangeDamageHandler extends AbstractDealDamageHandler { @Override public final void handlePacket(SeekableLittleEndianAccessor slea, MapleClient c) { MapleCharacter chr = c.getPlayer(); - chr.setPetLootCd(System.currentTimeMillis()); + chr.setPetLootCd(currentServerTime()); - /*long timeElapsed = System.currentTimeMillis() - chr.getAutobanManager().getLastSpam(8); + /*long timeElapsed = currentServerTime() - chr.getAutobanManager().getLastSpam(8); if(timeElapsed < 300) { AutobanFactory.FAST_ATTACK.alert(chr, "Time: " + timeElapsed); } @@ -115,7 +115,7 @@ public final class CloseRangeDamageHandler extends AbstractDealDamageHandler { int duration = combo.getEffect(olv).getDuration(); List> stat = Collections.singletonList(new Pair<>(MapleBuffStat.COMBO, neworbcount)); chr.setBuffedValue(MapleBuffStat.COMBO, neworbcount); - duration -= (int) (System.currentTimeMillis() - chr.getBuffedStarttime(MapleBuffStat.COMBO)); + duration -= (int) (currentServerTime() - chr.getBuffedStarttime(MapleBuffStat.COMBO)); c.announce(MaplePacketCreator.giveBuff(oid, duration, stat)); chr.getMap().broadcastMessage(chr, MaplePacketCreator.giveForeignBuff(chr.getId(), stat), false); } @@ -174,7 +174,7 @@ public final class CloseRangeDamageHandler extends AbstractDealDamageHandler { return; } else { c.announce(MaplePacketCreator.skillCooldown(attack.skill, effect_.getCooldown())); - chr.addCooldown(attack.skill, System.currentTimeMillis(), effect_.getCooldown() * 1000); + chr.addCooldown(attack.skill, currentServerTime(), effect_.getCooldown() * 1000); } } } diff --git a/src/net/server/channel/handlers/CoconutHandler.java b/src/net/server/channel/handlers/CoconutHandler.java index 66fe45525c..e25a2d167e 100644 --- a/src/net/server/channel/handlers/CoconutHandler.java +++ b/src/net/server/channel/handlers/CoconutHandler.java @@ -50,7 +50,7 @@ public final class CoconutHandler extends AbstractMaplePacketHandler { if (event == null){ return; } - if (System.currentTimeMillis() < nut.getHitTime()){ + if (currentServerTime() < nut.getHitTime()){ return; } if (nut.getHits() > 2 && Math.random() < 0.4) { diff --git a/src/net/server/channel/handlers/FaceExpressionHandler.java b/src/net/server/channel/handlers/FaceExpressionHandler.java index 03e170ca65..ed65bd715e 100644 --- a/src/net/server/channel/handlers/FaceExpressionHandler.java +++ b/src/net/server/channel/handlers/FaceExpressionHandler.java @@ -22,21 +22,32 @@ package net.server.channel.handlers; import client.MapleClient; +import client.MapleCharacter; import constants.ItemConstants; import net.AbstractMaplePacketHandler; -import tools.MaplePacketCreator; import tools.data.input.SeekableLittleEndianAccessor; public final class FaceExpressionHandler extends AbstractMaplePacketHandler { @Override public final void handlePacket(SeekableLittleEndianAccessor slea, MapleClient c) { + MapleCharacter chr = c.getPlayer(); int emote = slea.readInt(); + if (emote > 7) { int emoteid = 5159992 + emote; - if (c.getPlayer().getInventory(ItemConstants.getInventoryType(emoteid)).findById(emoteid) == null) { + if (chr.getInventory(ItemConstants.getInventoryType(emoteid)).findById(emoteid) == null) { return; } } - c.getPlayer().getMap().broadcastMessage(c.getPlayer(), MaplePacketCreator.facialExpression(c.getPlayer(), emote), false); + + if(c.trylockClient()) { + try { // expecting players never intends to wear the emote 0 (default face, that changes back after 5sec timeout) + if (emote != 0 && chr.isLoggedinWorld()) { + chr.changeFaceExpression(emote); + } + } finally { + c.unlockClient(); + } + } } } diff --git a/src/net/server/channel/handlers/GeneralChatHandler.java b/src/net/server/channel/handlers/GeneralChatHandler.java index b822499d76..0d30723da6 100644 --- a/src/net/server/channel/handlers/GeneralChatHandler.java +++ b/src/net/server/channel/handlers/GeneralChatHandler.java @@ -45,7 +45,7 @@ public final class GeneralChatHandler extends AbstractMaplePacketHandler { public final void handlePacket(SeekableLittleEndianAccessor slea, MapleClient c) { String s = slea.readMapleAsciiString(); MapleCharacter chr = c.getPlayer(); - if(chr.getAutobanManager().getLastSpam(7) + 200 > System.currentTimeMillis()) { + if(chr.getAutobanManager().getLastSpam(7) + 200 > currentServerTime()) { c.announce(MaplePacketCreator.enableActions()); return; } diff --git a/src/net/server/channel/handlers/GuildOperationHandler.java b/src/net/server/channel/handlers/GuildOperationHandler.java index 55317a7d33..396497ea02 100644 --- a/src/net/server/channel/handlers/GuildOperationHandler.java +++ b/src/net/server/channel/handlers/GuildOperationHandler.java @@ -60,7 +60,7 @@ public final class GuildOperationHandler extends AbstractMaplePacketHandler { public Invited(String n, int id) { name = n.toLowerCase(); gid = id; - expiration = System.currentTimeMillis() + 60 * 60 * 1000; + expiration = currentServerTime() + 60 * 60 * 1000; } @Override @@ -81,20 +81,20 @@ public final class GuildOperationHandler extends AbstractMaplePacketHandler { } } private java.util.List invited = new java.util.LinkedList(); - private long nextPruneTime = System.currentTimeMillis() + 20 * 60 * 1000; + private long nextPruneTime = currentServerTime() + 20 * 60 * 1000; @Override public final void handlePacket(SeekableLittleEndianAccessor slea, MapleClient c) { - if (System.currentTimeMillis() >= nextPruneTime) { + if (currentServerTime() >= nextPruneTime) { Iterator itr = invited.iterator(); Invited inv; while (itr.hasNext()) { inv = itr.next(); - if (System.currentTimeMillis() >= inv.expiration) { + if (currentServerTime() >= inv.expiration) { itr.remove(); } } - nextPruneTime = System.currentTimeMillis() + 20 * 60 * 1000; + nextPruneTime = currentServerTime() + 20 * 60 * 1000; } MapleCharacter mc = c.getPlayer(); byte type = slea.readByte(); diff --git a/src/net/server/channel/handlers/InventoryMergeHandler.java b/src/net/server/channel/handlers/InventoryMergeHandler.java index 94700cb3a3..cb129227d1 100644 --- a/src/net/server/channel/handlers/InventoryMergeHandler.java +++ b/src/net/server/channel/handlers/InventoryMergeHandler.java @@ -47,52 +47,57 @@ public final class InventoryMergeHandler extends AbstractMaplePacketHandler { } MapleInventory inventory = c.getPlayer().getInventory(inventoryType); + inventory.lockInventory(); + try { + //------------------- RonanLana's SLOT MERGER ----------------- - //------------------- RonanLana's SLOT MERGER ----------------- - - MapleItemInformationProvider ii = MapleItemInformationProvider.getInstance(); - Item srcItem, dstItem; + MapleItemInformationProvider ii = MapleItemInformationProvider.getInstance(); + Item srcItem, dstItem; - for(short dst = 1; dst <= inventory.getSlotLimit(); dst++) { - dstItem = inventory.getItem(dst); - if(dstItem == null) continue; + for(short dst = 1; dst <= inventory.getSlotLimit(); dst++) { + dstItem = inventory.getItem(dst); + if(dstItem == null) continue; - for(short src = (short)(dst + 1); src <= inventory.getSlotLimit(); src++) { - srcItem = inventory.getItem(src); - if(srcItem == null) continue; + for(short src = (short)(dst + 1); src <= inventory.getSlotLimit(); src++) { + srcItem = inventory.getItem(src); + if(srcItem == null) continue; - if(dstItem.getItemId() != srcItem.getItemId()) continue; - if(dstItem.getQuantity() == ii.getSlotMax(c, inventory.getItem(dst).getItemId())) break; + if(dstItem.getItemId() != srcItem.getItemId()) continue; + if(dstItem.getQuantity() == ii.getSlotMax(c, inventory.getItem(dst).getItemId())) break; - MapleInventoryManipulator.move(c, inventoryType, src, dst); - } - } - - //------------------------------------------------------------ - - inventory = c.getPlayer().getInventory(inventoryType); - boolean sorted = false; - - while (!sorted) { - short freeSlot = inventory.getNextFreeSlot(); - - if (freeSlot != -1) { - short itemSlot = -1; - for (short i = (short) (freeSlot + 1); i <= inventory.getSlotLimit(); i = (short) (i + 1)) { - if (inventory.getItem(i) != null) { - itemSlot = i; - break; - } + MapleInventoryManipulator.move(c, inventoryType, src, dst); } - if (itemSlot > 0) { - MapleInventoryManipulator.move(c, inventoryType, itemSlot, freeSlot); + } + + //------------------------------------------------------------ + + inventory = c.getPlayer().getInventory(inventoryType); + boolean sorted = false; + + while (!sorted) { + short freeSlot = inventory.getNextFreeSlot(); + + if (freeSlot != -1) { + short itemSlot = -1; + for (short i = (short) (freeSlot + 1); i <= inventory.getSlotLimit(); i = (short) (i + 1)) { + if (inventory.getItem(i) != null) { + itemSlot = i; + break; + } + } + if (itemSlot > 0) { + MapleInventoryManipulator.move(c, inventoryType, itemSlot, freeSlot); + } else { + sorted = true; + } } else { sorted = true; } - } else { - sorted = true; } + } finally { + inventory.unlockInventory(); } + c.announce(MaplePacketCreator.finishedSort(inventoryType.getType())); c.announce(MaplePacketCreator.enableActions()); } diff --git a/src/net/server/channel/handlers/InventorySortHandler.java b/src/net/server/channel/handlers/InventorySortHandler.java index ac7601feec..3442c1b430 100644 --- a/src/net/server/channel/handlers/InventorySortHandler.java +++ b/src/net/server/channel/handlers/InventorySortHandler.java @@ -199,33 +199,38 @@ public final class InventorySortHandler extends AbstractMaplePacketHandler { c.disconnect(false, false); return; } - - MapleInventory inventory = chr.getInventory(MapleInventoryType.getByType(inventoryType)); - + ArrayList itemarray = new ArrayList<>(); List mods = new ArrayList<>(); - for (short i = 1; i <= inventory.getSlotLimit(); i++) { - Item item = inventory.getItem(i); - if (item != null) { - itemarray.add((Item) item.copy()); + MapleInventory inventory = chr.getInventory(MapleInventoryType.getByType(inventoryType)); + inventory.lockInventory(); + try { + for (short i = 1; i <= inventory.getSlotLimit(); i++) { + Item item = inventory.getItem(i); + if (item != null) { + itemarray.add((Item) item.copy()); + } } + + for (Item item : itemarray) { + inventory.removeSlot(item.getPosition()); + mods.add(new ModifyInventory(3, item)); + } + + int invTypeCriteria = (MapleInventoryType.getByType(inventoryType) == MapleInventoryType.EQUIP) ? 3 : 1; + int sortCriteria = (ServerConstants.USE_ITEM_SORT_BY_NAME == true) ? 2 : 0; + PairedQuicksort pq = new PairedQuicksort(itemarray, sortCriteria, invTypeCriteria); + + for (Item item : itemarray) { + inventory.addItem(item); + mods.add(new ModifyInventory(0, item.copy()));//to prevent crashes + } + itemarray.clear(); + } finally { + inventory.unlockInventory(); } - for (Item item : itemarray) { - inventory.removeSlot(item.getPosition()); - mods.add(new ModifyInventory(3, item)); - } - - int invTypeCriteria = (MapleInventoryType.getByType(inventoryType) == MapleInventoryType.EQUIP) ? 3 : 1; - int sortCriteria = (ServerConstants.USE_ITEM_SORT_BY_NAME == true) ? 2 : 0; - PairedQuicksort pq = new PairedQuicksort(itemarray, sortCriteria, invTypeCriteria); - - for (Item item : itemarray) { - inventory.addItem(item); - mods.add(new ModifyInventory(0, item.copy()));//to prevent crashes - } - itemarray.clear(); c.announce(MaplePacketCreator.modifyInventory(true, mods)); c.announce(MaplePacketCreator.finishedSort2(inventoryType)); c.announce(MaplePacketCreator.enableActions()); diff --git a/src/net/server/channel/handlers/ItemMoveHandler.java b/src/net/server/channel/handlers/ItemMoveHandler.java index 07629891f7..959232cd98 100644 --- a/src/net/server/channel/handlers/ItemMoveHandler.java +++ b/src/net/server/channel/handlers/ItemMoveHandler.java @@ -36,7 +36,7 @@ public final class ItemMoveHandler extends AbstractMaplePacketHandler { @Override public final void handlePacket(SeekableLittleEndianAccessor slea, MapleClient c) { slea.skip(4); - if(c.getPlayer().getAutobanManager().getLastSpam(6) + 300 > System.currentTimeMillis()) { + if(c.getPlayer().getAutobanManager().getLastSpam(6) + 300 > currentServerTime()) { c.announce(MaplePacketCreator.enableActions()); return; } diff --git a/src/net/server/channel/handlers/ItemRewardHandler.java b/src/net/server/channel/handlers/ItemRewardHandler.java index e40ee239ed..1b9b8e6872 100644 --- a/src/net/server/channel/handlers/ItemRewardHandler.java +++ b/src/net/server/channel/handlers/ItemRewardHandler.java @@ -56,7 +56,7 @@ public final class ItemRewardHandler extends AbstractMaplePacketHandler { if (ItemConstants.getInventoryType(reward.itemid) == MapleInventoryType.EQUIP) { final Item item = ii.getEquipById(reward.itemid); if (reward.period != -1) { - item.setExpiration(System.currentTimeMillis() + (reward.period * 60 * 60 * 10)); + item.setExpiration(currentServerTime() + (reward.period * 60 * 60 * 10)); } MapleInventoryManipulator.addFromDrop(c, item, false); } else { diff --git a/src/net/server/channel/handlers/MagicDamageHandler.java b/src/net/server/channel/handlers/MagicDamageHandler.java index 34af281eb9..f7df498812 100644 --- a/src/net/server/channel/handlers/MagicDamageHandler.java +++ b/src/net/server/channel/handlers/MagicDamageHandler.java @@ -39,9 +39,9 @@ public final class MagicDamageHandler extends AbstractDealDamageHandler { @Override public final void handlePacket(SeekableLittleEndianAccessor slea, MapleClient c) { MapleCharacter chr = c.getPlayer(); - chr.setPetLootCd(System.currentTimeMillis()); + chr.setPetLootCd(currentServerTime()); - /*long timeElapsed = System.currentTimeMillis() - chr.getAutobanManager().getLastSpam(8); + /*long timeElapsed = currentServerTime() - chr.getAutobanManager().getLastSpam(8); if(timeElapsed < 300) { AutobanFactory.FAST_ATTACK.alert(chr, "Time: " + timeElapsed); } @@ -74,7 +74,7 @@ public final class MagicDamageHandler extends AbstractDealDamageHandler { return; } else { c.announce(MaplePacketCreator.skillCooldown(attack.skill, effect_.getCooldown())); - chr.addCooldown(attack.skill, System.currentTimeMillis(), effect_.getCooldown() * 1000); + chr.addCooldown(attack.skill, currentServerTime(), effect_.getCooldown() * 1000); } } applyAttack(attack, chr, effect.getAttackCount()); diff --git a/src/net/server/channel/handlers/MoveLifeHandler.java b/src/net/server/channel/handlers/MoveLifeHandler.java index 905bdd21a5..6bdad9449c 100644 --- a/src/net/server/channel/handlers/MoveLifeHandler.java +++ b/src/net/server/channel/handlers/MoveLifeHandler.java @@ -26,7 +26,6 @@ import client.MapleClient; import java.awt.Point; import java.util.ArrayList; import java.util.List; -import net.server.Server; import server.life.MapleMonster; import server.life.MapleMonsterInformationProvider; //import server.life.MobAttackInfo; @@ -102,7 +101,7 @@ public final class MoveLifeHandler extends AbstractMovementPacketHandler { toUse = MobSkillFactory.getMobSkill(nextCastSkill, nextCastSkillLevel); if (!isSkill && !isAttack) { - long curtime = Server.getInstance().getCurrentTime(); + long curtime = currentServerTime(); if(curtime >= monster.getNextBasicSkillTime()) { // dont use the special attack too often, chase the player f3 //MobAttackInfo mobAttack = MobAttackInfoFactory.getMobAttackInfo(monster, attackId); monster.setNextBasicSkillTime(curtime); diff --git a/src/net/server/channel/handlers/MultiChatHandler.java b/src/net/server/channel/handlers/MultiChatHandler.java index 587cb90a12..6a1a6e96c2 100644 --- a/src/net/server/channel/handlers/MultiChatHandler.java +++ b/src/net/server/channel/handlers/MultiChatHandler.java @@ -35,7 +35,7 @@ public final class MultiChatHandler extends AbstractMaplePacketHandler { @Override public final void handlePacket(SeekableLittleEndianAccessor slea, MapleClient c) { MapleCharacter player = c.getPlayer(); - if(player.getAutobanManager().getLastSpam(7) + 200 > System.currentTimeMillis()) { + if(player.getAutobanManager().getLastSpam(7) + 200 > currentServerTime()) { return; } diff --git a/src/net/server/channel/handlers/NPCTalkHandler.java b/src/net/server/channel/handlers/NPCTalkHandler.java index 49f5843e2c..5eeb025bd8 100644 --- a/src/net/server/channel/handlers/NPCTalkHandler.java +++ b/src/net/server/channel/handlers/NPCTalkHandler.java @@ -41,7 +41,7 @@ public final class NPCTalkHandler extends AbstractMaplePacketHandler { return; } - if(System.currentTimeMillis() - c.getPlayer().getNpcCooldown() < ServerConstants.BLOCK_NPC_RACE_CONDT) { + if(currentServerTime() - c.getPlayer().getNpcCooldown() < ServerConstants.BLOCK_NPC_RACE_CONDT) { c.announce(MaplePacketCreator.enableActions()); return; } @@ -53,7 +53,7 @@ public final class NPCTalkHandler extends AbstractMaplePacketHandler { if(ServerConstants.USE_DEBUG == true) c.getPlayer().dropMessage(5, "Talking to NPC " + npc.getId()); if (npc.getId() == 9010009) { //is duey - c.getPlayer().setNpcCooldown(System.currentTimeMillis()); + c.getPlayer().setNpcCooldown(currentServerTime()); DueyProcessor.dueySendTalk(c); } else { if (c.getCM() != null || c.getQM() != null) { diff --git a/src/net/server/channel/handlers/PetFoodHandler.java b/src/net/server/channel/handlers/PetFoodHandler.java index 44427ba916..3996114d25 100644 --- a/src/net/server/channel/handlers/PetFoodHandler.java +++ b/src/net/server/channel/handlers/PetFoodHandler.java @@ -38,7 +38,7 @@ public final class PetFoodHandler extends AbstractMaplePacketHandler { public final void handlePacket(SeekableLittleEndianAccessor slea, MapleClient c) { MapleCharacter chr = c.getPlayer(); AutobanManager abm = chr.getAutobanManager(); - if (abm.getLastSpam(2) + 500 > System.currentTimeMillis()) { + if (abm.getLastSpam(2) + 500 > currentServerTime()) { c.announce(MaplePacketCreator.enableActions()); return; } diff --git a/src/net/server/channel/handlers/PetLootHandler.java b/src/net/server/channel/handlers/PetLootHandler.java index dc07d32626..ea1bc23e42 100644 --- a/src/net/server/channel/handlers/PetLootHandler.java +++ b/src/net/server/channel/handlers/PetLootHandler.java @@ -42,7 +42,7 @@ public final class PetLootHandler extends AbstractMaplePacketHandler { @Override public final void handlePacket(SeekableLittleEndianAccessor slea, MapleClient c) { MapleCharacter chr = c.getPlayer(); - if(System.currentTimeMillis() - chr.getPetLootCd() < ServerConstants.PET_LOOT_UPON_ATTACK) { + if(currentServerTime() - chr.getPetLootCd() < ServerConstants.PET_LOOT_UPON_ATTACK) { c.announce(MaplePacketCreator.enableActions()); return; } diff --git a/src/net/server/channel/handlers/PlayerInteractionHandler.java b/src/net/server/channel/handlers/PlayerInteractionHandler.java index f6d58f54c6..bf90393e62 100644 --- a/src/net/server/channel/handlers/PlayerInteractionHandler.java +++ b/src/net/server/channel/handlers/PlayerInteractionHandler.java @@ -201,22 +201,20 @@ public final class PlayerInteractionHandler extends AbstractMaplePacketHandler { chr.getClient().announce(MaplePacketCreator.getMiniRoomError(6)); return; } - - if (itemId > 5030000 && itemId < 5030012 || itemId > 5140000 && itemId < 5140006) { - if (createType == 4) { - MaplePlayerShop shop = new MaplePlayerShop(chr, desc); - chr.setPlayerShop(shop); - chr.getMap().addMapObject(shop); - shop.sendShop(c); - c.getWorldServer().registerPlayerShop(shop); - //c.announce(MaplePacketCreator.getPlayerShopRemoveVisitor(1)); - } else { - MapleHiredMerchant merchant = new MapleHiredMerchant(chr, itemId, desc); - chr.setHiredMerchant(merchant); - c.getWorldServer().registerHiredMerchant(merchant); - chr.getClient().getChannelServer().addHiredMerchant(chr.getId(), merchant); - chr.announce(MaplePacketCreator.getHiredMerchant(chr, merchant, true)); - } + + if (ItemConstants.isPlayerShop(itemId)) { + MaplePlayerShop shop = new MaplePlayerShop(chr, desc); + chr.setPlayerShop(shop); + chr.getMap().addMapObject(shop); + shop.sendShop(c); + c.getWorldServer().registerPlayerShop(shop); + //c.announce(MaplePacketCreator.getPlayerShopRemoveVisitor(1)); + } else if (ItemConstants.isHiredMerchant(itemId)) { + MapleHiredMerchant merchant = new MapleHiredMerchant(chr, itemId, desc); + chr.setHiredMerchant(merchant); + c.getWorldServer().registerHiredMerchant(merchant); + chr.getClient().getChannelServer().addHiredMerchant(chr.getId(), merchant); + chr.announce(MaplePacketCreator.getHiredMerchant(chr, merchant, true)); } } } else if (mode == Action.INVITE.getCode()) { @@ -473,12 +471,18 @@ public final class PlayerInteractionHandler extends AbstractMaplePacketHandler { FilePrinter.printError(FilePrinter.EXPLOITS + chr.getName() + ".txt", chr.getName() + " might of possibly packet edited Hired Merchants\nperBundle: " + perBundle + "\nperBundle * bundles (This multiplied cannot be greater than 2000): " + perBundle * bundles + "\nbundles: " + bundles + "\nprice: " + price); return; } - Item sellItem = ivItem.copy(); - if (ServerConstants.USE_ENFORCE_UNMERCHABLE_PET && ItemConstants.isPet(ivItem.getItemId())) { - c.announce(MaplePacketCreator.serverNotice(1, "Pets are not allowed to be sold on the Player Shop.")); + + if(ServerConstants.USE_ENFORCE_UNMERCHABLE_CASH && MapleItemInformationProvider.getInstance().isCash(ivItem.getItemId())) { + c.announce(MaplePacketCreator.serverNotice(1, "Cash items are not allowed to be sold on the Player Store.")); return; } + if (ServerConstants.USE_ENFORCE_UNMERCHABLE_PET && ItemConstants.isPet(ivItem.getItemId())) { + c.announce(MaplePacketCreator.serverNotice(1, "Pets are not allowed to be sold on the Player Store.")); + return; + } + + Item sellItem = ivItem.copy(); if(!ItemConstants.isRechargeable(ivItem.getItemId())) { sellItem.setQuantity(perBundle); } diff --git a/src/net/server/channel/handlers/PlayerLoggedinHandler.java b/src/net/server/channel/handlers/PlayerLoggedinHandler.java index a23acdad1c..f44bb10e1d 100644 --- a/src/net/server/channel/handlers/PlayerLoggedinHandler.java +++ b/src/net/server/channel/handlers/PlayerLoggedinHandler.java @@ -343,7 +343,7 @@ public final class PlayerLoggedinHandler extends AbstractMaplePacketHandler { private static List> getLocalStartTimes(List lpbvl) { List> timedBuffs = new ArrayList<>(); - long curtime = System.currentTimeMillis(); + long curtime = currentServerTime(); for(PlayerBuffValueHolder pb : lpbvl) { timedBuffs.add(new Pair<>(curtime - pb.usedTime, pb)); diff --git a/src/net/server/channel/handlers/RangedAttackHandler.java b/src/net/server/channel/handlers/RangedAttackHandler.java index e72b2cd9d3..8bd367bc59 100644 --- a/src/net/server/channel/handlers/RangedAttackHandler.java +++ b/src/net/server/channel/handlers/RangedAttackHandler.java @@ -51,9 +51,9 @@ public final class RangedAttackHandler extends AbstractDealDamageHandler { @Override public final void handlePacket(SeekableLittleEndianAccessor slea, MapleClient c) { MapleCharacter chr = c.getPlayer(); - chr.setPetLootCd(System.currentTimeMillis()); + chr.setPetLootCd(currentServerTime()); - /*long timeElapsed = System.currentTimeMillis() - chr.getAutobanManager().getLastSpam(8); + /*long timeElapsed = currentServerTime() - chr.getAutobanManager().getLastSpam(8); if(timeElapsed < 300) { AutobanFactory.FAST_ATTACK.alert(chr, "Time: " + timeElapsed); } @@ -218,7 +218,7 @@ public final class RangedAttackHandler extends AbstractDealDamageHandler { return; } else { c.announce(MaplePacketCreator.skillCooldown(attack.skill, effect_.getCooldown())); - chr.addCooldown(attack.skill, System.currentTimeMillis(), effect_.getCooldown() * 1000); + chr.addCooldown(attack.skill, currentServerTime(), effect_.getCooldown() * 1000); } } } diff --git a/src/net/server/channel/handlers/SnowballHandler.java b/src/net/server/channel/handlers/SnowballHandler.java index d8abfcd1af..bf892385c6 100644 --- a/src/net/server/channel/handlers/SnowballHandler.java +++ b/src/net/server/channel/handlers/SnowballHandler.java @@ -44,10 +44,10 @@ public final class SnowballHandler extends AbstractMaplePacketHandler{ //slea.skip(4); if (snowball == null || othersnowball == null || snowball.getSnowmanHP() == 0) return; - if ((System.currentTimeMillis() - chr.getLastSnowballAttack()) < 500) return; + if ((currentServerTime() - chr.getLastSnowballAttack()) < 500) return; if (chr.getTeam() != (what % 2)) return; - chr.setLastSnowballAttack(System.currentTimeMillis()); + chr.setLastSnowballAttack(currentServerTime()); int damage = 0; if (what < 2 && othersnowball.getSnowmanHP() > 0) damage = 10; diff --git a/src/net/server/channel/handlers/SpecialMoveHandler.java b/src/net/server/channel/handlers/SpecialMoveHandler.java index b9483ac934..460607c29d 100644 --- a/src/net/server/channel/handlers/SpecialMoveHandler.java +++ b/src/net/server/channel/handlers/SpecialMoveHandler.java @@ -89,7 +89,7 @@ public final class SpecialMoveHandler extends AbstractMaplePacketHandler { } c.announce(MaplePacketCreator.skillCooldown(skillid, cooldownTime)); - chr.addCooldown(skillid, System.currentTimeMillis(), cooldownTime * 1000); + chr.addCooldown(skillid, currentServerTime(), cooldownTime * 1000); } } if (skillid == Hero.MONSTER_MAGNET || skillid == Paladin.MONSTER_MAGNET || skillid == DarkKnight.MONSTER_MAGNET) { // Monster Magnet diff --git a/src/net/server/channel/handlers/UseCashItemHandler.java b/src/net/server/channel/handlers/UseCashItemHandler.java index f8c4367a7e..34b83ce2e9 100644 --- a/src/net/server/channel/handlers/UseCashItemHandler.java +++ b/src/net/server/channel/handlers/UseCashItemHandler.java @@ -67,7 +67,7 @@ public final class UseCashItemHandler extends AbstractMaplePacketHandler { public final void handlePacket(SeekableLittleEndianAccessor slea, MapleClient c) { final MapleCharacter player = c.getPlayer(); - long timeNow = System.currentTimeMillis(); + long timeNow = currentServerTime(); if (timeNow - player.getLastUsedCashItem() < 3000) { player.dropMessage(1, "You have used a cash item recently. Wait a moment, then try again."); c.announce(MaplePacketCreator.enableActions()); @@ -310,7 +310,7 @@ public final class UseCashItemHandler extends AbstractMaplePacketHandler { } if (period > 0) { - eq.setExpiration(System.currentTimeMillis() + (period * 60 * 60 * 24 * 1000)); + eq.setExpiration(currentServerTime() + (period * 60 * 60 * 24 * 1000)); } remove(c, itemId); @@ -335,12 +335,13 @@ public final class UseCashItemHandler extends AbstractMaplePacketHandler { } } else if (itemType == 507) { boolean whisper; - switch (itemId / 1000 % 10) { + switch ((itemId / 1000) % 10) { case 1: // Megaphone if (player.getLevel() > 9) { player.getClient().getChannelServer().broadcastPacket(MaplePacketCreator.serverNotice(2, medal + player.getName() + " : " + slea.readMapleAsciiString())); } else { player.dropMessage(1, "You may not use this until you're level 10."); + return; } break; case 2: // Super megaphone @@ -375,15 +376,16 @@ public final class UseCashItemHandler extends AbstractMaplePacketHandler { messages.add(message); } slea.readInt(); - if (megassenger) { - Server.getInstance().broadcastMessage(c.getWorld(), MaplePacketCreator.serverNotice(3, c.getChannel(), medal + player.getName() + " : " + builder.toString(), ear)); - } - if (!MapleTVEffect.isActive()) { - new MapleTVEffect(player, victim, messages, tvType); - } else { + + if (!MapleTVEffect.broadcastMapleTVIfNotActive(player, victim, messages, tvType)) { player.dropMessage(1, "MapleTV is already in use."); return; } + + if (megassenger) { + Server.getInstance().broadcastMessage(c.getWorld(), MaplePacketCreator.serverNotice(3, c.getChannel(), medal + player.getName() + " : " + builder.toString(), ear)); + } + break; case 6: //item megaphone String msg = medal + c.getPlayer().getName() + " : " + slea.readMapleAsciiString(); diff --git a/src/net/server/channel/handlers/UseCatchItemHandler.java b/src/net/server/channel/handlers/UseCatchItemHandler.java index 85c93c01b6..c7782d38b7 100644 --- a/src/net/server/channel/handlers/UseCatchItemHandler.java +++ b/src/net/server/channel/handlers/UseCatchItemHandler.java @@ -65,7 +65,7 @@ public final class UseCatchItemHandler extends AbstractMaplePacketHandler { break; case 2270001: if (mob.getId() == 9500197) { - if ((abm.getLastSpam(10) + 1000) < System.currentTimeMillis()) { + if ((abm.getLastSpam(10) + 1000) < currentServerTime()) { if (mob.getHp() < ((mob.getMaxHp() / 10) * 4)) { chr.getMap().broadcastMessage(MaplePacketCreator.catchMonster(monsterid, itemId, (byte) 1)); mob.getMap().killMonster(mob, null, false); @@ -81,7 +81,7 @@ public final class UseCatchItemHandler extends AbstractMaplePacketHandler { break; case 2270002: if (mob.getId() == 9300157) { - if ((abm.getLastSpam(10) + 800) < System.currentTimeMillis()) { + if ((abm.getLastSpam(10) + 800) < currentServerTime()) { if (mob.getHp() < ((mob.getMaxHp() / 10) * 4)) { if (Math.random() < 0.5) { // 50% chance chr.getMap().broadcastMessage(MaplePacketCreator.catchMonster(monsterid, itemId, (byte) 1)); @@ -166,7 +166,7 @@ public final class UseCatchItemHandler extends AbstractMaplePacketHandler { break; case 2270008: if (mob.getId() == 9500336) { - if ((abm.getLastSpam(10) + 3000) < System.currentTimeMillis()) { + if ((abm.getLastSpam(10) + 3000) < currentServerTime()) { abm.spam(10); chr.getMap().broadcastMessage(MaplePacketCreator.catchMonster(monsterid, itemId, (byte) 1)); mob.getMap().killMonster(mob, null, false); diff --git a/src/net/server/channel/handlers/UseItemHandler.java b/src/net/server/channel/handlers/UseItemHandler.java index dac49603e3..ad2ee0ecd8 100644 --- a/src/net/server/channel/handlers/UseItemHandler.java +++ b/src/net/server/channel/handlers/UseItemHandler.java @@ -74,7 +74,7 @@ public final class UseItemHandler extends AbstractMaplePacketHandler { } else if (ItemConstants.isTownScroll(itemId)) { int banMap = chr.getMapId(); int banSp = chr.getMap().findClosestPlayerSpawnpoint(chr.getPosition()).getId(); - long banTime = System.currentTimeMillis(); + long banTime = currentServerTime(); if (ii.getItemEffect(toUse.getItemId()).applyTo(chr)) { if(ServerConstants.USE_BANISHABLE_TOWN_SCROLL) { diff --git a/src/net/server/channel/handlers/UseMapleLifeHandler.java b/src/net/server/channel/handlers/UseMapleLifeHandler.java index 77f781e7fb..7ecce520b2 100644 --- a/src/net/server/channel/handlers/UseMapleLifeHandler.java +++ b/src/net/server/channel/handlers/UseMapleLifeHandler.java @@ -33,7 +33,7 @@ public class UseMapleLifeHandler extends AbstractMaplePacketHandler { @Override public void handlePacket(SeekableLittleEndianAccessor slea, MapleClient c) { MapleCharacter player = c.getPlayer(); - long timeNow = System.currentTimeMillis(); + long timeNow = currentServerTime(); if(timeNow - player.getLastUsedCashItem() < 3000) { player.dropMessage(5, "Please wait a moment before trying again."); diff --git a/src/net/server/channel/handlers/WhisperHandler.java b/src/net/server/channel/handlers/WhisperHandler.java index 62dbaaa0ee..2920b7ce03 100644 --- a/src/net/server/channel/handlers/WhisperHandler.java +++ b/src/net/server/channel/handlers/WhisperHandler.java @@ -49,7 +49,7 @@ public final class WhisperHandler extends AbstractMaplePacketHandler { String recipient = slea.readMapleAsciiString(); String text = slea.readMapleAsciiString(); MapleCharacter player = c.getChannelServer().getPlayerStorage().getCharacterByName(recipient); - if(c.getPlayer().getAutobanManager().getLastSpam(7) + 200 > System.currentTimeMillis()) { + if(c.getPlayer().getAutobanManager().getLastSpam(7) + 200 > currentServerTime()) { return; } if (text.length() > Byte.MAX_VALUE && !player.isGM()) { diff --git a/src/net/server/channel/worker/BaseScheduler.java b/src/net/server/channel/worker/BaseScheduler.java index e643e4a8ce..699a5f5d39 100644 --- a/src/net/server/channel/worker/BaseScheduler.java +++ b/src/net/server/channel/worker/BaseScheduler.java @@ -40,6 +40,7 @@ import tools.locks.MonitoredReentrantLock; public abstract class BaseScheduler { private int idleProcs = 0; private List listeners = new LinkedList<>(); + private final List externalLocks; private Map> registeredEntries = new HashMap<>(); private ScheduledFuture schedulerTask = null; @@ -53,16 +54,43 @@ public abstract class BaseScheduler { protected BaseScheduler(MonitoredLockType lockType) { schedulerLock = new MonitoredReentrantLock(lockType, true); + externalLocks = new LinkedList<>(); + } + + // NOTE: practice EXTREME caution when adding external locks to the scheduler system, if you don't know what you're doing DON'T USE THIS. + protected BaseScheduler(MonitoredLockType lockType, List extLocks) { + schedulerLock = new MonitoredReentrantLock(lockType, true); + externalLocks = extLocks; } protected void addListener(SchedulerListener listener) { listeners.add(listener); } + private void lockScheduler() { + if(!externalLocks.isEmpty()) { + for(Lock l : externalLocks) { + l.lock(); + } + } + + schedulerLock.lock(); + } + + private void unlockScheduler() { + if(!externalLocks.isEmpty()) { + for(Lock l : externalLocks) { + l.unlock(); + } + } + + schedulerLock.unlock(); + } + private void runBaseSchedule() { List toRemove; - schedulerLock.lock(); + lockScheduler(); try { if(registeredEntries.isEmpty()) { idleProcs++; @@ -93,14 +121,14 @@ public abstract class BaseScheduler { registeredEntries.remove(mse); } } finally { - schedulerLock.unlock(); + unlockScheduler(); } dispatchRemovedEntries(toRemove, true); } protected void registerEntry(Object key, Runnable removalAction, long duration) { - schedulerLock.lock(); + lockScheduler(); try { idleProcs = 0; if(schedulerTask == null) { @@ -109,17 +137,17 @@ public abstract class BaseScheduler { registeredEntries.put(key, new Pair<>(removalAction, System.currentTimeMillis() + duration)); } finally { - schedulerLock.unlock(); + unlockScheduler(); } } protected void interruptEntry(Object key) { - schedulerLock.lock(); + lockScheduler(); try { Pair rm = registeredEntries.remove(key); if(rm != null) rm.getLeft().run(); } finally { - schedulerLock.unlock(); + unlockScheduler(); } dispatchRemovedEntries(Collections.singletonList(key), false); diff --git a/src/net/server/channel/worker/FaceExpressionScheduler.java b/src/net/server/channel/worker/FaceExpressionScheduler.java new file mode 100644 index 0000000000..d878717f25 --- /dev/null +++ b/src/net/server/channel/worker/FaceExpressionScheduler.java @@ -0,0 +1,42 @@ +/* + This file is part of the HeavenMS MapleStory Server + Copyleft 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 . +*/ +package net.server.channel.worker; + +import java.util.Collections; +import java.util.concurrent.locks.Lock; +import tools.locks.MonitoredLockType; + +/** + * + * @author Ronan + */ +public class FaceExpressionScheduler extends BaseScheduler { + public FaceExpressionScheduler(final Lock channelFaceLock) { + super(MonitoredLockType.CHANNEL_FACESCHDL, Collections.singletonList(channelFaceLock)); + } + + public void registerFaceExpression(Integer characterId, Runnable runAction) { + registerEntry(characterId, runAction, 5000); + } + + public void unregisterFaceExpression(Integer characterId) { + interruptEntry(characterId); + } +} diff --git a/src/net/server/handlers/login/CreateCharHandler.java b/src/net/server/handlers/login/CreateCharHandler.java index 86431bd7e3..a6024c0dc0 100644 --- a/src/net/server/handlers/login/CreateCharHandler.java +++ b/src/net/server/handlers/login/CreateCharHandler.java @@ -78,7 +78,7 @@ public final class CreateCharHandler extends AbstractMaplePacketHandler { int status; if (job == 0) { // Knights of Cygnus status = NoblesseCreator.createCharacter(c, name, face, hair + haircolor, skincolor, top, bottom, shoes, weapon, gender); - } else if (job == 1) { // Adventurer + } else if (job == 1) { // Adventurer status = BeginnerCreator.createCharacter(c, name, face, hair + haircolor, skincolor, top, bottom, shoes, weapon, gender); } else if (job == 2) { // Aran status = LegendCreator.createCharacter(c, name, face, hair + haircolor, skincolor, top, bottom, shoes, weapon, gender); diff --git a/src/net/server/handlers/login/DeleteCharHandler.java b/src/net/server/handlers/login/DeleteCharHandler.java index f6bd4ccae2..ae64c2d3d9 100644 --- a/src/net/server/handlers/login/DeleteCharHandler.java +++ b/src/net/server/handlers/login/DeleteCharHandler.java @@ -35,7 +35,7 @@ public final class DeleteCharHandler extends AbstractMaplePacketHandler { int cid = slea.readInt(); if (c.checkPic(pic)) { if(c.deleteCharacter(cid, c.getAccID())) { - FilePrinter.printError(FilePrinter.DELETED_CHARACTERS + c.getAccountName() + ".txt", c.getAccountName() + " deleted CID: " + cid + "\r\n"); + FilePrinter.print(FilePrinter.DELETED_CHARACTERS + c.getAccountName() + ".txt", c.getAccountName() + " deleted CID: " + cid + "\r\n"); c.announce(MaplePacketCreator.deleteCharResponse(cid, 0)); } else { c.announce(MaplePacketCreator.deleteCharResponse(cid, 0x14)); diff --git a/src/net/server/handlers/login/LoginPasswordHandler.java b/src/net/server/handlers/login/LoginPasswordHandler.java index 5cfea94e4e..a675cd68a3 100644 --- a/src/net/server/handlers/login/LoginPasswordHandler.java +++ b/src/net/server/handlers/login/LoginPasswordHandler.java @@ -34,6 +34,8 @@ import tools.DatabaseConnection; import tools.MaplePacketCreator; import tools.data.input.SeekableLittleEndianAccessor; import client.MapleClient; +import java.sql.ResultSet; +import java.sql.Statement; public final class LoginPasswordHandler implements MaplePacketHandler { @@ -58,12 +60,17 @@ public final class LoginPasswordHandler implements MaplePacketHandler { if (ServerConstants.AUTOMATIC_REGISTER && loginok == 5) { try { con = DatabaseConnection.getConnection(); - ps = con.prepareStatement("INSERT INTO accounts (name, password, birthday, tempban) VALUES (?, ?, ?, ?);"); //Jayd: Added birthday, tempban + ps = con.prepareStatement("INSERT INTO accounts (name, password, birthday, tempban) VALUES (?, ?, ?, ?);", Statement.RETURN_GENERATED_KEYS); //Jayd: Added birthday, tempban ps.setString(1, login); ps.setString(2, BCrypt.hashpw(pwd, BCrypt.gensalt(12))); ps.setString(3, "2018-06-20"); //Jayd: was added to solve the MySQL 5.7 strict checking (birthday) ps.setString(4, "2018-06-20"); //Jayd: was added to solve the MySQL 5.7 strict checking (tempban) ps.executeUpdate(); + + ResultSet rs = ps.getGeneratedKeys(); + rs.next(); + c.setAccID(rs.getInt(1)); + rs.close(); } catch (SQLException e) { e.printStackTrace(); } finally { @@ -113,9 +120,7 @@ public final class LoginPasswordHandler implements MaplePacketHandler { } private static void login(MapleClient c){ - Server.getInstance().loadAccountCharactersView(c); // locks the login session until data is recovered from the cache or the DB. c.announce(MaplePacketCreator.getAuthSuccess(c));//why the fk did I do c.getAccountName()? - Server.getInstance().registerLoginState(c); } diff --git a/src/net/server/handlers/login/ServerlistRequestHandler.java b/src/net/server/handlers/login/ServerlistRequestHandler.java index 1e18f3a352..902a4100fa 100644 --- a/src/net/server/handlers/login/ServerlistRequestHandler.java +++ b/src/net/server/handlers/login/ServerlistRequestHandler.java @@ -34,6 +34,9 @@ public final class ServerlistRequestHandler extends AbstractMaplePacketHandler { @Override public final void handlePacket(SeekableLittleEndianAccessor slea, MapleClient c) { Server server = Server.getInstance(); + server.loadAccountCharacters(c); // locks the login session until data is recovered from the cache or the DB. + c.setClickedNPC(); + for (World world : server.getWorlds()) { c.announce(MaplePacketCreator.getServerList(world.getId(), GameConstants.WORLD_NAMES[world.getId()], world.getFlag(), world.getEventMessage(), world.getChannels())); } diff --git a/src/net/server/handlers/login/ViewAllCharHandler.java b/src/net/server/handlers/login/ViewAllCharHandler.java index 5808224def..6e7ea0c85e 100644 --- a/src/net/server/handlers/login/ViewAllCharHandler.java +++ b/src/net/server/handlers/login/ViewAllCharHandler.java @@ -24,11 +24,9 @@ package net.server.handlers.login; import client.MapleCharacter; import client.MapleClient; import constants.ServerConstants; -import java.util.ArrayList; import java.util.List; import net.AbstractMaplePacketHandler; import net.server.Server; -import net.server.world.World; import tools.MaplePacketCreator; import tools.data.input.SeekableLittleEndianAccessor; import tools.Pair; @@ -37,23 +35,18 @@ public final class ViewAllCharHandler extends AbstractMaplePacketHandler { @Override public final void handlePacket(SeekableLittleEndianAccessor slea, MapleClient c) { try { - List wlist = Server.getInstance().getWorlds(); - List>> worldChars = new ArrayList<>(wlist.size() + 1); - - int chrTotal = 0; - int accountId = c.getAccID(); - List lastwchars = null; - for(World w : wlist) { - List wchars = w.getAccountCharactersView(accountId); - - if(!wchars.isEmpty()) { - lastwchars = wchars; - - worldChars.add(new Pair<>(w.getId(), wchars)); - chrTotal += wchars.size(); - } + if(!c.canRequestCharlist()) { + c.announce(MaplePacketCreator.showAllCharacter(0, 0)); + return; } + int accountId = c.getAccID(); + Pair>, List>>> loginBlob = Server.getInstance().loadAccountCharlist(accountId); + + List>> worldChars = loginBlob.getRight(); + int chrTotal = loginBlob.getLeft().getLeft(); + List lastwchars = loginBlob.getLeft().getRight(); + if (chrTotal > 9) { int padRight = chrTotal % 3; if (padRight > 0 && lastwchars != null) { diff --git a/src/net/server/world/World.java b/src/net/server/world/World.java index 35ba8dc474..b028194dfe 100644 --- a/src/net/server/world/World.java +++ b/src/net/server/world/World.java @@ -322,7 +322,14 @@ public class World { accountCharsLock.lock(); try { - chrList = new LinkedList<>(accountChars.get(accountId).values()); + SortedMap accChars = accountChars.get(accountId); + + if(accChars != null) { + chrList = new LinkedList<>(accChars.values()); + } else { + accountChars.put(accountId, new TreeMap()); + chrList = null; + } } finally { accountCharsLock.unlock(); } diff --git a/src/server/MapleItemInformationProvider.java b/src/server/MapleItemInformationProvider.java index 2379f79aff..3716ab8844 100644 --- a/src/server/MapleItemInformationProvider.java +++ b/src/server/MapleItemInformationProvider.java @@ -1489,7 +1489,12 @@ public class MapleItemInformationProvider { } public boolean isCash(int itemId) { - return itemId / 1000000 == 5 || getEquipStats(itemId).get("cash") == 1; + int itemType = itemId / 1000000; + if (itemType == 5) return true; + if (itemType != 1) return false; + + Map eqpStats = getEquipStats(itemId); + return eqpStats != null && eqpStats.get("cash") == 1; } public boolean isUpgradeable(int itemId) { diff --git a/src/server/maps/MapleMap.java b/src/server/maps/MapleMap.java index c9fcd86f71..01a1df16e6 100644 --- a/src/server/maps/MapleMap.java +++ b/src/server/maps/MapleMap.java @@ -1066,14 +1066,14 @@ public class MapleMap { return character; } - public List getPlayersInRange(Rectangle box, List chr) { + public List getPlayersInRange(Rectangle box, List chrList) { List character = new LinkedList<>(); chrRLock.lock(); try { - for (MapleCharacter a : characters) { - if (chr.contains(a.getClient().getPlayer())) { - if (box.contains(a.getPosition())) { - character.add(a); + for (MapleCharacter chr : chrList) { + if (characters.contains(chr)) { + if (box.contains(chr.getPosition())) { + character.add(chr); } } } @@ -2529,6 +2529,9 @@ public class MapleMap { */ public void removePlayer(MapleCharacter chr) { + Channel cserv = chr.getClient().getChannelServer(); + + cserv.unregisterFaceExpression(mapid, chr); chr.unregisterChairBuff(); chrWLock.lock(); @@ -2540,10 +2543,10 @@ public class MapleMap { } if (MapleMiniDungeonInfo.isDungeonMap(mapid)) { - MapleMiniDungeon mmd = chr.getClient().getChannelServer().getMiniDungeon(mapid); + MapleMiniDungeon mmd = cserv.getMiniDungeon(mapid); if(mmd != null) { if(!mmd.unregisterPlayer(chr)) { - chr.getClient().getChannelServer().removeMiniDungeon(mapid); + cserv.removeMiniDungeon(mapid); } } } diff --git a/src/server/maps/MapleTVEffect.java b/src/server/maps/MapleTVEffect.java index f11d3090df..1e832617ea 100644 --- a/src/server/maps/MapleTVEffect.java +++ b/src/server/maps/MapleTVEffect.java @@ -22,7 +22,6 @@ package server.maps; import client.MapleCharacter; -import java.util.ArrayList; import java.util.List; import net.server.Server; import server.TimerManager; @@ -31,34 +30,28 @@ import tools.MaplePacketCreator; /* * MapleTVEffect * @author MrXotic + * @author Ronan (made MapleTV mechanics synchronous) */ public class MapleTVEffect { - private static boolean ACTIVE; + private final static boolean ACTIVE[] = new boolean[Server.getInstance().getWorlds().size()]; - private List message = new ArrayList<>(5); - private MapleCharacter user; - private int type; - private MapleCharacter partner; - - public MapleTVEffect(MapleCharacter u, MapleCharacter p, List msg, int t) { - this.message = msg; - this.user = u; - this.type = t; - this.partner = p; - broadcastTV(true); + public static synchronized boolean broadcastMapleTVIfNotActive(MapleCharacter player, MapleCharacter victim, List messages, int tvType){ + int w = player.getWorld(); + if(!ACTIVE[w]) { + broadcastTV(true, w, messages, player, tvType, victim); + return true; + } + + return false; } - public static boolean isActive(){ - return ACTIVE; - } - - private void broadcastTV(boolean activity) { + private static synchronized void broadcastTV(boolean activity, final int userWorld, List message, MapleCharacter user, int type, MapleCharacter partner) { Server server = Server.getInstance(); - ACTIVE = activity; - if (ACTIVE) { - server.broadcastMessage(user.getWorld(), MaplePacketCreator.enableTV()); - server.broadcastMessage(user.getWorld(), MaplePacketCreator.sendTV(user, message, type <= 2 ? type : type - 3, partner)); + ACTIVE[userWorld] = activity; + if (activity) { + server.broadcastMessage(userWorld, MaplePacketCreator.enableTV()); + server.broadcastMessage(userWorld, MaplePacketCreator.sendTV(user, message, type <= 2 ? type : type - 3, partner)); int delay = 15000; if (type == 4) { delay = 30000; @@ -68,11 +61,11 @@ public class MapleTVEffect { TimerManager.getInstance().schedule(new Runnable() { @Override public void run() { - broadcastTV(false); + broadcastTV(false, userWorld, null, null, -1, null); } }, delay); } else { - server.broadcastMessage(user.getWorld(), MaplePacketCreator.removeTV()); + server.broadcastMessage(userWorld, MaplePacketCreator.removeTV()); } } } diff --git a/src/tools/MaplePacketCreator.java b/src/tools/MaplePacketCreator.java index 11148ab768..de2c4498f6 100644 --- a/src/tools/MaplePacketCreator.java +++ b/src/tools/MaplePacketCreator.java @@ -684,8 +684,9 @@ public class MaplePacketCreator { mplew.writeInt(c.getAccID()); mplew.write(c.getGender()); - mplew.writeBool(c.getGMLevel() > 1); // thanks Steve(kaito1410) for pointing this out - mplew.write((c.getGMLevel() > 1 && Server.getInstance().canFly(c.getAccID())) ? 0x80 : 0); // Admin Byte. 0x80,0x40,0x20.. Rubbish. + boolean canFly = Server.getInstance().canFly(c.getAccID()); + mplew.writeBool((ServerConstants.USE_ENFORCE_ADMIN_ACCOUNT || canFly) ? c.getGMLevel() > 1 : false); // thanks Steve(kaito1410) for pointing the GM account boolean here + mplew.write((c.getGMLevel() > 1 && canFly) ? 0x80 : 0); // Admin Byte. 0x80,0x40,0x20.. Rubbish. mplew.write(0); // Country Code. mplew.writeMapleAsciiString(c.getAccountName()); diff --git a/src/tools/locks/MonitoredLockType.java b/src/tools/locks/MonitoredLockType.java index 6a7b8b980a..5a8284987b 100644 --- a/src/tools/locks/MonitoredLockType.java +++ b/src/tools/locks/MonitoredLockType.java @@ -45,6 +45,8 @@ public enum MonitoredLockType { SERVER_DISEASES, MERCHANT, CHANNEL, + CHANNEL_FACEEXPRS, + CHANNEL_FACESCHDL, CHANNEL_MOBACTION, CHANNEL_MOBANIMAT, CHANNEL_MOBSTATUS, diff --git a/tools/MapleArrowFetcher/nbproject/private/private.xml b/tools/MapleArrowFetcher/nbproject/private/private.xml index 6d8069dbaf..755de73eb7 100644 --- a/tools/MapleArrowFetcher/nbproject/private/private.xml +++ b/tools/MapleArrowFetcher/nbproject/private/private.xml @@ -3,7 +3,7 @@ - file:/C:/Nexon/MapleSolaxia/MapleSolaxiaV2/tools/MapleArrowFetcher/src/maplearrowfetcher/MapleArrowFetcher.java + file:/C:/Nexon/MapleSolaxia/HeavenMS/tools/MapleArrowFetcher/src/maplearrowfetcher/MapleArrowFetcher.java diff --git a/tools/MapleIdRetriever/dist/MapleIdRetriever.jar b/tools/MapleIdRetriever/dist/MapleIdRetriever.jar index 2cff0d0139..b8909d533b 100644 Binary files a/tools/MapleIdRetriever/dist/MapleIdRetriever.jar and b/tools/MapleIdRetriever/dist/MapleIdRetriever.jar differ diff --git a/tools/MapleIdRetriever/dist/README.TXT b/tools/MapleIdRetriever/dist/README.TXT deleted file mode 100644 index b3bf59e8c2..0000000000 --- a/tools/MapleIdRetriever/dist/README.TXT +++ /dev/null @@ -1,32 +0,0 @@ -======================== -BUILD OUTPUT DESCRIPTION -======================== - -When you build an Java application project that has a main class, the IDE -automatically copies all of the JAR -files on the projects classpath to your projects dist/lib folder. The IDE -also adds each of the JAR files to the Class-Path element in the application -JAR files manifest file (MANIFEST.MF). - -To run the project from the command line, go to the dist folder and -type the following: - -java -jar "MapleIdRetriever.jar" - -To distribute this project, zip up the dist folder (including the lib folder) -and distribute the ZIP file. - -Notes: - -* If two JAR files on the project classpath have the same name, only the first -JAR file is copied to the lib folder. -* Only JAR files are copied to the lib folder. -If the classpath contains other types of files or folders, these files (folders) -are not copied. -* If a library on the projects classpath also has a Class-Path element -specified in the manifest,the content of the Class-Path element has to be on -the projects runtime path. -* To set a main class in a standard Java project, right-click the project node -in the Projects window and choose Properties. Then click Run and enter the -class name in the Main Class field. Alternatively, you can manually type the -class name in the manifest Main-Class element. diff --git a/tools/MapleIdRetriever/dist/lib/mysql-connector-java-bin.jar b/tools/MapleIdRetriever/dist/lib/mysql-connector-java-bin.jar deleted file mode 100644 index 0539039f71..0000000000 Binary files a/tools/MapleIdRetriever/dist/lib/mysql-connector-java-bin.jar and /dev/null differ diff --git a/tools/MapleIdRetriever/src/mapleidretriever/MapleIdRetriever.java b/tools/MapleIdRetriever/src/mapleidretriever/MapleIdRetriever.java index 6d69f68bf4..7ef2e447cf 100644 --- a/tools/MapleIdRetriever/src/mapleidretriever/MapleIdRetriever.java +++ b/tools/MapleIdRetriever/src/mapleidretriever/MapleIdRetriever.java @@ -147,7 +147,7 @@ public class MapleIdRetriever { } } - public static void fetchDataOnMapleHandbook() throws SQLException { + private static void fetchDataOnMapleHandbook() throws SQLException { String line; try { diff --git a/tools/MapleInvalidItemWithNoNameFetcher/build.xml b/tools/MapleInvalidItemWithNoNameFetcher/build.xml new file mode 100644 index 0000000000..22ac1635ba --- /dev/null +++ b/tools/MapleInvalidItemWithNoNameFetcher/build.xml @@ -0,0 +1,73 @@ + + + + + + + + + + + Builds, tests, and runs the project MapleInvalidItemWithNoNameFetcher. + + + diff --git a/tools/MapleInvalidItemWithNoNameFetcher/lib/output.txt b/tools/MapleInvalidItemWithNoNameFetcher/lib/output.txt new file mode 100644 index 0000000000..23b6bf8860 --- /dev/null +++ b/tools/MapleInvalidItemWithNoNameFetcher/lib/output.txt @@ -0,0 +1,803 @@ + # XML File autogenerated from the MapleInvalidItemWithNoNameFetcher feature by Ronan Lana. + # Generated data takes into account several data info from the server-side WZ.xmls. + +Cash.img: + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +Consume.img: + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +Eqp.img: + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +Etc.img: + + + + + + + + + + + + + + + + + + + + + +Ins.img: + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/tools/MapleInvalidItemWithNoNameFetcher/lib/result.txt b/tools/MapleInvalidItemWithNoNameFetcher/lib/result.txt new file mode 100644 index 0000000000..31340bff2e --- /dev/null +++ b/tools/MapleInvalidItemWithNoNameFetcher/lib/result.txt @@ -0,0 +1,446 @@ + # Report File autogenerated from the MapleInvalidItemWithNoNameFetcher feature by Ronan Lana. + # Generated data takes into account several data info from the server-side WZ.xmls. + +Itemids with missing 'name' property: + 30105 Character.wz/Hair/00030105.img + 30106 Character.wz/Hair/00030106.img + 30107 Character.wz/Hair/00030107.img + 30928 Character.wz/Hair/00030928.img + 30929 Character.wz/Hair/00030929.img + 31660 Character.wz/Hair/00031660.img + 31661 Character.wz/Hair/00031661.img + 31662 Character.wz/Hair/00031662.img + 31663 Character.wz/Hair/00031663.img + 31664 Character.wz/Hair/00031664.img + 31665 Character.wz/Hair/00031665.img + 31666 Character.wz/Hair/00031666.img + 31667 Character.wz/Hair/00031667.img + 33101 Character.wz/Hair/00033101.img + 1012133 Character.wz/Accessory/01012133.img + 1050148 Character.wz/Longcoat/01050148.img + 1051130 Character.wz/Longcoat/01051130.img + 1051176 Character.wz/Longcoat/01051176.img + 1052186 Character.wz/Longcoat/01052186.img + 1052217 Character.wz/Longcoat/01052217.img + 1052224 Character.wz/Longcoat/01052224.img + 1052228 Character.wz/Longcoat/01052228.img + 1082262 Character.wz/Glove/01082262.img + 1092067 Character.wz/Shield/01092067.img + 1142143 Character.wz/Accessory/01142143.img + 1142144 Character.wz/Accessory/01142144.img + 1142145 Character.wz/Accessory/01142145.img + 1142149 Character.wz/Accessory/01142149.img + 1142150 Character.wz/Accessory/01142150.img + 1142151 Character.wz/Accessory/01142151.img + 1142165 Character.wz/Accessory/01142165.img + 1302048 Character.wz/Weapon/01302048.img + 1302124 Character.wz/Weapon/01302124.img + 1302125 Character.wz/Weapon/01302125.img + 1302126 Character.wz/Weapon/01302126.img + 1312035 Character.wz/Weapon/01312035.img + 1312046 Character.wz/Weapon/01312046.img + 1322074 Character.wz/Weapon/01322074.img + 1332093 Character.wz/Weapon/01332093.img + 1332094 Character.wz/Weapon/01332094.img + 1332095 Character.wz/Weapon/01332095.img + 1372026 Character.wz/Weapon/01372026.img + 1372056 Character.wz/Weapon/01372056.img + 1382074 Character.wz/Weapon/01382074.img + 1382075 Character.wz/Weapon/01382075.img + 1382076 Character.wz/Weapon/01382076.img + 1392000 Character.wz/Weapon/01392000.img + 1402043 Character.wz/Weapon/01402043.img + 1402068 Character.wz/Weapon/01402068.img + 1412043 Character.wz/Weapon/01412043.img + 1412044 Character.wz/Weapon/01412044.img + 1422035 Character.wz/Weapon/01422035.img + 1422046 Character.wz/Weapon/01422046.img + 1422047 Character.wz/Weapon/01422047.img + 1432029 Character.wz/Weapon/01432029.img + 1432058 Character.wz/Weapon/01432058.img + 1432059 Character.wz/Weapon/01432059.img + 1442059 Character.wz/Weapon/01442059.img + 1442083 Character.wz/Weapon/01442083.img + 1442084 Character.wz/Weapon/01442084.img + 1452037 Character.wz/Weapon/01452037.img + 1452058 Character.wz/Weapon/01452058.img + 1452077 Character.wz/Weapon/01452077.img + 1452078 Character.wz/Weapon/01452078.img + 1452079 Character.wz/Weapon/01452079.img + 1462069 Character.wz/Weapon/01462069.img + 1462070 Character.wz/Weapon/01462070.img + 1462071 Character.wz/Weapon/01462071.img + 1472044 Character.wz/Weapon/01472044.img + 1472093 Character.wz/Weapon/01472093.img + 1472094 Character.wz/Weapon/01472094.img + 1472095 Character.wz/Weapon/01472095.img + 1482041 Character.wz/Weapon/01482041.img + 1482042 Character.wz/Weapon/01482042.img + 1482043 Character.wz/Weapon/01482043.img + 1492042 Character.wz/Weapon/01492042.img + 1492043 Character.wz/Weapon/01492043.img + 1492044 Character.wz/Weapon/01492044.img + 1802039 Character.wz/PetEquip/01802039.img + 1802056 Character.wz/PetEquip/01802056.img + 1902040 Character.wz/TamingMob/01902040.img + 1902041 Character.wz/TamingMob/01902041.img + 1902042 Character.wz/TamingMob/01902042.img + 1912033 Character.wz/TamingMob/01912033.img + 1912034 Character.wz/TamingMob/01912034.img + 1912035 Character.wz/TamingMob/01912035.img + 1932000 Character.wz/TamingMob/01932000.img + 1932001 Character.wz/TamingMob/01932001.img + 1932002 Character.wz/TamingMob/01932002.img + 1932003 Character.wz/TamingMob/01932003.img + 1932004 Character.wz/TamingMob/01932004.img + 1932005 Character.wz/TamingMob/01932005.img + 1932010 Character.wz/TamingMob/01932010.img + 1932012 Character.wz/TamingMob/01932012.img + 2022303 Item.wz/Consume/0202.img + 2100141 Item.wz/Consume/0210.img + 2100142 Item.wz/Consume/0210.img + 2100143 Item.wz/Consume/0210.img + 2100144 Item.wz/Consume/0210.img + 2100145 Item.wz/Consume/0210.img + 2100146 Item.wz/Consume/0210.img + 2100147 Item.wz/Consume/0210.img + 2100148 Item.wz/Consume/0210.img + 2100149 Item.wz/Consume/0210.img + 2100150 Item.wz/Consume/0210.img + 2100151 Item.wz/Consume/0210.img + 2100166 Item.wz/Consume/0210.img + 2100901 Item.wz/Consume/0210.img + 2100902 Item.wz/Consume/0210.img + 2100903 Item.wz/Consume/0210.img + 2100904 Item.wz/Consume/0210.img + 2101149 Item.wz/Consume/0210.img + 2101150 Item.wz/Consume/0210.img + 2280020 Item.wz/Consume/0228.img + 2280021 Item.wz/Consume/0228.img + 2280022 Item.wz/Consume/0228.img + 2280023 Item.wz/Consume/0228.img + 2280024 Item.wz/Consume/0228.img + 2280025 Item.wz/Consume/0228.img + 3010022 Item.wz/Install/0301.img + 3010023 Item.wz/Install/0301.img + 3010024 Item.wz/Install/0301.img + 3010026 Item.wz/Install/0301.img + 3010028 Item.wz/Install/0301.img + 3994119 Item.wz/Install/0399.img + 3994142 Item.wz/Install/0399.img + 3994143 Item.wz/Install/0399.img + 3994144 Item.wz/Install/0399.img + 3994145 Item.wz/Install/0399.img + 3994146 Item.wz/Install/0399.img + 3994147 Item.wz/Install/0399.img + 3994148 Item.wz/Install/0399.img + 3994149 Item.wz/Install/0399.img + 3994150 Item.wz/Install/0399.img + 3994151 Item.wz/Install/0399.img + 3994152 Item.wz/Install/0399.img + 3994153 Item.wz/Install/0399.img + 3994154 Item.wz/Install/0399.img + 3994155 Item.wz/Install/0399.img + 3994156 Item.wz/Install/0399.img + 3994157 Item.wz/Install/0399.img + 3994158 Item.wz/Install/0399.img + 3994159 Item.wz/Install/0399.img + 3994160 Item.wz/Install/0399.img + 3994161 Item.wz/Install/0399.img + 3994162 Item.wz/Install/0399.img + 3994163 Item.wz/Install/0399.img + 3994164 Item.wz/Install/0399.img + 3994165 Item.wz/Install/0399.img + 3994166 Item.wz/Install/0399.img + 3994167 Item.wz/Install/0399.img + 3994168 Item.wz/Install/0399.img + 3994169 Item.wz/Install/0399.img + 3994170 Item.wz/Install/0399.img + 3994171 Item.wz/Install/0399.img + 3994172 Item.wz/Install/0399.img + 3994173 Item.wz/Install/0399.img + 3994174 Item.wz/Install/0399.img + 3994175 Item.wz/Install/0399.img + 3994176 Item.wz/Install/0399.img + 3994177 Item.wz/Install/0399.img + 3994178 Item.wz/Install/0399.img + 3994179 Item.wz/Install/0399.img + 3994180 Item.wz/Install/0399.img + 4161049 Item.wz/Etc/0416.img + 4161050 Item.wz/Etc/0416.img + 4161051 Item.wz/Etc/0416.img + 4161999 Item.wz/Etc/0416.img + 5120033 Item.wz/Cash/0512.img + 5121011 Item.wz/Cash/0512.img + 5121012 Item.wz/Cash/0512.img + 5121013 Item.wz/Cash/0512.img + 5121022 Item.wz/Cash/0512.img + 5152049 Item.wz/Cash/0515.img + 5152050 Item.wz/Cash/0515.img + 5190007 Item.wz/Cash/0519.img + 5190008 Item.wz/Cash/0519.img + 5280000 Item.wz/Cash/0528.img + 5500005 Item.wz/Cash/0550.img + 5500006 Item.wz/Cash/0550.img + 5530001 Item.wz/Cash/0553.img + 5530002 Item.wz/Cash/0553.img + 5530003 Item.wz/Cash/0553.img + 5530004 Item.wz/Cash/0553.img + 5530005 Item.wz/Cash/0553.img + 5530006 Item.wz/Cash/0553.img + 5530007 Item.wz/Cash/0553.img + 5530008 Item.wz/Cash/0553.img + +Equipids with missing 'cash' property: + 30010 Character.wz/Hair/00030010.img + 30020 Character.wz/Hair/00030020.img + 30021 Character.wz/Hair/00030021.img + 30022 Character.wz/Hair/00030022.img + 30023 Character.wz/Hair/00030023.img + 30024 Character.wz/Hair/00030024.img + 30025 Character.wz/Hair/00030025.img + 30026 Character.wz/Hair/00030026.img + 30027 Character.wz/Hair/00030027.img + 30030 Character.wz/Hair/00030030.img + 30031 Character.wz/Hair/00030031.img + 30032 Character.wz/Hair/00030032.img + 30100 Character.wz/Hair/00030100.img + 30101 Character.wz/Hair/00030101.img + 30102 Character.wz/Hair/00030102.img + 30103 Character.wz/Hair/00030103.img + 30104 Character.wz/Hair/00030104.img + 30105 Character.wz/Hair/00030105.img + 30106 Character.wz/Hair/00030106.img + 30107 Character.wz/Hair/00030107.img + 30150 Character.wz/Hair/00030150.img + 30151 Character.wz/Hair/00030151.img + 30152 Character.wz/Hair/00030152.img + 30153 Character.wz/Hair/00030153.img + 30154 Character.wz/Hair/00030154.img + 30155 Character.wz/Hair/00030155.img + 30156 Character.wz/Hair/00030156.img + 30157 Character.wz/Hair/00030157.img + 30160 Character.wz/Hair/00030160.img + 30161 Character.wz/Hair/00030161.img + 30162 Character.wz/Hair/00030162.img + 30163 Character.wz/Hair/00030163.img + 30164 Character.wz/Hair/00030164.img + 30165 Character.wz/Hair/00030165.img + 30166 Character.wz/Hair/00030166.img + 30167 Character.wz/Hair/00030167.img + 30170 Character.wz/Hair/00030170.img + 30171 Character.wz/Hair/00030171.img + 30172 Character.wz/Hair/00030172.img + 30173 Character.wz/Hair/00030173.img + 30174 Character.wz/Hair/00030174.img + 30175 Character.wz/Hair/00030175.img + 30176 Character.wz/Hair/00030176.img + 30177 Character.wz/Hair/00030177.img + 30440 Character.wz/Hair/00030440.img + 30441 Character.wz/Hair/00030441.img + 30442 Character.wz/Hair/00030442.img + 30443 Character.wz/Hair/00030443.img + 30444 Character.wz/Hair/00030444.img + 30445 Character.wz/Hair/00030445.img + 30446 Character.wz/Hair/00030446.img + 30447 Character.wz/Hair/00030447.img + 30610 Character.wz/Hair/00030610.img + 30611 Character.wz/Hair/00030611.img + 30612 Character.wz/Hair/00030612.img + 30613 Character.wz/Hair/00030613.img + 30614 Character.wz/Hair/00030614.img + 30615 Character.wz/Hair/00030615.img + 30616 Character.wz/Hair/00030616.img + 30617 Character.wz/Hair/00030617.img + 30740 Character.wz/Hair/00030740.img + 30741 Character.wz/Hair/00030741.img + 30742 Character.wz/Hair/00030742.img + 30743 Character.wz/Hair/00030743.img + 30744 Character.wz/Hair/00030744.img + 30745 Character.wz/Hair/00030745.img + 30746 Character.wz/Hair/00030746.img + 30747 Character.wz/Hair/00030747.img + 30750 Character.wz/Hair/00030750.img + 30751 Character.wz/Hair/00030751.img + 30752 Character.wz/Hair/00030752.img + 30753 Character.wz/Hair/00030753.img + 30754 Character.wz/Hair/00030754.img + 30755 Character.wz/Hair/00030755.img + 30756 Character.wz/Hair/00030756.img + 30757 Character.wz/Hair/00030757.img + 30920 Character.wz/Hair/00030920.img + 30921 Character.wz/Hair/00030921.img + 30922 Character.wz/Hair/00030922.img + 30923 Character.wz/Hair/00030923.img + 30924 Character.wz/Hair/00030924.img + 30925 Character.wz/Hair/00030925.img + 30926 Character.wz/Hair/00030926.img + 30927 Character.wz/Hair/00030927.img + 31020 Character.wz/Hair/00031020.img + 31021 Character.wz/Hair/00031021.img + 31022 Character.wz/Hair/00031022.img + 31023 Character.wz/Hair/00031023.img + 31024 Character.wz/Hair/00031024.img + 31025 Character.wz/Hair/00031025.img + 31026 Character.wz/Hair/00031026.img + 31027 Character.wz/Hair/00031027.img + 31030 Character.wz/Hair/00031030.img + 31031 Character.wz/Hair/00031031.img + 31032 Character.wz/Hair/00031032.img + 31033 Character.wz/Hair/00031033.img + 31034 Character.wz/Hair/00031034.img + 31035 Character.wz/Hair/00031035.img + 31036 Character.wz/Hair/00031036.img + 31037 Character.wz/Hair/00031037.img + 31040 Character.wz/Hair/00031040.img + 31041 Character.wz/Hair/00031041.img + 31042 Character.wz/Hair/00031042.img + 31043 Character.wz/Hair/00031043.img + 31044 Character.wz/Hair/00031044.img + 31045 Character.wz/Hair/00031045.img + 31046 Character.wz/Hair/00031046.img + 31047 Character.wz/Hair/00031047.img + 31050 Character.wz/Hair/00031050.img + 31051 Character.wz/Hair/00031051.img + 31052 Character.wz/Hair/00031052.img + 31053 Character.wz/Hair/00031053.img + 31054 Character.wz/Hair/00031054.img + 31055 Character.wz/Hair/00031055.img + 31056 Character.wz/Hair/00031056.img + 31057 Character.wz/Hair/00031057.img + 31060 Character.wz/Hair/00031060.img + 31061 Character.wz/Hair/00031061.img + 31062 Character.wz/Hair/00031062.img + 31063 Character.wz/Hair/00031063.img + 31064 Character.wz/Hair/00031064.img + 31065 Character.wz/Hair/00031065.img + 31066 Character.wz/Hair/00031066.img + 31067 Character.wz/Hair/00031067.img + 31070 Character.wz/Hair/00031070.img + 31071 Character.wz/Hair/00031071.img + 31072 Character.wz/Hair/00031072.img + 31073 Character.wz/Hair/00031073.img + 31074 Character.wz/Hair/00031074.img + 31075 Character.wz/Hair/00031075.img + 31076 Character.wz/Hair/00031076.img + 31077 Character.wz/Hair/00031077.img + 31080 Character.wz/Hair/00031080.img + 31081 Character.wz/Hair/00031081.img + 31082 Character.wz/Hair/00031082.img + 31083 Character.wz/Hair/00031083.img + 31084 Character.wz/Hair/00031084.img + 31085 Character.wz/Hair/00031085.img + 31086 Character.wz/Hair/00031086.img + 31087 Character.wz/Hair/00031087.img + 31100 Character.wz/Hair/00031100.img + 31101 Character.wz/Hair/00031101.img + 31102 Character.wz/Hair/00031102.img + 31103 Character.wz/Hair/00031103.img + 31104 Character.wz/Hair/00031104.img + 31105 Character.wz/Hair/00031105.img + 31106 Character.wz/Hair/00031106.img + 31107 Character.wz/Hair/00031107.img + 31130 Character.wz/Hair/00031130.img + 31131 Character.wz/Hair/00031131.img + 31132 Character.wz/Hair/00031132.img + 31133 Character.wz/Hair/00031133.img + 31134 Character.wz/Hair/00031134.img + 31135 Character.wz/Hair/00031135.img + 31136 Character.wz/Hair/00031136.img + 31137 Character.wz/Hair/00031137.img + 31140 Character.wz/Hair/00031140.img + 31141 Character.wz/Hair/00031141.img + 31142 Character.wz/Hair/00031142.img + 31143 Character.wz/Hair/00031143.img + 31144 Character.wz/Hair/00031144.img + 31145 Character.wz/Hair/00031145.img + 31146 Character.wz/Hair/00031146.img + 31147 Character.wz/Hair/00031147.img + 31230 Character.wz/Hair/00031230.img + 31231 Character.wz/Hair/00031231.img + 31232 Character.wz/Hair/00031232.img + 31233 Character.wz/Hair/00031233.img + 31234 Character.wz/Hair/00031234.img + 31235 Character.wz/Hair/00031235.img + 31236 Character.wz/Hair/00031236.img + 31237 Character.wz/Hair/00031237.img + 31240 Character.wz/Hair/00031240.img + 31241 Character.wz/Hair/00031241.img + 31242 Character.wz/Hair/00031242.img + 31243 Character.wz/Hair/00031243.img + 31244 Character.wz/Hair/00031244.img + 31245 Character.wz/Hair/00031245.img + 31246 Character.wz/Hair/00031246.img + 31247 Character.wz/Hair/00031247.img + 31260 Character.wz/Hair/00031260.img + 31261 Character.wz/Hair/00031261.img + 31262 Character.wz/Hair/00031262.img + 31263 Character.wz/Hair/00031263.img + 31264 Character.wz/Hair/00031264.img + 31265 Character.wz/Hair/00031265.img + 31266 Character.wz/Hair/00031266.img + 31267 Character.wz/Hair/00031267.img + 31310 Character.wz/Hair/00031310.img + 31311 Character.wz/Hair/00031311.img + 31312 Character.wz/Hair/00031312.img + 31313 Character.wz/Hair/00031313.img + 31314 Character.wz/Hair/00031314.img + 31315 Character.wz/Hair/00031315.img + 31316 Character.wz/Hair/00031316.img + 31317 Character.wz/Hair/00031317.img + 31350 Character.wz/Hair/00031350.img + 31351 Character.wz/Hair/00031351.img + 31352 Character.wz/Hair/00031352.img + 31353 Character.wz/Hair/00031353.img + 31354 Character.wz/Hair/00031354.img + 31355 Character.wz/Hair/00031355.img + 31356 Character.wz/Hair/00031356.img + 31357 Character.wz/Hair/00031357.img + 31400 Character.wz/Hair/00031400.img + 31401 Character.wz/Hair/00031401.img + 31402 Character.wz/Hair/00031402.img + 31403 Character.wz/Hair/00031403.img + 31404 Character.wz/Hair/00031404.img + 31405 Character.wz/Hair/00031405.img + 31406 Character.wz/Hair/00031406.img + 31407 Character.wz/Hair/00031407.img + 31440 Character.wz/Hair/00031440.img + 31441 Character.wz/Hair/00031441.img + 31442 Character.wz/Hair/00031442.img + 31443 Character.wz/Hair/00031443.img + 31444 Character.wz/Hair/00031444.img + 31445 Character.wz/Hair/00031445.img + 31446 Character.wz/Hair/00031446.img + 31447 Character.wz/Hair/00031447.img + 31450 Character.wz/Hair/00031450.img + 31451 Character.wz/Hair/00031451.img + 31452 Character.wz/Hair/00031452.img + 31453 Character.wz/Hair/00031453.img + 31454 Character.wz/Hair/00031454.img + 31455 Character.wz/Hair/00031455.img + 31456 Character.wz/Hair/00031456.img + 31457 Character.wz/Hair/00031457.img + 31490 Character.wz/Hair/00031490.img + 31491 Character.wz/Hair/00031491.img + 31492 Character.wz/Hair/00031492.img + 31493 Character.wz/Hair/00031493.img + 31494 Character.wz/Hair/00031494.img + 31495 Character.wz/Hair/00031495.img + 31496 Character.wz/Hair/00031496.img + 31497 Character.wz/Hair/00031497.img + 31660 Character.wz/Hair/00031660.img + 31661 Character.wz/Hair/00031661.img + 31662 Character.wz/Hair/00031662.img + 31663 Character.wz/Hair/00031663.img + 31664 Character.wz/Hair/00031664.img + 31665 Character.wz/Hair/00031665.img + 31666 Character.wz/Hair/00031666.img + 31667 Character.wz/Hair/00031667.img + 1932000 Character.wz/TamingMob/01932000.img + 1932001 Character.wz/TamingMob/01932001.img + 1932002 Character.wz/TamingMob/01932002.img + 1932003 Character.wz/TamingMob/01932003.img + 1932004 Character.wz/TamingMob/01932004.img + 1932005 Character.wz/TamingMob/01932005.img + 1932010 Character.wz/TamingMob/01932010.img + 1932012 Character.wz/TamingMob/01932012.img diff --git a/tools/MapleInvalidItemWithNoNameFetcher/manifest.mf b/tools/MapleInvalidItemWithNoNameFetcher/manifest.mf new file mode 100644 index 0000000000..328e8e5bc3 --- /dev/null +++ b/tools/MapleInvalidItemWithNoNameFetcher/manifest.mf @@ -0,0 +1,3 @@ +Manifest-Version: 1.0 +X-COMMENT: Main-Class will be added automatically by build + diff --git a/tools/MapleInvalidItemWithNoNameFetcher/src/maplenoitemnamefetcher/MapleNoItemNameFetcher.java b/tools/MapleInvalidItemWithNoNameFetcher/src/maplenoitemnamefetcher/MapleNoItemNameFetcher.java new file mode 100644 index 0000000000..04656d8e56 --- /dev/null +++ b/tools/MapleInvalidItemWithNoNameFetcher/src/maplenoitemnamefetcher/MapleNoItemNameFetcher.java @@ -0,0 +1,563 @@ +/* + 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 . +*/ +package maplenoitemnamefetcher; + +import java.io.BufferedReader; +import java.io.File; +import java.io.InputStreamReader; +import java.io.PrintWriter; +import java.util.ArrayList; +import java.util.Collections; +import java.util.HashMap; +import java.util.HashSet; +import java.util.List; +import java.util.Map; +import java.util.Map.Entry; +import java.util.Set; +import provider.MapleData; +import provider.MapleDataDirectoryEntry; +import provider.MapleDataFileEntry; +import provider.MapleDataProvider; +import provider.MapleDataProviderFactory; + +/** + * + * @author RonanLana + * + * This application finds inexistent itemids within the drop data from + * the Maplestory database specified by the URL below. This program + * assumes all itemids have at most 7 digits. + * + * A file is generated listing all the inexistent ids. + * + * Estimated parse time: 2 minutes + */ +public class MapleNoItemNameFetcher { + static String wzPath = "../../wz"; + static String newFile = "lib/result.txt"; + static String xmlFile = "lib/output.txt"; + + static PrintWriter printWriter = null; + static InputStreamReader fileReader = null; + static BufferedReader bufferedReader = null; + + static Map itemsWzPath = new HashMap<>(); + static Map itemTypes = new HashMap<>(); + static Map equipTypes = new HashMap<>(); + + static Map itemsWithNoNameProperty = new HashMap<>(); + static Set equipsWithNoCashProperty = new HashSet<>(); + + static ItemType curType = ItemType.UNDEF; + + private enum ItemType { + UNDEF, CASH, CONSUME, EQP, ETC, INS, PET + } + + private enum EquipType { + UNDEF, ACCESSORY, CAP, CAPE, COAT, FACE, GLOVE, HAIR, LONGCOAT, PANTS, PETEQUIP, RING, SHIELD, SHOES, TAMING, WEAPON + } + + private static void processStringSubdirectoryData(MapleData subdirData, String subdirPath) { + for(MapleData md : subdirData.getChildren()) { + try { + if(md.getChildByPath("name") != null) { + int itemId = Integer.parseInt(md.getName()); + itemsWithNoNameProperty.remove(itemId); + } else { + System.out.println("Found itemid on String.wz with no name property: " + subdirPath + subdirData.getName() + "/" + md.getName()); + } + } catch (NumberFormatException nfe) { + System.out.println("Error reading string image: " + subdirPath + subdirData.getName() + "/" + md.getName()); + } + } + } + + private static void readStringSubdirectoryData(MapleData subdirData, int depth, String subdirPath) { + if(depth > 0) { + for (MapleData mDir : subdirData.getChildren()) { + readStringSubdirectoryData(mDir, depth - 1, subdirPath + mDir.getName() + "/"); + } + } else { + processStringSubdirectoryData(subdirData, subdirPath); + } + } + + private static void readStringSubdirectoryData(MapleData subdirData, int depth) { + readStringSubdirectoryData(subdirData, depth, ""); + } + + private static void readStringWZData() { + System.out.println("Parsing String.wz..."); + MapleDataProvider stringData = MapleDataProviderFactory.getDataProvider(new File(System.getProperty("wzpath") + "/String.wz")); + + MapleData cashStringData = stringData.getData("Cash.img"); + readStringSubdirectoryData(cashStringData, 0); + + MapleData consumeStringData = stringData.getData("Consume.img"); + readStringSubdirectoryData(consumeStringData, 0); + + MapleData eqpStringData = stringData.getData("Eqp.img"); + readStringSubdirectoryData(eqpStringData, 2); + + MapleData etcStringData = stringData.getData("Etc.img"); + readStringSubdirectoryData(etcStringData, 1); + + MapleData insStringData = stringData.getData("Ins.img"); + readStringSubdirectoryData(insStringData, 0); + + MapleData petStringData = stringData.getData("Pet.img"); + readStringSubdirectoryData(petStringData, 0); + } + + private static boolean isTamingMob(int itemId) { + int itemType = itemId / 1000; + return itemType == 1902 || itemType == 1912; + } + + private static boolean isAccessory(int itemId) { + return itemId >= 1110000 && itemId < 1140000; + } + + private static ItemType getItemTypeFromDirectoryName(String dirName) { + switch(dirName) { + case "Cash": + return ItemType.CASH; + + case "Consume": + return ItemType.CONSUME; + + case "Etc": + return ItemType.ETC; + + case "Install": + return ItemType.INS; + + case "Pet": + return ItemType.PET; + + default: + return ItemType.UNDEF; + } + } + + private static EquipType getEquipTypeFromDirectoryName(String dirName) { + switch(dirName) { + case "Accessory": + return EquipType.ACCESSORY; + + case "Cap": + return EquipType.CAP; + + case "Cape": + return EquipType.CAPE; + + case "Coat": + return EquipType.COAT; + + case "Face": + return EquipType.FACE; + + case "Glove": + return EquipType.GLOVE; + + case "Hair": + return EquipType.HAIR; + + case "Longcoat": + return EquipType.LONGCOAT; + + case "Pants": + return EquipType.PANTS; + + case "PetEquip": + return EquipType.PETEQUIP; + + case "Ring": + return EquipType.RING; + + case "Shield": + return EquipType.SHIELD; + + case "Shoes": + return EquipType.SHOES; + + case "TamingMob": + return EquipType.TAMING; + + case "Weapon": + return EquipType.WEAPON; + + default: + return EquipType.UNDEF; + } + } + + private static String getStringDirectoryNameFromEquipType(EquipType eType) { + switch(eType) { + case ACCESSORY: + return "Accessory"; + + case CAP: + return "Cap"; + + case CAPE: + return "Cape"; + + case COAT: + return "Coat"; + + case FACE: + return "Face"; + + case GLOVE: + return "Glove"; + + case HAIR: + return "Hair"; + + case LONGCOAT: + return "Longcoat"; + + case PANTS: + return "Pants"; + + case PETEQUIP: + return "PetEquip"; + + case RING: + return "Ring"; + + case SHIELD: + return "Shield"; + + case SHOES: + return "Shoes"; + + case TAMING: + return "Taming"; + + case WEAPON: + return "Weapon"; + + default: + return "Undefined"; + } + } + + private static void readEquipNodeData(MapleDataProvider data, MapleDataDirectoryEntry mDir, String wzFileName, String dirName) { + EquipType eqType = getEquipTypeFromDirectoryName(dirName); + + for(MapleDataFileEntry mFile : mDir.getFiles()) { + String fileName = mFile.getName(); + + try { + int itemId = Integer.parseInt(fileName.substring(0, 8)); + itemsWithNoNameProperty.put(itemId, curType); + equipTypes.put(itemId, eqType); + + itemsWzPath.put(itemId, wzFileName + "/" + dirName + "/" + fileName); + + if(!isAccessory(itemId) && !isTamingMob(itemId)) { + try { + MapleData fileData = data.getData(dirName + "/" + fileName); + MapleData mdinfo = fileData.getChildByPath("info"); + if( mdinfo.getChildByPath("cash") == null) { + equipsWithNoCashProperty.add(itemId); + } + } catch(NullPointerException npe) { + System.out.println("[SEVERE] " + mFile.getName() + " failed to load. Issue: " + npe.getMessage() + "\n\n"); + } + } + } catch (Exception e) {} + } + } + + private static void readEquipWZData() { + String wzFileName = "Character.wz"; + + MapleDataProvider data = MapleDataProviderFactory.getDataProvider(new File(System.getProperty("wzpath") + "/Character.wz")); + MapleDataDirectoryEntry root = data.getRoot(); + + System.out.println("Parsing " + wzFileName + "..."); + for (MapleDataDirectoryEntry mDir : root.getSubdirectories()) { + String dirName = mDir.getName(); + if(dirName.contentEquals("Dragon")) continue; + + readEquipNodeData(data, mDir, wzFileName, dirName); + } + } + + private static void readItemWZData() { + String wzFileName = "Item.wz"; + + MapleDataProvider data = MapleDataProviderFactory.getDataProvider(new File(System.getProperty("wzpath") + "/Item.wz")); + MapleDataDirectoryEntry root = data.getRoot(); + + System.out.println("Parsing " + wzFileName + "..."); + for (MapleDataDirectoryEntry mDir : root.getSubdirectories()) { + String dirName = mDir.getName(); + if(dirName.contentEquals("Special")) continue; + + curType = getItemTypeFromDirectoryName(dirName); + if(!dirName.contentEquals("Pet")) { + for(MapleDataFileEntry mFile : mDir.getFiles()) { + String fileName = mFile.getName(); + + MapleData fileData = data.getData(dirName + "/" + fileName); + for(MapleData mData : fileData.getChildren()) { + try { + int itemId = Integer.parseInt(mData.getName()); + itemsWithNoNameProperty.put(itemId, curType); + itemsWzPath.put(itemId, wzFileName + "/" + dirName + "/" + fileName); + } catch (Exception e) { + System.out.println("EXCEPTION on '" + mData.getName() + "' " + wzFileName + "/" + dirName + "/" + fileName); + } + } + } + } else { + readEquipNodeData(data, mDir, wzFileName, dirName); + } + } + } + + private static void printReportFileHeader() { + printWriter.println(" # Report File autogenerated from the MapleInvalidItemWithNoNameFetcher feature by Ronan Lana."); + printWriter.println(" # Generated data takes into account several data info from the server-side WZ.xmls."); + printWriter.println(); + } + + private static void printReportFileResults() { + if(!itemsWithNoNameProperty.isEmpty()) { + printWriter.println("Itemids with missing 'name' property: "); + + List itemids = new ArrayList<>(itemsWithNoNameProperty.keySet()); + Collections.sort(itemids); + + for(Integer itemid : itemids) { + printWriter.println(" " + itemid + " " + itemsWzPath.get(itemid)); + } + printWriter.println(); + } + + if(!equipsWithNoCashProperty.isEmpty()) { + printWriter.println("Equipids with missing 'cash' property: "); + + List itemids = new ArrayList<>(equipsWithNoCashProperty); + Collections.sort(itemids); + + for(Integer itemid : itemids) { + printWriter.println(" " + itemid + " " + itemsWzPath.get(itemid)); + } + } + } + + private static Map> filterMissingItemNames() { + List cashList = new ArrayList<>(20); + List consList = new ArrayList<>(20); + List eqpList = new ArrayList<>(20); + List etcList = new ArrayList<>(20); + List insList = new ArrayList<>(20); + List petList = new ArrayList<>(20); + + for(Entry ids : itemsWithNoNameProperty.entrySet()) { + switch(ids.getValue()) { + case CASH: + cashList.add(ids.getKey()); + break; + + case CONSUME: + consList.add(ids.getKey()); + break; + + case EQP: + eqpList.add(ids.getKey()); + break; + + case ETC: + etcList.add(ids.getKey()); + break; + + case INS: + insList.add(ids.getKey()); + break; + + case PET: + petList.add(ids.getKey()); + break; + } + } + + Map> nameTags = new HashMap<>(); + nameTags.put("Cash.img", cashList); + nameTags.put("Consume.img", consList); + nameTags.put("Eqp.img", eqpList); + nameTags.put("Etc.img", etcList); + nameTags.put("Ins.img", insList); + nameTags.put("Pet.img", petList); + + return nameTags; + } + + private static void printOutputFileHeader() { + printWriter.println(" # XML File autogenerated from the MapleInvalidItemWithNoNameFetcher feature by Ronan Lana."); + printWriter.println(" # Generated data takes into account several data info from the server-side WZ.xmls."); + printWriter.println(); + } + + private static void writeMissingEquipInfo(Integer itemid) { + printWriter.println(" "); + printWriter.println(" "); + printWriter.println(" "); + printWriter.println(" "); + } + + private static void writeEquipSubdirectoryHeader(EquipType eType) { + printWriter.println(" "); + } + + private static void writeEquipSubdirectoryFooter() { + printWriter.println(" "); + } + + private static void writeEquipXMLHeader() { + printWriter.println(" "); + } + + private static void writeEquipXMLFooter() { + printWriter.println(" "); + } + + private static void writeMissingItemInfo(Integer itemid) { + printWriter.println(" "); + printWriter.println(" "); + printWriter.println(" "); + printWriter.println(" "); + } + + private static void writeXMLHeader(String fileName) { + printWriter.println(""); + printWriter.println(""); + } + + private static void writeXMLFooter() { + printWriter.println(""); + } + + private static void writeMissingEquipWZNode(EquipType eType, List missingNames) { + if(!missingNames.isEmpty()) { + Collections.sort(missingNames); + writeEquipSubdirectoryHeader(eType); + + for(Integer equipid : missingNames) { + writeMissingEquipInfo(equipid); + } + + writeEquipSubdirectoryFooter(); + } + } + + private static void writeMissingStringWZNode(String nodePath, List missingNames, boolean isEquip) { + if(!missingNames.isEmpty()) { + if(!isEquip) { + Collections.sort(missingNames); + + printWriter.println(nodePath + ":"); + printWriter.println(); + + writeXMLHeader(nodePath); + + for(Integer i : missingNames) { + writeMissingItemInfo(i); + } + + writeXMLFooter(); + + printWriter.println(); + } else { + int arraySize = EquipType.values().length; + + List equips[] = new List[arraySize]; + for(int i = 0; i < arraySize; i++) { + equips[i] = new ArrayList<>(42); + } + + for(Integer itemid : missingNames) { + equips[equipTypes.get(itemid).ordinal()].add(itemid); + } + + printWriter.println(nodePath + ":"); + printWriter.println(); + + writeXMLHeader(nodePath); + writeEquipXMLHeader(); + + for(EquipType eType : EquipType.values()) { + writeMissingEquipWZNode(eType, equips[eType.ordinal()]); + } + + writeEquipXMLFooter(); + writeXMLFooter(); + + printWriter.println(); + } + } + } + + private static void writeMissingStringWZNames(Map> missingNames) throws Exception { + System.out.println("Writing remaining 'String.wz' names..."); + + printWriter = new PrintWriter(xmlFile, "UTF-8"); + printOutputFileHeader(); + + String nodePaths[] = {"Cash.img", "Consume.img", "Eqp.img", "Etc.img", "Ins.img", "Pet.img"}; + for(int i = 0; i < nodePaths.length; i++) { + writeMissingStringWZNode(nodePaths[i], missingNames.get(nodePaths[i]), i == 2); + } + + printWriter.close(); + } + + public static void main(String[] args) { + try { + System.setProperty("wzpath", wzPath); + + curType = ItemType.EQP; + readEquipWZData(); + + curType = ItemType.UNDEF; + readItemWZData(); + readStringWZData(); // calculates the diff and effectively holds all items with no name property on the WZ + + System.out.println("Reporting results..."); + printWriter = new PrintWriter(newFile, "UTF-8"); + printReportFileHeader(); + printReportFileResults(); + printWriter.close(); + + Map> missingNames = filterMissingItemNames(); + writeMissingStringWZNames(missingNames); + + System.out.println("Done!"); + } catch(Exception e) { + e.printStackTrace(); + } + } +} diff --git a/tools/MapleInvalidItemWithNoNameFetcher/src/maplenoitemnamefetcher/Pair.java b/tools/MapleInvalidItemWithNoNameFetcher/src/maplenoitemnamefetcher/Pair.java new file mode 100644 index 0000000000..8e61bf7e93 --- /dev/null +++ b/tools/MapleInvalidItemWithNoNameFetcher/src/maplenoitemnamefetcher/Pair.java @@ -0,0 +1,121 @@ +/* +This file is part of the OdinMS Maple Story Server +Copyright (C) 2008 ~ 2010 Patrick Huy +Matthias Butz +Jan Christian Meyer + +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 +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 . + */ +package maplenoitemnamefetcher; + +/** + * Represents a pair of values. + * + * @author Frz + * @since Revision 333 + * @version 1.0 + * + * @param The type of the left value. + * @param The type of the right value. + */ +public class Pair { + + public E left; + public F right; + + /** + * Class constructor - pairs two objects together. + * + * @param left The left object. + * @param right The right object. + */ + public Pair(E left, F right) { + this.left = left; + this.right = right; + } + + /** + * Gets the left value. + * + * @return The left value. + */ + public E getLeft() { + return left; + } + + /** + * Gets the right value. + * + * @return The right value. + */ + public F getRight() { + return right; + } + + /** + * Turns the pair into a string. + * + * @return Each value of the pair as a string joined by a colon. + */ + @Override + public String toString() { + return left.toString() + ":" + right.toString(); + } + + /** + * Gets the hash code of this pair. + */ + @Override + public int hashCode() { + final int prime = 31; + int result = 1; + result = prime * result + ((left == null) ? 0 : left.hashCode()); + result = prime * result + ((right == null) ? 0 : right.hashCode()); + return result; + } + + /** + * Checks to see if two pairs are equal. + */ + @SuppressWarnings("unchecked") + @Override + public boolean equals(Object obj) { + if (this == obj) { + return true; + } + if (obj == null) { + return false; + } + if (getClass() != obj.getClass()) { + return false; + } + final Pair other = (Pair) obj; + if (left == null) { + if (other.left != null) { + return false; + } + } else if (!left.equals(other.left)) { + return false; + } + if (right == null) { + if (other.right != null) { + return false; + } + } else if (!right.equals(other.right)) { + return false; + } + return true; + } +} \ No newline at end of file diff --git a/tools/MapleInvalidItemWithNoNameFetcher/src/provider/MapleCanvas.java b/tools/MapleInvalidItemWithNoNameFetcher/src/provider/MapleCanvas.java new file mode 100644 index 0000000000..10ab682196 --- /dev/null +++ b/tools/MapleInvalidItemWithNoNameFetcher/src/provider/MapleCanvas.java @@ -0,0 +1,30 @@ +/* + This file is part of the OdinMS Maple Story Server + Copyright (C) 2008 Patrick Huy + Matthias Butz + Jan Christian Meyer + + 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 . +*/ +package provider; + +import java.awt.image.BufferedImage; + +public interface MapleCanvas { + int getHeight(); + int getWidth(); + BufferedImage getImage(); +} diff --git a/tools/MapleInvalidItemWithNoNameFetcher/src/provider/MapleData.java b/tools/MapleInvalidItemWithNoNameFetcher/src/provider/MapleData.java new file mode 100644 index 0000000000..4d90a93804 --- /dev/null +++ b/tools/MapleInvalidItemWithNoNameFetcher/src/provider/MapleData.java @@ -0,0 +1,34 @@ +/* + This file is part of the OdinMS Maple Story Server + Copyright (C) 2008 Patrick Huy + Matthias Butz + Jan Christian Meyer + + 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 . +*/ +package provider; + +import java.util.List; +import provider.wz.MapleDataType; + +public interface MapleData extends MapleDataEntity, Iterable { + @Override + public String getName(); + public MapleDataType getType(); + public List getChildren(); + public MapleData getChildByPath(String path); + public Object getData(); +} diff --git a/tools/MapleInvalidItemWithNoNameFetcher/src/provider/MapleDataDirectoryEntry.java b/tools/MapleInvalidItemWithNoNameFetcher/src/provider/MapleDataDirectoryEntry.java new file mode 100644 index 0000000000..cb043e0c94 --- /dev/null +++ b/tools/MapleInvalidItemWithNoNameFetcher/src/provider/MapleDataDirectoryEntry.java @@ -0,0 +1,34 @@ +/* + This file is part of the OdinMS Maple Story Server + Copyright (C) 2008 Patrick Huy + Matthias Butz + Jan Christian Meyer + + 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 . +*/ +package provider; + +import java.util.List; + +/** + * + * @author Matze + */ +public interface MapleDataDirectoryEntry extends MapleDataEntry { + public List getSubdirectories(); + public List getFiles(); + public MapleDataEntry getEntry(String name); +} diff --git a/tools/MapleInvalidItemWithNoNameFetcher/src/provider/MapleDataEntity.java b/tools/MapleInvalidItemWithNoNameFetcher/src/provider/MapleDataEntity.java new file mode 100644 index 0000000000..03ff77649c --- /dev/null +++ b/tools/MapleInvalidItemWithNoNameFetcher/src/provider/MapleDataEntity.java @@ -0,0 +1,31 @@ +/* + This file is part of the OdinMS Maple Story Server + Copyright (C) 2008 Patrick Huy + Matthias Butz + Jan Christian Meyer + + 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 . +*/ +package provider; + +/** + * + * @author Matze + */ +public interface MapleDataEntity { + public String getName(); + public MapleDataEntity getParent(); +} diff --git a/tools/MapleInvalidItemWithNoNameFetcher/src/provider/MapleDataEntry.java b/tools/MapleInvalidItemWithNoNameFetcher/src/provider/MapleDataEntry.java new file mode 100644 index 0000000000..62db6d0abe --- /dev/null +++ b/tools/MapleInvalidItemWithNoNameFetcher/src/provider/MapleDataEntry.java @@ -0,0 +1,33 @@ +/* + This file is part of the OdinMS Maple Story Server + Copyright (C) 2008 Patrick Huy + Matthias Butz + Jan Christian Meyer + + 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 . +*/ +package provider; + +/** + * + * @author Matze + */ +public interface MapleDataEntry extends MapleDataEntity { + public String getName(); + public int getSize(); + public int getChecksum(); + public int getOffset(); +} diff --git a/tools/MapleInvalidItemWithNoNameFetcher/src/provider/MapleDataFileEntry.java b/tools/MapleInvalidItemWithNoNameFetcher/src/provider/MapleDataFileEntry.java new file mode 100644 index 0000000000..902130a612 --- /dev/null +++ b/tools/MapleInvalidItemWithNoNameFetcher/src/provider/MapleDataFileEntry.java @@ -0,0 +1,30 @@ +/* + This file is part of the OdinMS Maple Story Server + Copyright (C) 2008 Patrick Huy + Matthias Butz + Jan Christian Meyer + + 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 . +*/ +package provider; + +/** + * + * @author Matze + */ +public interface MapleDataFileEntry extends MapleDataEntry { + public void setOffset(int offset); +} diff --git a/tools/MapleInvalidItemWithNoNameFetcher/src/provider/MapleDataProvider.java b/tools/MapleInvalidItemWithNoNameFetcher/src/provider/MapleDataProvider.java new file mode 100644 index 0000000000..5237b7ac37 --- /dev/null +++ b/tools/MapleInvalidItemWithNoNameFetcher/src/provider/MapleDataProvider.java @@ -0,0 +1,27 @@ +/* + This file is part of the OdinMS Maple Story Server + Copyright (C) 2008 Patrick Huy + Matthias Butz + Jan Christian Meyer + + 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 . +*/ +package provider; + +public interface MapleDataProvider { + MapleData getData(String path); + MapleDataDirectoryEntry getRoot(); +} diff --git a/tools/MapleInvalidItemWithNoNameFetcher/src/provider/MapleDataProviderFactory.java b/tools/MapleInvalidItemWithNoNameFetcher/src/provider/MapleDataProviderFactory.java new file mode 100644 index 0000000000..14753d4406 --- /dev/null +++ b/tools/MapleInvalidItemWithNoNameFetcher/src/provider/MapleDataProviderFactory.java @@ -0,0 +1,55 @@ +/* + This file is part of the OdinMS Maple Story Server + Copyright (C) 2008 Patrick Huy + Matthias Butz + Jan Christian Meyer + + 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 . +*/ +package provider; + +import java.io.File; +import java.io.IOException; +import provider.wz.WZFile; +import provider.wz.XMLWZFile; + +public class MapleDataProviderFactory { + private final static String wzPath = System.getProperty("wzpath"); + + private static MapleDataProvider getWZ(File in, boolean provideImages) { + if (in.getName().toLowerCase().endsWith("wz") && !in.isDirectory()) { + try { + return new WZFile(in, provideImages); + } catch (IOException e) { + throw new RuntimeException("Loading WZ File failed", e); + } + } else { + return new XMLWZFile(in); + } + } + + public static MapleDataProvider getDataProvider(File in) { + return getWZ(in, false); + } + + public static MapleDataProvider getImageProvidingDataProvider(File in) { + return getWZ(in, true); + } + + public static File fileInWZPath(String filename) { + return new File(wzPath, filename); + } +} \ No newline at end of file diff --git a/tools/MapleInvalidItemWithNoNameFetcher/src/provider/MapleDataTool.java b/tools/MapleInvalidItemWithNoNameFetcher/src/provider/MapleDataTool.java new file mode 100644 index 0000000000..25f4c7f817 --- /dev/null +++ b/tools/MapleInvalidItemWithNoNameFetcher/src/provider/MapleDataTool.java @@ -0,0 +1,145 @@ +/* + This file is part of the OdinMS Maple Story Server + Copyright (C) 2008 Patrick Huy + Matthias Butz + Jan Christian Meyer + + 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 . +*/ +package provider; + +import java.awt.Point; +import java.awt.image.BufferedImage; +import provider.wz.MapleDataType; + +public class MapleDataTool { + public static String getString(MapleData data) { + return ((String) data.getData()); + } + + public static String getString(MapleData data, String def) { + if (data == null || data.getData() == null) { + return def; + } else { + return ((String) data.getData()); + } + } + + public static String getString(String path, MapleData data) { + return getString(data.getChildByPath(path)); + } + + public static String getString(String path, MapleData data, String def) { + return getString(data.getChildByPath(path), def); + } + + public static double getDouble(MapleData data) { + return ((Double) data.getData()).doubleValue(); + } + + public static float getFloat(MapleData data) { + return ((Float) data.getData()).floatValue(); + } + + public static int getInt(MapleData data) { + if (data == null || data.getData() == null) { + return 0;// DEF? + } + return ((Integer) data.getData()).intValue(); + } + + public static int getInt(String path, MapleData data) { + return getInt(data.getChildByPath(path)); + } + + public static int getIntConvert(MapleData data) { + if (data.getType() == MapleDataType.STRING) { + return Integer.parseInt(getString(data)); + } else { + return getInt(data); + } + } + + public static int getIntConvert(String path, MapleData data) { + MapleData d = data.getChildByPath(path); + if (d.getType() == MapleDataType.STRING) { + return Integer.parseInt(getString(d)); + } else { + return getInt(d); + } + } + + public static int getInt(MapleData data, int def) { + if (data == null || data.getData() == null) { + return def; + } else if (data.getType() == MapleDataType.STRING) { + return Integer.parseInt(getString(data)); + } else { + return ((Integer) data.getData()).intValue(); + } + } + + public static int getInt(String path, MapleData data, int def) { + return getInt(data.getChildByPath(path), def); + } + + public static int getIntConvert(String path, MapleData data, int def) { + MapleData d = data.getChildByPath(path); + if (d == null) { + return def; + } + if (d.getType() == MapleDataType.STRING) { + try { + return Integer.parseInt(getString(d)); + } catch (NumberFormatException nfe) { + nfe.printStackTrace(); + return def; + } + } else { + return getInt(d, def); + } + } + + public static BufferedImage getImage(MapleData data) { + return ((MapleCanvas) data.getData()).getImage(); + } + + public static Point getPoint(MapleData data) { + return ((Point) data.getData()); + } + + public static Point getPoint(String path, MapleData data) { + return getPoint(data.getChildByPath(path)); + } + + public static Point getPoint(String path, MapleData data, Point def) { + final MapleData pointData = data.getChildByPath(path); + if (pointData == null) { + return def; + } + return getPoint(pointData); + } + + public static String getFullDataPath(MapleData data) { + String path = ""; + MapleDataEntity myData = data; + while (myData != null) { + path = myData.getName() + "/" + path; + myData = myData.getParent(); + } + return path.substring(0, path.length() - 1); + } +} diff --git a/tools/MapleInvalidItemWithNoNameFetcher/src/provider/wz/FileStoredPngMapleCanvas.java b/tools/MapleInvalidItemWithNoNameFetcher/src/provider/wz/FileStoredPngMapleCanvas.java new file mode 100644 index 0000000000..21736c2c16 --- /dev/null +++ b/tools/MapleInvalidItemWithNoNameFetcher/src/provider/wz/FileStoredPngMapleCanvas.java @@ -0,0 +1,70 @@ +/* + This file is part of the OdinMS Maple Story Server + Copyright (C) 2008 Patrick Huy + Matthias Butz + Jan Christian Meyer + + 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 . +*/ +package provider.wz; + +import java.awt.image.BufferedImage; +import java.io.File; +import java.io.IOException; +import javax.imageio.ImageIO; +import provider.MapleCanvas; + +public class FileStoredPngMapleCanvas implements MapleCanvas { + private File file; + private int width; + private int height; + private BufferedImage image; + + public FileStoredPngMapleCanvas(int width, int height, File fileIn) { + this.width = width; + this.height = height; + this.file = fileIn; + } + + @Override + public int getHeight() { + return height; + } + + @Override + public int getWidth() { + return width; + } + + @Override + public BufferedImage getImage() { + loadImageIfNecessary(); + return image; + } + + private void loadImageIfNecessary() { + if (image == null) { + try { + image = ImageIO.read(file); + // replace the dimensions loaded from the wz by the REAL dimensions from the image - should be equal tho + width = image.getWidth(); + height = image.getHeight(); + } catch (IOException e) { + throw new RuntimeException(e); + } + } + } +} diff --git a/tools/MapleInvalidItemWithNoNameFetcher/src/provider/wz/ImgMapleSound.java b/tools/MapleInvalidItemWithNoNameFetcher/src/provider/wz/ImgMapleSound.java new file mode 100644 index 0000000000..8add2ccb36 --- /dev/null +++ b/tools/MapleInvalidItemWithNoNameFetcher/src/provider/wz/ImgMapleSound.java @@ -0,0 +1,39 @@ +/* + This file is part of the OdinMS Maple Story Server + Copyright (C) 2008 Patrick Huy + Matthias Butz + Jan Christian Meyer + + 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 . +*/ +package provider.wz; + +public class ImgMapleSound { + private int dataLength, offset; + + public ImgMapleSound(int dataLength, int offset) { + this.dataLength = dataLength; + this.offset = offset; + } + + public int getDataLength() { + return dataLength; + } + + public int getOffset() { + return offset; + } +} diff --git a/tools/MapleInvalidItemWithNoNameFetcher/src/provider/wz/ListWZFile.java b/tools/MapleInvalidItemWithNoNameFetcher/src/provider/wz/ListWZFile.java new file mode 100644 index 0000000000..1672a08c59 --- /dev/null +++ b/tools/MapleInvalidItemWithNoNameFetcher/src/provider/wz/ListWZFile.java @@ -0,0 +1,86 @@ +/* + This file is part of the OdinMS Maple Story Server + Copyright (C) 2008 Patrick Huy + Matthias Butz + Jan Christian Meyer + + 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 . +*/ +package provider.wz; + +import java.io.BufferedInputStream; +import java.io.File; +import java.io.FileInputStream; +import java.io.FileNotFoundException; +import java.util.ArrayList; +import java.util.Collection; +import java.util.Collections; +import java.util.HashSet; +import java.util.List; +import provider.MapleDataProviderFactory; +import tools.data.input.GenericLittleEndianAccessor; +import tools.data.input.InputStreamByteStream; +import tools.data.input.LittleEndianAccessor; + +public class ListWZFile { + private LittleEndianAccessor lea; + private List entries = new ArrayList(); + private static Collection modernImgs = new HashSet(); + + public static byte[] xorBytes(byte[] a, byte[] b) { + byte[] wusched = new byte[a.length]; + for (int i = 0; i < a.length; i++) { + wusched[i] = (byte) (a[i] ^ b[i]); + } + return wusched; + } + + public ListWZFile(File listwz) throws FileNotFoundException { + lea = new GenericLittleEndianAccessor(new InputStreamByteStream(new BufferedInputStream(new FileInputStream(listwz)))); + while (lea.available() > 0) { + int l = lea.readInt() * 2; + byte[] chunk = new byte[l]; + for (int i = 0; i < chunk.length; i++) { + chunk[i] = lea.readByte(); + } + lea.readChar(); + final String value = String.valueOf(WZTool.readListString(chunk)); + entries.add(value); + } + entries = Collections.unmodifiableList(entries); + } + + public List getEntries() { + return entries; + } + + public static void init() { + final String listWz = System.getProperty("listwz"); + if (listWz != null) { + ListWZFile listwz; + try { + listwz = new ListWZFile(MapleDataProviderFactory.fileInWZPath("List.wz")); + modernImgs = new HashSet(listwz.getEntries()); + } catch (FileNotFoundException e) { + e.printStackTrace(); + } + } + } + + public static boolean isModernImgFile(String path) { + return modernImgs.contains(path); + } +} diff --git a/tools/MapleInvalidItemWithNoNameFetcher/src/provider/wz/MapleDataType.java b/tools/MapleInvalidItemWithNoNameFetcher/src/provider/wz/MapleDataType.java new file mode 100644 index 0000000000..e074d57d14 --- /dev/null +++ b/tools/MapleInvalidItemWithNoNameFetcher/src/provider/wz/MapleDataType.java @@ -0,0 +1,26 @@ +/* + This file is part of the OdinMS Maple Story Server + Copyright (C) 2008 Patrick Huy + Matthias Butz + Jan Christian Meyer + + 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 . +*/ +package provider.wz; + +public enum MapleDataType { + NONE, IMG_0x00, SHORT, INT, FLOAT, DOUBLE, STRING, EXTENDED, PROPERTY, CANVAS, VECTOR, CONVEX, SOUND, UOL, UNKNOWN_TYPE, UNKNOWN_EXTENDED_TYPE; +} \ No newline at end of file diff --git a/tools/MapleInvalidItemWithNoNameFetcher/src/provider/wz/PNGMapleCanvas.java b/tools/MapleInvalidItemWithNoNameFetcher/src/provider/wz/PNGMapleCanvas.java new file mode 100644 index 0000000000..97c2303804 --- /dev/null +++ b/tools/MapleInvalidItemWithNoNameFetcher/src/provider/wz/PNGMapleCanvas.java @@ -0,0 +1,151 @@ +/* + This file is part of the OdinMS Maple Story Server + Copyright (C) 2008 Patrick Huy + Matthias Butz + Jan Christian Meyer + + 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 . +*/ +package provider.wz; + +import java.awt.Point; +import java.awt.image.BufferedImage; +import java.awt.image.DataBuffer; +import java.awt.image.DataBufferByte; +import java.awt.image.PixelInterleavedSampleModel; +import java.awt.image.Raster; +import java.awt.image.SampleModel; +import java.awt.image.WritableRaster; +import java.util.zip.DataFormatException; +import java.util.zip.Inflater; +import provider.MapleCanvas; + +public class PNGMapleCanvas implements MapleCanvas { + private static final int[] ZAHLEN = new int[]{2, 1, 0, 3}; + private int height; + private int width; + private int dataLength; + private int format; + private byte[] data; + + public PNGMapleCanvas(int width, int height, int dataLength, int format, byte[] data) { + super(); + this.height = height; + this.width = width; + this.dataLength = dataLength; + this.format = format; + this.data = data; + } + + public int getHeight() { + return height; + } + + public int getWidth() { + return width; + } + + public int getFormat() { + return format; + } + + private byte[] getData() { + return data; + } + + @Override + public BufferedImage getImage() { + int sizeUncompressed = 0; + int size8888 = 0; + int maxWriteBuf = 2; + int maxHeight = 3; + byte[] writeBuf = new byte[maxWriteBuf]; + @SuppressWarnings ("unused") + byte[] rowPointers = new byte[maxHeight]; + switch (getFormat()) { + case 1: + case 513: + sizeUncompressed = getHeight() * getWidth() * 4; + break; + case 2: + sizeUncompressed = getHeight() * getWidth() * 8; + break; + case 517: + sizeUncompressed = getHeight() * getWidth() / 128; + break; + } + size8888 = getHeight() * getWidth() * 8; + if (size8888 > maxWriteBuf) { + maxWriteBuf = size8888; + writeBuf = new byte[maxWriteBuf]; + } + if (getHeight() > maxHeight) { + maxHeight = getHeight(); + rowPointers = new byte[maxHeight]; + } + Inflater dec = new Inflater(); + dec.setInput(getData(), 0, dataLength); + int declen = 0; + byte[] uc = new byte[sizeUncompressed]; + try { + declen = dec.inflate(uc); + } catch (DataFormatException ex) { + throw new RuntimeException("zlib fucks", ex); + } + dec.end(); + if (getFormat() == 1) { + for (int i = 0; i < sizeUncompressed; i++) { + byte low = (byte) (uc[i] & 0x0F); + byte high = (byte) (uc[i] & 0xF0); + writeBuf[(i << 1)] = (byte) (((low << 4) | low) & 0xFF); + writeBuf[(i << 1) + 1] = (byte) (high | ((high >>> 4) & 0xF)); + } + } else if (getFormat() == 2) { + writeBuf = uc; + } else if (getFormat() == 513) { + for (int i = 0; i < declen; i += 2) { + byte bBits = (byte) ((uc[i] & 0x1F) << 3); + byte gBits = (byte) (((uc[i + 1] & 0x07) << 5) | ((uc[i] & 0xE0) >> 3)); + byte rBits = (byte) (uc[i + 1] & 0xF8); + writeBuf[(i << 1)] = (byte) (bBits | (bBits >> 5)); + writeBuf[(i << 1) + 1] = (byte) (gBits | (gBits >> 6)); + writeBuf[(i << 1) + 2] = (byte) (rBits | (rBits >> 5)); + writeBuf[(i << 1) + 3] = (byte) 0xFF; + } + } else if (getFormat() == 517) { + byte b = 0x00; + int pixelIndex = 0; + for (int i = 0; i < declen; i++) { + for (int j = 0; j < 8; j++) { + b = (byte) (((uc[i] & (0x01 << (7 - j))) >> (7 - j)) * 255); + for (int k = 0; k < 16; k++) { + pixelIndex = (i << 9) + (j << 6) + k * 2; + writeBuf[pixelIndex] = b; + writeBuf[pixelIndex + 1] = b; + writeBuf[pixelIndex + 2] = b; + writeBuf[pixelIndex + 3] = (byte) 0xFF; + } + } + } + } + DataBufferByte imgData = new DataBufferByte(writeBuf, sizeUncompressed); + SampleModel sm = new PixelInterleavedSampleModel(DataBuffer.TYPE_BYTE, getWidth(), getHeight(), 4, getWidth() * 4, ZAHLEN); + WritableRaster imgRaster = Raster.createWritableRaster(sm, imgData, new Point(0, 0)); + BufferedImage aa = new BufferedImage(getWidth(), getHeight(), BufferedImage.TYPE_INT_ARGB); + aa.setData(imgRaster); + return aa; + } +} diff --git a/tools/MapleInvalidItemWithNoNameFetcher/src/provider/wz/WZDirectoryEntry.java b/tools/MapleInvalidItemWithNoNameFetcher/src/provider/wz/WZDirectoryEntry.java new file mode 100644 index 0000000000..d24b8cb2b9 --- /dev/null +++ b/tools/MapleInvalidItemWithNoNameFetcher/src/provider/wz/WZDirectoryEntry.java @@ -0,0 +1,68 @@ +/* + This file is part of the OdinMS Maple Story Server + Copyright (C) 2008 Patrick Huy + Matthias Butz + Jan Christian Meyer + + 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 . +*/ +package provider.wz; + +import java.util.ArrayList; +import java.util.Collections; +import java.util.HashMap; +import java.util.List; +import java.util.Map; +import provider.MapleDataDirectoryEntry; +import provider.MapleDataEntity; +import provider.MapleDataEntry; +import provider.MapleDataFileEntry; + +public class WZDirectoryEntry extends WZEntry implements MapleDataDirectoryEntry { + private List subdirs = new ArrayList(); + private List files = new ArrayList(); + private Map entries = new HashMap(); + + public WZDirectoryEntry(String name, int size, int checksum, MapleDataEntity parent) { + super(name, size, checksum, parent); + } + + public WZDirectoryEntry() { + super(null, 0, 0, null); + } + + public void addDirectory(MapleDataDirectoryEntry dir) { + subdirs.add(dir); + entries.put(dir.getName(), dir); + } + + public void addFile(MapleDataFileEntry fileEntry) { + files.add(fileEntry); + entries.put(fileEntry.getName(), fileEntry); + } + + public List getSubdirectories() { + return Collections.unmodifiableList(subdirs); + } + + public List getFiles() { + return Collections.unmodifiableList(files); + } + + public MapleDataEntry getEntry(String name) { + return entries.get(name); + } +} diff --git a/tools/MapleInvalidItemWithNoNameFetcher/src/provider/wz/WZEntry.java b/tools/MapleInvalidItemWithNoNameFetcher/src/provider/wz/WZEntry.java new file mode 100644 index 0000000000..1e921b2082 --- /dev/null +++ b/tools/MapleInvalidItemWithNoNameFetcher/src/provider/wz/WZEntry.java @@ -0,0 +1,61 @@ +/* + This file is part of the OdinMS Maple Story Server + Copyright (C) 2008 Patrick Huy + Matthias Butz + Jan Christian Meyer + + 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 . +*/ +package provider.wz; + +import provider.MapleDataEntity; +import provider.MapleDataEntry; + +public class WZEntry implements MapleDataEntry { + private String name; + private int size; + private int checksum; + private int offset; + private MapleDataEntity parent; + + public WZEntry(String name, int size, int checksum, MapleDataEntity parent) { + super(); + this.name = name; + this.size = size; + this.checksum = checksum; + this.parent = parent; + } + + public String getName() { + return name; + } + + public int getSize() { + return size; + } + + public int getChecksum() { + return checksum; + } + + public int getOffset() { + return offset; + } + + public MapleDataEntity getParent() { + return parent; + } +} diff --git a/tools/MapleInvalidItemWithNoNameFetcher/src/provider/wz/WZFile.java b/tools/MapleInvalidItemWithNoNameFetcher/src/provider/wz/WZFile.java new file mode 100644 index 0000000000..c6c0abf537 --- /dev/null +++ b/tools/MapleInvalidItemWithNoNameFetcher/src/provider/wz/WZFile.java @@ -0,0 +1,154 @@ +/* + This file is part of the OdinMS Maple Story Server + Copyright (C) 2008 Patrick Huy + Matthias Butz + Jan Christian Meyer + + 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 . +*/ +package provider.wz; + +import java.io.BufferedInputStream; +import java.io.File; +import java.io.FileInputStream; +import java.io.IOException; +import java.io.RandomAccessFile; +import provider.MapleData; +import provider.MapleDataDirectoryEntry; +import provider.MapleDataFileEntry; +import provider.MapleDataProvider; +import tools.data.input.GenericLittleEndianAccessor; +import tools.data.input.GenericSeekableLittleEndianAccessor; +import tools.data.input.InputStreamByteStream; +import tools.data.input.LittleEndianAccessor; +import tools.data.input.RandomAccessByteStream; +import tools.data.input.SeekableLittleEndianAccessor; + +public class WZFile implements MapleDataProvider { + static { + ListWZFile.init(); + } + private File wzfile; + private LittleEndianAccessor lea; + private SeekableLittleEndianAccessor slea; + private int headerSize; + private WZDirectoryEntry root; + private boolean provideImages; + private int cOffset; + + public WZFile(File wzfile, boolean provideImages) throws IOException { + this.wzfile = wzfile; + lea = new GenericLittleEndianAccessor(new InputStreamByteStream(new BufferedInputStream(new FileInputStream(wzfile)))); + RandomAccessFile raf = new RandomAccessFile(wzfile, "r"); + slea = new GenericSeekableLittleEndianAccessor(new RandomAccessByteStream(raf)); + root = new WZDirectoryEntry(wzfile.getName(), 0, 0, null); + this.provideImages = provideImages; + load(); + } + + private void load() throws IOException { + lea.readAsciiString(4); + lea.readInt(); + lea.readInt(); + headerSize = lea.readInt(); + lea.readNullTerminatedAsciiString(); + lea.readShort(); + parseDirectory(root); + cOffset = (int) lea.getBytesRead(); + getOffsets(root); + } + + private void getOffsets(MapleDataDirectoryEntry dir) { + for (MapleDataFileEntry file : dir.getFiles()) { + file.setOffset(cOffset); + cOffset += file.getSize(); + } + for (MapleDataDirectoryEntry sdir : dir.getSubdirectories()) { + getOffsets(sdir); + } + } + + private void parseDirectory(WZDirectoryEntry dir) { + int entries = WZTool.readValue(lea); + for (int i = 0; i < entries; i++) { + byte marker = lea.readByte(); + String name = null; + int size, checksum; + switch (marker) { + case 0x02: + name = WZTool.readDecodedStringAtOffsetAndReset(slea, lea.readInt() + this.headerSize + 1); + size = WZTool.readValue(lea); + checksum = WZTool.readValue(lea); + lea.readInt(); //dummy int + dir.addFile(new WZFileEntry(name, size, checksum, dir)); + break; + case 0x03: + case 0x04: + name = WZTool.readDecodedString(lea); + size = WZTool.readValue(lea); + checksum = WZTool.readValue(lea); + lea.readInt(); //dummy int + if (marker == 3) { + dir.addDirectory(new WZDirectoryEntry(name, size, checksum, dir)); + } else { + dir.addFile(new WZFileEntry(name, size, checksum, dir)); + } + break; + default: + } + } + for (MapleDataDirectoryEntry idir : dir.getSubdirectories()) { + parseDirectory((WZDirectoryEntry) idir); + } + } + + public WZIMGFile getImgFile(String path) throws IOException { + String segments[] = path.split("/"); + WZDirectoryEntry dir = root; + for (int x = 0; x < segments.length - 1; x++) { + dir = (WZDirectoryEntry) dir.getEntry(segments[x]); + if (dir == null) { + return null; + } + } + WZFileEntry entry = (WZFileEntry) dir.getEntry(segments[segments.length - 1]); + if (entry == null) { + return null; + } + String fullPath = wzfile.getName().substring(0, wzfile.getName().length() - 3).toLowerCase() + "/" + path; + return new WZIMGFile(this.wzfile, entry, provideImages, ListWZFile.isModernImgFile(fullPath)); + } + + @Override + public synchronized MapleData getData(String path) { + try { + WZIMGFile imgFile = getImgFile(path); + if (imgFile == null) { + return null; + } + MapleData ret = imgFile.getRoot(); + return ret; + } catch (IOException e) { + e.printStackTrace(); + } + return null; + } + + @Override + public MapleDataDirectoryEntry getRoot() { + return root; + } +} diff --git a/tools/MapleInvalidItemWithNoNameFetcher/src/provider/wz/WZFileEntry.java b/tools/MapleInvalidItemWithNoNameFetcher/src/provider/wz/WZFileEntry.java new file mode 100644 index 0000000000..792371d9cf --- /dev/null +++ b/tools/MapleInvalidItemWithNoNameFetcher/src/provider/wz/WZFileEntry.java @@ -0,0 +1,42 @@ +/* + This file is part of the OdinMS Maple Story Server + Copyright (C) 2008 Patrick Huy + Matthias Butz + Jan Christian Meyer + + 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 . +*/ +package provider.wz; + +import provider.MapleDataEntity; +import provider.MapleDataFileEntry; + +public class WZFileEntry extends WZEntry implements MapleDataFileEntry { + private int offset; + + public WZFileEntry(String name, int size, int checksum, MapleDataEntity parent) { + super(name, size, checksum, parent); + } + + @Override + public int getOffset() { + return offset; + } + + public void setOffset(int offset) { + this.offset = offset; + } +} diff --git a/tools/MapleInvalidItemWithNoNameFetcher/src/provider/wz/WZIMGEntry.java b/tools/MapleInvalidItemWithNoNameFetcher/src/provider/wz/WZIMGEntry.java new file mode 100644 index 0000000000..385d785183 --- /dev/null +++ b/tools/MapleInvalidItemWithNoNameFetcher/src/provider/wz/WZIMGEntry.java @@ -0,0 +1,118 @@ +/* + This file is part of the OdinMS Maple Story Server + Copyright (C) 2008 Patrick Huy + Matthias Butz + Jan Christian Meyer + + 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 . +*/ +package provider.wz; + +import java.util.ArrayList; +import java.util.Collections; +import java.util.Iterator; +import java.util.List; +import provider.MapleData; +import provider.MapleDataEntity; + +public class WZIMGEntry implements MapleData { + private String name; + private MapleDataType type; + private List children = new ArrayList(10); + private Object data; + private MapleDataEntity parent; + + public WZIMGEntry(MapleDataEntity parent) { + this.parent = parent; + } + + @Override + public String getName() { + return name; + } + + @Override + public MapleDataType getType() { + return type; + } + + @Override + public List getChildren() { + return Collections.unmodifiableList(children); + } + + @Override + public MapleData getChildByPath(String path) { + String segments[] = path.split("/"); + if (segments[0].equals("..")) { + return ((MapleData) getParent()).getChildByPath(path.substring(path.indexOf("/") + 1)); + } + MapleData ret = this; + for (int x = 0; x < segments.length; x++) { + boolean foundChild = false; + for (MapleData child : ret.getChildren()) { + if (child.getName().equals(segments[x])) { + ret = child; + foundChild = true; + break; + } + } + if (!foundChild) { + return null; + } + } + return ret; + } + + @Override + public Object getData() { + return data; + } + + public void setName(String name) { + this.name = name; + } + + public void setType(MapleDataType type) { + this.type = type; + } + + public void setData(Object data) { + this.data = data; + } + + public void addChild(WZIMGEntry entry) { + children.add(entry); + } + + @Override + public Iterator iterator() { + return getChildren().iterator(); + } + + @Override + public String toString() { + return getName() + ":" + getData(); + } + + public MapleDataEntity getParent() { + return parent; + } + + public void finish() { + ((ArrayList) children).trimToSize(); + } +} diff --git a/tools/MapleInvalidItemWithNoNameFetcher/src/provider/wz/WZIMGFile.java b/tools/MapleInvalidItemWithNoNameFetcher/src/provider/wz/WZIMGFile.java new file mode 100644 index 0000000000..bec06c78bd --- /dev/null +++ b/tools/MapleInvalidItemWithNoNameFetcher/src/provider/wz/WZIMGFile.java @@ -0,0 +1,227 @@ +/* + This file is part of the OdinMS Maple Story Server + Copyright (C) 2008 Patrick Huy + Matthias Butz + Jan Christian Meyer + + 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 . +*/ +package provider.wz; + +import java.awt.Point; +import java.io.DataOutputStream; +import java.io.File; +import java.io.IOException; +import java.io.OutputStream; +import java.io.RandomAccessFile; +import tools.data.input.GenericSeekableLittleEndianAccessor; +import tools.data.input.RandomAccessByteStream; +import tools.data.input.SeekableLittleEndianAccessor; + +public class WZIMGFile { + private WZFileEntry file; + private WZIMGEntry root; + private boolean provideImages; + @SuppressWarnings ("unused") + private boolean modernImg; + + public WZIMGFile(File wzfile, WZFileEntry file, boolean provideImages, boolean modernImg) throws IOException { + RandomAccessFile raf = new RandomAccessFile(wzfile, "r"); + SeekableLittleEndianAccessor slea = new GenericSeekableLittleEndianAccessor(new RandomAccessByteStream(raf)); + slea.seek(file.getOffset()); + this.file = file; + this.provideImages = provideImages; + root = new WZIMGEntry(file.getParent()); + root.setName(file.getName()); + root.setType(MapleDataType.EXTENDED); + this.modernImg = modernImg; + parseExtended(root, slea, 0); + root.finish(); + raf.close(); + } + + protected void dumpImg(OutputStream out, SeekableLittleEndianAccessor slea) throws IOException { + DataOutputStream os = new DataOutputStream(out); + long oldPos = slea.getPosition(); + slea.seek(file.getOffset()); + for (int x = 0; x < file.getSize(); x++) { + os.write(slea.readByte()); + } + slea.seek(oldPos); + } + + public WZIMGEntry getRoot() { + return root; + } + + private void parse(WZIMGEntry entry, SeekableLittleEndianAccessor slea) { + byte marker = slea.readByte(); + switch (marker) { + case 0: { + String name = WZTool.readDecodedString(slea); + entry.setName(name); + break; + } + case 1: { + String name = WZTool.readDecodedStringAtOffsetAndReset(slea, file.getOffset() + slea.readInt()); + entry.setName(name); + break; + } + default: + System.out.println("Unknown Image identifier: " + marker + " at offset " + (slea.getPosition() - file.getOffset())); + } + marker = slea.readByte(); + switch (marker) { + case 0: + entry.setType(MapleDataType.IMG_0x00); + break; + case 2: + case 11: //??? no idea, since 0.49 + entry.setType(MapleDataType.SHORT); + entry.setData(Short.valueOf(slea.readShort())); + break; + case 3: + entry.setType(MapleDataType.INT); + entry.setData(Integer.valueOf(WZTool.readValue(slea))); + break; + case 4: + entry.setType(MapleDataType.FLOAT); + entry.setData(Float.valueOf(WZTool.readFloatValue(slea))); + break; + case 5: + entry.setType(MapleDataType.DOUBLE); + entry.setData(Double.valueOf(slea.readDouble())); + break; + case 8: + entry.setType(MapleDataType.STRING); + byte iMarker = slea.readByte(); + if (iMarker == 0) { + entry.setData(WZTool.readDecodedString(slea)); + } else if (iMarker == 1) { + entry.setData(WZTool.readDecodedStringAtOffsetAndReset(slea, slea.readInt() + file.getOffset())); + } else { + System.out.println("Unknown String type " + iMarker); + } + break; + case 9: + entry.setType(MapleDataType.EXTENDED); + long endOfExtendedBlock = slea.readInt(); + endOfExtendedBlock += slea.getPosition(); + parseExtended(entry, slea, endOfExtendedBlock); + break; + default: + System.out.println("Unknown Image type " + marker); + } + } + + private void parseExtended(WZIMGEntry entry, SeekableLittleEndianAccessor slea, long endOfExtendedBlock) { + byte marker = slea.readByte(); + String type; + switch (marker) { + case 0x73: + type = WZTool.readDecodedString(slea); + break; + case 0x1B: + type = WZTool.readDecodedStringAtOffsetAndReset(slea, file.getOffset() + slea.readInt()); + break; + default: + throw new RuntimeException("Unknown extended image identifier: " + marker + " at offset " + + (slea.getPosition() - file.getOffset())); + } + if (type.equals("Property")) { + entry.setType(MapleDataType.PROPERTY); + slea.readByte(); + slea.readByte(); + int children = WZTool.readValue(slea); + for (int i = 0; i < children; i++) { + WZIMGEntry cEntry = new WZIMGEntry(entry); + parse(cEntry, slea); + cEntry.finish(); + entry.addChild(cEntry); + } + } else if (type.equals("Canvas")) { + entry.setType(MapleDataType.CANVAS); + slea.readByte(); + marker = slea.readByte(); + if (marker == 0) { + // do nothing + } else if (marker == 1) { + slea.readByte(); + slea.readByte(); + int children = WZTool.readValue(slea); + for (int i = 0; i < children; i++) { + WZIMGEntry child = new WZIMGEntry(entry); + parse(child, slea); + child.finish(); + entry.addChild(child); + } + } else { + System.out.println("Canvas marker != 1 (" + marker + ")"); + } + int width = WZTool.readValue(slea); + int height = WZTool.readValue(slea); + int format = WZTool.readValue(slea); + int format2 = slea.readByte(); + slea.readInt(); + int dataLength = slea.readInt() - 1; + slea.readByte(); + if (provideImages) { + byte[] pngdata = slea.read(dataLength); + entry.setData(new PNGMapleCanvas(width, height, dataLength, format + format2, pngdata)); + } else { + entry.setData(new PNGMapleCanvas(width, height, dataLength, format + format2, null)); + slea.skip(dataLength); + } + } else if (type.equals("Shape2D#Vector2D")) { + entry.setType(MapleDataType.VECTOR); + int x = WZTool.readValue(slea); + int y = WZTool.readValue(slea); + entry.setData(new Point(x, y)); + } else if (type.equals("Shape2D#Convex2D")) { + int children = WZTool.readValue(slea); + for (int i = 0; i < children; i++) { + WZIMGEntry cEntry = new WZIMGEntry(entry); + parseExtended(cEntry, slea, 0); + cEntry.finish(); + entry.addChild(cEntry); + } + } else if (type.equals("Sound_DX8")) { + entry.setType(MapleDataType.SOUND); + slea.readByte(); + int dataLength = WZTool.readValue(slea); + WZTool.readValue(slea); // no clue what this is + int offset = (int) slea.getPosition(); + entry.setData(new ImgMapleSound(dataLength, offset - file.getOffset())); + slea.seek(endOfExtendedBlock); + } else if (type.equals("UOL")) { + entry.setType(MapleDataType.UOL); + slea.readByte(); + byte uolmarker = slea.readByte(); + switch (uolmarker) { + case 0: + entry.setData(WZTool.readDecodedString(slea)); + break; + case 1: + entry.setData(WZTool.readDecodedStringAtOffsetAndReset(slea, file.getOffset() + slea.readInt())); + break; + default: + System.out.println("Unknown UOL marker: " + uolmarker + " " + entry.getName()); + } + } else { + throw new RuntimeException("Unhandled extended type: " + type); + } + } +} diff --git a/tools/MapleInvalidItemWithNoNameFetcher/src/provider/wz/WZTool.java b/tools/MapleInvalidItemWithNoNameFetcher/src/provider/wz/WZTool.java new file mode 100644 index 0000000000..85e1c8d90b --- /dev/null +++ b/tools/MapleInvalidItemWithNoNameFetcher/src/provider/wz/WZTool.java @@ -0,0 +1,187 @@ +/* + This file is part of the OdinMS Maple Story Server + Copyright (C) 2008 Patrick Huy + Matthias Butz + Jan Christian Meyer + + 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 . +*/ +package provider.wz; + +import java.security.InvalidKeyException; +import java.security.NoSuchAlgorithmException; +import javax.crypto.BadPaddingException; +import javax.crypto.Cipher; +import javax.crypto.IllegalBlockSizeException; +import javax.crypto.NoSuchPaddingException; +import javax.crypto.spec.SecretKeySpec; +import tools.data.input.LittleEndianAccessor; +import tools.data.input.SeekableLittleEndianAccessor; + +/* + * Ported Code, see WZFile.java for more info + */ +public class WZTool { + private static byte[] encKey; + + static { + byte[] iv = new byte[]{(byte) 0x4d, (byte) 0x23, (byte) 0xc7, (byte) 0x2b, + (byte) 0x4d, (byte) 0x23, (byte) 0xc7, (byte) 0x2b, + (byte) 0x4d, (byte) 0x23, (byte) 0xc7, (byte) 0x2b, + (byte) 0x4d, (byte) 0x23, (byte) 0xc7, (byte) 0x2b,}; + byte[] key = new byte[]{(byte) 0x13, 0x00, 0x00, 0x00, + (byte) 0x08, 0x00, 0x00, 0x00, + (byte) 0x06, 0x00, 0x00, 0x00, + (byte) 0xB4, 0x00, 0x00, 0x00, + (byte) 0x1B, 0x00, 0x00, 0x00, + (byte) 0x0F, 0x00, 0x00, 0x00, + (byte) 0x33, 0x00, 0x00, 0x00, + (byte) 0x52, 0x00, 0x00, 0x00 + }; + Cipher cipher = null; + SecretKeySpec skeySpec = new SecretKeySpec(key, "AES"); + try { + cipher = Cipher.getInstance("AES"); + } catch (NoSuchAlgorithmException e) { + e.printStackTrace(); + } catch (NoSuchPaddingException e) { + e.printStackTrace(); + } + try { + cipher.init(Cipher.ENCRYPT_MODE, skeySpec); + } catch (InvalidKeyException e) { + e.printStackTrace(); + } + encKey = new byte[0xFFFF]; + for (int i = 0; i < (0xFFFF / 16); i++) { + try { + iv = cipher.doFinal(iv); + } catch (IllegalBlockSizeException e) { + e.printStackTrace(); + } catch (BadPaddingException e) { + e.printStackTrace(); + } + System.arraycopy(iv, 0, encKey, (i * 16), 16); + } + try { + iv = cipher.doFinal(iv); + } catch (IllegalBlockSizeException e) { + e.printStackTrace(); + } catch (BadPaddingException e) { + e.printStackTrace(); + } + System.arraycopy(iv, 0, encKey, 65520, 15); + } + + public static byte[] readListString(byte[] str) { + for (int i = 0; i < str.length; i++) { + str[i] = (byte) (str[i] ^ encKey[i]); + } + return str; + } + + public static String readDecodedString(LittleEndianAccessor llea) { + int strLength; + byte b = llea.readByte(); + if (b == 0x00) { + return ""; + } + if (b >= 0) { + if (b == 0x7F) { + strLength = llea.readInt(); + } else { + strLength = (int) b; + } + if (strLength < 0) { + return ""; + } + byte str[] = new byte[strLength * 2]; + for (int i = 0; i < strLength * 2; i++) { + str[i] = llea.readByte(); + } + return DecryptUnicodeStr(str); + } else { + if (b == -128) { + strLength = llea.readInt(); + } else { + strLength = -b; + } + if (strLength < 0) { + return ""; + } + byte str[] = new byte[strLength]; + for (int i = 0; i < strLength; i++) { + str[i] = llea.readByte(); + } + return DecryptAsciiStr(str); + } + } + + public static String DecryptAsciiStr(byte[] str) { + byte xorByte = (byte) 0xAA; + for (int i = 0; i < str.length; i++) { + str[i] = (byte) (str[i] ^ xorByte ^ encKey[i]); + xorByte++; + } + return new String(str); + } + + public static String DecryptUnicodeStr(byte[] str) { + int xorByte = 0xAAAA; + char[] charRet = new char[str.length / 2]; + for (int i = 0; i < str.length; i++) { + str[i] = (byte) (str[i] ^ encKey[i]); + } + for (int i = 0; i < (str.length / 2); i++) { + char toXor = (char) ((str[i] << 8) | str[i + 1]); + charRet[i] = (char) (toXor ^ xorByte); + xorByte++; + } + return String.valueOf(charRet); + } + + public static String readDecodedStringAtOffset(SeekableLittleEndianAccessor slea, int offset) { + slea.seek(offset); + return readDecodedString(slea); + } + + public static String readDecodedStringAtOffsetAndReset(SeekableLittleEndianAccessor slea, int offset) { + long pos = 0; + pos = slea.getPosition(); + slea.seek(offset); + String ret = readDecodedString(slea); + slea.seek(pos); + return ret; + } + + public static int readValue(LittleEndianAccessor lea) { + byte b = lea.readByte(); + if (b == -128) { + return lea.readInt(); + } else { + return ((int) b); + } + } + + public static float readFloatValue(LittleEndianAccessor lea) { + byte b = lea.readByte(); + if (b == -128) { + return lea.readFloat(); + } else { + return 0; + } + } +} \ No newline at end of file diff --git a/tools/MapleInvalidItemWithNoNameFetcher/src/provider/wz/XMLDomMapleData.java b/tools/MapleInvalidItemWithNoNameFetcher/src/provider/wz/XMLDomMapleData.java new file mode 100644 index 0000000000..151a04c2fd --- /dev/null +++ b/tools/MapleInvalidItemWithNoNameFetcher/src/provider/wz/XMLDomMapleData.java @@ -0,0 +1,219 @@ +/* + This file is part of the OdinMS Maple Story Server + Copyright (C) 2008 Patrick Huy + Matthias Butz + Jan Christian Meyer + + 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 . + */ +package provider.wz; + +import java.awt.Point; +import java.io.File; +import java.io.FileInputStream; +import java.io.IOException; +import java.util.ArrayList; +import java.util.Iterator; +import java.util.List; +import java.util.Locale; +import java.text.NumberFormat; +import javax.xml.parsers.DocumentBuilder; +import javax.xml.parsers.DocumentBuilderFactory; +import javax.xml.parsers.ParserConfigurationException; +import provider.MapleData; +import provider.MapleDataEntity; +import org.w3c.dom.Document; +import org.w3c.dom.NamedNodeMap; +import org.w3c.dom.Node; +import org.w3c.dom.NodeList; +import org.xml.sax.SAXException; + +public class XMLDomMapleData implements MapleData { + private Node node; + private File imageDataDir; + private NumberFormat nf; + + public XMLDomMapleData(FileInputStream fis, File imageDataDir) { + try { + DocumentBuilderFactory documentBuilderFactory = DocumentBuilderFactory.newInstance(); + DocumentBuilder documentBuilder = documentBuilderFactory.newDocumentBuilder(); + Document document = documentBuilder.parse(fis); + this.node = document.getFirstChild(); + } catch (ParserConfigurationException e) { + throw new RuntimeException(e); + } catch (SAXException e) { + throw new RuntimeException(e); + } catch (IOException e) { + throw new RuntimeException(e); + } + this.imageDataDir = imageDataDir; + this.nf = NumberFormat.getInstance(Locale.FRANCE); + } + + private XMLDomMapleData(Node node) { + this.node = node; + this.nf = NumberFormat.getInstance(Locale.FRANCE); + } + + @Override + public MapleData getChildByPath(String path) { + String segments[] = path.split("/"); + if (segments[0].equals("..")) { + return ((MapleData) getParent()).getChildByPath(path.substring(path.indexOf("/") + 1)); + } + + Node myNode = node; + for (int x = 0; x < segments.length; x++) { + NodeList childNodes = myNode.getChildNodes(); + boolean foundChild = false; + for (int i = 0; i < childNodes.getLength(); i++) { + Node childNode = childNodes.item(i); + if (childNode.getNodeType() == Node.ELEMENT_NODE && childNode.getAttributes().getNamedItem("name").getNodeValue().equals(segments[x])) { + myNode = childNode; + foundChild = true; + break; + } + } + if (!foundChild) { + return null; + } + } + XMLDomMapleData ret = new XMLDomMapleData(myNode); + ret.imageDataDir = new File(imageDataDir, getName() + "/" + path).getParentFile(); + return ret; + } + + @Override + public List getChildren() { + List ret = new ArrayList(); + NodeList childNodes = node.getChildNodes(); + for (int i = 0; i < childNodes.getLength(); i++) { + Node childNode = childNodes.item(i); + if (childNode.getNodeType() == Node.ELEMENT_NODE) { + XMLDomMapleData child = new XMLDomMapleData(childNode); + child.imageDataDir = new File(imageDataDir, getName()); + ret.add(child); + } + } + return ret; + } + + @Override + public Object getData() { + NamedNodeMap attributes = node.getAttributes(); + MapleDataType type = getType(); + switch (type) { + case DOUBLE: + case FLOAT: + case INT: + case SHORT: { + String value = attributes.getNamedItem("value").getNodeValue(); + Number nval; + + try { + nval = nf.parse(value); + } + catch(java.text.ParseException pe) { + pe.printStackTrace(); + nval = 0.0f; + } + + switch (type) { + case DOUBLE: + return nval.doubleValue(); + case FLOAT: + return nval.floatValue(); + case INT: + return nval.intValue(); + case SHORT: + return nval.shortValue(); + default: + return null; + } + } + case STRING: + case UOL: { + String value = attributes.getNamedItem("value").getNodeValue(); + return value; + } + case VECTOR: { + String x = attributes.getNamedItem("x").getNodeValue(); + String y = attributes.getNamedItem("y").getNodeValue(); + return new Point(Integer.parseInt(x), Integer.parseInt(y)); + } + case CANVAS: { + String width = attributes.getNamedItem("width").getNodeValue(); + String height = attributes.getNamedItem("height").getNodeValue(); + return new FileStoredPngMapleCanvas(Integer.parseInt(width), Integer.parseInt(height), new File( + imageDataDir, getName() + ".png")); + } + default: + return null; + } + } + + @Override + public MapleDataType getType() { + String nodeName = node.getNodeName(); + if (nodeName.equals("imgdir")) { + return MapleDataType.PROPERTY; + } else if (nodeName.equals("canvas")) { + return MapleDataType.CANVAS; + } else if (nodeName.equals("convex")) { + return MapleDataType.CONVEX; + } else if (nodeName.equals("sound")) { + return MapleDataType.SOUND; + } else if (nodeName.equals("uol")) { + return MapleDataType.UOL; + } else if (nodeName.equals("double")) { + return MapleDataType.DOUBLE; + } else if (nodeName.equals("float")) { + return MapleDataType.FLOAT; + } else if (nodeName.equals("int")) { + return MapleDataType.INT; + } else if (nodeName.equals("short")) { + return MapleDataType.SHORT; + } else if (nodeName.equals("string")) { + return MapleDataType.STRING; + } else if (nodeName.equals("vector")) { + return MapleDataType.VECTOR; + } else if (nodeName.equals("null")) { + return MapleDataType.IMG_0x00; + } + return null; + } + + @Override + public MapleDataEntity getParent() { + Node parentNode = node.getParentNode(); + if (parentNode.getNodeType() == Node.DOCUMENT_NODE) { + return null; + } + XMLDomMapleData parentData = new XMLDomMapleData(parentNode); + parentData.imageDataDir = imageDataDir.getParentFile(); + return parentData; + } + + @Override + public String getName() { + return node.getAttributes().getNamedItem("name").getNodeValue(); + } + + @Override + public Iterator iterator() { + return getChildren().iterator(); + } +} diff --git a/tools/MapleInvalidItemWithNoNameFetcher/src/provider/wz/XMLWZFile.java b/tools/MapleInvalidItemWithNoNameFetcher/src/provider/wz/XMLWZFile.java new file mode 100644 index 0000000000..2a7694fdc9 --- /dev/null +++ b/tools/MapleInvalidItemWithNoNameFetcher/src/provider/wz/XMLWZFile.java @@ -0,0 +1,85 @@ +/* + This file is part of the OdinMS Maple Story Server + Copyright (C) 2008 Patrick Huy + Matthias Butz + Jan Christian Meyer + + 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 . +*/ +package provider.wz; + +import java.io.File; +import java.io.FileInputStream; +import java.io.FileNotFoundException; +import java.io.IOException; +import provider.MapleData; +import provider.MapleDataDirectoryEntry; +import provider.MapleDataProvider; + +public class XMLWZFile implements MapleDataProvider { + private File root; + private WZDirectoryEntry rootForNavigation; + + public XMLWZFile(File fileIn) { + root = fileIn; + rootForNavigation = new WZDirectoryEntry(fileIn.getName(), 0, 0, null); + fillMapleDataEntitys(root, rootForNavigation); + } + + private void fillMapleDataEntitys(File lroot, WZDirectoryEntry wzdir) { + for (File file : lroot.listFiles()) { + String fileName = file.getName(); + if (file.isDirectory() && !fileName.endsWith(".img")) { + WZDirectoryEntry newDir = new WZDirectoryEntry(fileName, 0, 0, wzdir); + wzdir.addDirectory(newDir); + fillMapleDataEntitys(file, newDir); + } else if (fileName.endsWith(".xml")) { + wzdir.addFile(new WZFileEntry(fileName.substring(0, fileName.length() - 4), 0, 0, wzdir)); + } + } + } + + @Override + public MapleData getData(String path) { + File dataFile = new File(root, path + ".xml"); + File imageDataDir = new File(root, path); + if (!dataFile.exists()) { + return null;//bitches + } + FileInputStream fis; + try { + fis = new FileInputStream(dataFile); + } catch (FileNotFoundException e) { + throw new RuntimeException("Datafile " + path + " does not exist in " + root.getAbsolutePath()); + } + final XMLDomMapleData domMapleData; + try { + domMapleData = new XMLDomMapleData(fis, imageDataDir.getParentFile()); + } finally { + try { + fis.close(); + } catch (IOException e) { + throw new RuntimeException(e); + } + } + return domMapleData; + } + + @Override + public MapleDataDirectoryEntry getRoot() { + return rootForNavigation; + } +} diff --git a/tools/MapleInvalidItemWithNoNameFetcher/src/tools/DatabaseConnection.java b/tools/MapleInvalidItemWithNoNameFetcher/src/tools/DatabaseConnection.java new file mode 100644 index 0000000000..9dcd4e6545 --- /dev/null +++ b/tools/MapleInvalidItemWithNoNameFetcher/src/tools/DatabaseConnection.java @@ -0,0 +1,51 @@ +package tools; + +import java.sql.Connection; +import java.sql.DriverManager; +import java.sql.SQLException; + +/** + * @author Frz (Big Daddy) + * @author The Real Spookster (some modifications to this beautiful code) + */ +public class DatabaseConnection { + private static String DB_URL = "jdbc:mysql://localhost:3306/heavenms"; + private static String DB_USER = "root"; + private static String DB_PASS = ""; + + public static final int RETURN_GENERATED_KEYS = 1; + + private static ThreadLocal con = new ThreadLocalConnection(); + + public static Connection getConnection() { + Connection c = con.get(); + try { + c.getMetaData(); + } catch (SQLException e) { // connection is dead, therefore discard old object 5ever + con.remove(); + c = con.get(); + } + return c; + } + + private static class ThreadLocalConnection extends ThreadLocal { + + @Override + protected Connection initialValue() { + try { + Class.forName("com.mysql.jdbc.Driver"); // touch the mysql driver + } catch (ClassNotFoundException e) { + System.out.println("[SEVERE] SQL Driver Not Found. Consider death by clams."); + e.printStackTrace(); + return null; + } + try { + return DriverManager.getConnection(DB_URL, DB_USER, DB_PASS); + } catch (SQLException e) { + System.out.println("[SEVERE] Unable to make database connection."); + e.printStackTrace(); + return null; + } + } + } +} \ No newline at end of file diff --git a/tools/MapleInvalidItemWithNoNameFetcher/src/tools/HexTool.java b/tools/MapleInvalidItemWithNoNameFetcher/src/tools/HexTool.java new file mode 100644 index 0000000000..8cc0c8aa84 --- /dev/null +++ b/tools/MapleInvalidItemWithNoNameFetcher/src/tools/HexTool.java @@ -0,0 +1,79 @@ +/* + This file is part of the OdinMS Maple Story Server + Copyright (C) 2008 Patrick Huy + Matthias Butz + Jan Christian Meyer + + 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 . +*/ +package tools; + +import java.io.ByteArrayOutputStream; + +public class HexTool { + private static final char[] HEX = {'0', '1', '2', '3', '4', '5', '6', '7', '8', '9', 'A', 'B', 'C', 'D', 'E', 'F'}; + + private static String toString(byte byteValue) { + int tmp = byteValue << 8; + char[] retstr = new char[]{HEX[(tmp >> 12) & 0x0F], HEX[(tmp >> 8) & 0x0F]}; + return String.valueOf(retstr); + } + + public static String toString(byte[] bytes) { + StringBuilder hexed = new StringBuilder(); + for (int i = 0; i < bytes.length; i++) { + hexed.append(toString(bytes[i])); + hexed.append(' '); + } + return hexed.substring(0, hexed.length() - 1); + } + + public static byte[] getByteArrayFromHexString(String hex) { + ByteArrayOutputStream baos = new ByteArrayOutputStream(); + int nexti = 0; + int nextb = 0; + boolean highoc = true; + outer: + for (;;) { + int number = -1; + while (number == -1) { + if (nexti == hex.length()) { + break outer; + } + char chr = hex.charAt(nexti); + if (chr >= '0' && chr <= '9') { + number = chr - '0'; + } else if (chr >= 'a' && chr <= 'f') { + number = chr - 'a' + 10; + } else if (chr >= 'A' && chr <= 'F') { + number = chr - 'A' + 10; + } else { + number = -1; + } + nexti++; + } + if (highoc) { + nextb = number << 4; + highoc = false; + } else { + nextb |= number; + highoc = true; + baos.write(nextb); + } + } + return baos.toByteArray(); + } +} diff --git a/tools/MapleInvalidItemWithNoNameFetcher/src/tools/Pair.java b/tools/MapleInvalidItemWithNoNameFetcher/src/tools/Pair.java new file mode 100644 index 0000000000..f88718cbe3 --- /dev/null +++ b/tools/MapleInvalidItemWithNoNameFetcher/src/tools/Pair.java @@ -0,0 +1,121 @@ +/* +This file is part of the OdinMS Maple Story Server +Copyright (C) 2008 ~ 2010 Patrick Huy +Matthias Butz +Jan Christian Meyer + +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 +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 . + */ +package tools; + +/** + * Represents a pair of values. + * + * @author Frz + * @since Revision 333 + * @version 1.0 + * + * @param The type of the left value. + * @param The type of the right value. + */ +public class Pair { + + public E left; + public F right; + + /** + * Class constructor - pairs two objects together. + * + * @param left The left object. + * @param right The right object. + */ + public Pair(E left, F right) { + this.left = left; + this.right = right; + } + + /** + * Gets the left value. + * + * @return The left value. + */ + public E getLeft() { + return left; + } + + /** + * Gets the right value. + * + * @return The right value. + */ + public F getRight() { + return right; + } + + /** + * Turns the pair into a string. + * + * @return Each value of the pair as a string joined by a colon. + */ + @Override + public String toString() { + return left.toString() + ":" + right.toString(); + } + + /** + * Gets the hash code of this pair. + */ + @Override + public int hashCode() { + final int prime = 31; + int result = 1; + result = prime * result + ((left == null) ? 0 : left.hashCode()); + result = prime * result + ((right == null) ? 0 : right.hashCode()); + return result; + } + + /** + * Checks to see if two pairs are equal. + */ + @SuppressWarnings("unchecked") + @Override + public boolean equals(Object obj) { + if (this == obj) { + return true; + } + if (obj == null) { + return false; + } + if (getClass() != obj.getClass()) { + return false; + } + final Pair other = (Pair) obj; + if (left == null) { + if (other.left != null) { + return false; + } + } else if (!left.equals(other.left)) { + return false; + } + if (right == null) { + if (other.right != null) { + return false; + } + } else if (!right.equals(other.right)) { + return false; + } + return true; + } +} \ No newline at end of file diff --git a/tools/MapleInvalidItemWithNoNameFetcher/src/tools/data/input/ByteArrayByteStream.java b/tools/MapleInvalidItemWithNoNameFetcher/src/tools/data/input/ByteArrayByteStream.java new file mode 100644 index 0000000000..eac7de21ea --- /dev/null +++ b/tools/MapleInvalidItemWithNoNameFetcher/src/tools/data/input/ByteArrayByteStream.java @@ -0,0 +1,72 @@ +/* + This file is part of the OdinMS Maple Story Server + Copyright (C) 2008 Patrick Huy + Matthias Butz + Jan Christian Meyer + + 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 . +*/ +package tools.data.input; + +import java.io.IOException; +import tools.HexTool; + +public class ByteArrayByteStream implements SeekableInputStreamBytestream { + private int pos = 0; + private long bytesRead = 0; + private byte[] arr; + + public ByteArrayByteStream(byte[] arr) { + this.arr = arr; + } + + @Override + public long getPosition() { + return pos; + } + + @Override + public void seek(long offset) throws IOException { + pos = (int) offset; + } + + @Override + public long getBytesRead() { + return bytesRead; + } + + @Override + public int readByte() { + bytesRead++; + return ((int) arr[pos++]) & 0xFF; + } + + @Override + public String toString() { + String nows = "kevintjuh93 pwns";//I lol'd + if (arr.length - pos > 0) { + byte[] now = new byte[arr.length - pos]; + System.arraycopy(arr, pos, now, 0, arr.length - pos); + nows = HexTool.toString(now); + } + return "All: " + HexTool.toString(arr) + "\nNow: " + nows; + } + + @Override + public long available() { + return arr.length - pos; + } +} diff --git a/tools/MapleInvalidItemWithNoNameFetcher/src/tools/data/input/ByteInputStream.java b/tools/MapleInvalidItemWithNoNameFetcher/src/tools/data/input/ByteInputStream.java new file mode 100644 index 0000000000..107f71843e --- /dev/null +++ b/tools/MapleInvalidItemWithNoNameFetcher/src/tools/data/input/ByteInputStream.java @@ -0,0 +1,35 @@ +/* + This file is part of the OdinMS Maple Story Server + Copyright (C) 2008 Patrick Huy + Matthias Butz + Jan Christian Meyer + + 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 . +*/ +package tools.data.input; + +/** + * Represents an abstract stream of bytes. + * + * @author Frz + * @version 1.0 + * @since Revision 323 + */ +public interface ByteInputStream { + int readByte(); + long getBytesRead(); + long available(); +} diff --git a/tools/MapleInvalidItemWithNoNameFetcher/src/tools/data/input/GenericLittleEndianAccessor.java b/tools/MapleInvalidItemWithNoNameFetcher/src/tools/data/input/GenericLittleEndianAccessor.java new file mode 100644 index 0000000000..d08a9b8374 --- /dev/null +++ b/tools/MapleInvalidItemWithNoNameFetcher/src/tools/data/input/GenericLittleEndianAccessor.java @@ -0,0 +1,239 @@ +/* + This file is part of the OdinMS Maple Story Server + Copyright (C) 2008 Patrick Huy + Matthias Butz + Jan Christian Meyer + + 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 . +*/ +package tools.data.input; + +import java.awt.Point; +import java.io.ByteArrayOutputStream; + +/** + * Provides a generic interface to a Little Endian stream of bytes. + * + * @version 1.0 + * @author Frz + * @since Revision 323 + */ +public class GenericLittleEndianAccessor implements LittleEndianAccessor { + private ByteInputStream bs; + + /** + * Class constructor - Wraps the accessor around a stream of bytes. + * + * @param bs The byte stream to wrap the accessor around. + */ + public GenericLittleEndianAccessor(ByteInputStream bs) { + this.bs = bs; + } + + /** + * Read a single byte from the stream. + * + * @return The byte read. + * @see tools.data.input.ByteInputStream#readByte + */ + @Override + public byte readByte() { + return (byte) bs.readByte(); + } + + /** + * Reads an integer from the stream. + * + * @return The integer read. + */ + @Override + public int readInt() { + return bs.readByte() + (bs.readByte() << 8) + (bs.readByte() << 16) + (bs.readByte() << 24); + } + + /** + * Reads a short integer from the stream. + * + * @return The short read. + */ + @Override + public short readShort() { + return (short) (bs.readByte() + (bs.readByte() << 8)); + } + + /** + * Reads a single character from the stream. + * + * @return The character read. + */ + @Override + public char readChar() { + return (char) readShort(); + } + + /** + * Reads a long integer from the stream. + * + * @return The long integer read. + */ + @Override + public long readLong() { + long byte1 = bs.readByte(); + long byte2 = bs.readByte(); + long byte3 = bs.readByte(); + long byte4 = bs.readByte(); + long byte5 = bs.readByte(); + long byte6 = bs.readByte(); + long byte7 = bs.readByte(); + long byte8 = bs.readByte(); + return (byte8 << 56) + (byte7 << 48) + (byte6 << 40) + (byte5 << 32) + (byte4 << 24) + (byte3 << 16) + (byte2 << 8) + byte1; + } + + /** + * Reads a floating point integer from the stream. + * + * @return The float-type integer read. + */ + @Override + public float readFloat() { + return Float.intBitsToFloat(readInt()); + } + + /** + * Reads a double-precision integer from the stream. + * + * @return The double-type integer read. + */ + @Override + public double readDouble() { + return Double.longBitsToDouble(readLong()); + } + + /** + * Reads an ASCII string from the stream with length n. + * + * @param n Number of characters to read. + * @return The string read. + */ + public final String readAsciiString(int n) { + char ret[] = new char[n]; + for (int x = 0; x < n; x++) { + ret[x] = (char) readByte(); + } + return String.valueOf(ret); + } + + /** + * Reads a null-terminated string from the stream. + * + * @return The string read. + */ + public final String readNullTerminatedAsciiString() { + ByteArrayOutputStream baos = new ByteArrayOutputStream(); + byte b; + while (true) { + b = readByte(); + if (b == 0) { + break; + } + baos.write(b); + } + byte[] buf = baos.toByteArray(); + char[] chrBuf = new char[buf.length]; + for (int x = 0; x < buf.length; x++) { + chrBuf[x] = (char) buf[x]; + } + return String.valueOf(chrBuf); + } + + /** + * Gets the number of bytes read from the stream so far. + * + * @return A long integer representing the number of bytes read. + * @see tools.data.input.ByteInputStream#getBytesRead() + */ + public long getBytesRead() { + return bs.getBytesRead(); + } + + /** + * Reads a MapleStory convention lengthed ASCII string. + * This consists of a short integer telling the length of the string, + * then the string itself. + * + * @return The string read. + */ + @Override + public String readMapleAsciiString() { + return readAsciiString(readShort()); + } + + /** + * Reads num bytes off the stream. + * + * @param num The number of bytes to read. + * @return An array of bytes with the length of num + */ + @Override + public byte[] read(int num) { + byte[] ret = new byte[num]; + for (int x = 0; x < num; x++) { + ret[x] = readByte(); + } + return ret; + } + + /** + * Reads a MapleStory Position information. + * This consists of 2 short integer. + * + * @return The Position read. + */ + @Override + public final Point readPos() { + final int x = readShort(); + final int y = readShort(); + return new Point(x, y); + } + + /** + * Skips the current position of the stream num bytes ahead. + * + * @param num Number of bytes to skip. + */ + @Override + public void skip(int num) { + for (int x = 0; x < num; x++) { + readByte(); + } + } + + /** + * @see tools.data.input.ByteInputStream#available + */ + @Override + public long available() { + return bs.available(); + } + + /** + * @see java.lang.Object#toString + */ + @Override + public String toString() { + return bs.toString(); + } +} \ No newline at end of file diff --git a/tools/MapleInvalidItemWithNoNameFetcher/src/tools/data/input/GenericSeekableLittleEndianAccessor.java b/tools/MapleInvalidItemWithNoNameFetcher/src/tools/data/input/GenericSeekableLittleEndianAccessor.java new file mode 100644 index 0000000000..fdd147d796 --- /dev/null +++ b/tools/MapleInvalidItemWithNoNameFetcher/src/tools/data/input/GenericSeekableLittleEndianAccessor.java @@ -0,0 +1,91 @@ +/* + This file is part of the OdinMS Maple Story Server + Copyright (C) 2008 Patrick Huy + Matthias Butz + Jan Christian Meyer + + 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 . +*/ +package tools.data.input; + +import java.io.IOException; + +/** + * Provides an abstract accessor to a generic Little Endian byte stream. This + * accessor is seekable. + * + * @author Frz + * @version 1.0 + * @since Revision 323 + * @see tools.data.input.GenericLittleEndianAccessor + */ +public class GenericSeekableLittleEndianAccessor extends GenericLittleEndianAccessor implements SeekableLittleEndianAccessor { + private SeekableInputStreamBytestream bs; + + /** + * Class constructor + * Provide a seekable input stream to wrap this object around. + * + * @param bs The byte stream to wrap this around. + */ + public GenericSeekableLittleEndianAccessor(SeekableInputStreamBytestream bs) { + super(bs); + this.bs = bs; + } + + /** + * Seek the pointer to offset + * + * @param offset The offset to seek to. + * @see tools.data.input.SeekableInputStreamBytestream#seek + */ + @Override + public void seek(long offset) { + try { + bs.seek(offset); + } catch (IOException e) { + e.printStackTrace(); + System.out.println("Seek failed " + e); + } + } + + /** + * Get the current position of the pointer. + * + * @return The current position of the pointer as a long integer. + * @see tools.data.input.SeekableInputStreamBytestream#getPosition + */ + @Override + public long getPosition() { + try { + return bs.getPosition(); + } catch (IOException e) { + e.printStackTrace(); + System.out.println("getPosition failed" + e); + return -1; + } + } + + /** + * Skip num number of bytes in the stream. + * + * @param num The number of bytes to skip. + */ + @Override + public void skip(int num) { + seek(getPosition() + num); + } +} diff --git a/tools/MapleInvalidItemWithNoNameFetcher/src/tools/data/input/InputStreamByteStream.java b/tools/MapleInvalidItemWithNoNameFetcher/src/tools/data/input/InputStreamByteStream.java new file mode 100644 index 0000000000..70aef3489f --- /dev/null +++ b/tools/MapleInvalidItemWithNoNameFetcher/src/tools/data/input/InputStreamByteStream.java @@ -0,0 +1,93 @@ +/* + This file is part of the OdinMS Maple Story Server + Copyright (C) 2008 Patrick Huy + Matthias Butz + Jan Christian Meyer + + 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 . +*/ +package tools.data.input; + +import java.io.IOException; +import java.io.InputStream; + +/** + * Provides an abstract wrapper to a stream of bytes. + * + * @author Frz + * @version 1.0 + * @since Revision 323 + */ +public class InputStreamByteStream implements ByteInputStream { + private InputStream is; + private long read = 0; + + /** + * Class constructor. + * Provide an input stream to wrap this around. + * + * @param is The input stream to wrap this object around. + */ + public InputStreamByteStream(InputStream is) { + this.is = is; + } + + /** + * Reads the next byte from the stream. + * + * @return Then next byte in the stream. + */ + @Override + public int readByte() { + int temp; + try { + temp = is.read(); + if (temp == -1) { + throw new RuntimeException("EOF"); + } + read++; + return temp; + } catch (IOException e) { + throw new RuntimeException(e); + } + } + + /** + * Gets the number of bytes read from the stream. + * + * @return The number of bytes read as a long integer. + */ + @Override + public long getBytesRead() { + return read; + } + + /** + * Returns the number of bytes left in the stream. + * + * @return The number of bytes available for reading as a long integer. + */ + @Override + public long available() { + try { + return is.available(); + } catch (IOException e) { + e.printStackTrace(); + System.out.println("ERROR" + e); + return 0; + } + } +} diff --git a/tools/MapleInvalidItemWithNoNameFetcher/src/tools/data/input/LittleEndianAccessor.java b/tools/MapleInvalidItemWithNoNameFetcher/src/tools/data/input/LittleEndianAccessor.java new file mode 100644 index 0000000000..f991dbf537 --- /dev/null +++ b/tools/MapleInvalidItemWithNoNameFetcher/src/tools/data/input/LittleEndianAccessor.java @@ -0,0 +1,45 @@ +/* + This file is part of the OdinMS Maple Story Server + Copyright (C) 2008 Patrick Huy + Matthias Butz + Jan Christian Meyer + + 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 . +*/ +package tools.data.input; + +import java.awt.Point; + +/** + * @author Frz + */ +public interface LittleEndianAccessor { + byte readByte(); + char readChar(); + short readShort(); + int readInt(); + Point readPos(); + long readLong(); + void skip(int num); + byte[] read(int num); + float readFloat(); + double readDouble(); + String readAsciiString(int n); + String readNullTerminatedAsciiString(); + String readMapleAsciiString(); + long getBytesRead(); + long available(); +} diff --git a/tools/MapleInvalidItemWithNoNameFetcher/src/tools/data/input/RandomAccessByteStream.java b/tools/MapleInvalidItemWithNoNameFetcher/src/tools/data/input/RandomAccessByteStream.java new file mode 100644 index 0000000000..c0004be17f --- /dev/null +++ b/tools/MapleInvalidItemWithNoNameFetcher/src/tools/data/input/RandomAccessByteStream.java @@ -0,0 +1,84 @@ +/* + This file is part of the OdinMS Maple Story Server + Copyright (C) 2008 Patrick Huy + Matthias Butz + Jan Christian Meyer + + 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 . +*/ +package tools.data.input; + +import java.io.IOException; +import java.io.RandomAccessFile; + +/** + * Provides an abstract layer to a byte stream. This layer can be accessed + * randomly. + * + * @author Frz + * @version 1.0 + * @since Revision 323 + */ +public class RandomAccessByteStream implements SeekableInputStreamBytestream { + private RandomAccessFile raf; + private long read = 0; + + public RandomAccessByteStream(RandomAccessFile raf) { + super(); + this.raf = raf; + } + + @Override + public int readByte() { + int temp; + try { + temp = raf.read(); + if (temp == -1) { + throw new RuntimeException("EOF"); + } + read++; + return temp; + } catch (IOException e) { + throw new RuntimeException(e); + } + } + + @Override + public void seek(long offset) throws IOException { + raf.seek(offset); + } + + @Override + public long getPosition() throws IOException { + return raf.getFilePointer(); + } + + @Override + public long getBytesRead() { + return read; + } + + @Override + public long available() { + try { + return raf.length() - raf.getFilePointer(); + } catch (IOException e) { + e.printStackTrace(); + System.out.println("ERROR " + e); + return 0; + } + } +} diff --git a/tools/MapleInvalidItemWithNoNameFetcher/src/tools/data/input/SeekableInputStreamBytestream.java b/tools/MapleInvalidItemWithNoNameFetcher/src/tools/data/input/SeekableInputStreamBytestream.java new file mode 100644 index 0000000000..f4922dc876 --- /dev/null +++ b/tools/MapleInvalidItemWithNoNameFetcher/src/tools/data/input/SeekableInputStreamBytestream.java @@ -0,0 +1,51 @@ +/* + This file is part of the OdinMS Maple Story Server + Copyright (C) 2008 Patrick Huy + Matthias Butz + Jan Christian Meyer + + 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 . +*/ +package tools.data.input; + +import java.io.IOException; + +/** + * Provides an abstract interface to a stream of bytes. This stream can be + * seeked. + * + * @author Frz + * @version 1.0 + * @since 299 + */ +public interface SeekableInputStreamBytestream extends ByteInputStream { + /** + * Seeks the stream by the specified offset. + * + * @param offset + * Number of bytes to seek. + * @throws IOException + */ + void seek(long offset) throws IOException; + + /** + * Gets the current position of the stream. + * + * @return The stream position as a long integer. + * @throws IOException + */ + long getPosition() throws IOException; +} diff --git a/tools/MapleInvalidItemWithNoNameFetcher/src/tools/data/input/SeekableLittleEndianAccessor.java b/tools/MapleInvalidItemWithNoNameFetcher/src/tools/data/input/SeekableLittleEndianAccessor.java new file mode 100644 index 0000000000..16b2317f7a --- /dev/null +++ b/tools/MapleInvalidItemWithNoNameFetcher/src/tools/data/input/SeekableLittleEndianAccessor.java @@ -0,0 +1,27 @@ +/* + This file is part of the OdinMS Maple Story Server + Copyright (C) 2008 Patrick Huy + Matthias Butz + Jan Christian Meyer + + 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 . +*/ +package tools.data.input; + +public interface SeekableLittleEndianAccessor extends LittleEndianAccessor { + void seek(long offset); + long getPosition(); +} diff --git a/tools/MapleInvalidItemWithNoNameFetcher/src/tools/data/output/BAOSByteOutputStream.java b/tools/MapleInvalidItemWithNoNameFetcher/src/tools/data/output/BAOSByteOutputStream.java new file mode 100644 index 0000000000..80cbc9301e --- /dev/null +++ b/tools/MapleInvalidItemWithNoNameFetcher/src/tools/data/output/BAOSByteOutputStream.java @@ -0,0 +1,56 @@ +/* + This file is part of the OdinMS Maple Story Server + Copyright (C) 2008 Patrick Huy + Matthias Butz + Jan Christian Meyer + + 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 . +*/ +package tools.data.output; + +import java.io.ByteArrayOutputStream; + +/** + * Uses a byte array to output a stream of bytes. + * + * @author Frz + * @version 1.0 + * @since Revision 352 + */ +class BAOSByteOutputStream implements ByteOutputStream { + private ByteArrayOutputStream baos; + + /** + * Class constructor - Wraps the stream around a Java BAOS. + * + * @param baos The ByteArrayOutputStream to wrap this around. + */ + BAOSByteOutputStream(ByteArrayOutputStream baos) { + super(); + this.baos = baos; + } + + /** + * Writes a byte to the stream. + * + * @param b The byte to write to the stream. + * @see tools.data.output.ByteOutputStream#writeByte(byte) + */ + @Override + public void writeByte(byte b) { + baos.write(b); + } +} diff --git a/tools/MapleInvalidItemWithNoNameFetcher/src/tools/data/output/ByteOutputStream.java b/tools/MapleInvalidItemWithNoNameFetcher/src/tools/data/output/ByteOutputStream.java new file mode 100644 index 0000000000..0df7ca7753 --- /dev/null +++ b/tools/MapleInvalidItemWithNoNameFetcher/src/tools/data/output/ByteOutputStream.java @@ -0,0 +1,38 @@ +/* + This file is part of the OdinMS Maple Story Server + Copyright (C) 2008 Patrick Huy + Matthias Butz + Jan Christian Meyer + + 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 . +*/ +package tools.data.output; + +/** + * Provides an interface to an output stream of bytes. + * + * @author Frz + * @since Revision 323 + * @version 1.0 + */ +interface ByteOutputStream { + /** + * Writes a byte to the stream. + * + * @param b The byte to write. + */ + void writeByte(byte b); +} diff --git a/tools/MapleInvalidItemWithNoNameFetcher/src/tools/data/output/GenericLittleEndianWriter.java b/tools/MapleInvalidItemWithNoNameFetcher/src/tools/data/output/GenericLittleEndianWriter.java new file mode 100644 index 0000000000..e804fd8000 --- /dev/null +++ b/tools/MapleInvalidItemWithNoNameFetcher/src/tools/data/output/GenericLittleEndianWriter.java @@ -0,0 +1,183 @@ +/* + This file is part of the OdinMS Maple Story Server + Copyright (C) 2008 Patrick Huy + Matthias Butz + Jan Christian Meyer + + 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 . +*/ +package tools.data.output; + +import java.awt.Point; +import java.nio.charset.Charset; + +/** + * Provides a generic writer of a little-endian sequence of bytes. + * + * @author Frz + * @version 1.0 + * @since Revision 323 + */ +public class GenericLittleEndianWriter implements LittleEndianWriter { + private static Charset ASCII = Charset.forName("US-ASCII"); + private ByteOutputStream bos; + + /** + * Class constructor - Protected to prevent instantiation with no arguments. + */ + protected GenericLittleEndianWriter() { + // Blah! + } + + /** + * Sets the byte-output stream for this instance of the object. + * + * @param bos The new output stream to set. + */ + void setByteOutputStream(ByteOutputStream bos) { + this.bos = bos; + } + + /** + * Write an array of bytes to the stream. + * + * @param b The bytes to write. + */ + @Override + public void write(byte[] b) { + for (int x = 0; x < b.length; x++) { + bos.writeByte(b[x]); + } + } + + /** + * Write a byte to the stream. + * + * @param b The byte to write. + */ + @Override + public void write(byte b) { + bos.writeByte(b); + } + + /** + * Write a byte in integer form to the stream. + * + * @param b The byte as an Integer to write. + */ + @Override + public void write(int b) { + bos.writeByte((byte) b); + } + + @Override + public void skip(int b) { + write(new byte[b]); + } + + /** + * Write a short integer to the stream. + * + * @param i The short integer to write. + */ + @Override + public void writeShort(int i) { + bos.writeByte((byte) (i & 0xFF)); + bos.writeByte((byte) ((i >>> 8) & 0xFF)); + } + + /** + * Writes an integer to the stream. + * + * @param i The integer to write. + */ + @Override + public void writeInt(int i) { + bos.writeByte((byte) (i & 0xFF)); + bos.writeByte((byte) ((i >>> 8) & 0xFF)); + bos.writeByte((byte) ((i >>> 16) & 0xFF)); + bos.writeByte((byte) ((i >>> 24) & 0xFF)); + } + + /** + * Writes an ASCII string the the stream. + * + * @param s The ASCII string to write. + */ + @Override + public void writeAsciiString(String s) { + write(s.getBytes(ASCII)); + } + + /** + * Writes a maple-convention ASCII string to the stream. + * + * @param s The ASCII string to use maple-convention to write. + */ + @Override + public void writeMapleAsciiString(String s) { + writeShort((short) s.length()); + writeAsciiString(s); + } + + /** + * Writes a null-terminated ASCII string to the stream. + * + * @param s The ASCII string to write. + */ + @Override + public void writeNullTerminatedAsciiString(String s) { + writeAsciiString(s); + write(0); + } + + /** + * Write a long integer to the stream. + * @param l The long integer to write. + */ + @Override + public void writeLong(long l) { + bos.writeByte((byte) (l & 0xFF)); + bos.writeByte((byte) ((l >>> 8) & 0xFF)); + bos.writeByte((byte) ((l >>> 16) & 0xFF)); + bos.writeByte((byte) ((l >>> 24) & 0xFF)); + bos.writeByte((byte) ((l >>> 32) & 0xFF)); + bos.writeByte((byte) ((l >>> 40) & 0xFF)); + bos.writeByte((byte) ((l >>> 48) & 0xFF)); + bos.writeByte((byte) ((l >>> 56) & 0xFF)); + } + + /** + * Writes a 2D 4 byte position information + * + * @param s The Point position to write. + */ + @Override + public void writePos(Point s) { + writeShort(s.x); + writeShort(s.y); + } + + /** + * Writes a boolean true ? 1 : 0 + * + * @param b The boolean to write. + */ + @Override + public void writeBool(final boolean b) { + write(b ? 1 : 0); + } +} diff --git a/tools/MapleInvalidItemWithNoNameFetcher/src/tools/data/output/LittleEndianWriter.java b/tools/MapleInvalidItemWithNoNameFetcher/src/tools/data/output/LittleEndianWriter.java new file mode 100644 index 0000000000..f17bd7c72e --- /dev/null +++ b/tools/MapleInvalidItemWithNoNameFetcher/src/tools/data/output/LittleEndianWriter.java @@ -0,0 +1,114 @@ +/* + This file is part of the OdinMS Maple Story Server + Copyright (C) 2008 Patrick Huy + Matthias Butz + Jan Christian Meyer + + 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 . + */ +package tools.data.output; + +import java.awt.Point; + +/** + * Provides an interface to a writer class that writes a little-endian sequence + * of bytes. + * + * @author Frz + * @version 1.0 + * @since Revision 323 + */ +public interface LittleEndianWriter { + + /** + * Write an array of bytes to the sequence. + * + * @param b The bytes to write. + */ + public void write(byte b[]); + + /** + * Write a byte to the sequence. + * + * @param b The byte to write. + */ + public void write(byte b); + + /** + * Write a byte in integer form to the sequence. + * + * @param b The byte as an Integer to write. + */ + public void write(int b); + + public void skip(int b); + + /** + * Writes an integer to the sequence. + * + * @param i The integer to write. + */ + public void writeInt(int i); + + /** + * Write a short integer to the sequence. + * + * @param s The short integer to write. + */ + public void writeShort(int s); + + /** + * Write a long integer to the sequence. + * + * @param l The long integer to write. + */ + public void writeLong(long l); + + /** + * Writes an ASCII string the the sequence. + * + * @param s The ASCII string to write. + */ + void writeAsciiString(String s); + + /** + * Writes a null-terminated ASCII string to the sequence. + * + * @param s The ASCII string to write. + */ + void writeNullTerminatedAsciiString(String s); + + /** + * Writes a maple-convention ASCII string to the sequence. + * + * @param s The ASCII string to use maple-convention to write. + */ + void writeMapleAsciiString(String s); + + /** + * Writes a 2D 4 byte position information + * + * @param s The Point position to write. + */ + void writePos(Point s); + + /** + * Writes a boolean true ? 1 : 0 + * + * @param b The boolean to write. + */ + void writeBool(final boolean b); +} diff --git a/tools/MapleInvalidItemWithNoNameFetcher/src/tools/data/output/MaplePacketLittleEndianWriter.java b/tools/MapleInvalidItemWithNoNameFetcher/src/tools/data/output/MaplePacketLittleEndianWriter.java new file mode 100644 index 0000000000..b02365ec62 --- /dev/null +++ b/tools/MapleInvalidItemWithNoNameFetcher/src/tools/data/output/MaplePacketLittleEndianWriter.java @@ -0,0 +1,73 @@ +/* + This file is part of the OdinMS Maple Story Server + Copyright (C) 2008 Patrick Huy + Matthias Butz + Jan Christian Meyer + + 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 . +*/ +package tools.data.output; + +import java.io.ByteArrayOutputStream; +import tools.HexTool; + +/** + * Writes a maplestory-packet little-endian stream of bytes. + * + * @author Frz + * @version 1.0 + * @since Revision 352 + */ +public class MaplePacketLittleEndianWriter extends GenericLittleEndianWriter { + private ByteArrayOutputStream baos; + + /** + * Constructor - initializes this stream with a default size. + */ + public MaplePacketLittleEndianWriter() { + this(32); + } + + /** + * Constructor - initializes this stream with size size. + * + * @param size The size of the underlying stream. + */ + public MaplePacketLittleEndianWriter(int size) { + this.baos = new ByteArrayOutputStream(size); + setByteOutputStream(new BAOSByteOutputStream(baos)); + } + + /** + * Gets a MaplePacket instance representing this + * sequence of bytes. + * + * @return A MaplePacket with the bytes in this stream. + */ + public byte[] getPacket() { + return baos.toByteArray(); + } + + /** + * Changes this packet into a human-readable hexadecimal stream of bytes. + * + * @return This packet as hex digits. + */ + @Override + public String toString() { + return HexTool.toString(baos.toByteArray()); + } +} diff --git a/tools/MapleQuestItemFetcher/nbproject/private/private.xml b/tools/MapleQuestItemFetcher/nbproject/private/private.xml index 6807a2ba19..531edc4876 100644 --- a/tools/MapleQuestItemFetcher/nbproject/private/private.xml +++ b/tools/MapleQuestItemFetcher/nbproject/private/private.xml @@ -2,6 +2,8 @@ - + + file:/C:/Nexon/MapleSolaxia/HeavenMS/tools/MapleQuestItemFetcher/src/maplequestitemfetcher/MapleQuestItemFetcher.java + diff --git a/tools/MapleQuestItemFetcher/src/maplequestitemfetcher/MapleQuestItemFetcher.java b/tools/MapleQuestItemFetcher/src/maplequestitemfetcher/MapleQuestItemFetcher.java index 9b69103142..2efca3a613 100644 --- a/tools/MapleQuestItemFetcher/src/maplequestitemfetcher/MapleQuestItemFetcher.java +++ b/tools/MapleQuestItemFetcher/src/maplequestitemfetcher/MapleQuestItemFetcher.java @@ -39,7 +39,6 @@ import java.util.HashMap; import java.util.HashSet; import java.util.Map; import java.util.Map.Entry; -import java.util.Scanner; import java.util.Set; import org.apache.commons.io.FileUtils; diff --git a/wz/Character.wz/Accessory/01012011.img.xml b/wz/Character.wz/Accessory/01012011.img.xml index d642cc32e3..7992767aaf 100644 --- a/wz/Character.wz/Accessory/01012011.img.xml +++ b/wz/Character.wz/Accessory/01012011.img.xml @@ -18,6 +18,7 @@ + diff --git a/wz/Character.wz/Accessory/01012012.img.xml b/wz/Character.wz/Accessory/01012012.img.xml index d8d3724e0c..758dd2ae48 100644 --- a/wz/Character.wz/Accessory/01012012.img.xml +++ b/wz/Character.wz/Accessory/01012012.img.xml @@ -18,6 +18,7 @@ + diff --git a/wz/Character.wz/Accessory/01012013.img.xml b/wz/Character.wz/Accessory/01012013.img.xml index 83cde93c6a..e2d28ac925 100644 --- a/wz/Character.wz/Accessory/01012013.img.xml +++ b/wz/Character.wz/Accessory/01012013.img.xml @@ -18,6 +18,7 @@ + diff --git a/wz/Character.wz/Accessory/01012014.img.xml b/wz/Character.wz/Accessory/01012014.img.xml index cfe0f48e1f..30738a5770 100644 --- a/wz/Character.wz/Accessory/01012014.img.xml +++ b/wz/Character.wz/Accessory/01012014.img.xml @@ -18,6 +18,7 @@ + diff --git a/wz/Character.wz/Accessory/01012015.img.xml b/wz/Character.wz/Accessory/01012015.img.xml index c41dc12056..35c69a9008 100644 --- a/wz/Character.wz/Accessory/01012015.img.xml +++ b/wz/Character.wz/Accessory/01012015.img.xml @@ -18,6 +18,7 @@ + diff --git a/wz/Character.wz/Accessory/01012016.img.xml b/wz/Character.wz/Accessory/01012016.img.xml index bcacc0abdb..6cd9382cb1 100644 --- a/wz/Character.wz/Accessory/01012016.img.xml +++ b/wz/Character.wz/Accessory/01012016.img.xml @@ -18,6 +18,7 @@ + diff --git a/wz/Character.wz/Accessory/01012017.img.xml b/wz/Character.wz/Accessory/01012017.img.xml index 0b4561925a..8dfa5d7a81 100644 --- a/wz/Character.wz/Accessory/01012017.img.xml +++ b/wz/Character.wz/Accessory/01012017.img.xml @@ -18,6 +18,7 @@ + diff --git a/wz/Character.wz/Accessory/01012018.img.xml b/wz/Character.wz/Accessory/01012018.img.xml index 8d6f0b9e0b..44445a3791 100644 --- a/wz/Character.wz/Accessory/01012018.img.xml +++ b/wz/Character.wz/Accessory/01012018.img.xml @@ -18,6 +18,7 @@ + diff --git a/wz/Character.wz/Accessory/01012019.img.xml b/wz/Character.wz/Accessory/01012019.img.xml index e5c3a161b6..41a6a3c757 100644 --- a/wz/Character.wz/Accessory/01012019.img.xml +++ b/wz/Character.wz/Accessory/01012019.img.xml @@ -18,6 +18,7 @@ + diff --git a/wz/Character.wz/Accessory/01012020.img.xml b/wz/Character.wz/Accessory/01012020.img.xml index 6eaa6aecef..4b8081bc99 100644 --- a/wz/Character.wz/Accessory/01012020.img.xml +++ b/wz/Character.wz/Accessory/01012020.img.xml @@ -18,6 +18,7 @@ + diff --git a/wz/Character.wz/Accessory/01012058.img.xml b/wz/Character.wz/Accessory/01012058.img.xml index d8735cb5ec..5a273b04fb 100644 --- a/wz/Character.wz/Accessory/01012058.img.xml +++ b/wz/Character.wz/Accessory/01012058.img.xml @@ -19,6 +19,7 @@ + diff --git a/wz/Character.wz/Accessory/01012059.img.xml b/wz/Character.wz/Accessory/01012059.img.xml index ecf5dfb0a9..8456e6fb58 100644 --- a/wz/Character.wz/Accessory/01012059.img.xml +++ b/wz/Character.wz/Accessory/01012059.img.xml @@ -19,6 +19,7 @@ + diff --git a/wz/Character.wz/Accessory/01012060.img.xml b/wz/Character.wz/Accessory/01012060.img.xml index cda1186499..1ac46f9052 100644 --- a/wz/Character.wz/Accessory/01012060.img.xml +++ b/wz/Character.wz/Accessory/01012060.img.xml @@ -19,6 +19,7 @@ + diff --git a/wz/Character.wz/Accessory/01012061.img.xml b/wz/Character.wz/Accessory/01012061.img.xml index 0495145d92..3cbe627e5c 100644 --- a/wz/Character.wz/Accessory/01012061.img.xml +++ b/wz/Character.wz/Accessory/01012061.img.xml @@ -19,6 +19,7 @@ + diff --git a/wz/Character.wz/Accessory/01012098.img.xml b/wz/Character.wz/Accessory/01012098.img.xml index f9e0108899..fed471fe19 100644 --- a/wz/Character.wz/Accessory/01012098.img.xml +++ b/wz/Character.wz/Accessory/01012098.img.xml @@ -19,6 +19,7 @@ + diff --git a/wz/Character.wz/Accessory/01012101.img.xml b/wz/Character.wz/Accessory/01012101.img.xml index ffcf13c81b..39e29f1ddf 100644 --- a/wz/Character.wz/Accessory/01012101.img.xml +++ b/wz/Character.wz/Accessory/01012101.img.xml @@ -19,6 +19,7 @@ + diff --git a/wz/Character.wz/Accessory/01012102.img.xml b/wz/Character.wz/Accessory/01012102.img.xml index 278d1add61..026e277e43 100644 --- a/wz/Character.wz/Accessory/01012102.img.xml +++ b/wz/Character.wz/Accessory/01012102.img.xml @@ -19,6 +19,7 @@ + diff --git a/wz/Character.wz/Accessory/01012103.img.xml b/wz/Character.wz/Accessory/01012103.img.xml index a195e7eaa6..d0a9eaa7eb 100644 --- a/wz/Character.wz/Accessory/01012103.img.xml +++ b/wz/Character.wz/Accessory/01012103.img.xml @@ -19,6 +19,7 @@ + diff --git a/wz/Character.wz/Accessory/01012106.img.xml b/wz/Character.wz/Accessory/01012106.img.xml index 2165cb2ae3..562fda6b5a 100644 --- a/wz/Character.wz/Accessory/01012106.img.xml +++ b/wz/Character.wz/Accessory/01012106.img.xml @@ -19,6 +19,7 @@ + diff --git a/wz/Character.wz/Accessory/01012107.img.xml b/wz/Character.wz/Accessory/01012107.img.xml index 1b65cb55ff..cad28daef4 100644 --- a/wz/Character.wz/Accessory/01012107.img.xml +++ b/wz/Character.wz/Accessory/01012107.img.xml @@ -19,6 +19,7 @@ + diff --git a/wz/Character.wz/Accessory/01012108.img.xml b/wz/Character.wz/Accessory/01012108.img.xml index d367f7ff1e..a7ab895d6e 100644 --- a/wz/Character.wz/Accessory/01012108.img.xml +++ b/wz/Character.wz/Accessory/01012108.img.xml @@ -18,6 +18,7 @@ + diff --git a/wz/Character.wz/Accessory/01012109.img.xml b/wz/Character.wz/Accessory/01012109.img.xml index d6ea74598a..6f3dc193b9 100644 --- a/wz/Character.wz/Accessory/01012109.img.xml +++ b/wz/Character.wz/Accessory/01012109.img.xml @@ -18,6 +18,7 @@ + diff --git a/wz/Character.wz/Accessory/01012110.img.xml b/wz/Character.wz/Accessory/01012110.img.xml index c911dd68ee..089030bc03 100644 --- a/wz/Character.wz/Accessory/01012110.img.xml +++ b/wz/Character.wz/Accessory/01012110.img.xml @@ -18,6 +18,7 @@ + diff --git a/wz/Character.wz/Accessory/01012111.img.xml b/wz/Character.wz/Accessory/01012111.img.xml index db84a189e6..ec5b7a857e 100644 --- a/wz/Character.wz/Accessory/01012111.img.xml +++ b/wz/Character.wz/Accessory/01012111.img.xml @@ -18,6 +18,7 @@ + diff --git a/wz/Character.wz/Accessory/01012139.img.xml b/wz/Character.wz/Accessory/01012139.img.xml index 31fe9c0244..7bbe1d597b 100644 --- a/wz/Character.wz/Accessory/01012139.img.xml +++ b/wz/Character.wz/Accessory/01012139.img.xml @@ -20,6 +20,7 @@ + diff --git a/wz/Character.wz/Accessory/01012140.img.xml b/wz/Character.wz/Accessory/01012140.img.xml index 1b6ec27012..62dbd0c327 100644 --- a/wz/Character.wz/Accessory/01012140.img.xml +++ b/wz/Character.wz/Accessory/01012140.img.xml @@ -20,6 +20,7 @@ + diff --git a/wz/Character.wz/Accessory/01012141.img.xml b/wz/Character.wz/Accessory/01012141.img.xml index bcbe4e7e4f..6709464804 100644 --- a/wz/Character.wz/Accessory/01012141.img.xml +++ b/wz/Character.wz/Accessory/01012141.img.xml @@ -20,6 +20,7 @@ + diff --git a/wz/Character.wz/Accessory/01012146.img.xml b/wz/Character.wz/Accessory/01012146.img.xml index 6967932539..86d6e72159 100644 --- a/wz/Character.wz/Accessory/01012146.img.xml +++ b/wz/Character.wz/Accessory/01012146.img.xml @@ -20,6 +20,7 @@ + diff --git a/wz/Character.wz/Accessory/01012181.img.xml b/wz/Character.wz/Accessory/01012181.img.xml index 56938f4a78..8b16897966 100644 --- a/wz/Character.wz/Accessory/01012181.img.xml +++ b/wz/Character.wz/Accessory/01012181.img.xml @@ -21,6 +21,7 @@ + diff --git a/wz/Character.wz/Accessory/01012182.img.xml b/wz/Character.wz/Accessory/01012182.img.xml index cfc77e9a88..bca48d35bc 100644 --- a/wz/Character.wz/Accessory/01012182.img.xml +++ b/wz/Character.wz/Accessory/01012182.img.xml @@ -21,6 +21,7 @@ + diff --git a/wz/Character.wz/Accessory/01012183.img.xml b/wz/Character.wz/Accessory/01012183.img.xml index db6910503c..0448c64586 100644 --- a/wz/Character.wz/Accessory/01012183.img.xml +++ b/wz/Character.wz/Accessory/01012183.img.xml @@ -21,6 +21,7 @@ + diff --git a/wz/Character.wz/Accessory/01012184.img.xml b/wz/Character.wz/Accessory/01012184.img.xml index fe6ad74615..0c86c83ea1 100644 --- a/wz/Character.wz/Accessory/01012184.img.xml +++ b/wz/Character.wz/Accessory/01012184.img.xml @@ -21,6 +21,7 @@ + diff --git a/wz/Character.wz/Accessory/01012185.img.xml b/wz/Character.wz/Accessory/01012185.img.xml index 3de5e4f5db..503268d53e 100644 --- a/wz/Character.wz/Accessory/01012185.img.xml +++ b/wz/Character.wz/Accessory/01012185.img.xml @@ -21,6 +21,7 @@ + diff --git a/wz/Character.wz/Accessory/01012186.img.xml b/wz/Character.wz/Accessory/01012186.img.xml index fd0b4a852d..eff5c5e2f5 100644 --- a/wz/Character.wz/Accessory/01012186.img.xml +++ b/wz/Character.wz/Accessory/01012186.img.xml @@ -21,6 +21,7 @@ + diff --git a/wz/Character.wz/Accessory/01022058.img.xml b/wz/Character.wz/Accessory/01022058.img.xml index 1b4a64244d..4f916fd016 100644 --- a/wz/Character.wz/Accessory/01022058.img.xml +++ b/wz/Character.wz/Accessory/01022058.img.xml @@ -19,6 +19,7 @@ + diff --git a/wz/Character.wz/Accessory/01022060.img.xml b/wz/Character.wz/Accessory/01022060.img.xml index d66278802e..b0d23e993e 100644 --- a/wz/Character.wz/Accessory/01022060.img.xml +++ b/wz/Character.wz/Accessory/01022060.img.xml @@ -18,6 +18,7 @@ + diff --git a/wz/Character.wz/Accessory/01022073.img.xml b/wz/Character.wz/Accessory/01022073.img.xml index a94b83987e..5125bd3b43 100644 --- a/wz/Character.wz/Accessory/01022073.img.xml +++ b/wz/Character.wz/Accessory/01022073.img.xml @@ -363,5 +363,6 @@ + diff --git a/wz/Character.wz/Accessory/01022088.img.xml b/wz/Character.wz/Accessory/01022088.img.xml index a0f187fbac..04f1624683 100644 --- a/wz/Character.wz/Accessory/01022088.img.xml +++ b/wz/Character.wz/Accessory/01022088.img.xml @@ -23,6 +23,7 @@ + diff --git a/wz/Character.wz/Accessory/01022089.img.xml b/wz/Character.wz/Accessory/01022089.img.xml index 329733f009..0f541eea6d 100644 --- a/wz/Character.wz/Accessory/01022089.img.xml +++ b/wz/Character.wz/Accessory/01022089.img.xml @@ -22,6 +22,7 @@ + diff --git a/wz/Character.wz/Accessory/01022103.img.xml b/wz/Character.wz/Accessory/01022103.img.xml index d568308f0b..24313b0cba 100644 --- a/wz/Character.wz/Accessory/01022103.img.xml +++ b/wz/Character.wz/Accessory/01022103.img.xml @@ -23,6 +23,7 @@ + diff --git a/wz/Character.wz/Accessory/01032060.img.xml b/wz/Character.wz/Accessory/01032060.img.xml index 91e51ba797..6cef8287c0 100644 --- a/wz/Character.wz/Accessory/01032060.img.xml +++ b/wz/Character.wz/Accessory/01032060.img.xml @@ -393,5 +393,6 @@ + diff --git a/wz/Character.wz/Accessory/01032061.img.xml b/wz/Character.wz/Accessory/01032061.img.xml index 4c3b5abb9e..3120e37fe5 100644 --- a/wz/Character.wz/Accessory/01032061.img.xml +++ b/wz/Character.wz/Accessory/01032061.img.xml @@ -393,5 +393,6 @@ + diff --git a/wz/Character.wz/Accessory/01032075.img.xml b/wz/Character.wz/Accessory/01032075.img.xml index 79dd9514e6..dbd73500c4 100644 --- a/wz/Character.wz/Accessory/01032075.img.xml +++ b/wz/Character.wz/Accessory/01032075.img.xml @@ -23,6 +23,7 @@ + diff --git a/wz/Character.wz/Accessory/01142079.img.xml b/wz/Character.wz/Accessory/01142079.img.xml index 0820a3a53f..546886ee1f 100644 --- a/wz/Character.wz/Accessory/01142079.img.xml +++ b/wz/Character.wz/Accessory/01142079.img.xml @@ -28,5 +28,6 @@ + diff --git a/wz/Character.wz/Accessory/01142080.img.xml b/wz/Character.wz/Accessory/01142080.img.xml index 95dbe0df3e..a617ca435a 100644 --- a/wz/Character.wz/Accessory/01142080.img.xml +++ b/wz/Character.wz/Accessory/01142080.img.xml @@ -25,5 +25,6 @@ + diff --git a/wz/Character.wz/Accessory/01142081.img.xml b/wz/Character.wz/Accessory/01142081.img.xml index 0aa390a459..70a0a1496f 100644 --- a/wz/Character.wz/Accessory/01142081.img.xml +++ b/wz/Character.wz/Accessory/01142081.img.xml @@ -28,5 +28,6 @@ + diff --git a/wz/Character.wz/Accessory/01142082.img.xml b/wz/Character.wz/Accessory/01142082.img.xml index f1e1198654..4410f3a1a6 100644 --- a/wz/Character.wz/Accessory/01142082.img.xml +++ b/wz/Character.wz/Accessory/01142082.img.xml @@ -28,5 +28,6 @@ + diff --git a/wz/Character.wz/Accessory/01142083.img.xml b/wz/Character.wz/Accessory/01142083.img.xml index 98bf343c70..eae00508c9 100644 --- a/wz/Character.wz/Accessory/01142083.img.xml +++ b/wz/Character.wz/Accessory/01142083.img.xml @@ -28,5 +28,6 @@ + diff --git a/wz/Character.wz/Accessory/01142084.img.xml b/wz/Character.wz/Accessory/01142084.img.xml index d7a6c2a7b4..195ca29915 100644 --- a/wz/Character.wz/Accessory/01142084.img.xml +++ b/wz/Character.wz/Accessory/01142084.img.xml @@ -28,5 +28,6 @@ + diff --git a/wz/Character.wz/Accessory/01142085.img.xml b/wz/Character.wz/Accessory/01142085.img.xml index f566f17de9..4010128574 100644 --- a/wz/Character.wz/Accessory/01142085.img.xml +++ b/wz/Character.wz/Accessory/01142085.img.xml @@ -30,5 +30,6 @@ + diff --git a/wz/Character.wz/Accessory/01142086.img.xml b/wz/Character.wz/Accessory/01142086.img.xml index 8a17d4b23c..1903e616a1 100644 --- a/wz/Character.wz/Accessory/01142086.img.xml +++ b/wz/Character.wz/Accessory/01142086.img.xml @@ -30,5 +30,6 @@ + diff --git a/wz/Character.wz/Accessory/01142087.img.xml b/wz/Character.wz/Accessory/01142087.img.xml index 16496adbe6..573a9d6c7a 100644 --- a/wz/Character.wz/Accessory/01142087.img.xml +++ b/wz/Character.wz/Accessory/01142087.img.xml @@ -30,5 +30,6 @@ + diff --git a/wz/Character.wz/Accessory/01142088.img.xml b/wz/Character.wz/Accessory/01142088.img.xml index dd054992c7..f7fc54bb60 100644 --- a/wz/Character.wz/Accessory/01142088.img.xml +++ b/wz/Character.wz/Accessory/01142088.img.xml @@ -30,5 +30,6 @@ + diff --git a/wz/Character.wz/Accessory/01142089.img.xml b/wz/Character.wz/Accessory/01142089.img.xml index 9036309ab3..0a10996124 100644 --- a/wz/Character.wz/Accessory/01142089.img.xml +++ b/wz/Character.wz/Accessory/01142089.img.xml @@ -30,5 +30,6 @@ + diff --git a/wz/Character.wz/Accessory/01142090.img.xml b/wz/Character.wz/Accessory/01142090.img.xml index efb764a5d6..71a8a7dbc4 100644 --- a/wz/Character.wz/Accessory/01142090.img.xml +++ b/wz/Character.wz/Accessory/01142090.img.xml @@ -31,5 +31,6 @@ + diff --git a/wz/Character.wz/Accessory/01142091.img.xml b/wz/Character.wz/Accessory/01142091.img.xml index 5d01a38456..9957c55e27 100644 --- a/wz/Character.wz/Accessory/01142091.img.xml +++ b/wz/Character.wz/Accessory/01142091.img.xml @@ -31,5 +31,6 @@ + diff --git a/wz/Character.wz/Accessory/01142092.img.xml b/wz/Character.wz/Accessory/01142092.img.xml index 23f26c73e1..0237ff1e5d 100644 --- a/wz/Character.wz/Accessory/01142092.img.xml +++ b/wz/Character.wz/Accessory/01142092.img.xml @@ -31,5 +31,6 @@ + diff --git a/wz/Character.wz/Accessory/01142093.img.xml b/wz/Character.wz/Accessory/01142093.img.xml index c954ce12a7..9eba6d43a9 100644 --- a/wz/Character.wz/Accessory/01142093.img.xml +++ b/wz/Character.wz/Accessory/01142093.img.xml @@ -31,5 +31,6 @@ + diff --git a/wz/Character.wz/Accessory/01142094.img.xml b/wz/Character.wz/Accessory/01142094.img.xml index 78a4c4a1fa..e9530c010d 100644 --- a/wz/Character.wz/Accessory/01142094.img.xml +++ b/wz/Character.wz/Accessory/01142094.img.xml @@ -31,5 +31,6 @@ + diff --git a/wz/Character.wz/Accessory/01142095.img.xml b/wz/Character.wz/Accessory/01142095.img.xml index e8974fb501..ea6cb9d154 100644 --- a/wz/Character.wz/Accessory/01142095.img.xml +++ b/wz/Character.wz/Accessory/01142095.img.xml @@ -31,5 +31,6 @@ + diff --git a/wz/Character.wz/Accessory/01142096.img.xml b/wz/Character.wz/Accessory/01142096.img.xml index 7b3a8ea69c..1554da63c3 100644 --- a/wz/Character.wz/Accessory/01142096.img.xml +++ b/wz/Character.wz/Accessory/01142096.img.xml @@ -31,5 +31,6 @@ + diff --git a/wz/Character.wz/Accessory/01142097.img.xml b/wz/Character.wz/Accessory/01142097.img.xml index 3a388ba9eb..872c0bdbec 100644 --- a/wz/Character.wz/Accessory/01142097.img.xml +++ b/wz/Character.wz/Accessory/01142097.img.xml @@ -31,5 +31,6 @@ + diff --git a/wz/Character.wz/Accessory/01142098.img.xml b/wz/Character.wz/Accessory/01142098.img.xml index 8857f87c65..8e4f08ca0c 100644 --- a/wz/Character.wz/Accessory/01142098.img.xml +++ b/wz/Character.wz/Accessory/01142098.img.xml @@ -31,5 +31,6 @@ + diff --git a/wz/Character.wz/Accessory/01142099.img.xml b/wz/Character.wz/Accessory/01142099.img.xml index 9e855ff8b2..fc906648c5 100644 --- a/wz/Character.wz/Accessory/01142099.img.xml +++ b/wz/Character.wz/Accessory/01142099.img.xml @@ -28,5 +28,6 @@ + diff --git a/wz/Character.wz/Accessory/01142100.img.xml b/wz/Character.wz/Accessory/01142100.img.xml index 80aa940b86..94f45c733d 100644 --- a/wz/Character.wz/Accessory/01142100.img.xml +++ b/wz/Character.wz/Accessory/01142100.img.xml @@ -30,5 +30,6 @@ + diff --git a/wz/Character.wz/Accessory/01142101.img.xml b/wz/Character.wz/Accessory/01142101.img.xml index c2a5a76a5f..4bce5ffbe2 100644 --- a/wz/Character.wz/Accessory/01142101.img.xml +++ b/wz/Character.wz/Accessory/01142101.img.xml @@ -21,5 +21,6 @@ + diff --git a/wz/Character.wz/Cap/01002424.img.xml b/wz/Character.wz/Cap/01002424.img.xml index 362368ed8a..5c6eef6c08 100644 --- a/wz/Character.wz/Cap/01002424.img.xml +++ b/wz/Character.wz/Cap/01002424.img.xml @@ -19,6 +19,7 @@ + diff --git a/wz/Character.wz/Cap/01002425.img.xml b/wz/Character.wz/Cap/01002425.img.xml index 2bac6fd4b1..827aff291c 100644 --- a/wz/Character.wz/Cap/01002425.img.xml +++ b/wz/Character.wz/Cap/01002425.img.xml @@ -19,6 +19,7 @@ + diff --git a/wz/Character.wz/Cap/01002448.img.xml b/wz/Character.wz/Cap/01002448.img.xml index 10267affd4..d35e69a879 100644 --- a/wz/Character.wz/Cap/01002448.img.xml +++ b/wz/Character.wz/Cap/01002448.img.xml @@ -16,6 +16,7 @@ + diff --git a/wz/Character.wz/Cap/01002562.img.xml b/wz/Character.wz/Cap/01002562.img.xml index 88186ffa9a..7183d2f7ff 100644 --- a/wz/Character.wz/Cap/01002562.img.xml +++ b/wz/Character.wz/Cap/01002562.img.xml @@ -15,6 +15,7 @@ + diff --git a/wz/Character.wz/Cap/01002723.img.xml b/wz/Character.wz/Cap/01002723.img.xml index 0a4d9b28f9..37fcea5acf 100644 --- a/wz/Character.wz/Cap/01002723.img.xml +++ b/wz/Character.wz/Cap/01002723.img.xml @@ -17,6 +17,7 @@ + diff --git a/wz/Character.wz/Cap/01002788.img.xml b/wz/Character.wz/Cap/01002788.img.xml index 023617a699..3ff4027926 100644 --- a/wz/Character.wz/Cap/01002788.img.xml +++ b/wz/Character.wz/Cap/01002788.img.xml @@ -21,6 +21,7 @@ + diff --git a/wz/Character.wz/Cap/01002971.img.xml b/wz/Character.wz/Cap/01002971.img.xml index 1a30b3a73d..c7af92ecfa 100644 --- a/wz/Character.wz/Cap/01002971.img.xml +++ b/wz/Character.wz/Cap/01002971.img.xml @@ -23,6 +23,7 @@ + diff --git a/wz/Character.wz/Cap/01002980.img.xml b/wz/Character.wz/Cap/01002980.img.xml index 4752625475..15310b4e3f 100644 --- a/wz/Character.wz/Cap/01002980.img.xml +++ b/wz/Character.wz/Cap/01002980.img.xml @@ -23,6 +23,7 @@ + diff --git a/wz/Character.wz/Cap/01002981.img.xml b/wz/Character.wz/Cap/01002981.img.xml index 138b01b816..9843b50051 100644 --- a/wz/Character.wz/Cap/01002981.img.xml +++ b/wz/Character.wz/Cap/01002981.img.xml @@ -22,6 +22,7 @@ + diff --git a/wz/Character.wz/Cap/01003073.img.xml b/wz/Character.wz/Cap/01003073.img.xml index 8b2eb0dec6..9b5903f6c2 100644 --- a/wz/Character.wz/Cap/01003073.img.xml +++ b/wz/Character.wz/Cap/01003073.img.xml @@ -23,6 +23,7 @@ + diff --git a/wz/Character.wz/Cape/01102205.img.xml b/wz/Character.wz/Cape/01102205.img.xml index 9affd82ded..be85fc3d24 100644 --- a/wz/Character.wz/Cape/01102205.img.xml +++ b/wz/Character.wz/Cape/01102205.img.xml @@ -22,6 +22,7 @@ + diff --git a/wz/Character.wz/Cape/01102206.img.xml b/wz/Character.wz/Cape/01102206.img.xml index eb50169c8d..bbd18cc9ba 100644 --- a/wz/Character.wz/Cape/01102206.img.xml +++ b/wz/Character.wz/Cape/01102206.img.xml @@ -20,6 +20,7 @@ + diff --git a/wz/Character.wz/Cape/01102207.img.xml b/wz/Character.wz/Cape/01102207.img.xml index 1930b38c12..e591959727 100644 --- a/wz/Character.wz/Cape/01102207.img.xml +++ b/wz/Character.wz/Cape/01102207.img.xml @@ -20,6 +20,7 @@ + diff --git a/wz/Character.wz/Cape/01102211.img.xml b/wz/Character.wz/Cape/01102211.img.xml index 38b386541f..17138daf4e 100644 --- a/wz/Character.wz/Cape/01102211.img.xml +++ b/wz/Character.wz/Cape/01102211.img.xml @@ -16,6 +16,7 @@ + diff --git a/wz/Character.wz/Cape/01102226.img.xml b/wz/Character.wz/Cape/01102226.img.xml index 496712483f..439fc189a1 100644 --- a/wz/Character.wz/Cape/01102226.img.xml +++ b/wz/Character.wz/Cape/01102226.img.xml @@ -22,6 +22,7 @@ + diff --git a/wz/Character.wz/Cape/01102227.img.xml b/wz/Character.wz/Cape/01102227.img.xml index a731fd4b2f..95017928d9 100644 --- a/wz/Character.wz/Cape/01102227.img.xml +++ b/wz/Character.wz/Cape/01102227.img.xml @@ -24,6 +24,7 @@ + diff --git a/wz/Character.wz/Glove/01082252.img.xml b/wz/Character.wz/Glove/01082252.img.xml index f382c6db6e..61afc86d3a 100644 --- a/wz/Character.wz/Glove/01082252.img.xml +++ b/wz/Character.wz/Glove/01082252.img.xml @@ -19,6 +19,7 @@ + diff --git a/wz/Character.wz/Longcoat/01052081.img.xml b/wz/Character.wz/Longcoat/01052081.img.xml index 156641cfb9..f263929482 100644 --- a/wz/Character.wz/Longcoat/01052081.img.xml +++ b/wz/Character.wz/Longcoat/01052081.img.xml @@ -15,6 +15,7 @@ + diff --git a/wz/Character.wz/Longcoat/01052165.img.xml b/wz/Character.wz/Longcoat/01052165.img.xml index 2480e5bb01..6a84825441 100644 --- a/wz/Character.wz/Longcoat/01052165.img.xml +++ b/wz/Character.wz/Longcoat/01052165.img.xml @@ -27,6 +27,7 @@ + diff --git a/wz/Character.wz/Longcoat/01052166.img.xml b/wz/Character.wz/Longcoat/01052166.img.xml index f99fb597cb..3dfa1f3bd4 100644 --- a/wz/Character.wz/Longcoat/01052166.img.xml +++ b/wz/Character.wz/Longcoat/01052166.img.xml @@ -26,6 +26,7 @@ + diff --git a/wz/Character.wz/Longcoat/01052167.img.xml b/wz/Character.wz/Longcoat/01052167.img.xml index 8bf7ee9319..f00d94897b 100644 --- a/wz/Character.wz/Longcoat/01052167.img.xml +++ b/wz/Character.wz/Longcoat/01052167.img.xml @@ -26,6 +26,7 @@ + diff --git a/wz/Character.wz/Longcoat/01052173.img.xml b/wz/Character.wz/Longcoat/01052173.img.xml index 98d97e3262..82d491f16a 100644 --- a/wz/Character.wz/Longcoat/01052173.img.xml +++ b/wz/Character.wz/Longcoat/01052173.img.xml @@ -18,6 +18,7 @@ + diff --git a/wz/Character.wz/Longcoat/01052202.img.xml b/wz/Character.wz/Longcoat/01052202.img.xml index e8ed7fc7ac..88435f4c46 100644 --- a/wz/Character.wz/Longcoat/01052202.img.xml +++ b/wz/Character.wz/Longcoat/01052202.img.xml @@ -25,6 +25,7 @@ + diff --git a/wz/Character.wz/Ring/01112803.img.xml b/wz/Character.wz/Ring/01112803.img.xml index c5f51f5445..1bb4c2bf5c 100644 --- a/wz/Character.wz/Ring/01112803.img.xml +++ b/wz/Character.wz/Ring/01112803.img.xml @@ -23,5 +23,6 @@ + diff --git a/wz/Character.wz/Ring/01112806.img.xml b/wz/Character.wz/Ring/01112806.img.xml index 03b5280039..8cc5d8ad72 100644 --- a/wz/Character.wz/Ring/01112806.img.xml +++ b/wz/Character.wz/Ring/01112806.img.xml @@ -23,5 +23,6 @@ + diff --git a/wz/Character.wz/Ring/01112807.img.xml b/wz/Character.wz/Ring/01112807.img.xml index 3c55a481de..f3946bd39f 100644 --- a/wz/Character.wz/Ring/01112807.img.xml +++ b/wz/Character.wz/Ring/01112807.img.xml @@ -23,5 +23,6 @@ + diff --git a/wz/Character.wz/Ring/01112809.img.xml b/wz/Character.wz/Ring/01112809.img.xml index cb957827a8..2467bc382c 100644 --- a/wz/Character.wz/Ring/01112809.img.xml +++ b/wz/Character.wz/Ring/01112809.img.xml @@ -23,5 +23,6 @@ + diff --git a/wz/Character.wz/Shoes/01072369.img.xml b/wz/Character.wz/Shoes/01072369.img.xml index 763cbe1cef..296487c929 100644 --- a/wz/Character.wz/Shoes/01072369.img.xml +++ b/wz/Character.wz/Shoes/01072369.img.xml @@ -26,6 +26,7 @@ + diff --git a/wz/Character.wz/Shoes/01072375.img.xml b/wz/Character.wz/Shoes/01072375.img.xml index faf400ae97..c72dfe3793 100644 --- a/wz/Character.wz/Shoes/01072375.img.xml +++ b/wz/Character.wz/Shoes/01072375.img.xml @@ -23,6 +23,7 @@ + diff --git a/wz/Character.wz/Shoes/01072376.img.xml b/wz/Character.wz/Shoes/01072376.img.xml index 86b4a9d23d..22467203dc 100644 --- a/wz/Character.wz/Shoes/01072376.img.xml +++ b/wz/Character.wz/Shoes/01072376.img.xml @@ -54,6 +54,7 @@ + diff --git a/wz/Character.wz/TamingMob/01932000.img.xml b/wz/Character.wz/TamingMob/01932000.img.xml index 9d82d23fea..028d52c18f 100644 --- a/wz/Character.wz/TamingMob/01932000.img.xml +++ b/wz/Character.wz/TamingMob/01932000.img.xml @@ -16,6 +16,7 @@ + diff --git a/wz/Character.wz/TamingMob/01932001.img.xml b/wz/Character.wz/TamingMob/01932001.img.xml index 6b760b9879..86b99e778f 100644 --- a/wz/Character.wz/TamingMob/01932001.img.xml +++ b/wz/Character.wz/TamingMob/01932001.img.xml @@ -17,6 +17,7 @@ + diff --git a/wz/Character.wz/TamingMob/01932002.img.xml b/wz/Character.wz/TamingMob/01932002.img.xml index ce0dde43f0..199024aacc 100644 --- a/wz/Character.wz/TamingMob/01932002.img.xml +++ b/wz/Character.wz/TamingMob/01932002.img.xml @@ -17,6 +17,7 @@ + diff --git a/wz/Character.wz/TamingMob/01932003.img.xml b/wz/Character.wz/TamingMob/01932003.img.xml index f86cc8e271..9ee32b658a 100644 --- a/wz/Character.wz/TamingMob/01932003.img.xml +++ b/wz/Character.wz/TamingMob/01932003.img.xml @@ -16,6 +16,7 @@ + diff --git a/wz/Character.wz/TamingMob/01932004.img.xml b/wz/Character.wz/TamingMob/01932004.img.xml index 4b97077915..7a868270a7 100644 --- a/wz/Character.wz/TamingMob/01932004.img.xml +++ b/wz/Character.wz/TamingMob/01932004.img.xml @@ -16,6 +16,7 @@ + diff --git a/wz/Character.wz/TamingMob/01932005.img.xml b/wz/Character.wz/TamingMob/01932005.img.xml index d69c7470d4..92e5712cdb 100644 --- a/wz/Character.wz/TamingMob/01932005.img.xml +++ b/wz/Character.wz/TamingMob/01932005.img.xml @@ -16,6 +16,7 @@ + diff --git a/wz/Character.wz/TamingMob/01932010.img.xml b/wz/Character.wz/TamingMob/01932010.img.xml index ebf42187d5..3bd293b068 100644 --- a/wz/Character.wz/TamingMob/01932010.img.xml +++ b/wz/Character.wz/TamingMob/01932010.img.xml @@ -14,6 +14,7 @@ + diff --git a/wz/Character.wz/TamingMob/01932012.img.xml b/wz/Character.wz/TamingMob/01932012.img.xml index 8a2b8810e4..78afd11023 100644 --- a/wz/Character.wz/TamingMob/01932012.img.xml +++ b/wz/Character.wz/TamingMob/01932012.img.xml @@ -15,6 +15,7 @@ + diff --git a/wz/Map.wz/Map/Map6/677000010.img.xml b/wz/Map.wz/Map/Map6/677000010.img.xml index 57eda21771..3d879963c8 100644 --- a/wz/Map.wz/Map/Map6/677000010.img.xml +++ b/wz/Map.wz/Map/Map6/677000010.img.xml @@ -1 +1,1046 @@ - \ No newline at end of file + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/wz/Map.wz/Map/Map6/677000011.img.xml b/wz/Map.wz/Map/Map6/677000011.img.xml index 57d6e53403..2391d516f8 100644 --- a/wz/Map.wz/Map/Map6/677000011.img.xml +++ b/wz/Map.wz/Map/Map6/677000011.img.xml @@ -1 +1,3984 @@ - \ No newline at end of file + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/wz/Map.wz/Map/Map6/677000012.img.xml b/wz/Map.wz/Map/Map6/677000012.img.xml index 5c90d004b8..26253dcc11 100644 --- a/wz/Map.wz/Map/Map6/677000012.img.xml +++ b/wz/Map.wz/Map/Map6/677000012.img.xml @@ -1 +1,1494 @@ - \ No newline at end of file + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/wz/Quest.wz/Act.img.xml b/wz/Quest.wz/Act.img.xml index 0914bce47f..4dc71e60bb 100644 --- a/wz/Quest.wz/Act.img.xml +++ b/wz/Quest.wz/Act.img.xml @@ -1 +1,56020 @@ - \ No newline at end of file + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/wz/Quest.wz/QuestInfo.img.xml b/wz/Quest.wz/QuestInfo.img.xml index a5cacbd618..4adc2f7bdb 100644 --- a/wz/Quest.wz/QuestInfo.img.xml +++ b/wz/Quest.wz/QuestInfo.img.xml @@ -1,254 +1,2640 @@ - + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file +"/> + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/wz/Quest.wz/Say.img.xml b/wz/Quest.wz/Say.img.xml index 28760b3886..b2d48aec0f 100644 --- a/wz/Quest.wz/Say.img.xml +++ b/wz/Quest.wz/Say.img.xml @@ -2045,7 +2045,7 @@ - + diff --git a/wz/String.wz/Cash.img.xml b/wz/String.wz/Cash.img.xml index 0ce69ab360..da0f04224c 100644 --- a/wz/String.wz/Cash.img.xml +++ b/wz/String.wz/Cash.img.xml @@ -2002,4 +2002,84 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/wz/String.wz/Consume.img.xml b/wz/String.wz/Consume.img.xml index 1b75eb4461..271ea81f59 100644 --- a/wz/String.wz/Consume.img.xml +++ b/wz/String.wz/Consume.img.xml @@ -9204,4 +9204,104 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/wz/String.wz/Eqp.img.xml b/wz/String.wz/Eqp.img.xml index 7e47031340..e5dd35ff9e 100644 --- a/wz/String.wz/Eqp.img.xml +++ b/wz/String.wz/Eqp.img.xml @@ -1529,6 +1529,38 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + @@ -8609,6 +8641,10 @@ + + + + @@ -13123,6 +13159,62 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + @@ -14606,6 +14698,34 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + @@ -16100,6 +16220,14 @@ + + + + + + + + @@ -16710,6 +16838,10 @@ + + + + @@ -18116,6 +18248,62 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + @@ -22036,6 +22224,194 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/wz/String.wz/Etc.img.xml b/wz/String.wz/Etc.img.xml index 14f985fcd8..62b174a731 100644 --- a/wz/String.wz/Etc.img.xml +++ b/wz/String.wz/Etc.img.xml @@ -9522,5 +9522,21 @@ + + + + + + + + + + + + + + + + diff --git a/wz/String.wz/Ins.img.xml b/wz/String.wz/Ins.img.xml index 761ddac9d0..6aca7c5c25 100644 --- a/wz/String.wz/Ins.img.xml +++ b/wz/String.wz/Ins.img.xml @@ -1001,4 +1001,184 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +