From 5429f7195d9dcfb6d5335e477ade76970db33a94 Mon Sep 17 00:00:00 2001 From: MobiusDevelopment <8391001+MobiusDevelopment@users.noreply.github.com> Date: Tue, 4 Feb 2020 04:05:50 +0000 Subject: [PATCH] Drop of char_templates, class_list and lvlupgain SQL tables. --- .../db_installer/sql/game/char_templates.sql | 138 --------- .../dist/db_installer/sql/game/class_list.sql | 105 ------- .../dist/db_installer/sql/game/lvlupgain.sql | 113 ------- .../dist/game/data/stats/playerTemplates.xml | 92 ++++++ .../dist/game/data/xsd/playerTemplates.xsd | 49 +++ .../org/l2jmobius/gameserver/GameServer.java | 31 +- .../datatables/sql/CharTemplateTable.java | 279 ------------------ .../datatables/sql/HelperBuffTable.java | 2 +- .../datatables/sql/LevelUpData.java | 114 ------- .../datatables/sql/SkillTreeTable.java | 68 ++--- .../datatables/xml/PlayerTemplateData.java | 131 ++++++++ .../gameserver/engines/DocumentEngine.java | 2 +- .../instancemanager/ClassDamageManager.java | 10 +- .../actor/instance/ClassMasterInstance.java | 186 ++++++------ .../model/actor/instance/PlayerInstance.java | 19 +- .../actor/instance/VillageMasterInstance.java | 18 +- .../actor/templates/CreatureTemplate.java | 4 +- .../model/actor/templates/PlayerTemplate.java | 108 +++---- .../gameserver/model/skills/Formulas.java | 18 +- .../clientpackets/CharacterCreate.java | 9 +- .../clientpackets/CharacterSelected.java | 1 - .../network/clientpackets/NewCharacter.java | 22 +- .../network/serverpackets/CustomNpcInfo.java | 6 +- 23 files changed, 500 insertions(+), 1025 deletions(-) delete mode 100644 L2J_Mobius_C6_Interlude/dist/db_installer/sql/game/char_templates.sql delete mode 100644 L2J_Mobius_C6_Interlude/dist/db_installer/sql/game/class_list.sql delete mode 100644 L2J_Mobius_C6_Interlude/dist/db_installer/sql/game/lvlupgain.sql create mode 100644 L2J_Mobius_C6_Interlude/dist/game/data/stats/playerTemplates.xml create mode 100644 L2J_Mobius_C6_Interlude/dist/game/data/xsd/playerTemplates.xsd delete mode 100644 L2J_Mobius_C6_Interlude/java/org/l2jmobius/gameserver/datatables/sql/CharTemplateTable.java delete mode 100644 L2J_Mobius_C6_Interlude/java/org/l2jmobius/gameserver/datatables/sql/LevelUpData.java create mode 100644 L2J_Mobius_C6_Interlude/java/org/l2jmobius/gameserver/datatables/xml/PlayerTemplateData.java diff --git a/L2J_Mobius_C6_Interlude/dist/db_installer/sql/game/char_templates.sql b/L2J_Mobius_C6_Interlude/dist/db_installer/sql/game/char_templates.sql deleted file mode 100644 index a215ccd62d..0000000000 --- a/L2J_Mobius_C6_Interlude/dist/db_installer/sql/game/char_templates.sql +++ /dev/null @@ -1,138 +0,0 @@ --- --- Table structure for table `char_templates` --- -DROP TABLE IF EXISTS `char_templates`; -CREATE TABLE `char_templates` ( - `ClassId` int(11) NOT NULL default '0', - `ClassName` varchar(20) NOT NULL default '', - `RaceId` int(1) NOT NULL default '0', - `STR` int(2) NOT NULL default '0', - `CON` int(2) NOT NULL default '0', - `DEX` int(2) NOT NULL default '0', - `_INT` int(2) NOT NULL default '0', - `WIT` int(2) NOT NULL default '0', - `MEN` int(2) NOT NULL default '0', - `P_ATK` int(3) NOT NULL default '0', - `P_DEF` int(3) NOT NULL default '0', - `M_ATK` int(3) NOT NULL default '0', - `M_DEF` int(2) NOT NULL default '0', - `P_SPD` int(3) NOT NULL default '0', - `M_SPD` int(3) NOT NULL default '0', - `ACC` int(3) NOT NULL default '0', - `CRITICAL` int(3) NOT NULL default '0', - `EVASION` int(3) NOT NULL default '0', - `MOVE_SPD` int(3) NOT NULL default '0', - `_LOAD` int(11) NOT NULL default '0', - `x` int(9) NOT NULL default '0', - `y` int(9) NOT NULL default '0', - `z` int(9) NOT NULL default '0', - `canCraft` int(1) NOT NULL default '0', - `M_UNK1` decimal(4,2) NOT NULL default '0.00', - `M_UNK2` decimal(8,6) NOT NULL default '0.000000', - `M_COL_R` decimal(3,1) NOT NULL default '0.0', - `M_COL_H` decimal(4,1) NOT NULL default '0.0', - `F_UNK1` decimal(4,2) NOT NULL default '0.00', - `F_UNK2` decimal(8,6) NOT NULL default '0.000000', - `F_COL_R` decimal(3,1) NOT NULL default '0.0', - `F_COL_H` decimal(4,1) NOT NULL default '0.0', - `items1` int(4) NOT NULL default '0', - `items2` int(4) NOT NULL default '0', - `items3` int(4) NOT NULL default '0', - `items4` int(4) NOT NULL default '0', - `items5` int(10) NOT NULL default '0', - PRIMARY KEY (`ClassId`) -) ENGINE=MyISAM DEFAULT CHARSET=latin1 COLLATE=latin1_general_ci; - --- --- Dumping data for table `char_templates` --- - -INSERT INTO `char_templates` VALUES (0, 'Human Fighter', 0, 40, 43, 30, 21, 11, 25, 4, 80, 6, 41, 300, 333, 33, 44, 33, 115, 81900, -71338, 258271, -3104, 0, 1.10, 1.188000, 9.0, 23.0, 1.10, 1.188000, 8.0, 23.5, 1147, 1146, 10, 2369, 5588); -INSERT INTO `char_templates` VALUES (1, 'Warrior', 0, 40, 43, 30, 21, 11, 25, 4, 80, 6, 41, 300, 333, 33, 44, 33, 115, 81900, -71338, 258271, -3104, 0, 1.10, 1.188000, 9.0, 23.0, 1.10, 1.188000, 8.0, 23.5, 1147, 1146, 10, 2369, 5588); -INSERT INTO `char_templates` VALUES (2, 'Gladiator', 0, 40, 43, 30, 21, 11, 25, 4, 80, 6, 41, 300, 333, 33, 44, 33, 115, 81900, -71338, 258271, -3104, 0, 1.10, 1.188000, 9.0, 23.0, 1.10, 1.188000, 8.0, 23.5, 1147, 1146, 10, 2369, 5588); -INSERT INTO `char_templates` VALUES (3, 'Warlord', 0, 40, 43, 30, 21, 11, 25, 4, 80, 6, 41, 300, 333, 33, 44, 33, 115, 81900, -71338, 258271, -3104, 0, 1.10, 1.188000, 9.0, 23.0, 1.10, 1.188000, 8.0, 23.5, 1147, 1146, 10, 2369, 5588); -INSERT INTO `char_templates` VALUES (4, 'Human Knight', 0, 40, 43, 30, 21, 11, 25, 4, 80, 6, 41, 300, 333, 33, 44, 33, 115, 81900, -71338, 258271, -3104, 0, 1.10, 1.188000, 9.0, 23.0, 1.10, 1.188000, 8.0, 23.5, 1147, 1146, 10, 2369, 5588); -INSERT INTO `char_templates` VALUES (5, 'Paladin', 0, 40, 43, 30, 21, 11, 25, 4, 80, 6, 41, 300, 333, 33, 44, 33, 115, 81900, -71338, 258271, -3104, 0, 1.10, 1.188000, 9.0, 23.0, 1.10, 1.188000, 8.0, 23.5, 1147, 1146, 10, 2369, 5588); -INSERT INTO `char_templates` VALUES (6, 'Dark Avenger', 0, 40, 43, 30, 21, 11, 25, 4, 80, 6, 41, 300, 333, 33, 44, 33, 115, 81900, -71338, 258271, -3104, 0, 1.10, 1.188000, 9.0, 23.0, 1.10, 1.188000, 8.0, 23.5, 1147, 1146, 10, 2369, 5588); -INSERT INTO `char_templates` VALUES (7, 'Rogue', 0, 40, 43, 30, 21, 11, 25, 4, 80, 6, 41, 300, 333, 33, 44, 33, 115, 81900, -71338, 258271, -3104, 0, 1.10, 1.188000, 9.0, 23.0, 1.10, 1.188000, 8.0, 23.5, 1147, 1146, 10, 2369, 5588); -INSERT INTO `char_templates` VALUES (8, 'Treasure Hunter', 0, 40, 43, 30, 21, 11, 25, 4, 80, 6, 41, 300, 333, 33, 44, 33, 115, 81900, -71338, 258271, -3104, 0, 1.10, 1.188000, 9.0, 23.0, 1.10, 1.188000, 8.0, 23.5, 1147, 1146, 10, 2369, 5588); -INSERT INTO `char_templates` VALUES (9, 'Hawkeye', 0, 40, 43, 30, 21, 11, 25, 4, 80, 6, 41, 300, 333, 33, 44, 33, 115, 81900, -71338, 258271, -3104, 0, 1.10, 1.188000, 9.0, 23.0, 1.10, 1.188000, 8.0, 23.5, 1147, 1146, 10, 2369, 5588); -INSERT INTO `char_templates` VALUES (10, 'Human Mage', 0, 22, 27, 21, 41, 20, 39, 3, 54, 6, 41, 300, 333, 28, 40, 28, 120, 62500, -90890, 248027, -3570, 0, 1.01, 0.872640, 7.5, 22.8, 1.01, 0.872640, 6.5, 22.5, 425, 461, 6, 5588, 0); -INSERT INTO `char_templates` VALUES (11, 'Human Wizard', 0, 22, 27, 21, 41, 20, 39, 3, 54, 6, 41, 300, 333, 28, 40, 28, 120, 62500, -90890, 248027, -3570, 0, 1.01, 0.872640, 7.5, 22.8, 1.01, 0.872640, 6.5, 22.5, 425, 461, 6, 5588, 0); -INSERT INTO `char_templates` VALUES (12, 'Sorcerer', 0, 22, 27, 21, 41, 20, 39, 3, 54, 6, 41, 300, 333, 28, 40, 28, 120, 62500, -90890, 248027, -3570, 0, 1.01, 0.872640, 7.5, 22.8, 1.01, 0.872640, 6.5, 22.5, 425, 461, 6, 5588, 0); -INSERT INTO `char_templates` VALUES (13, 'Necromancer', 0, 22, 27, 21, 41, 20, 39, 3, 54, 6, 41, 300, 333, 28, 40, 28, 120, 62500, -90890, 248027, -3570, 0, 1.01, 0.872640, 7.5, 22.8, 1.01, 0.872640, 6.5, 22.5, 425, 461, 6, 5588, 0); -INSERT INTO `char_templates` VALUES (14, 'Warlock', 0, 22, 27, 21, 41, 20, 39, 3, 54, 6, 41, 300, 333, 28, 40, 28, 120, 62500, -90890, 248027, -3570, 0, 1.01, 0.872640, 7.5, 22.8, 1.01, 0.872640, 6.5, 22.5, 425, 461, 6, 5588, 0); -INSERT INTO `char_templates` VALUES (15, 'Cleric', 0, 22, 27, 21, 41, 20, 39, 3, 54, 6, 41, 300, 333, 28, 40, 28, 120, 62500, -90890, 248027, -3570, 0, 1.01, 0.872640, 7.5, 22.8, 1.01, 0.872640, 6.5, 22.5, 425, 461, 6, 5588, 0); -INSERT INTO `char_templates` VALUES (16, 'Bishop', 0, 22, 27, 21, 41, 20, 39, 3, 54, 6, 41, 300, 333, 28, 40, 28, 120, 62500, -90890, 248027, -3570, 0, 1.01, 0.872640, 7.5, 22.8, 1.01, 0.872640, 6.5, 22.5, 425, 461, 6, 5588, 0); -INSERT INTO `char_templates` VALUES (17, 'Human Prophet', 0, 22, 27, 21, 41, 20, 39, 3, 54, 6, 41, 300, 333, 28, 40, 28, 120, 62500, -90890, 248027, -3570, 0, 1.01, 0.872640, 7.5, 22.8, 1.01, 0.872640, 6.5, 22.5, 425, 461, 6, 5588, 0); -INSERT INTO `char_templates` VALUES (18, 'Elf Fighter', 1, 36, 36, 35, 23, 14, 26, 4, 80, 6, 41, 300, 333, 36, 46, 36, 125, 73000, 45978, 41196, -3440, 0, 1.15, 1.242000, 7.5, 24.0, 1.15, 1.242000, 7.5, 23.0, 1147, 1146, 10, 2369, 5588); -INSERT INTO `char_templates` VALUES (19, 'Elf Knight', 1, 36, 36, 35, 23, 14, 26, 4, 80, 6, 41, 300, 333, 36, 46, 36, 125, 73000, 45978, 41196, -3440, 0, 1.15, 1.242000, 7.5, 24.0, 1.15, 1.242000, 7.5, 23.0, 1147, 1146, 10, 2369, 5588); -INSERT INTO `char_templates` VALUES (20, 'Temple Knight', 1, 36, 36, 35, 23, 14, 26, 4, 80, 6, 41, 300, 333, 36, 46, 36, 125, 73000, 45978, 41196, -3440, 0, 1.15, 1.242000, 7.5, 24.0, 1.15, 1.242000, 7.5, 23.0, 1147, 1146, 10, 2369, 5588); -INSERT INTO `char_templates` VALUES (21, 'Swordsinger', 1, 36, 36, 35, 23, 14, 26, 4, 80, 6, 41, 300, 333, 36, 46, 36, 125, 73000, 45978, 41196, -3440, 0, 1.15, 1.242000, 7.5, 24.0, 1.15, 1.242000, 7.5, 23.0, 1147, 1146, 10, 2369, 5588); -INSERT INTO `char_templates` VALUES (22, 'Scout', 1, 36, 36, 35, 23, 14, 26, 4, 80, 6, 41, 300, 333, 36, 46, 36, 125, 73000, 45978, 41196, -3440, 0, 1.15, 1.242000, 7.5, 24.0, 1.15, 1.242000, 7.5, 23.0, 1147, 1146, 10, 2369, 5588); -INSERT INTO `char_templates` VALUES (23, 'Plains Walker', 1, 36, 36, 35, 23, 14, 26, 4, 80, 6, 41, 300, 333, 36, 46, 36, 125, 73000, 45978, 41196, -3440, 0, 1.15, 1.242000, 7.5, 24.0, 1.15, 1.242000, 7.5, 23.0, 1147, 1146, 10, 2369, 5588); -INSERT INTO `char_templates` VALUES (24, 'Silver Ranger', 1, 36, 36, 35, 23, 14, 26, 4, 80, 6, 41, 300, 333, 36, 46, 36, 125, 73000, 45978, 41196, -3440, 0, 1.15, 1.242000, 7.5, 24.0, 1.15, 1.242000, 7.5, 23.0, 1147, 1146, 10, 2369, 5588); -INSERT INTO `char_templates` VALUES (25, 'Elf Mage', 1, 21, 25, 24, 37, 23, 40, 3, 54, 6, 41, 300, 333, 30, 41, 30, 122, 62400, 46182, 41198, -3440, 0, 1.04, 0.898560, 7.5, 24.0, 1.04, 0.898560, 7.5, 23.0, 425, 461, 6, 5588, 0); -INSERT INTO `char_templates` VALUES (26, 'Elf Wizard', 1, 21, 25, 24, 37, 23, 40, 3, 54, 6, 41, 300, 333, 30, 41, 30, 122, 62400, 46182, 41198, -3440, 0, 1.04, 0.898560, 7.5, 24.0, 1.04, 0.898560, 7.5, 23.0, 425, 461, 6, 5588, 0); -INSERT INTO `char_templates` VALUES (27, 'Spellsinger', 1, 21, 25, 24, 37, 23, 40, 3, 54, 6, 41, 300, 333, 30, 41, 30, 122, 62400, 46182, 41198, -3440, 0, 1.04, 0.898560, 7.5, 24.0, 1.04, 0.898560, 7.5, 23.0, 425, 461, 6, 5588, 0); -INSERT INTO `char_templates` VALUES (28, 'Elemental Summoner', 1, 21, 25, 24, 37, 23, 40, 3, 54, 6, 41, 300, 333, 30, 41, 30, 122, 62400, 46182, 41198, -3440, 0, 1.04, 0.898560, 7.5, 24.0, 1.04, 0.898560, 7.5, 23.0, 425, 461, 6, 5588, 0); -INSERT INTO `char_templates` VALUES (29, 'Oracle', 1, 21, 25, 24, 37, 23, 40, 3, 54, 6, 41, 300, 333, 30, 41, 30, 122, 62400, 46182, 41198, -3440, 0, 1.04, 0.898560, 7.5, 24.0, 1.04, 0.898560, 7.5, 23.0, 425, 461, 6, 5588, 0); -INSERT INTO `char_templates` VALUES (30, 'Elder', 1, 21, 25, 24, 37, 23, 40, 3, 54, 6, 41, 300, 333, 30, 41, 30, 122, 62400, 46182, 41198, -3440, 0, 1.04, 0.898560, 7.5, 24.0, 1.04, 0.898560, 7.5, 23.0, 425, 461, 6, 5588, 0); -INSERT INTO `char_templates` VALUES (31, 'DE Fighter', 2, 41, 32, 34, 25, 12, 26, 4, 80, 6, 41, 300, 333, 35, 45, 35, 122, 69000, 28377, 10916, -4224, 0, 1.14, 1.231200, 7.5, 24.0, 1.14, 1.231200, 7.0, 23.5, 1147, 1146, 10, 2369, 5588); -INSERT INTO `char_templates` VALUES (32, 'Palus Knight', 2, 41, 32, 34, 25, 12, 26, 4, 80, 6, 41, 300, 333, 35, 45, 35, 122, 69000, 28377, 10916, -4224, 0, 1.14, 1.231200, 7.5, 24.0, 1.14, 1.231200, 7.0, 23.5, 1147, 1146, 10, 2369, 5588); -INSERT INTO `char_templates` VALUES (33, 'Shillien Knight', 2, 41, 32, 34, 25, 12, 26, 4, 80, 6, 41, 300, 333, 35, 45, 35, 122, 69000, 28377, 10916, -4224, 0, 1.14, 1.231200, 7.5, 24.0, 1.14, 1.231200, 7.0, 23.5, 1147, 1146, 10, 2369, 5588); -INSERT INTO `char_templates` VALUES (34, 'Bladedancer', 2, 41, 32, 34, 25, 12, 26, 4, 80, 6, 41, 300, 333, 35, 45, 35, 122, 69000, 28377, 10916, -4224, 0, 1.14, 1.231200, 7.5, 24.0, 1.14, 1.231200, 7.0, 23.5, 1147, 1146, 10, 2369, 5588); -INSERT INTO `char_templates` VALUES (35, 'Assassin', 2, 41, 32, 34, 25, 12, 26, 4, 80, 6, 41, 300, 333, 35, 45, 35, 122, 69000, 28377, 10916, -4224, 0, 1.14, 1.231200, 7.5, 24.0, 1.14, 1.231200, 7.0, 23.5, 1147, 1146, 10, 2369, 5588); -INSERT INTO `char_templates` VALUES (36, 'Abyss Walker', 2, 41, 32, 34, 25, 12, 26, 4, 80, 6, 41, 300, 333, 35, 45, 35, 122, 69000, 28377, 10916, -4224, 0, 1.14, 1.231200, 7.5, 24.0, 1.14, 1.231200, 7.0, 23.5, 1147, 1146, 10, 2369, 5588); -INSERT INTO `char_templates` VALUES (37, 'Phantom Ranger', 2, 41, 32, 34, 25, 12, 26, 4, 80, 6, 41, 300, 333, 35, 45, 35, 122, 69000, 28377, 10916, -4224, 0, 1.14, 1.231200, 7.5, 24.0, 1.14, 1.231200, 7.0, 23.5, 1147, 1146, 10, 2369, 5588); -INSERT INTO `char_templates` VALUES (38, 'DE Mage', 2, 23, 24, 23, 44, 19, 37, 3, 54, 6, 41, 300, 333, 29, 41, 29, 122, 61000, 28295, 11063, -4224, 0, 1.14, 1.231200, 7.5, 24.0, 1.03, 0.889920, 7.0, 23.5, 425, 461, 6, 5588, 0); -INSERT INTO `char_templates` VALUES (39, 'DE Wizard', 2, 23, 24, 23, 44, 19, 37, 3, 54, 6, 41, 300, 333, 29, 41, 29, 122, 61000, 28295, 11063, -4224, 0, 1.14, 1.231200, 7.5, 24.0, 1.03, 0.889920, 7.0, 23.5, 425, 461, 6, 5588, 0); -INSERT INTO `char_templates` VALUES (40, 'Spell Howler', 2, 23, 24, 23, 44, 19, 37, 3, 54, 6, 41, 300, 333, 29, 41, 29, 122, 61000, 28295, 11063, -4224, 0, 1.14, 1.231200, 7.5, 24.0, 1.03, 0.889920, 7.0, 23.5, 425, 461, 6, 5588, 0); -INSERT INTO `char_templates` VALUES (41, 'Phantom Summoner', 2, 23, 24, 23, 44, 19, 37, 3, 54, 6, 41, 300, 333, 29, 41, 29, 122, 61000, 28295, 11063, -4224, 0, 1.14, 1.231200, 7.5, 24.0, 1.03, 0.889920, 7.0, 23.5, 425, 461, 6, 5588, 0); -INSERT INTO `char_templates` VALUES (42, 'Shillien Oracle', 2, 23, 24, 23, 44, 19, 37, 3, 54, 6, 41, 300, 333, 29, 41, 29, 122, 61000, 28295, 11063, -4224, 0, 1.14, 1.231200, 7.5, 24.0, 1.03, 0.889920, 7.0, 23.5, 425, 461, 6, 5588, 0); -INSERT INTO `char_templates` VALUES (43, 'Shillien Elder', 2, 23, 24, 23, 44, 19, 37, 3, 54, 6, 41, 300, 333, 29, 41, 29, 122, 61000, 28295, 11063, -4224, 0, 1.14, 1.231200, 7.5, 24.0, 1.03, 0.889920, 7.0, 23.5, 425, 461, 6, 5588, 0); -INSERT INTO `char_templates` VALUES (44, 'Orc Fighter', 3, 40, 47, 26, 18, 12, 27, 4, 80, 6, 41, 300, 333, 31, 42, 31, 117, 87000, -56693, -113610, -690, 0, 1.06, 1.144800, 11.0, 28.0, 1.06, 1.144800, 7.0, 27.0, 1147, 1146, 2368, 2369, 5588); -INSERT INTO `char_templates` VALUES (45, 'Raider', 3, 40, 47, 26, 18, 12, 27, 4, 80, 6, 41, 300, 333, 31, 42, 31, 117, 87000, -56693, -113610, -690, 0, 1.06, 1.144800, 11.0, 28.0, 1.06, 1.144800, 7.0, 27.0, 1147, 1146, 2368, 2369, 5588); -INSERT INTO `char_templates` VALUES (46, 'Destroyer', 3, 40, 47, 26, 18, 12, 27, 4, 80, 6, 41, 300, 333, 31, 42, 31, 117, 87000, -56693, -113610, -690, 0, 1.06, 1.144800, 11.0, 28.0, 1.06, 1.144800, 7.0, 27.0, 1147, 1146, 2368, 2369, 5588); -INSERT INTO `char_templates` VALUES (47, 'Monk', 3, 40, 47, 26, 18, 12, 27, 4, 80, 6, 41, 300, 333, 31, 42, 31, 117, 87000, -56682, -113610, -690, 0, 1.06, 1.144800, 11.0, 28.0, 1.06, 1.144800, 7.0, 27.0, 1147, 1146, 2368, 2369, 5588); -INSERT INTO `char_templates` VALUES (48, 'Tyrant', 3, 40, 47, 26, 18, 12, 27, 4, 80, 6, 41, 300, 333, 31, 42, 31, 117, 87000, -56693, -113610, -690, 0, 1.06, 1.144800, 11.0, 28.0, 1.06, 1.144800, 7.0, 27.0, 1147, 1146, 2368, 2369, 5588); -INSERT INTO `char_templates` VALUES (49, 'Orc Mage', 3, 27, 31, 24, 31, 15, 42, 3, 54, 6, 41, 300, 333, 30, 41, 30, 121, 68000, -56682, -113730, -690, 0, 1.04, 0.898560, 7.0, 27.5, 1.04, 0.898560, 8.0, 25.5, 425, 461, 2368, 5588, 0); -INSERT INTO `char_templates` VALUES (50, 'Shaman', 3, 27, 31, 24, 31, 15, 42, 3, 54, 6, 41, 300, 333, 30, 41, 30, 121, 68000, -56682, -113730, -690, 0, 1.04, 0.898560, 7.0, 27.5, 1.04, 0.898560, 8.0, 25.5, 425, 461, 2368, 5588, 0); -INSERT INTO `char_templates` VALUES (51, 'Overlord', 3, 27, 31, 24, 31, 15, 42, 3, 54, 6, 41, 300, 333, 30, 41, 30, 121, 68000, -56682, -113730, -690, 0, 1.04, 0.898560, 7.0, 27.5, 1.04, 0.898560, 8.0, 25.5, 425, 461, 2368, 5588, 0); -INSERT INTO `char_templates` VALUES (52, 'Warcryer', 3, 27, 31, 24, 31, 15, 42, 3, 54, 6, 41, 300, 333, 30, 41, 30, 121, 68000, -56682, -113730, -690, 0, 1.04, 0.898560, 7.0, 27.5, 1.04, 0.898560, 8.0, 25.5, 425, 461, 2368, 5588, 0); -INSERT INTO `char_templates` VALUES (53, 'Dwarf Fighter', 4, 39, 45, 29, 20, 10, 27, 4, 80, 6, 41, 300, 333, 33, 43, 33, 115, 83000, 108512, -174026, -400, 1, 1.09, 1.487196, 9.0, 18.0, 1.09, 1.487196, 5.0, 19.0, 1147, 1146, 10, 2370, 5588); -INSERT INTO `char_templates` VALUES (54, 'Scavenger', 4, 39, 45, 29, 20, 10, 27, 4, 80, 6, 41, 300, 333, 33, 43, 33, 115, 83000, 108512, -174026, -400, 1, 1.09, 1.487196, 9.0, 18.0, 1.09, 1.487196, 5.0, 19.0, 1147, 1146, 10, 2370, 5588); -INSERT INTO `char_templates` VALUES (55, 'Bounty Hunter', 4, 39, 45, 29, 20, 10, 27, 4, 80, 6, 41, 300, 333, 33, 43, 33, 115, 83000, 108512, -174026, -400, 1, 1.09, 1.487196, 9.0, 18.0, 1.09, 1.487196, 5.0, 19.0, 1147, 1146, 10, 2370, 5588); -INSERT INTO `char_templates` VALUES (56, 'Artisan', 4, 39, 45, 29, 20, 10, 27, 4, 80, 6, 41, 300, 333, 33, 43, 33, 115, 83000, 108512, -174026, -400, 1, 1.09, 1.487196, 9.0, 18.0, 1.09, 1.487196, 5.0, 19.0, 1147, 1146, 10, 2370, 5588); -INSERT INTO `char_templates` VALUES (57, 'Warsmith', 4, 39, 45, 29, 20, 10, 27, 4, 80, 6, 41, 300, 333, 33, 43, 33, 115, 83000, 108512, -174026, -400, 1, 1.09, 1.487196, 9.0, 18.0, 1.09, 1.487196, 5.0, 19.0, 1147, 1146, 10, 2370, 5588); -INSERT INTO `char_templates` VALUES (88, 'Duelist', 0, 40, 43, 30, 21, 11, 25, 4, 80, 6, 41, 300, 333, 33, 44, 33, 115, 81900, -71338, 258271, -3104, 0, 1.10, 1.188000, 9.0, 23.0, 1.10, 1.188000, 8.0, 23.5, 1147, 1146, 10, 2369, 5588); -INSERT INTO `char_templates` VALUES (89, 'DreadNought', 0, 40, 43, 30, 21, 11, 25, 4, 80, 6, 41, 300, 333, 33, 44, 33, 115, 81900, -71338, 258271, -3104, 0, 1.10, 1.188000, 9.0, 23.0, 1.10, 1.188000, 8.0, 23.5, 1147, 1146, 10, 2369, 5588); -INSERT INTO `char_templates` VALUES (90, 'Phoenix Knight', 0, 40, 43, 30, 21, 11, 25, 4, 80, 6, 41, 300, 333, 33, 44, 33, 115, 81900, -71338, 258271, -3104, 0, 1.10, 1.188000, 9.0, 23.0, 1.10, 1.188000, 8.0, 23.5, 1147, 1146, 10, 2369, 5588); -INSERT INTO `char_templates` VALUES (91, 'Hell Knight', 0, 40, 43, 30, 21, 11, 25, 4, 80, 6, 41, 300, 333, 33, 44, 33, 115, 81900, -71338, 258271, -3104, 0, 1.10, 1.188000, 9.0, 23.0, 1.10, 1.188000, 8.0, 23.5, 1147, 1146, 10, 2369, 5588); -INSERT INTO `char_templates` VALUES (92, 'Sagittarius', 0, 40, 43, 30, 21, 11, 25, 4, 80, 6, 41, 300, 333, 33, 44, 33, 115, 81900, -71338, 258271, -3104, 0, 1.10, 1.188000, 9.0, 23.0, 1.10, 1.188000, 8.0, 23.5, 1147, 1146, 10, 2369, 5588); -INSERT INTO `char_templates` VALUES (93, 'Adventurer', 0, 40, 43, 30, 21, 11, 25, 4, 80, 6, 41, 300, 333, 33, 44, 33, 115, 81900, -71338, 258271, -3104, 0, 1.10, 1.188000, 9.0, 23.0, 1.10, 1.188000, 8.0, 23.5, 1147, 1146, 10, 2369, 5588); -INSERT INTO `char_templates` VALUES (94, 'Archmage', 0, 22, 27, 21, 41, 20, 39, 3, 54, 6, 41, 300, 333, 28, 40, 28, 120, 62500, -90890, 248027, -3570, 0, 1.01, 0.872640, 7.5, 22.8, 1.01, 0.872640, 6.5, 22.5, 425, 461, 6, 5588, 0); -INSERT INTO `char_templates` VALUES (95, 'Soultaker', 0, 22, 27, 21, 41, 20, 39, 3, 54, 6, 41, 300, 333, 28, 40, 28, 120, 62500, -90890, 248027, -3570, 0, 1.01, 0.872640, 7.5, 22.8, 1.01, 0.872640, 6.5, 22.5, 425, 461, 6, 5588, 0); -INSERT INTO `char_templates` VALUES (96, 'Arcana Lord', 0, 22, 27, 21, 41, 20, 39, 3, 54, 6, 41, 300, 333, 28, 40, 28, 120, 62500, -90890, 248027, -3570, 0, 1.01, 0.872640, 7.5, 22.8, 1.01, 0.872640, 6.5, 22.5, 425, 461, 6, 5588, 0); -INSERT INTO `char_templates` VALUES (97, 'Cardinal', 0, 22, 27, 21, 41, 20, 39, 3, 54, 6, 41, 300, 333, 28, 40, 28, 120, 62500, -90890, 248027, -3570, 0, 1.01, 0.872640, 7.5, 22.8, 1.01, 0.872640, 6.5, 22.5, 425, 461, 6, 5588, 0); -INSERT INTO `char_templates` VALUES (98, 'Hierophant', 0, 22, 27, 21, 41, 20, 39, 3, 54, 6, 41, 300, 333, 28, 40, 28, 120, 62500, -90890, 248027, -3570, 0, 1.01, 0.872640, 7.5, 22.8, 1.01, 0.872640, 6.5, 22.5, 425, 461, 6, 5588, 0); -INSERT INTO `char_templates` VALUES (99, 'Eva Templar', 1, 36, 36, 35, 23, 14, 26, 4, 80, 6, 41, 300, 333, 36, 46, 36, 125, 73000, 45978, 41196, -3440, 0, 1.15, 1.242000, 7.5, 24.0, 1.15, 1.242000, 7.5, 23.0, 1147, 1146, 10, 2369, 5588); -INSERT INTO `char_templates` VALUES (100, 'Sword Muse', 1, 36, 36, 35, 23, 14, 26, 4, 80, 6, 41, 300, 333, 36, 46, 36, 125, 73000, 45978, 41196, -3440, 0, 1.15, 1.242000, 7.5, 24.0, 1.15, 1.242000, 7.5, 23.0, 1147, 1146, 10, 2369, 5588); -INSERT INTO `char_templates` VALUES (101, 'Wind Rider', 1, 36, 36, 35, 23, 14, 26, 4, 80, 6, 41, 300, 333, 36, 46, 36, 125, 73000, 45978, 41196, -3440, 0, 1.15, 1.242000, 7.5, 24.0, 1.15, 1.242000, 7.5, 23.0, 1147, 1146, 10, 2369, 5588); -INSERT INTO `char_templates` VALUES (102, 'Moonlight Sentinel', 1, 36, 36, 35, 23, 14, 26, 4, 80, 6, 41, 300, 333, 36, 46, 36, 125, 73000, 45978, 41196, -3440, 0, 1.15, 1.242000, 7.5, 24.0, 1.15, 1.242000, 7.5, 23.0, 1147, 1146, 10, 2369, 5588); -INSERT INTO `char_templates` VALUES (103, 'Mystic Muse', 1, 21, 25, 24, 37, 23, 40, 3, 54, 6, 41, 300, 333, 30, 41, 30, 122, 62400, 46182, 41198, -3440, 0, 1.04, 0.898560, 7.5, 24.0, 1.04, 0.898560, 7.5, 23.0, 425, 461, 6, 5588, 0); -INSERT INTO `char_templates` VALUES (104, 'Elemental Master', 1, 21, 25, 24, 37, 23, 40, 3, 54, 6, 41, 300, 333, 30, 41, 30, 122, 62400, 46182, 41198, -3440, 0, 1.04, 0.898560, 7.5, 24.0, 1.04, 0.898560, 7.5, 23.0, 425, 461, 6, 5588, 0); -INSERT INTO `char_templates` VALUES (105, 'Eva Saint', 1, 21, 25, 24, 37, 23, 40, 3, 54, 6, 41, 300, 333, 30, 41, 30, 122, 62400, 46182, 41198, -3440, 0, 1.04, 0.898560, 7.5, 24.0, 1.04, 0.898560, 7.5, 23.0, 425, 461, 6, 5588, 0); -INSERT INTO `char_templates` VALUES (106, 'Shillien Templar', 2, 41, 32, 34, 25, 12, 26, 4, 80, 6, 41, 300, 333, 35, 45, 35, 122, 69000, 28377, 10916, -4224, 0, 1.14, 1.231200, 7.5, 24.0, 1.14, 1.231200, 7.0, 23.5, 1147, 1146, 10, 2369, 5588); -INSERT INTO `char_templates` VALUES (107, 'Spectral Dancer', 2, 41, 32, 34, 25, 12, 26, 4, 80, 6, 41, 300, 333, 35, 45, 35, 122, 69000, 28377, 10916, -4224, 0, 1.14, 1.231200, 7.5, 24.0, 1.14, 1.231200, 7.0, 23.5, 1147, 1146, 10, 2369, 5588); -INSERT INTO `char_templates` VALUES (108, 'Ghost Hunter', 2, 41, 32, 34, 25, 12, 26, 4, 80, 6, 41, 300, 333, 35, 45, 35, 122, 69000, 28377, 10916, -4224, 0, 1.14, 1.231200, 7.5, 24.0, 1.14, 1.231200, 7.0, 23.5, 1147, 1146, 10, 2369, 5588); -INSERT INTO `char_templates` VALUES (109, 'Ghost Sentinel', 2, 41, 32, 34, 25, 12, 26, 4, 80, 6, 41, 300, 333, 35, 45, 35, 122, 69000, 28377, 10916, -4224, 0, 1.14, 1.231200, 7.5, 24.0, 1.14, 1.231200, 7.0, 23.5, 1147, 1146, 10, 2369, 5588); -INSERT INTO `char_templates` VALUES (110, 'Storm Screamer', 2, 23, 24, 23, 44, 19, 37, 3, 54, 6, 41, 300, 333, 29, 41, 29, 122, 61000, 28295, 11063, -4224, 0, 1.14, 1.231200, 7.5, 24.0, 1.03, 0.889920, 7.0, 23.5, 425, 461, 6, 5588, 0); -INSERT INTO `char_templates` VALUES (111, 'Spectral Master', 2, 23, 24, 23, 44, 19, 37, 3, 54, 6, 41, 300, 333, 29, 41, 29, 122, 61000, 28295, 11063, -4224, 0, 1.14, 1.231200, 7.5, 24.0, 1.03, 0.889920, 7.0, 23.5, 425, 461, 6, 5588, 0); -INSERT INTO `char_templates` VALUES (112, 'Shillen Saint', 2, 23, 24, 23, 44, 19, 37, 3, 54, 6, 41, 300, 333, 29, 41, 29, 122, 61000, 28295, 11063, -4224, 0, 1.14, 1.231200, 7.5, 24.0, 1.03, 0.889920, 7.0, 23.5, 425, 461, 6, 5588, 0); -INSERT INTO `char_templates` VALUES (113, 'Titan', 3, 40, 47, 26, 18, 12, 27, 4, 80, 6, 41, 300, 333, 31, 42, 31, 117, 87000, -56693, -113610, -690, 0, 1.06, 1.144800, 11.0, 28.0, 1.06, 1.144800, 7.0, 27.0, 1147, 1146, 2368, 2369, 5588); -INSERT INTO `char_templates` VALUES (114, 'Grand Khauatari', 3, 40, 47, 26, 18, 12, 27, 4, 80, 6, 41, 300, 333, 31, 42, 31, 117, 87000, -56693, -113610, -690, 0, 1.06, 1.144800, 11.0, 28.0, 1.06, 1.144800, 7.0, 27.0, 1147, 1146, 2368, 2369, 5588); -INSERT INTO `char_templates` VALUES (115, 'Dominator', 3, 27, 31, 24, 31, 15, 42, 3, 54, 6, 41, 300, 333, 30, 41, 30, 121, 68000, -56682, -113730, -690, 0, 1.04, 0.898560, 7.0, 27.5, 1.04, 0.898560, 8.0, 25.5, 425, 461, 2368, 5588, 0); -INSERT INTO `char_templates` VALUES (116, 'Doomcryer', 3, 27, 31, 24, 31, 15, 42, 3, 54, 6, 41, 300, 333, 30, 41, 30, 121, 68000, -56682, -113730, -690, 0, 1.04, 0.898560, 7.0, 27.5, 1.04, 0.898560, 8.0, 25.5, 425, 461, 2368, 5588, 0); -INSERT INTO `char_templates` VALUES (117, 'Fortune Seeker', 4, 39, 45, 29, 20, 10, 27, 4, 80, 6, 41, 300, 333, 33, 43, 33, 115, 83000, 108512, -174026, -400, 1, 1.09, 1.487196, 9.0, 18.0, 1.09, 1.487196, 5.0, 19.0, 1147, 1146, 10, 2370, 5588); -INSERT INTO `char_templates` VALUES (118, 'Maestro', 4, 39, 45, 29, 20, 10, 27, 4, 80, 6, 41, 300, 333, 33, 43, 33, 115, 83000, 108512, -174026, -400, 1, 1.09, 1.487196, 9.0, 18.0, 1.09, 1.487196, 5.0, 19.0, 1147, 1146, 10, 2370, 5588); diff --git a/L2J_Mobius_C6_Interlude/dist/db_installer/sql/game/class_list.sql b/L2J_Mobius_C6_Interlude/dist/db_installer/sql/game/class_list.sql deleted file mode 100644 index 70534f73be..0000000000 --- a/L2J_Mobius_C6_Interlude/dist/db_installer/sql/game/class_list.sql +++ /dev/null @@ -1,105 +0,0 @@ -#---------------------------- -# Table structure for class_list -#---------------------------- -DROP TABLE IF EXISTS class_list; -CREATE TABLE `class_list` ( - `class_name` varchar(19) NOT NULL default '', - `id` int(10) unsigned NOT NULL default '0', - `parent_id` int(11) NOT NULL default '0', - PRIMARY KEY (`id`) -) ENGINE=MyISAM DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; - -#---------------------------- -# Records for table class_list -#---------------------------- - -INSERT INTO `class_list` VALUES -('H_Fighter', 0, -1), -('H_Warrior', 1, 0), -('H_Gladiator', 2, 1), -('H_Duelist', 88, 2), -('H_Warlord', 3, 1), -('H_Dreadnought', 89, 3), -('H_Knight', 4, 0), -('H_Paladin', 5, 4), -('H_PhoenixKnight', 90, 5), -('H_DarkAvenger', 6, 4), -('H_HellKnight', 91, 6), -('H_Rogue', 7, 0), -('H_TreasureHunter', 8, 7), -('H_Adventurer', 93, 8), -('H_Hawkeye', 9, 7), -('H_Sagittarius', 92, 9), -('H_Mage', 10, -1), -('H_Wizard', 11, 10), -('H_Sorceror', 12, 11), -('H_Archmage', 94, 12), -('H_Necromancer', 13, 11), -('H_Soultaker', 95, 13), -('H_Warlock', 14, 11), -('H_ArcanaLord', 96, 14), -('H_Cleric', 15, 10), -('H_Bishop', 16, 15), -('H_Cardinal', 97, 16), -('H_Prophet', 17, 15), -('H_Hierophant', 98, 17), -('E_Fighter', 18, -1), -('E_Knight', 19, 18), -('E_TempleKnight', 20, 19), -('E_EvaTemplar', 99, 20), -('E_SwordSinger', 21, 19), -('E_SwordMuse', 100, 21), -('E_Scout', 22, 18), -('E_PlainsWalker', 23, 22), -('E_WindRider', 101, 23), -('E_SilverRanger', 24, 22), -('E_MoonlightSentinel', 102, 24), -('E_Mage', 25, -1), -('E_Wizard', 26, 25), -('E_SpellSinger', 27, 26), -('E_MysticMuse', 103, 27), -('E_ElementalSummoner', 28, 26), -('E_ElementalMaster', 104, 28), -('E_Oracle', 29, 25), -('E_Elder', 30, 29), -('E_EvaSaint', 105, 30), -('DE_Fighter', 31, -1), -('DE_PaulusKnight', 32, 31), -('DE_ShillienKnight', 33, 32), -('DE_ShillienTemplar', 106, 33), -('DE_BladeDancer', 34, 32), -('DE_SpectralDancer', 107, 34), -('DE_Assassin', 35, 31), -('DE_AbyssWalker', 36, 35), -('DE_GhostHunter', 108, 36), -('DE_PhantomRanger', 37, 35), -('DE_GhostSentinel', 109, 37), -('DE_Mage', 38, -1), -('DE_DarkWizard', 39, 38), -('DE_Spellhowler', 40, 39), -('DE_StormScreamer', 110, 40), -('DE_PhantomSummoner', 41, 39), -('DE_SpectralMaster', 111, 41), -('DE_ShillienOracle', 42, 38), -('DE_ShillienElder', 43, 42), -('DE_ShillienSaint', 112, 43), -('O_Fighter', 44, -1), -('O_Raider', 45, 44), -('O_Destroyer', 46, 45), -('O_Titan', 113, 46), -('O_Monk', 47, 44), -('O_Tyrant', 48, 47), -('O_GrandKhauatari', 114, 48), -('O_Mage', 49, -1), -('O_Shaman', 50, 49), -('O_Overlord', 51, 50), -('O_Dominator', 115, 51), -('O_Warcryer', 52, 50), -('O_Doomcryer', 116, 52), -('D_Fighter', 53, -1), -('D_Scavenger', 54, 53), -('D_BountyHunter', 55, 54), -('D_FortuneSeeker', 117, 55), -('D_Artisan', 56, 53), -('D_Warsmith', 57, 56), -('D_Maestro', 118, 57); \ No newline at end of file diff --git a/L2J_Mobius_C6_Interlude/dist/db_installer/sql/game/lvlupgain.sql b/L2J_Mobius_C6_Interlude/dist/db_installer/sql/game/lvlupgain.sql deleted file mode 100644 index 0af323bc5b..0000000000 --- a/L2J_Mobius_C6_Interlude/dist/db_installer/sql/game/lvlupgain.sql +++ /dev/null @@ -1,113 +0,0 @@ --- --- Table structure for table `lvlupgain` --- - -DROP TABLE IF EXISTS `lvlupgain`; -CREATE TABLE `lvlupgain` ( - `classid` int(3) NOT NULL default '0', - `defaulthpbase` decimal(5,1) NOT NULL default '0.0', - `defaulthpadd` decimal(4,2) NOT NULL default '0.00', - `defaulthpmod` decimal(4,2) NOT NULL default '0.00', - `defaultcpbase` decimal(5,1) NOT NULL default '0.0', - `defaultcpadd` decimal(4,2) NOT NULL default '0.00', - `defaultcpmod` decimal(4,2) NOT NULL default '0.00', - `defaultmpbase` decimal(5,1) NOT NULL default '0.0', - `defaultmpadd` decimal(4,2) NOT NULL default '0.00', - `defaultmpmod` decimal(4,2) NOT NULL default '0.00', - `class_lvl` int(3) NOT NULL default '0', - PRIMARY KEY (`classid`) -) ENGINE=MyISAM DEFAULT CHARSET=latin1 COLLATE=latin1_general_ci; - --- --- Dumping data for table `lvlupgain` --- - -INSERT INTO `lvlupgain` VALUES ('0', '80.0', '11.83', '0.37', '32.0', '4.73', '0.22', '30.0', '5.46', '0.14', '1'); -INSERT INTO `lvlupgain` VALUES ('1', '327.0', '33.00', '0.37', '261.6', '26.40', '0.22', '144.0', '9.90', '0.14', '20'); -INSERT INTO `lvlupgain` VALUES ('2', '1044.0', '49.40', '0.37', '939.6', '44.46', '0.22', '359.1', '19.50', '0.14', '40'); -INSERT INTO `lvlupgain` VALUES ('3', '1044.0', '54.60', '0.37', '835.2', '43.68', '0.22', '359.1', '19.50', '0.14', '40'); -INSERT INTO `lvlupgain` VALUES ('4', '327.0', '29.70', '0.37', '196.2', '17.82', '0.22', '144.0', '9.90', '0.14', '20'); -INSERT INTO `lvlupgain` VALUES ('5', '972.3', '46.80', '0.37', '583.3', '28.08', '0.22', '359.1', '19.50', '0.14', '40'); -INSERT INTO `lvlupgain` VALUES ('6', '972.3', '46.80', '0.37', '583.3', '28.08', '0.22', '359.1', '19.50', '0.14', '40'); -INSERT INTO `lvlupgain` VALUES ('7', '327.0', '27.50', '0.37', '130.8', '11.00', '0.22', '144.0', '9.90', '0.14', '20'); -INSERT INTO `lvlupgain` VALUES ('8', '924.5', '41.60', '0.37', '369.8', '16.64', '0.22', '359.1', '19.50', '0.14', '40'); -INSERT INTO `lvlupgain` VALUES ('9', '924.5', '44.20', '0.37', '647.1', '30.94', '0.22', '359.1', '19.50', '0.14', '40'); -INSERT INTO `lvlupgain` VALUES ('10', '101.0', '15.57', '0.37', '50.5', '7.84', '0.22', '40.0', '7.38', '0.14', '1'); -INSERT INTO `lvlupgain` VALUES ('11', '424.0', '27.60', '0.37', '212.0', '13.85', '0.22', '192.0', '13.30', '0.14', '20'); -INSERT INTO `lvlupgain` VALUES ('12', '1021.5', '45.60', '0.37', '510.7', '22.85', '0.22', '478.8', '26.10', '0.14', '40'); -INSERT INTO `lvlupgain` VALUES ('13', '1021.5', '45.60', '0.37', '510.7', '22.85', '0.22', '478.8', '26.10', '0.14', '40'); -INSERT INTO `lvlupgain` VALUES ('14', '1021.5', '49.50', '0.37', '612.9', '29.74', '0.22', '478.8', '26.10', '0.14', '40'); -INSERT INTO `lvlupgain` VALUES ('15', '424.0', '34.20', '0.37', '212.0', '17.15', '0.22', '192.0', '13.30', '0.14', '20'); -INSERT INTO `lvlupgain` VALUES ('16', '1164.9', '49.50', '0.37', '815.4', '34.68', '0.22', '478.8', '26.10', '0.14', '40'); -INSERT INTO `lvlupgain` VALUES ('17', '1164.9', '53.40', '0.37', '582.4', '26.75', '0.22', '478.8', '26.10', '0.14', '40'); -INSERT INTO `lvlupgain` VALUES ('18', '89.0', '12.74', '0.37', '35.6', '5.00', '0.22', '30.0', '5.46', '0.14', '1'); -INSERT INTO `lvlupgain` VALUES ('19', '355.0', '33.00', '0.37', '177.5', '16.50', '0.22', '144.0', '9.90', '0.14', '20'); -INSERT INTO `lvlupgain` VALUES ('20', '1072.0', '52.00', '0.37', '643.2', '31.20', '0.22', '359.1', '19.50', '0.14', '40'); -INSERT INTO `lvlupgain` VALUES ('21', '1072.0', '54.60', '0.37', '536.0', '27.30', '0.22', '359.1', '19.50', '0.14', '40'); -INSERT INTO `lvlupgain` VALUES ('22', '355.0', '30.80', '0.37', '142.0', '12.32', '0.22', '144.0', '9.90', '0.14', '20'); -INSERT INTO `lvlupgain` VALUES ('23', '1024.2', '46.80', '0.37', '409.6', '18.72', '0.22', '359.1', '19.50', '0.14', '40'); -INSERT INTO `lvlupgain` VALUES ('24', '1024.2', '49.40', '0.37', '512.1', '24.70', '0.22', '359.1', '19.50', '0.14', '40'); -INSERT INTO `lvlupgain` VALUES ('25', '104.0', '15.57', '0.37', '52.0', '7.84', '0.22', '40.0', '7.38', '0.14', '1'); -INSERT INTO `lvlupgain` VALUES ('26', '427.0', '28.70', '0.37', '213.5', '14.40', '0.22', '192.0', '13.30', '0.14', '20'); -INSERT INTO `lvlupgain` VALUES ('27', '1048.4', '48.20', '0.37', '524.2', '24.15', '0.22', '478.8', '26.10', '0.14', '40'); -INSERT INTO `lvlupgain` VALUES ('28', '1048.4', '50.80', '0.37', '629.0', '30.52', '0.22', '478.8', '26.10', '0.14', '40'); -INSERT INTO `lvlupgain` VALUES ('29', '427.0', '35.30', '0.37', '213.5', '17.70', '0.22', '192.0', '13.30', '0.14', '20'); -INSERT INTO `lvlupgain` VALUES ('30', '1191.8', '54.70', '0.37', '595.9', '27.40', '0.22', '478.8', '26.10', '0.14', '40'); -INSERT INTO `lvlupgain` VALUES ('31', '94.0', '13.65', '0.37', '37.6', '5.46', '0.22', '30.0', '5.46', '0.14', '1'); -INSERT INTO `lvlupgain` VALUES ('32', '379.0', '35.20', '0.37', '189.5', '17.60', '0.22', '144.0', '9.90', '0.14', '20'); -INSERT INTO `lvlupgain` VALUES ('33', '1143.8', '54.60', '0.37', '686.2', '32.76', '0.22', '359.1', '19.50', '0.14', '40'); -INSERT INTO `lvlupgain` VALUES ('34', '1143.8', '58.50', '0.37', '571.9', '29.25', '0.22', '359.1', '19.50', '0.14', '40'); -INSERT INTO `lvlupgain` VALUES ('35', '379.0', '33.00', '0.37', '151.6', '13.20', '0.22', '144.0', '9.90', '0.14', '20'); -INSERT INTO `lvlupgain` VALUES ('36', '1096.0', '49.40', '0.37', '438.4', '19.76', '0.22', '359.1', '19.50', '0.14', '40'); -INSERT INTO `lvlupgain` VALUES ('37', '1096.0', '52.00', '0.37', '548.0', '26.00', '0.22', '359.1', '19.50', '0.14', '40'); -INSERT INTO `lvlupgain` VALUES ('38', '106.0', '15.57', '0.37', '53.0', '7.84', '0.22', '40.0', '7.38', '0.14', '1'); -INSERT INTO `lvlupgain` VALUES ('39', '429.0', '29.80', '0.37', '214.5', '14.95', '0.22', '192.0', '13.30', '0.14', '20'); -INSERT INTO `lvlupgain` VALUES ('40', '1074.3', '48.20', '0.37', '537.1', '24.15', '0.22', '478.8', '26.10', '0.14', '40'); -INSERT INTO `lvlupgain` VALUES ('41', '1074.3', '52.10', '0.37', '644.5', '31.30', '0.22', '478.8', '26.10', '0.14', '40'); -INSERT INTO `lvlupgain` VALUES ('42', '429.0', '36.40', '0.37', '214.5', '18.25', '0.22', '192.0', '13.30', '0.14', '20'); -INSERT INTO `lvlupgain` VALUES ('43', '1217.7', '54.70', '0.37', '608.8', '27.40', '0.22', '478.8', '26.10', '0.14', '40'); -INSERT INTO `lvlupgain` VALUES ('44', '80.0', '12.64', '0.37', '40.0', '6.27', '0.22', '30.0', '5.36', '0.14', '1'); -INSERT INTO `lvlupgain` VALUES ('45', '346.0', '35.10', '0.37', '242.2', '24.54', '0.22', '144.0', '9.80', '0.14', '20'); -INSERT INTO `lvlupgain` VALUES ('46', '1110.8', '57.10', '0.37', '777.5', '39.94', '0.22', '359.1', '19.40', '0.14', '40'); -INSERT INTO `lvlupgain` VALUES ('47', '346.0', '32.90', '0.37', '173.0', '16.40', '0.22', '144.0', '9.80', '0.14', '20'); -INSERT INTO `lvlupgain` VALUES ('48', '1063.0', '54.50', '0.37', '531.5', '27.20', '0.22', '359.1', '19.40', '0.14', '40'); -INSERT INTO `lvlupgain` VALUES ('49', '95.0', '15.47', '0.37', '47.5', '7.74', '0.22', '40.0', '7.28', '0.14', '1'); -INSERT INTO `lvlupgain` VALUES ('50', '418.0', '35.20', '0.37', '209.0', '17.60', '0.22', '192.0', '13.20', '0.14', '20'); -INSERT INTO `lvlupgain` VALUES ('51', '1182.8', '53.30', '0.37', '946.2', '42.64', '0.22', '478.8', '26.00', '0.14', '40'); -INSERT INTO `lvlupgain` VALUES ('52', '1182.8', '53.30', '0.37', '591.4', '26.65', '0.22', '478.8', '26.00', '0.14', '40'); -INSERT INTO `lvlupgain` VALUES ('53', '80.0', '12.64', '0.37', '56.0', '8.82', '0.22', '30.0', '5.36', '0.14', '1'); -INSERT INTO `lvlupgain` VALUES ('54', '346.0', '35.10', '0.37', '242.2', '24.54', '0.22', '144.0', '9.80', '0.14', '20'); -INSERT INTO `lvlupgain` VALUES ('55', '1110.8', '57.10', '0.37', '777.5', '39.94', '0.22', '359.1', '19.40', '0.14', '40'); -INSERT INTO `lvlupgain` VALUES ('56', '346.0', '32.90', '0.37', '276.8', '26.30', '0.22', '144.0', '9.80', '0.14', '20'); -INSERT INTO `lvlupgain` VALUES ('57', '1063.0', '54.50', '0.37', '850.4', '43.58', '0.22', '359.1', '19.40', '0.14', '40'); -INSERT INTO `lvlupgain` VALUES ('88', '3061.8', '63.08', '0.37', '2755.6', '56.77', '0.22', '1155.6', '24.90', '0.14', '76'); -INSERT INTO `lvlupgain` VALUES ('89', '3274.2', '69.72', '0.37', '2619.3', '55.78', '0.22', '1155.6', '24.90', '0.14', '76'); -INSERT INTO `lvlupgain` VALUES ('90', '2883.9', '59.76', '0.37', '1730.3', '35.86', '0.22', '1155.6', '24.90', '0.14', '76'); -INSERT INTO `lvlupgain` VALUES ('91', '2883.9', '59.76', '0.37', '1730.3', '35.86', '0.22', '1155.6', '24.90', '0.14', '76'); -INSERT INTO `lvlupgain` VALUES ('92', '2729.9', '56.44', '0.37', '1910.9', '39.51', '0.22', '1155.6', '24.90', '0.14', '76'); -INSERT INTO `lvlupgain` VALUES ('93', '2623.7', '53.12', '0.37', '1049.4', '21.25', '0.22', '1155.6', '24.90', '0.14', '76'); -INSERT INTO `lvlupgain` VALUES ('94', '2880.0', '58.10', '0.37', '1440.0', '29.05', '0.22', '1540.8', '33.20', '0.14', '76'); -INSERT INTO `lvlupgain` VALUES ('95', '2880.0', '58.10', '0.37', '1440.0', '29.05', '0.22', '1540.8', '33.20', '0.14', '76'); -INSERT INTO `lvlupgain` VALUES ('96', '3039.3', '63.08', '0.37', '1823.5', '37.85', '0.22', '1540.8', '33.20', '0.14', '76'); -INSERT INTO `lvlupgain` VALUES ('97', '3182.7', '63.08', '0.37', '2227.8', '44.16', '0.22', '1540.8', '33.20', '0.14', '76'); -INSERT INTO `lvlupgain` VALUES ('98', '3342.0', '68.06', '0.37', '1671.0', '34.03', '0.22', '1540.8', '33.20', '0.14', '76'); -INSERT INTO `lvlupgain` VALUES ('99', '3196.0', '66.40', '0.37', '1917.6', '39.84', '0.22', '1155.6', '24.90', '0.14', '76'); -INSERT INTO `lvlupgain` VALUES ('100', '3302.2', '69.72', '0.37', '1651.1', '34.86', '0.22', '1155.6', '24.90', '0.14', '76'); -INSERT INTO `lvlupgain` VALUES ('101', '2935.8', '59.76', '0.37', '1174.3', '23.90', '0.22', '1155.6', '24.90', '0.14', '76'); -INSERT INTO `lvlupgain` VALUES ('102', '3042.0', '63.08', '0.37', '1521.0', '31.54', '0.22', '1155.6', '24.90', '0.14', '76'); -INSERT INTO `lvlupgain` VALUES ('103', '3013.1', '61.42', '0.37', '1506.5', '30.71', '0.22', '1540.8', '33.20', '0.14', '76'); -INSERT INTO `lvlupgain` VALUES ('104', '3119.3', '64.74', '0.37', '1871.5', '38.84', '0.22', '1540.8', '33.20', '0.14', '76'); -INSERT INTO `lvlupgain` VALUES ('105', '3422.0', '69.72', '0.37', '1711.0', '34.86', '0.22', '1540.8', '33.20', '0.14', '76'); -INSERT INTO `lvlupgain` VALUES ('106', '3374.0', '69.72', '0.37', '2024.4', '41.83', '0.22', '1155.6', '24.90', '0.14', '76'); -INSERT INTO `lvlupgain` VALUES ('107', '3533.3', '74.70', '0.37', '1766.6', '37.35', '0.22', '1155.6', '24.90', '0.14', '76'); -INSERT INTO `lvlupgain` VALUES ('108', '3113.8', '63.08', '0.37', '1245.5', '25.23', '0.22', '1155.6', '24.90', '0.14', '76'); -INSERT INTO `lvlupgain` VALUES ('109', '3220.0', '66.40', '0.37', '1610.0', '33.20', '0.22', '1155.6', '24.90', '0.14', '76'); -INSERT INTO `lvlupgain` VALUES ('110', '3039.0', '61.42', '0.37', '1519.5', '30.71', '0.22', '1540.8', '33.20', '0.14', '76'); -INSERT INTO `lvlupgain` VALUES ('111', '3198.3', '66.40', '0.37', '1918.9', '39.84', '0.22', '1540.8', '33.20', '0.14', '76'); -INSERT INTO `lvlupgain` VALUES ('112', '3447.9', '69.72', '0.37', '1723.9', '34.86', '0.22', '1540.8', '33.20', '0.14', '76'); -INSERT INTO `lvlupgain` VALUES ('113', '3447.2', '72.94', '0.37', '2413.0', '51.03', '0.22', '1155.6', '24.80', '0.14', '76'); -INSERT INTO `lvlupgain` VALUES ('114', '3293.2', '69.62', '0.37', '1646.6', '34.76', '0.22', '1155.6', '24.80', '0.14', '76'); -INSERT INTO `lvlupgain` VALUES ('115', '3359.9', '67.96', '0.37', '2687.9', '54.35', '0.22', '1540.8', '33.10', '0.14', '76'); -INSERT INTO `lvlupgain` VALUES ('116', '3359.9', '67.96', '0.37', '1679.9', '33.93', '0.22', '1540.8', '33.10', '0.14', '76'); -INSERT INTO `lvlupgain` VALUES ('117', '3447.2', '72.94', '0.37', '2413.0', '51.03', '0.22', '1155.6', '24.80', '0.14', '76'); -INSERT INTO `lvlupgain` VALUES ('118', '3293.2', '69.62', '0.37', '2634.5', '55.68', '0.22', '1155.6', '24.80', '0.14', '76'); \ No newline at end of file diff --git a/L2J_Mobius_C6_Interlude/dist/game/data/stats/playerTemplates.xml b/L2J_Mobius_C6_Interlude/dist/game/data/stats/playerTemplates.xml new file mode 100644 index 0000000000..b309242623 --- /dev/null +++ b/L2J_Mobius_C6_Interlude/dist/game/data/stats/playerTemplates.xml @@ -0,0 +1,92 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/L2J_Mobius_C6_Interlude/dist/game/data/xsd/playerTemplates.xsd b/L2J_Mobius_C6_Interlude/dist/game/data/xsd/playerTemplates.xsd new file mode 100644 index 0000000000..d7e57ffc9f --- /dev/null +++ b/L2J_Mobius_C6_Interlude/dist/game/data/xsd/playerTemplates.xsd @@ -0,0 +1,49 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/L2J_Mobius_C6_Interlude/java/org/l2jmobius/gameserver/GameServer.java b/L2J_Mobius_C6_Interlude/java/org/l2jmobius/gameserver/GameServer.java index 5d06160374..cad6c642c2 100644 --- a/L2J_Mobius_C6_Interlude/java/org/l2jmobius/gameserver/GameServer.java +++ b/L2J_Mobius_C6_Interlude/java/org/l2jmobius/gameserver/GameServer.java @@ -48,10 +48,8 @@ import org.l2jmobius.gameserver.datatables.OfflineTradeTable; import org.l2jmobius.gameserver.datatables.SchemeBufferTable; import org.l2jmobius.gameserver.datatables.SkillTable; import org.l2jmobius.gameserver.datatables.sql.CharNameTable; -import org.l2jmobius.gameserver.datatables.sql.CharTemplateTable; import org.l2jmobius.gameserver.datatables.sql.ClanTable; import org.l2jmobius.gameserver.datatables.sql.HelperBuffTable; -import org.l2jmobius.gameserver.datatables.sql.LevelUpData; import org.l2jmobius.gameserver.datatables.sql.NpcTable; import org.l2jmobius.gameserver.datatables.sql.PetDataTable; import org.l2jmobius.gameserver.datatables.sql.SkillSpellbookTable; @@ -70,6 +68,7 @@ import org.l2jmobius.gameserver.datatables.xml.FishData; import org.l2jmobius.gameserver.datatables.xml.HennaData; import org.l2jmobius.gameserver.datatables.xml.ManorSeedData; import org.l2jmobius.gameserver.datatables.xml.MapRegionData; +import org.l2jmobius.gameserver.datatables.xml.PlayerTemplateData; import org.l2jmobius.gameserver.datatables.xml.RecipeData; import org.l2jmobius.gameserver.datatables.xml.StaticObjectData; import org.l2jmobius.gameserver.datatables.xml.SummonItemData; @@ -216,10 +215,17 @@ public class GameServer ExperienceData.getInstance(); DuelManager.getInstance(); + Util.printSection("Players"); + PlayerTemplateData.getInstance(); if (Config.ENABLE_CLASS_DAMAGES) { ClassDamageManager.loadConfig(); } + ClanTable.getInstance(); + if (Config.ENABLE_COMMUNITY_BOARD) + { + ForumsBBSManager.getInstance().initRoot(); + } Util.printSection("Skills"); if (!SkillTable.getInstance().isInitialized()) @@ -231,6 +237,10 @@ public class GameServer SkillSpellbookTable.getInstance(); NobleSkillTable.getInstance(); HeroSkillTable.getInstance(); + if (!HelperBuffTable.getInstance().isInitialized()) + { + throw new Exception("Could not initialize the Helper Buff Table."); + } LOGGER.info("Skills: All skills loaded."); Util.printSection("Items"); @@ -238,6 +248,7 @@ public class GameServer ArmorSetData.getInstance(); ExtractableItemData.getInstance(); SummonItemData.getInstance(); + HennaData.getInstance(); if (Config.ALLOWFISHING) { FishData.getInstance(); @@ -252,22 +263,6 @@ public class GameServer throw new Exception("Could not initialize the npc table"); } - Util.printSection("Characters"); - if (Config.ENABLE_COMMUNITY_BOARD) - { - ForumsBBSManager.getInstance().initRoot(); - } - - ClanTable.getInstance(); - CharTemplateTable.getInstance(); - LevelUpData.getInstance(); - HennaData.getInstance(); - - if (!HelperBuffTable.getInstance().isInitialized()) - { - throw new Exception("Could not initialize the Helper Buff Table"); - } - Util.printSection("Geodata"); GeoEngine.getInstance(); diff --git a/L2J_Mobius_C6_Interlude/java/org/l2jmobius/gameserver/datatables/sql/CharTemplateTable.java b/L2J_Mobius_C6_Interlude/java/org/l2jmobius/gameserver/datatables/sql/CharTemplateTable.java deleted file mode 100644 index cfc8ee2f54..0000000000 --- a/L2J_Mobius_C6_Interlude/java/org/l2jmobius/gameserver/datatables/sql/CharTemplateTable.java +++ /dev/null @@ -1,279 +0,0 @@ -/* - * This file is part of the L2J Mobius project. - * - * This program is free software: you can redistribute it and/or modify - * it under the terms of the GNU General Public License as published by - * the Free Software Foundation, either version 3 of the License, or - * (at your option) any later version. - * - * This program is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - * General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with this program. If not, see . - */ -package org.l2jmobius.gameserver.datatables.sql; - -import java.sql.Connection; -import java.sql.PreparedStatement; -import java.sql.ResultSet; -import java.sql.SQLException; -import java.util.HashMap; -import java.util.Map; -import java.util.logging.Logger; - -import org.l2jmobius.commons.database.DatabaseFactory; -import org.l2jmobius.gameserver.model.StatSet; -import org.l2jmobius.gameserver.model.actor.templates.PlayerTemplate; -import org.l2jmobius.gameserver.model.base.ClassId; - -/** - * @version $Revision: 1.6.2.1.2.10 $ $Date: 2005/03/29 14:00:54 $ - */ -public class CharTemplateTable -{ - private static final Logger LOGGER = Logger.getLogger(CharTemplateTable.class.getName()); - - private static final String[] CHAR_CLASSES = - { - "Human Fighter", - "Warrior", - "Gladiator", - "Warlord", - "Human Knight", - "Paladin", - "Dark Avenger", - "Rogue", - "Treasure Hunter", - "Hawkeye", - "Human Mystic", - "Human Wizard", - "Sorceror", - "Necromancer", - "Warlock", - "Cleric", - "Bishop", - "Prophet", - "Elven Fighter", - "Elven Knight", - "Temple Knight", - "Swordsinger", - "Elven Scout", - "Plainswalker", - "Silver Ranger", - "Elven Mystic", - "Elven Wizard", - "Spellsinger", - "Elemental Summoner", - "Elven Oracle", - "Elven Elder", - "Dark Fighter", - "Palus Knight", - "Shillien Knight", - "Bladedancer", - "Assassin", - "Abyss Walker", - "Phantom Ranger", - "Dark Elven Mystic", - "Dark Elven Wizard", - "Spellhowler", - "Phantom Summoner", - "Shillien Oracle", - "Shillien Elder", - "Orc Fighter", - "Orc Raider", - "Destroyer", - "Orc Monk", - "Tyrant", - "Orc Mystic", - "Orc Shaman", - "Overlord", - "Warcryer", - "Dwarven Fighter", - "Dwarven Scavenger", - "Bounty Hunter", - "Dwarven Artisan", - "Warsmith", - "dummyEntry1", - "dummyEntry2", - "dummyEntry3", - "dummyEntry4", - "dummyEntry5", - "dummyEntry6", - "dummyEntry7", - "dummyEntry8", - "dummyEntry9", - "dummyEntry10", - "dummyEntry11", - "dummyEntry12", - "dummyEntry13", - "dummyEntry14", - "dummyEntry15", - "dummyEntry16", - "dummyEntry17", - "dummyEntry18", - "dummyEntry19", - "dummyEntry20", - "dummyEntry21", - "dummyEntry22", - "dummyEntry23", - "dummyEntry24", - "dummyEntry25", - "dummyEntry26", - "dummyEntry27", - "dummyEntry28", - "dummyEntry29", - "dummyEntry30", - "Duelist", - "DreadNought", - "Phoenix Knight", - "Hell Knight", - "Sagittarius", - "Adventurer", - "Archmage", - "Soultaker", - "Arcana Lord", - "Cardinal", - "Hierophant", - "Eva Templar", - "Sword Muse", - "Wind Rider", - "Moonlight Sentinel", - "Mystic Muse", - "Elemental Master", - "Eva's Saint", - "Shillien Templar", - "Spectral Dancer", - "Ghost Hunter", - "Ghost Sentinel", - "Storm Screamer", - "Spectral Master", - "Shillien Saint", - "Titan", - "Grand Khauatari", - "Dominator", - "Doomcryer", - "Fortune Seeker", - "Maestro" - }; - - private final Map _templates; - - private CharTemplateTable() - { - _templates = new HashMap<>(); - try (Connection con = DatabaseFactory.getConnection()) - { - final PreparedStatement statement = con.prepareStatement("SELECT * FROM class_list, char_templates, lvlupgain WHERE class_list.id = char_templates.classId AND class_list.id = lvlupgain.classId ORDER BY class_list.id"); - final ResultSet rset = statement.executeQuery(); - - while (rset.next()) - { - final StatSet set = new StatSet(); - set.set("classId", rset.getInt("id")); - set.set("className", rset.getString("className")); - set.set("raceId", rset.getInt("raceId")); - set.set("baseSTR", rset.getInt("STR")); - set.set("baseCON", rset.getInt("CON")); - set.set("baseDEX", rset.getInt("DEX")); - set.set("baseINT", rset.getInt("_INT")); - set.set("baseWIT", rset.getInt("WIT")); - set.set("baseMEN", rset.getInt("MEN")); - set.set("baseHpMax", rset.getFloat("defaultHpBase")); - set.set("lvlHpAdd", rset.getFloat("defaultHpAdd")); - set.set("lvlHpMod", rset.getFloat("defaultHpMod")); - set.set("baseMpMax", rset.getFloat("defaultMpBase")); - set.set("baseCpMax", rset.getFloat("defaultCpBase")); - set.set("lvlCpAdd", rset.getFloat("defaultCpAdd")); - set.set("lvlCpMod", rset.getFloat("defaultCpMod")); - set.set("lvlMpAdd", rset.getFloat("defaultMpAdd")); - set.set("lvlMpMod", rset.getFloat("defaultMpMod")); - set.set("baseHpReg", 1.5); - set.set("baseMpReg", 0.9); - set.set("basePAtk", rset.getInt("p_atk")); - set.set("basePDef", /* classId.isMage()? 77 : 129 */rset.getInt("p_def")); - set.set("baseMAtk", rset.getInt("m_atk")); - set.set("baseMDef", rset.getInt("char_templates.m_def")); - set.set("classBaseLevel", rset.getInt("class_lvl")); - set.set("basePAtkSpd", rset.getInt("p_spd")); - set.set("baseMAtkSpd", /* classId.isMage()? 166 : 333 */rset.getInt("char_templates.m_spd")); - set.set("baseCritRate", rset.getInt("char_templates.critical") / 10); - set.set("baseRunSpd", rset.getInt("move_spd")); - set.set("baseWalkSpd", 0); - set.set("baseShldDef", 0); - set.set("baseShldRate", 0); - set.set("baseAtkRange", 40); - - set.set("spawnX", rset.getInt("x")); - set.set("spawnY", rset.getInt("y")); - set.set("spawnZ", rset.getInt("z")); - - PlayerTemplate ct; - - set.set("collision_radius", rset.getDouble("m_col_r")); - set.set("collision_height", rset.getDouble("m_col_h")); - ct = new PlayerTemplate(set); - // 5 items must go here - for (int x = 1; x < 6; x++) - { - if (rset.getInt("items" + x) != 0) - { - ct.addItem(rset.getInt("items" + x)); - } - } - _templates.put(ct.getClassId().getId(), ct); - } - - statement.close(); - rset.close(); - } - catch (SQLException e) - { - LOGGER.warning("error while loading char templates " + e.getMessage()); - } - - LOGGER.info("CharTemplateTable: Loaded " + _templates.size() + " Character Templates."); - } - - public PlayerTemplate getTemplate(ClassId classId) - { - return getTemplate(classId.getId()); - } - - public PlayerTemplate getTemplate(int classId) - { - return _templates.get(classId); - } - - public static final String getClassNameById(int classId) - { - return CHAR_CLASSES[classId]; - } - - public static final int getClassIdByName(String className) - { - int currId = 1; - for (String name : CHAR_CLASSES) - { - if (name.equalsIgnoreCase(className)) - { - break; - } - - currId++; - } - return currId; - } - - public static CharTemplateTable getInstance() - { - return SingletonHolder.INSTANCE; - } - - private static class SingletonHolder - { - protected static final CharTemplateTable INSTANCE = new CharTemplateTable(); - } -} diff --git a/L2J_Mobius_C6_Interlude/java/org/l2jmobius/gameserver/datatables/sql/HelperBuffTable.java b/L2J_Mobius_C6_Interlude/java/org/l2jmobius/gameserver/datatables/sql/HelperBuffTable.java index 3b2c89b70d..6539bcc4da 100644 --- a/L2J_Mobius_C6_Interlude/java/org/l2jmobius/gameserver/datatables/sql/HelperBuffTable.java +++ b/L2J_Mobius_C6_Interlude/java/org/l2jmobius/gameserver/datatables/sql/HelperBuffTable.java @@ -125,7 +125,7 @@ public class HelperBuffTable helperBuff.add(template); } - LOGGER.info("Helper Buff Table: Loaded " + helperBuff.size() + " templates"); + LOGGER.info("HelperBuffTable: Loaded " + helperBuff.size() + " templates."); } public boolean isInitialized() diff --git a/L2J_Mobius_C6_Interlude/java/org/l2jmobius/gameserver/datatables/sql/LevelUpData.java b/L2J_Mobius_C6_Interlude/java/org/l2jmobius/gameserver/datatables/sql/LevelUpData.java deleted file mode 100644 index ed274fa578..0000000000 --- a/L2J_Mobius_C6_Interlude/java/org/l2jmobius/gameserver/datatables/sql/LevelUpData.java +++ /dev/null @@ -1,114 +0,0 @@ -/* - * This file is part of the L2J Mobius project. - * - * This program is free software: you can redistribute it and/or modify - * it under the terms of the GNU General Public License as published by - * the Free Software Foundation, either version 3 of the License, or - * (at your option) any later version. - * - * This program is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - * General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with this program. If not, see . - */ -package org.l2jmobius.gameserver.datatables.sql; - -import java.sql.Connection; -import java.sql.PreparedStatement; -import java.sql.ResultSet; -import java.util.HashMap; -import java.util.Map; -import java.util.logging.Logger; - -import org.l2jmobius.commons.database.DatabaseFactory; -import org.l2jmobius.gameserver.model.LvlupData; -import org.l2jmobius.gameserver.model.base.ClassId; - -/** - * @author NightMarez - * @version $Revision: 1.3.2.4.2.3 $ $Date: 2005/03/27 15:29:18 $ - */ -public class LevelUpData -{ - private static final String SELECT_ALL = "SELECT classid, defaulthpbase, defaulthpadd, defaulthpmod, defaultcpbase, defaultcpadd, defaultcpmod, defaultmpbase, defaultmpadd, defaultmpmod, class_lvl FROM lvlupgain"; - private static final String CLASS_LVL = "class_lvl"; - private static final String MP_MOD = "defaultmpmod"; - private static final String MP_ADD = "defaultmpadd"; - private static final String MP_BASE = "defaultmpbase"; - private static final String HP_MOD = "defaulthpmod"; - private static final String HP_ADD = "defaulthpadd"; - private static final String HP_BASE = "defaulthpbase"; - private static final String CP_MOD = "defaultcpmod"; - private static final String CP_ADD = "defaultcpadd"; - private static final String CP_BASE = "defaultcpbase"; - private static final String CLASS_ID = "classid"; - - private static final Logger LOGGER = Logger.getLogger(LevelUpData.class.getName()); - - private final Map _lvlTable; - - private LevelUpData() - { - _lvlTable = new HashMap<>(); - try (Connection con = DatabaseFactory.getConnection()) - { - final PreparedStatement statement = con.prepareStatement(SELECT_ALL); - final ResultSet rset = statement.executeQuery(); - LvlupData lvlDat; - - while (rset.next()) - { - lvlDat = new LvlupData(); - lvlDat.setClassid(rset.getInt(CLASS_ID)); - lvlDat.setClassLvl(rset.getInt(CLASS_LVL)); - lvlDat.setClassHpBase(rset.getFloat(HP_BASE)); - lvlDat.setClassHpAdd(rset.getFloat(HP_ADD)); - lvlDat.setClassHpModifier(rset.getFloat(HP_MOD)); - lvlDat.setClassCpBase(rset.getFloat(CP_BASE)); - lvlDat.setClassCpAdd(rset.getFloat(CP_ADD)); - lvlDat.setClassCpModifier(rset.getFloat(CP_MOD)); - lvlDat.setClassMpBase(rset.getFloat(MP_BASE)); - lvlDat.setClassMpAdd(rset.getFloat(MP_ADD)); - lvlDat.setClassMpModifier(rset.getFloat(MP_MOD)); - - _lvlTable.put(lvlDat.getClassid(), lvlDat); - } - - statement.close(); - rset.close(); - - LOGGER.info("LevelUpData: Loaded " + _lvlTable.size() + " Character Level Up Templates."); - } - catch (Exception e) - { - LOGGER.warning("Error while creating Lvl up data table " + e); - } - } - - /** - * @param classId - * @return - */ - public LvlupData getTemplate(int classId) - { - return _lvlTable.get(classId); - } - - public LvlupData getTemplate(ClassId classId) - { - return _lvlTable.get(classId.getId()); - } - - public static LevelUpData getInstance() - { - return SingletonHolder.INSTANCE; - } - - private static class SingletonHolder - { - protected static final LevelUpData INSTANCE = new LevelUpData(); - } -} diff --git a/L2J_Mobius_C6_Interlude/java/org/l2jmobius/gameserver/datatables/sql/SkillTreeTable.java b/L2J_Mobius_C6_Interlude/java/org/l2jmobius/gameserver/datatables/sql/SkillTreeTable.java index 75ce120c41..9152c7b609 100644 --- a/L2J_Mobius_C6_Interlude/java/org/l2jmobius/gameserver/datatables/sql/SkillTreeTable.java +++ b/L2J_Mobius_C6_Interlude/java/org/l2jmobius/gameserver/datatables/sql/SkillTreeTable.java @@ -30,11 +30,13 @@ import java.util.logging.Logger; import org.l2jmobius.Config; import org.l2jmobius.commons.database.DatabaseFactory; import org.l2jmobius.gameserver.datatables.SkillTable; +import org.l2jmobius.gameserver.datatables.xml.PlayerTemplateData; import org.l2jmobius.gameserver.model.EnchantSkillLearn; import org.l2jmobius.gameserver.model.PledgeSkillLearn; import org.l2jmobius.gameserver.model.Skill; import org.l2jmobius.gameserver.model.SkillLearn; import org.l2jmobius.gameserver.model.actor.instance.PlayerInstance; +import org.l2jmobius.gameserver.model.actor.templates.PlayerTemplate; import org.l2jmobius.gameserver.model.base.ClassId; import org.l2jmobius.gameserver.model.skills.holders.ISkillsHolder; import org.l2jmobius.gameserver.model.skills.holders.PlayerSkillHolder; @@ -47,42 +49,36 @@ public class SkillTreeTable private static final Logger LOGGER = Logger.getLogger(SkillTreeTable.class.getName()); private Map> _skillTrees; - private List _fishingSkillTrees; // all common skills (teached by Fisherman) - private List _expandDwarfCraftSkillTrees; // list of special skill for dwarf (expand dwarf craft) learned by class teacher - private List _pledgeSkillTrees; // pledge skill list - private List _enchantSkillTrees; // enchant skill list + private List _fishingSkillTrees; + private List _expandDwarfCraftSkillTrees; + private List _pledgeSkillTrees; + private List _enchantSkillTrees; private SkillTreeTable() { - int classId = 0; int count = 0; + ClassId classId = null; + ClassId parentClassId; + Map map; - try (Connection con = DatabaseFactory.getConnection()) + for (PlayerTemplate playerTemplate : PlayerTemplateData.getInstance().getAllTemplates()) { - final PreparedStatement statement = con.prepareStatement("SELECT * FROM class_list ORDER BY id"); - final ResultSet classlist = statement.executeQuery(); - - Map map; - int parentClassId; - SkillLearn skillLearn; - - while (classlist.next()) + try (Connection con = DatabaseFactory.getConnection()) { map = new HashMap<>(); - parentClassId = classlist.getInt("parent_id"); - classId = classlist.getInt("id"); - final PreparedStatement statement2 = con.prepareStatement("SELECT class_id, skill_id, level, name, sp, min_level FROM skill_trees where class_id=? ORDER BY skill_id, level"); - statement2.setInt(1, classId); - final ResultSet skilltree = statement2.executeQuery(); + classId = playerTemplate.getClassId(); + parentClassId = classId.getParent(); - if (parentClassId != -1) + final PreparedStatement statement = con.prepareStatement("SELECT class_id, skill_id, level, name, sp, min_level FROM skill_trees where class_id=? ORDER BY skill_id, level"); + statement.setInt(1, classId.getId()); + final ResultSet skilltree = statement.executeQuery(); + + if (parentClassId != null) { - final Map parentMap = getSkillTrees().get(ClassId.getClassId(parentClassId)); - map.putAll(parentMap); + map.putAll(getSkillTrees().get(parentClassId)); } int prevSkillId = -1; - while (skilltree.next()) { final int id = skilltree.getInt("skill_id"); @@ -96,24 +92,22 @@ public class SkillTreeTable prevSkillId = id; } - skillLearn = new SkillLearn(id, lvl, minLvl, name, cost, 0, 0); - map.put(SkillTable.getSkillHashCode(id, lvl), skillLearn); + map.put(SkillTable.getSkillHashCode(id, lvl), new SkillLearn(id, lvl, minLvl, name, cost, 0, 0)); } - getSkillTrees().put(ClassId.getClassId(classId), map); - skilltree.close(); - statement2.close(); - + getSkillTrees().put(classId, map); count += map.size(); - // LOGGER.info("SkillTreeTable: skill tree for class " + classId + " has " + map.size() + " skills."); + + skilltree.close(); + statement.close(); + } + catch (Exception e) + { + if (classId != null) + { + LOGGER.warning("Error while creating skill tree (Class ID " + classId.getId() + "): " + e); + } } - - classlist.close(); - statement.close(); - } - catch (Exception e) - { - LOGGER.warning("Error while creating skill tree (Class ID " + classId + "): " + e); } LOGGER.info("SkillTreeTable: Loaded " + count + " skills."); diff --git a/L2J_Mobius_C6_Interlude/java/org/l2jmobius/gameserver/datatables/xml/PlayerTemplateData.java b/L2J_Mobius_C6_Interlude/java/org/l2jmobius/gameserver/datatables/xml/PlayerTemplateData.java new file mode 100644 index 0000000000..2d635cade2 --- /dev/null +++ b/L2J_Mobius_C6_Interlude/java/org/l2jmobius/gameserver/datatables/xml/PlayerTemplateData.java @@ -0,0 +1,131 @@ +/* + * This file is part of the L2J Mobius project. + * + * This program is free software: you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation, either version 3 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program. If not, see . + */ +package org.l2jmobius.gameserver.datatables.xml; + +import java.io.File; +import java.util.Collection; +import java.util.HashMap; +import java.util.Map; + +import org.w3c.dom.Document; +import org.w3c.dom.NamedNodeMap; +import org.w3c.dom.Node; + +import org.l2jmobius.commons.util.IXmlReader; +import org.l2jmobius.gameserver.model.StatSet; +import org.l2jmobius.gameserver.model.actor.templates.PlayerTemplate; +import org.l2jmobius.gameserver.model.base.ClassId; + +/** + * @author Mobius + */ +public class PlayerTemplateData implements IXmlReader +{ + private final Map _templates = new HashMap<>(); + + protected PlayerTemplateData() + { + load(); + } + + @Override + public void load() + { + _templates.clear(); + parseDatapackFile("data/stats/playerTemplates.xml"); + LOGGER.info(getClass().getSimpleName() + ": Loaded " + _templates.size() + " player templates."); + } + + @Override + public void parseDocument(Document doc, File f) + { + // StatsSet used to feed informations. Cleaned on every entry. + final StatSet set = new StatSet(); + + // First element is never read. + final Node n = doc.getFirstChild(); + + for (Node node = n.getFirstChild(); node != null; node = node.getNextSibling()) + { + if (!"class".equalsIgnoreCase(node.getNodeName())) + { + continue; + } + + // Parse and feed content. + final NamedNodeMap attrs = node.getAttributes(); + for (int i = 0; i < attrs.getLength(); i++) + { + final Node attr = attrs.item(i); + set.set(attr.getNodeName(), attr.getNodeValue()); + } + + set.set("baseHpReg", 1.5); + set.set("baseMpReg", 0.9); + set.set("baseWalkSpd", 0); + set.set("baseShldDef", 0); + set.set("baseShldRate", 0); + set.set("baseAtkRange", 40); + set.set("baseCritRate", set.getInt("baseCritRate") / 10); + + final PlayerTemplate template = new PlayerTemplate(set); + _templates.put(template.getClassId().getId(), template); + } + } + + public Collection getAllTemplates() + { + return _templates.values(); + } + + public PlayerTemplate getTemplate(int classId) + { + return _templates.get(classId); + } + + public PlayerTemplate getTemplate(ClassId classId) + { + return _templates.get(classId.getId()); + } + + public String getClassNameById(int classId) + { + return _templates.get(classId).getClassName(); + } + + public int getClassIdByName(String className) + { + for (PlayerTemplate template : _templates.values()) + { + if (template.getClassName().equalsIgnoreCase(className)) + { + return template.getClassId().getId(); + } + } + return -1; + } + + public static PlayerTemplateData getInstance() + { + return SingletonHolder.INSTANCE; + } + + private static class SingletonHolder + { + protected static final PlayerTemplateData INSTANCE = new PlayerTemplateData(); + } +} diff --git a/L2J_Mobius_C6_Interlude/java/org/l2jmobius/gameserver/engines/DocumentEngine.java b/L2J_Mobius_C6_Interlude/java/org/l2jmobius/gameserver/engines/DocumentEngine.java index 0b5b932077..9f230b6bba 100644 --- a/L2J_Mobius_C6_Interlude/java/org/l2jmobius/gameserver/engines/DocumentEngine.java +++ b/L2J_Mobius_C6_Interlude/java/org/l2jmobius/gameserver/engines/DocumentEngine.java @@ -99,7 +99,7 @@ public class DocumentEngine count++; } } - LOGGER.info("SkillsEngine: Loaded " + count + " Skill templates from XML files."); + LOGGER.info("SkillsEngine: Loaded " + count + " skill templates."); } /** diff --git a/L2J_Mobius_C6_Interlude/java/org/l2jmobius/gameserver/instancemanager/ClassDamageManager.java b/L2J_Mobius_C6_Interlude/java/org/l2jmobius/gameserver/instancemanager/ClassDamageManager.java index def88857d3..dcab67d3b3 100644 --- a/L2J_Mobius_C6_Interlude/java/org/l2jmobius/gameserver/instancemanager/ClassDamageManager.java +++ b/L2J_Mobius_C6_Interlude/java/org/l2jmobius/gameserver/instancemanager/ClassDamageManager.java @@ -26,7 +26,7 @@ import java.util.Properties; import java.util.logging.Logger; import org.l2jmobius.Config; -import org.l2jmobius.gameserver.datatables.sql.CharTemplateTable; +import org.l2jmobius.gameserver.datatables.xml.PlayerTemplateData; import org.l2jmobius.gameserver.model.actor.instance.PlayerInstance; /** @@ -46,13 +46,12 @@ public class ClassDamageManager public static void loadConfig() { - final String SCRIPT = Config.CLASS_DAMAGE_CONFIG_FILE; InputStream is = null; File file = null; try { final Properties scriptSetting = new Properties(); - file = new File(SCRIPT); + file = new File(Config.CLASS_DAMAGE_CONFIG_FILE); is = new FileInputStream(file); scriptSetting.load(is); @@ -69,8 +68,7 @@ public class ClassDamageManager } final String type = classAndType[1]; - - final Integer classId = CharTemplateTable.getClassIdByName(className) - 1; + final Integer classId = PlayerTemplateData.getInstance().getClassIdByName(className) - 1; ID_TO_NAME.put(classId, className); NAME_TO_ID.put(className, classId); @@ -93,7 +91,7 @@ public class ClassDamageManager } } - LOGGER.info("Loaded " + ID_TO_NAME.size() + " classes Damages configurations"); + LOGGER.info("Loaded " + ID_TO_NAME.size() + " class damage configurations."); } catch (Exception e) { diff --git a/L2J_Mobius_C6_Interlude/java/org/l2jmobius/gameserver/model/actor/instance/ClassMasterInstance.java b/L2J_Mobius_C6_Interlude/java/org/l2jmobius/gameserver/model/actor/instance/ClassMasterInstance.java index 06f2146f9a..9dd2f95485 100644 --- a/L2J_Mobius_C6_Interlude/java/org/l2jmobius/gameserver/model/actor/instance/ClassMasterInstance.java +++ b/L2J_Mobius_C6_Interlude/java/org/l2jmobius/gameserver/model/actor/instance/ClassMasterInstance.java @@ -19,7 +19,7 @@ package org.l2jmobius.gameserver.model.actor.instance; import org.l2jmobius.Config; import org.l2jmobius.gameserver.ai.CtrlIntention; import org.l2jmobius.gameserver.datatables.ItemTable; -import org.l2jmobius.gameserver.datatables.sql.CharTemplateTable; +import org.l2jmobius.gameserver.datatables.xml.PlayerTemplateData; import org.l2jmobius.gameserver.model.actor.templates.NpcTemplate; import org.l2jmobius.gameserver.model.base.ClassId; import org.l2jmobius.gameserver.model.items.instance.ItemInstance; @@ -130,7 +130,7 @@ public class ClassMasterInstance extends FolkInstance { if (child.childOf(classId) && (child.level() == jobLevel)) { - sb.append("
" + CharTemplateTable.getClassNameById(child.getId()) + ""); + sb.append("
" + PlayerTemplateData.getInstance().getClassNameById(child.getId()) + ""); } } @@ -259,7 +259,7 @@ public class ClassMasterInstance extends FolkInstance final NpcHtmlMessage html = new NpcHtmlMessage(getObjectId()); final StringBuilder sb = new StringBuilder(); sb.append("Class Manager





"); - sb.append("You have now become a " + CharTemplateTable.getClassNameById(player.getClassId().getId()) + "."); + sb.append("You have now become a " + PlayerTemplateData.getInstance().getClassNameById(player.getClassId().getId()) + "."); sb.append("
"); html.setHtml(sb.toString()); @@ -400,7 +400,7 @@ public class ClassMasterInstance extends FolkInstance final NpcHtmlMessage html = new NpcHtmlMessage(getObjectId()); final StringBuilder sb = new StringBuilder(); sb.append("Class Manager





"); - sb.append("You have now become a " + CharTemplateTable.getClassNameById(player.getClassId().getId()) + "."); + sb.append("You have now become a " + PlayerTemplateData.getInstance().getClassNameById(player.getClassId().getId()) + "."); sb.append("
"); html.setHtml(sb.toString()); @@ -509,24 +509,24 @@ public class ClassMasterInstance extends FolkInstance sb.append(""); sb.append(""); sb.append(""); - sb.append(""); - sb.append(""); - sb.append(""); - sb.append(""); - sb.append(""); - sb.append(""); - sb.append(""); - sb.append(""); - sb.append(""); - sb.append(""); - sb.append(""); - sb.append(""); - sb.append(""); - sb.append(""); - sb.append(""); - sb.append(""); - sb.append(""); - sb.append(""); + sb.append(""); + sb.append(""); + sb.append(""); + sb.append(""); + sb.append(""); + sb.append(""); + sb.append(""); + sb.append(""); + sb.append(""); + sb.append(""); + sb.append(""); + sb.append(""); + sb.append(""); + sb.append(""); + sb.append(""); + sb.append(""); + sb.append(""); + sb.append(""); sb.append("
GM Class Master:

Advance to " + CharTemplateTable.getClassNameById(1) + "
Advance to " + CharTemplateTable.getClassNameById(4) + "
Advance to " + CharTemplateTable.getClassNameById(7) + "
Advance to " + CharTemplateTable.getClassNameById(11) + "
Advance to " + CharTemplateTable.getClassNameById(15) + "
Advance to " + CharTemplateTable.getClassNameById(19) + "
Advance to " + CharTemplateTable.getClassNameById(22) + "
Advance to " + CharTemplateTable.getClassNameById(26) + "
Advance to " + CharTemplateTable.getClassNameById(29) + "
Advance to " + CharTemplateTable.getClassNameById(32) + "
Advance to " + CharTemplateTable.getClassNameById(35) + "
Advance to " + CharTemplateTable.getClassNameById(39) + "
Advance to " + CharTemplateTable.getClassNameById(42) + "
Advance to " + CharTemplateTable.getClassNameById(45) + "
Advance to " + CharTemplateTable.getClassNameById(47) + "
Advance to " + CharTemplateTable.getClassNameById(50) + "
Advance to " + CharTemplateTable.getClassNameById(54) + "
Advance to " + CharTemplateTable.getClassNameById(56) + "
Advance to " + PlayerTemplateData.getInstance().getClassNameById(1) + "
Advance to " + PlayerTemplateData.getInstance().getClassNameById(4) + "
Advance to " + PlayerTemplateData.getInstance().getClassNameById(7) + "
Advance to " + PlayerTemplateData.getInstance().getClassNameById(11) + "
Advance to " + PlayerTemplateData.getInstance().getClassNameById(15) + "
Advance to " + PlayerTemplateData.getInstance().getClassNameById(19) + "
Advance to " + PlayerTemplateData.getInstance().getClassNameById(22) + "
Advance to " + PlayerTemplateData.getInstance().getClassNameById(26) + "
Advance to " + PlayerTemplateData.getInstance().getClassNameById(29) + "
Advance to " + PlayerTemplateData.getInstance().getClassNameById(32) + "
Advance to " + PlayerTemplateData.getInstance().getClassNameById(35) + "
Advance to " + PlayerTemplateData.getInstance().getClassNameById(39) + "
Advance to " + PlayerTemplateData.getInstance().getClassNameById(42) + "
Advance to " + PlayerTemplateData.getInstance().getClassNameById(45) + "
Advance to " + PlayerTemplateData.getInstance().getClassNameById(47) + "
Advance to " + PlayerTemplateData.getInstance().getClassNameById(50) + "
Advance to " + PlayerTemplateData.getInstance().getClassNameById(54) + "
Advance to " + PlayerTemplateData.getInstance().getClassNameById(56) + "
"); sb.append(""); sb.append(""); @@ -547,37 +547,37 @@ public class ClassMasterInstance extends FolkInstance sb.append(""); sb.append(""); sb.append(""); - sb.append(""); - sb.append(""); - sb.append(""); - sb.append(""); - sb.append(""); - sb.append(""); - sb.append(""); - sb.append(""); - sb.append(""); - sb.append(""); - sb.append(""); - sb.append(""); - sb.append(""); - sb.append(""); - sb.append(""); - sb.append(""); - sb.append(""); - sb.append(""); - sb.append(""); - sb.append(""); - sb.append(""); - sb.append(""); - sb.append(""); - sb.append(""); - sb.append(""); - sb.append(""); - sb.append(""); - sb.append(""); - sb.append(""); - sb.append(""); - sb.append(""); + sb.append(""); + sb.append(""); + sb.append(""); + sb.append(""); + sb.append(""); + sb.append(""); + sb.append(""); + sb.append(""); + sb.append(""); + sb.append(""); + sb.append(""); + sb.append(""); + sb.append(""); + sb.append(""); + sb.append(""); + sb.append(""); + sb.append(""); + sb.append(""); + sb.append(""); + sb.append(""); + sb.append(""); + sb.append(""); + sb.append(""); + sb.append(""); + sb.append(""); + sb.append(""); + sb.append(""); + sb.append(""); + sb.append(""); + sb.append(""); + sb.append(""); sb.append("
GM Class Master:

Advance to " + CharTemplateTable.getClassNameById(2) + "
Advance to " + CharTemplateTable.getClassNameById(3) + "
Advance to " + CharTemplateTable.getClassNameById(5) + "
Advance to " + CharTemplateTable.getClassNameById(6) + "
Advance to " + CharTemplateTable.getClassNameById(8) + "
Advance to " + CharTemplateTable.getClassNameById(9) + "
Advance to " + CharTemplateTable.getClassNameById(12) + "
Advance to " + CharTemplateTable.getClassNameById(13) + "
Advance to " + CharTemplateTable.getClassNameById(14) + "
Advance to " + CharTemplateTable.getClassNameById(16) + "
Advance to " + CharTemplateTable.getClassNameById(17) + "
Advance to " + CharTemplateTable.getClassNameById(20) + "
Advance to " + CharTemplateTable.getClassNameById(21) + "
Advance to " + CharTemplateTable.getClassNameById(23) + "
Advance to " + CharTemplateTable.getClassNameById(24) + "
Advance to " + CharTemplateTable.getClassNameById(27) + "
Advance to " + CharTemplateTable.getClassNameById(28) + "
Advance to " + CharTemplateTable.getClassNameById(30) + "
Advance to " + CharTemplateTable.getClassNameById(33) + "
Advance to " + CharTemplateTable.getClassNameById(34) + "
Advance to " + CharTemplateTable.getClassNameById(36) + "
Advance to " + CharTemplateTable.getClassNameById(37) + "
Advance to " + CharTemplateTable.getClassNameById(40) + "
Advance to " + CharTemplateTable.getClassNameById(41) + "
Advance to " + CharTemplateTable.getClassNameById(43) + "
Advance to " + CharTemplateTable.getClassNameById(46) + "
Advance to " + CharTemplateTable.getClassNameById(48) + "
Advance to " + CharTemplateTable.getClassNameById(51) + "
Advance to " + CharTemplateTable.getClassNameById(52) + "
Advance to " + CharTemplateTable.getClassNameById(55) + "
Advance to " + CharTemplateTable.getClassNameById(57) + "
Advance to " + PlayerTemplateData.getInstance().getClassNameById(2) + "
Advance to " + PlayerTemplateData.getInstance().getClassNameById(3) + "
Advance to " + PlayerTemplateData.getInstance().getClassNameById(5) + "
Advance to " + PlayerTemplateData.getInstance().getClassNameById(6) + "
Advance to " + PlayerTemplateData.getInstance().getClassNameById(8) + "
Advance to " + PlayerTemplateData.getInstance().getClassNameById(9) + "
Advance to " + PlayerTemplateData.getInstance().getClassNameById(12) + "
Advance to " + PlayerTemplateData.getInstance().getClassNameById(13) + "
Advance to " + PlayerTemplateData.getInstance().getClassNameById(14) + "
Advance to " + PlayerTemplateData.getInstance().getClassNameById(16) + "
Advance to " + PlayerTemplateData.getInstance().getClassNameById(17) + "
Advance to " + PlayerTemplateData.getInstance().getClassNameById(20) + "
Advance to " + PlayerTemplateData.getInstance().getClassNameById(21) + "
Advance to " + PlayerTemplateData.getInstance().getClassNameById(23) + "
Advance to " + PlayerTemplateData.getInstance().getClassNameById(24) + "
Advance to " + PlayerTemplateData.getInstance().getClassNameById(27) + "
Advance to " + PlayerTemplateData.getInstance().getClassNameById(28) + "
Advance to " + PlayerTemplateData.getInstance().getClassNameById(30) + "
Advance to " + PlayerTemplateData.getInstance().getClassNameById(33) + "
Advance to " + PlayerTemplateData.getInstance().getClassNameById(34) + "
Advance to " + PlayerTemplateData.getInstance().getClassNameById(36) + "
Advance to " + PlayerTemplateData.getInstance().getClassNameById(37) + "
Advance to " + PlayerTemplateData.getInstance().getClassNameById(40) + "
Advance to " + PlayerTemplateData.getInstance().getClassNameById(41) + "
Advance to " + PlayerTemplateData.getInstance().getClassNameById(43) + "
Advance to " + PlayerTemplateData.getInstance().getClassNameById(46) + "
Advance to " + PlayerTemplateData.getInstance().getClassNameById(48) + "
Advance to " + PlayerTemplateData.getInstance().getClassNameById(51) + "
Advance to " + PlayerTemplateData.getInstance().getClassNameById(52) + "
Advance to " + PlayerTemplateData.getInstance().getClassNameById(55) + "
Advance to " + PlayerTemplateData.getInstance().getClassNameById(57) + "
"); sb.append(""); sb.append(""); @@ -598,37 +598,37 @@ public class ClassMasterInstance extends FolkInstance sb.append(""); sb.append(""); sb.append(""); - sb.append(""); - sb.append(""); - sb.append(""); - sb.append(""); - sb.append(""); - sb.append(""); - sb.append(""); - sb.append(""); - sb.append(""); - sb.append(""); - sb.append(""); - sb.append(""); - sb.append(""); - sb.append(""); - sb.append(""); - sb.append(""); - sb.append(""); - sb.append(""); - sb.append(""); - sb.append(""); - sb.append(""); - sb.append(""); - sb.append(""); - sb.append(""); - sb.append(""); - sb.append(""); - sb.append(""); - sb.append(""); - sb.append(""); - sb.append(""); - sb.append(""); + sb.append(""); + sb.append(""); + sb.append(""); + sb.append(""); + sb.append(""); + sb.append(""); + sb.append(""); + sb.append(""); + sb.append(""); + sb.append(""); + sb.append(""); + sb.append(""); + sb.append(""); + sb.append(""); + sb.append(""); + sb.append(""); + sb.append(""); + sb.append(""); + sb.append(""); + sb.append(""); + sb.append(""); + sb.append(""); + sb.append(""); + sb.append(""); + sb.append(""); + sb.append(""); + sb.append(""); + sb.append(""); + sb.append(""); + sb.append(""); + sb.append(""); sb.append("
GM Class Master:

Advance to " + CharTemplateTable.getClassNameById(88) + "
Advance to " + CharTemplateTable.getClassNameById(89) + "
Advance to " + CharTemplateTable.getClassNameById(90) + "
Advance to " + CharTemplateTable.getClassNameById(91) + "
Advance to " + CharTemplateTable.getClassNameById(92) + "
Advance to " + CharTemplateTable.getClassNameById(93) + "
Advance to " + CharTemplateTable.getClassNameById(94) + "
Advance to " + CharTemplateTable.getClassNameById(95) + "
Advance to " + CharTemplateTable.getClassNameById(96) + "
Advance to " + CharTemplateTable.getClassNameById(97) + "
Advance to " + CharTemplateTable.getClassNameById(98) + "
Advance to " + CharTemplateTable.getClassNameById(99) + "
Advance to " + CharTemplateTable.getClassNameById(100) + "
Advance to " + CharTemplateTable.getClassNameById(101) + "
Advance to " + CharTemplateTable.getClassNameById(102) + "
Advance to " + CharTemplateTable.getClassNameById(103) + "
Advance to " + CharTemplateTable.getClassNameById(104) + "
Advance to " + CharTemplateTable.getClassNameById(105) + "
Advance to " + CharTemplateTable.getClassNameById(106) + "
Advance to " + CharTemplateTable.getClassNameById(107) + "
Advance to " + CharTemplateTable.getClassNameById(108) + "
Advance to " + CharTemplateTable.getClassNameById(109) + "
Advance to " + CharTemplateTable.getClassNameById(110) + "
Advance to " + CharTemplateTable.getClassNameById(111) + "
Advance to " + CharTemplateTable.getClassNameById(112) + "
Advance to " + CharTemplateTable.getClassNameById(113) + "
Advance to " + CharTemplateTable.getClassNameById(114) + "
Advance to " + CharTemplateTable.getClassNameById(115) + "
Advance to " + CharTemplateTable.getClassNameById(116) + "
Advance to " + CharTemplateTable.getClassNameById(117) + "
Advance to " + CharTemplateTable.getClassNameById(118) + "
Advance to " + PlayerTemplateData.getInstance().getClassNameById(88) + "
Advance to " + PlayerTemplateData.getInstance().getClassNameById(89) + "
Advance to " + PlayerTemplateData.getInstance().getClassNameById(90) + "
Advance to " + PlayerTemplateData.getInstance().getClassNameById(91) + "
Advance to " + PlayerTemplateData.getInstance().getClassNameById(92) + "
Advance to " + PlayerTemplateData.getInstance().getClassNameById(93) + "
Advance to " + PlayerTemplateData.getInstance().getClassNameById(94) + "
Advance to " + PlayerTemplateData.getInstance().getClassNameById(95) + "
Advance to " + PlayerTemplateData.getInstance().getClassNameById(96) + "
Advance to " + PlayerTemplateData.getInstance().getClassNameById(97) + "
Advance to " + PlayerTemplateData.getInstance().getClassNameById(98) + "
Advance to " + PlayerTemplateData.getInstance().getClassNameById(99) + "
Advance to " + PlayerTemplateData.getInstance().getClassNameById(100) + "
Advance to " + PlayerTemplateData.getInstance().getClassNameById(101) + "
Advance to " + PlayerTemplateData.getInstance().getClassNameById(102) + "
Advance to " + PlayerTemplateData.getInstance().getClassNameById(103) + "
Advance to " + PlayerTemplateData.getInstance().getClassNameById(104) + "
Advance to " + PlayerTemplateData.getInstance().getClassNameById(105) + "
Advance to " + PlayerTemplateData.getInstance().getClassNameById(106) + "
Advance to " + PlayerTemplateData.getInstance().getClassNameById(107) + "
Advance to " + PlayerTemplateData.getInstance().getClassNameById(108) + "
Advance to " + PlayerTemplateData.getInstance().getClassNameById(109) + "
Advance to " + PlayerTemplateData.getInstance().getClassNameById(110) + "
Advance to " + PlayerTemplateData.getInstance().getClassNameById(111) + "
Advance to " + PlayerTemplateData.getInstance().getClassNameById(112) + "
Advance to " + PlayerTemplateData.getInstance().getClassNameById(113) + "
Advance to " + PlayerTemplateData.getInstance().getClassNameById(114) + "
Advance to " + PlayerTemplateData.getInstance().getClassNameById(115) + "
Advance to " + PlayerTemplateData.getInstance().getClassNameById(116) + "
Advance to " + PlayerTemplateData.getInstance().getClassNameById(117) + "
Advance to " + PlayerTemplateData.getInstance().getClassNameById(118) + "
"); sb.append(""); sb.append(""); @@ -649,15 +649,15 @@ public class ClassMasterInstance extends FolkInstance sb.append(""); sb.append(""); sb.append(""); - sb.append(""); - sb.append(""); - sb.append(""); - sb.append(""); - sb.append(""); - sb.append(""); - sb.append(""); - sb.append(""); - sb.append(""); + sb.append(""); + sb.append(""); + sb.append(""); + sb.append(""); + sb.append(""); + sb.append(""); + sb.append(""); + sb.append(""); + sb.append(""); sb.append("
GM Class Master:

Advance to " + CharTemplateTable.getClassNameById(0) + "
Advance to " + CharTemplateTable.getClassNameById(10) + "
Advance to " + CharTemplateTable.getClassNameById(18) + "
Advance to " + CharTemplateTable.getClassNameById(25) + "
Advance to " + CharTemplateTable.getClassNameById(31) + "
Advance to " + CharTemplateTable.getClassNameById(38) + "
Advance to " + CharTemplateTable.getClassNameById(44) + "
Advance to " + CharTemplateTable.getClassNameById(49) + "
Advance to " + CharTemplateTable.getClassNameById(53) + "
Advance to " + PlayerTemplateData.getInstance().getClassNameById(0) + "
Advance to " + PlayerTemplateData.getInstance().getClassNameById(10) + "
Advance to " + PlayerTemplateData.getInstance().getClassNameById(18) + "
Advance to " + PlayerTemplateData.getInstance().getClassNameById(25) + "
Advance to " + PlayerTemplateData.getInstance().getClassNameById(31) + "
Advance to " + PlayerTemplateData.getInstance().getClassNameById(38) + "
Advance to " + PlayerTemplateData.getInstance().getClassNameById(44) + "
Advance to " + PlayerTemplateData.getInstance().getClassNameById(49) + "
Advance to " + PlayerTemplateData.getInstance().getClassNameById(53) + "
"); sb.append(""); sb.append(""); diff --git a/L2J_Mobius_C6_Interlude/java/org/l2jmobius/gameserver/model/actor/instance/PlayerInstance.java b/L2J_Mobius_C6_Interlude/java/org/l2jmobius/gameserver/model/actor/instance/PlayerInstance.java index d7e174ce76..4fb1d82361 100644 --- a/L2J_Mobius_C6_Interlude/java/org/l2jmobius/gameserver/model/actor/instance/PlayerInstance.java +++ b/L2J_Mobius_C6_Interlude/java/org/l2jmobius/gameserver/model/actor/instance/PlayerInstance.java @@ -56,7 +56,6 @@ import org.l2jmobius.gameserver.datatables.HeroSkillTable; import org.l2jmobius.gameserver.datatables.ItemTable; import org.l2jmobius.gameserver.datatables.NobleSkillTable; import org.l2jmobius.gameserver.datatables.SkillTable; -import org.l2jmobius.gameserver.datatables.sql.CharTemplateTable; import org.l2jmobius.gameserver.datatables.sql.ClanTable; import org.l2jmobius.gameserver.datatables.sql.NpcTable; import org.l2jmobius.gameserver.datatables.sql.SkillTreeTable; @@ -65,6 +64,7 @@ import org.l2jmobius.gameserver.datatables.xml.ExperienceData; import org.l2jmobius.gameserver.datatables.xml.FishData; import org.l2jmobius.gameserver.datatables.xml.HennaData; import org.l2jmobius.gameserver.datatables.xml.MapRegionData; +import org.l2jmobius.gameserver.datatables.xml.PlayerTemplateData; import org.l2jmobius.gameserver.datatables.xml.RecipeData; import org.l2jmobius.gameserver.datatables.xml.ZoneData; import org.l2jmobius.gameserver.enums.Race; @@ -1016,7 +1016,7 @@ public class PlayerInstance extends Playable } /** - * Retrieve a PlayerInstance from the characters table of the database and add it in _allObjects of the L2world (call restore method).
+ * Retrieve a PlayerInstance from the characters table of the database and add it in _allObjects of the World (call restore method).
*
* Actions :
*
@@ -1067,7 +1067,7 @@ public class PlayerInstance extends Playable getKnownList(); // init knownlist getStat(); // init stats getStatus(); // init status - super.initCharStatusUpdateValues(); + initCharStatusUpdateValues(); initPcStatusUpdateValues(); _accountName = accountName; @@ -1153,7 +1153,7 @@ public class PlayerInstance extends Playable */ public PlayerTemplate getBaseTemplate() { - return CharTemplateTable.getInstance().getTemplate(_baseClass); + return PlayerTemplateData.getInstance().getTemplate(_baseClass); } /** @@ -1172,7 +1172,7 @@ public class PlayerInstance extends Playable */ public void setTemplate(ClassId newclass) { - super.setTemplate(CharTemplateTable.getInstance().getTemplate(newclass)); + super.setTemplate(PlayerTemplateData.getInstance().getTemplate(newclass)); } public void setTimerToAttack(long time) @@ -3116,7 +3116,7 @@ public class PlayerInstance extends Playable { return getTemplate().getRace(); } - return CharTemplateTable.getInstance().getTemplate(_baseClass).getRace(); + return PlayerTemplateData.getInstance().getTemplate(_baseClass).getRace(); } /** @@ -8505,7 +8505,7 @@ public class PlayerInstance extends Playable } /** - * Retrieve a PlayerInstance from the characters table of the database and add it in _allObjects of the L2world.
+ * Retrieve a PlayerInstance from the characters table of the database and add it in _allObjects of the World.
*
* Actions :
*
@@ -8534,7 +8534,7 @@ public class PlayerInstance extends Playable { final int activeClassId = rset.getInt("classid"); final boolean female = rset.getInt("sex") != 0; - final PlayerTemplate template = CharTemplateTable.getInstance().getTemplate(activeClassId); + final PlayerTemplate template = PlayerTemplateData.getInstance().getTemplate(activeClassId); final PlayerAppearance app = new PlayerAppearance(rset.getByte("face"), rset.getByte("hairColor"), rset.getByte("hairStyle"), female); player = new PlayerInstance(objectId, template, rset.getString("account_name"), app); @@ -12784,8 +12784,7 @@ public class PlayerInstance extends Playable { _activeClass = classId; - final PlayerTemplate t = CharTemplateTable.getInstance().getTemplate(classId); - + final PlayerTemplate t = PlayerTemplateData.getInstance().getTemplate(classId); if (t == null) { LOGGER.warning("Missing template for classId: " + classId); diff --git a/L2J_Mobius_C6_Interlude/java/org/l2jmobius/gameserver/model/actor/instance/VillageMasterInstance.java b/L2J_Mobius_C6_Interlude/java/org/l2jmobius/gameserver/model/actor/instance/VillageMasterInstance.java index 4ebcb9fba0..6a2bda043e 100644 --- a/L2J_Mobius_C6_Interlude/java/org/l2jmobius/gameserver/model/actor/instance/VillageMasterInstance.java +++ b/L2J_Mobius_C6_Interlude/java/org/l2jmobius/gameserver/model/actor/instance/VillageMasterInstance.java @@ -20,9 +20,9 @@ import java.util.Iterator; import java.util.Set; import org.l2jmobius.Config; -import org.l2jmobius.gameserver.datatables.sql.CharTemplateTable; import org.l2jmobius.gameserver.datatables.sql.ClanTable; import org.l2jmobius.gameserver.datatables.sql.SkillTreeTable; +import org.l2jmobius.gameserver.datatables.xml.PlayerTemplateData; import org.l2jmobius.gameserver.enums.Race; import org.l2jmobius.gameserver.instancemanager.CastleManager; import org.l2jmobius.gameserver.instancemanager.FortManager; @@ -287,11 +287,11 @@ public class VillageMasterInstance extends FolkInstance content.append("Which class would you like to switch to?
"); if (baseClassId == player.getActiveClass()) { - content.append(CharTemplateTable.getClassNameById(baseClassId) + " (Base Class)

"); + content.append(PlayerTemplateData.getInstance().getClassNameById(baseClassId) + " (Base Class)

"); } else { - content.append("" + CharTemplateTable.getClassNameById(baseClassId) + " (Base Class)

"); + content.append("" + PlayerTemplateData.getInstance().getClassNameById(baseClassId) + " (Base Class)

"); } for (Iterator subList = iterSubClasses(player); subList.hasNext();) { @@ -299,11 +299,11 @@ public class VillageMasterInstance extends FolkInstance final int subClassId = subClass.getClassId(); if (subClassId == player.getActiveClass()) { - content.append(CharTemplateTable.getClassNameById(subClassId) + "
"); + content.append(PlayerTemplateData.getInstance().getClassNameById(subClassId) + "
"); } else { - content.append("" + CharTemplateTable.getClassNameById(subClassId) + "
"); + content.append("" + PlayerTemplateData.getInstance().getClassNameById(subClassId) + "
"); } } } @@ -317,7 +317,7 @@ public class VillageMasterInstance extends FolkInstance { final SubClass subClass = subList.next(); content.append("Sub-class " + classIndex + ""); - content.append("" + CharTemplateTable.getClassNameById(subClass.getClassId()) + "
"); + content.append("" + PlayerTemplateData.getInstance().getClassNameById(subClass.getClassId()) + "
"); classIndex++; } content.append("
If you change a sub class, you'll start at level 40 after the 2nd class transfer."); @@ -394,7 +394,7 @@ public class VillageMasterInstance extends FolkInstance } if (allowAddition) { - final String className = CharTemplateTable.getClassNameById(paramOne); + final String className = PlayerTemplateData.getInstance().getClassNameById(paramOne); if (!player.addSubClass(paramOne, player.getTotalSubClasses() + 1)) { player.sendMessage("The sub class could not be added."); @@ -448,7 +448,7 @@ public class VillageMasterInstance extends FolkInstance return; } player.setActiveClass(paramOne); - content.append("Change Subclass:
Your active sub class is now a " + CharTemplateTable.getClassNameById(player.getActiveClass()) + "."); + content.append("Change Subclass:
Your active sub class is now a " + PlayerTemplateData.getInstance().getClassNameById(player.getActiveClass()) + "."); player.sendPacket(SystemMessageId.SUBCLASS_TRANSFER_COMPLETED); // Transfer completed. // check player skills // Player skills are already checked during setActiveClass @@ -506,7 +506,7 @@ public class VillageMasterInstance extends FolkInstance if (player.modifySubClass(paramOne, paramTwo)) { player.setActiveClass(paramOne); - content.append("Change Subclass:
Your sub class has been changed to " + CharTemplateTable.getClassNameById(paramTwo) + "."); + content.append("Change Subclass:
Your sub class has been changed to " + PlayerTemplateData.getInstance().getClassNameById(paramTwo) + "."); player.sendPacket(SystemMessageId.ADD_NEW_SUBCLASS); // Subclass added. // check player skills // Player skills are already checked during setActiveClass diff --git a/L2J_Mobius_C6_Interlude/java/org/l2jmobius/gameserver/model/actor/templates/CreatureTemplate.java b/L2J_Mobius_C6_Interlude/java/org/l2jmobius/gameserver/model/actor/templates/CreatureTemplate.java index 9a19273b80..2abd821326 100644 --- a/L2J_Mobius_C6_Interlude/java/org/l2jmobius/gameserver/model/actor/templates/CreatureTemplate.java +++ b/L2J_Mobius_C6_Interlude/java/org/l2jmobius/gameserver/model/actor/templates/CreatureTemplate.java @@ -161,8 +161,8 @@ public class CreatureTemplate _baseHpConsumeRate = set.getInt("baseHpConsumeRate", 0); // Geometry - _collisionRadius = set.getInt("collision_radius"); - _collisionHeight = set.getInt("collision_height"); + _collisionRadius = (int) set.getFloat("collision_radius"); // TODO: Support float. + _collisionHeight = (int) set.getFloat("collision_height"); // TODO: Support float. } public int getBaseSTR() diff --git a/L2J_Mobius_C6_Interlude/java/org/l2jmobius/gameserver/model/actor/templates/PlayerTemplate.java b/L2J_Mobius_C6_Interlude/java/org/l2jmobius/gameserver/model/actor/templates/PlayerTemplate.java index 32c0cb6d21..644cc6112a 100644 --- a/L2J_Mobius_C6_Interlude/java/org/l2jmobius/gameserver/model/actor/templates/PlayerTemplate.java +++ b/L2J_Mobius_C6_Interlude/java/org/l2jmobius/gameserver/model/actor/templates/PlayerTemplate.java @@ -19,80 +19,58 @@ package org.l2jmobius.gameserver.model.actor.templates; import java.util.ArrayList; import java.util.List; -import org.l2jmobius.gameserver.datatables.ItemTable; import org.l2jmobius.gameserver.enums.Race; import org.l2jmobius.gameserver.model.StatSet; import org.l2jmobius.gameserver.model.base.ClassId; -import org.l2jmobius.gameserver.model.items.Item; +import org.l2jmobius.gameserver.model.holders.ItemHolder; /** * @author mkizub */ public class PlayerTemplate extends CreatureTemplate { - /** The Class object of the PlayerInstance */ private final Race _race; private final ClassId _classId; - - private final int _currentCollisionRadius; - private final int _currentCollisionHeight; private final String _className; - + private final int _classBaseLevel; + private final float _levelHpAdd; + private final float _levelHpMod; + private final float _levelCpAdd; + private final float _levelCpMod; + private final float _levelMpAdd; + private final float _levelMpMod; private final int _spawnX; private final int _spawnY; private final int _spawnZ; - - private final int _classBaseLevel; - private final float _lvlHpAdd; - private final float _lvlHpMod; - private final float _lvlCpAdd; - private final float _lvlCpMod; - private final float _lvlMpAdd; - private final float _lvlMpMod; - - private final List _items = new ArrayList<>(); + private final List _items = new ArrayList<>(); public PlayerTemplate(StatSet set) { super(set); - _classId = ClassId.getClassId(set.getInt("classId")); - _race = Race.values()[set.getInt("raceId")]; - _className = set.getString("className"); - _currentCollisionRadius = set.getInt("collision_radius"); - _currentCollisionHeight = set.getInt("collision_height"); - + _classId = ClassId.getClassId(set.getInt("id")); + _race = Enum.valueOf(Race.class, set.getString("race")); + _className = set.getString("name"); _spawnX = set.getInt("spawnX"); _spawnY = set.getInt("spawnY"); _spawnZ = set.getInt("spawnZ"); - - _classBaseLevel = set.getInt("classBaseLevel"); - _lvlHpAdd = set.getFloat("lvlHpAdd"); - _lvlHpMod = set.getFloat("lvlHpMod"); - _lvlCpAdd = set.getFloat("lvlCpAdd"); - _lvlCpMod = set.getFloat("lvlCpMod"); - _lvlMpAdd = set.getFloat("lvlMpAdd"); - _lvlMpMod = set.getFloat("lvlMpMod"); - } - - /** - * add starter equipment - * @param itemId - */ - public void addItem(int itemId) - { - final Item item = ItemTable.getInstance().getTemplate(itemId); - if (item != null) + _classBaseLevel = set.getInt("baseLevel"); + _levelHpAdd = set.getFloat("levelHpAdd"); + _levelHpMod = set.getFloat("levelHpMod"); + _levelCpAdd = set.getFloat("levelCpAdd"); + _levelCpMod = set.getFloat("levelCpMod"); + _levelMpAdd = set.getFloat("levelMpAdd"); + _levelMpMod = set.getFloat("levelMpMod"); + String[] item; + for (String split : set.getString("items").split(";")) { - _items.add(item); + item = split.split(","); + _items.add(new ItemHolder(Integer.parseInt(item[0]), Integer.parseInt(item[1]))); } } - /** - * @return itemIds of all the starter equipment - */ - public Item[] getItems() + public List getItems() { - return _items.toArray(new Item[_items.size()]); + return _items; } public Race getRace() @@ -105,18 +83,6 @@ public class PlayerTemplate extends CreatureTemplate return _classId; } - @Override - public int getCollisionRadius() - { - return _currentCollisionRadius; - } - - @Override - public int getCollisionHeight() - { - return _currentCollisionHeight; - } - public String getClassName() { return _className; @@ -142,34 +108,34 @@ public class PlayerTemplate extends CreatureTemplate return _classBaseLevel; } - public float getLvlHpAdd() + public float getLevelHpAdd() { - return _lvlHpAdd; + return _levelHpAdd; } - public float getLvlHpMod() + public float getLevelHpMod() { - return _lvlHpMod; + return _levelHpMod; } - public float getLvlCpAdd() + public float getLevelCpAdd() { - return _lvlCpAdd; + return _levelCpAdd; } - public float getLvlCpMod() + public float getLevelCpMod() { - return _lvlCpMod; + return _levelCpMod; } - public float getLvlMpAdd() + public float getLevelMpAdd() { - return _lvlMpAdd; + return _levelMpAdd; } - public float getLvlMpMod() + public float getLevelMpMod() { - return _lvlMpMod; + return _levelMpMod; } public int getBaseFallSafeHeight(boolean female) diff --git a/L2J_Mobius_C6_Interlude/java/org/l2jmobius/gameserver/model/skills/Formulas.java b/L2J_Mobius_C6_Interlude/java/org/l2jmobius/gameserver/model/skills/Formulas.java index d38468190f..74cdead8df 100644 --- a/L2J_Mobius_C6_Interlude/java/org/l2jmobius/gameserver/model/skills/Formulas.java +++ b/L2J_Mobius_C6_Interlude/java/org/l2jmobius/gameserver/model/skills/Formulas.java @@ -714,9 +714,9 @@ public class Formulas { final PlayerTemplate t = (PlayerTemplate) env.player.getTemplate(); final int lvl = env.player.getLevel() - t.getClassBaseLevel(); - final double hpmod = t.getLvlHpMod() * lvl; - final double hpmax = (t.getLvlHpAdd() + hpmod) * lvl; - final double hpmin = (t.getLvlHpAdd() * lvl) + hpmod; + final double hpmod = t.getLevelHpMod() * lvl; + final double hpmax = (t.getLevelHpAdd() + hpmod) * lvl; + final double hpmin = (t.getLevelHpAdd() * lvl) + hpmod; env.value += (hpmax + hpmin) / 2; } } @@ -761,9 +761,9 @@ public class Formulas { final PlayerTemplate t = (PlayerTemplate) env.player.getTemplate(); final int lvl = env.player.getLevel() - t.getClassBaseLevel(); - final double cpmod = t.getLvlCpMod() * lvl; - final double cpmax = (t.getLvlCpAdd() + cpmod) * lvl; - final double cpmin = (t.getLvlCpAdd() * lvl) + cpmod; + final double cpmod = t.getLevelCpMod() * lvl; + final double cpmax = (t.getLevelCpAdd() + cpmod) * lvl; + final double cpmin = (t.getLevelCpAdd() * lvl) + cpmod; env.value += (cpmax + cpmin) / 2; } } @@ -808,9 +808,9 @@ public class Formulas { final PlayerTemplate t = (PlayerTemplate) env.player.getTemplate(); final int lvl = env.player.getLevel() - t.getClassBaseLevel(); - final double mpmod = t.getLvlMpMod() * lvl; - final double mpmax = (t.getLvlMpAdd() + mpmod) * lvl; - final double mpmin = (t.getLvlMpAdd() * lvl) + mpmod; + final double mpmod = t.getLevelMpMod() * lvl; + final double mpmax = (t.getLevelMpAdd() + mpmod) * lvl; + final double mpmin = (t.getLevelMpAdd() * lvl) + mpmod; env.value += (mpmax + mpmin) / 2; } } diff --git a/L2J_Mobius_C6_Interlude/java/org/l2jmobius/gameserver/network/clientpackets/CharacterCreate.java b/L2J_Mobius_C6_Interlude/java/org/l2jmobius/gameserver/network/clientpackets/CharacterCreate.java index 8e3edf76c0..4f8e6e3bef 100644 --- a/L2J_Mobius_C6_Interlude/java/org/l2jmobius/gameserver/network/clientpackets/CharacterCreate.java +++ b/L2J_Mobius_C6_Interlude/java/org/l2jmobius/gameserver/network/clientpackets/CharacterCreate.java @@ -26,9 +26,9 @@ import org.l2jmobius.gameserver.GameServer; import org.l2jmobius.gameserver.datatables.ItemTable; import org.l2jmobius.gameserver.datatables.SkillTable; import org.l2jmobius.gameserver.datatables.sql.CharNameTable; -import org.l2jmobius.gameserver.datatables.sql.CharTemplateTable; import org.l2jmobius.gameserver.datatables.sql.SkillTreeTable; import org.l2jmobius.gameserver.datatables.xml.ExperienceData; +import org.l2jmobius.gameserver.datatables.xml.PlayerTemplateData; import org.l2jmobius.gameserver.idfactory.IdFactory; import org.l2jmobius.gameserver.instancemanager.QuestManager; import org.l2jmobius.gameserver.model.ShortCut; @@ -36,6 +36,7 @@ import org.l2jmobius.gameserver.model.SkillLearn; import org.l2jmobius.gameserver.model.World; import org.l2jmobius.gameserver.model.actor.instance.PlayerInstance; import org.l2jmobius.gameserver.model.actor.templates.PlayerTemplate; +import org.l2jmobius.gameserver.model.holders.ItemHolder; import org.l2jmobius.gameserver.model.items.Item; import org.l2jmobius.gameserver.model.items.instance.ItemInstance; import org.l2jmobius.gameserver.model.quest.Quest; @@ -115,7 +116,7 @@ public class CharacterCreate extends GameClientPacket return; } - template = CharTemplateTable.getInstance().getTemplate(_classId); + template = PlayerTemplateData.getInstance().getTemplate(_classId); if ((template == null) || (template.getClassBaseLevel() > 1)) { sendPacket(new CharCreateFail(CharCreateFail.REASON_CREATION_FAILED)); @@ -249,9 +250,9 @@ public class CharacterCreate extends GameClientPacket newChar.registerShortCut(new ShortCut(3, 0, 3, 5, -1)); // Take newChar.registerShortCut(new ShortCut(10, 0, 3, 0, -1)); // Sit - for (Item item : template.getItems()) + for (ItemHolder item : template.getItems()) { - final ItemInstance itemInstance = newChar.getInventory().addItem("Init", item.getItemId(), 1, newChar, null); + final ItemInstance itemInstance = newChar.getInventory().addItem("Init", item.getId(), (int) item.getCount(), newChar, null); if (itemInstance.getItemId() == 5588) { newChar.registerShortCut(new ShortCut(11, 0, 1, itemInstance.getObjectId(), -1)); // Tutorial Book shortcut diff --git a/L2J_Mobius_C6_Interlude/java/org/l2jmobius/gameserver/network/clientpackets/CharacterSelected.java b/L2J_Mobius_C6_Interlude/java/org/l2jmobius/gameserver/network/clientpackets/CharacterSelected.java index 8451ecb3e6..af28b5d2fc 100644 --- a/L2J_Mobius_C6_Interlude/java/org/l2jmobius/gameserver/network/clientpackets/CharacterSelected.java +++ b/L2J_Mobius_C6_Interlude/java/org/l2jmobius/gameserver/network/clientpackets/CharacterSelected.java @@ -68,7 +68,6 @@ public class CharacterSelected extends GameClientPacket { // Load up character from disk final PlayerInstance cha = getClient().loadCharFromDisk(_charSlot); - if (cha == null) { LOGGER.warning(getType() + ": Character could not be loaded (slot:" + _charSlot + ")"); diff --git a/L2J_Mobius_C6_Interlude/java/org/l2jmobius/gameserver/network/clientpackets/NewCharacter.java b/L2J_Mobius_C6_Interlude/java/org/l2jmobius/gameserver/network/clientpackets/NewCharacter.java index 79ab76dbcf..20ea7a6c88 100644 --- a/L2J_Mobius_C6_Interlude/java/org/l2jmobius/gameserver/network/clientpackets/NewCharacter.java +++ b/L2J_Mobius_C6_Interlude/java/org/l2jmobius/gameserver/network/clientpackets/NewCharacter.java @@ -16,7 +16,7 @@ */ package org.l2jmobius.gameserver.network.clientpackets; -import org.l2jmobius.gameserver.datatables.sql.CharTemplateTable; +import org.l2jmobius.gameserver.datatables.xml.PlayerTemplateData; import org.l2jmobius.gameserver.model.actor.templates.PlayerTemplate; import org.l2jmobius.gameserver.model.base.ClassId; import org.l2jmobius.gameserver.network.serverpackets.CharTemplates; @@ -33,34 +33,34 @@ public class NewCharacter extends GameClientPacket { final CharTemplates ct = new CharTemplates(); - PlayerTemplate template = CharTemplateTable.getInstance().getTemplate(0); + PlayerTemplate template = PlayerTemplateData.getInstance().getTemplate(0); ct.addChar(template); - template = CharTemplateTable.getInstance().getTemplate(ClassId.FIGHTER); // Human Fighter + template = PlayerTemplateData.getInstance().getTemplate(ClassId.FIGHTER); // Human Fighter ct.addChar(template); - template = CharTemplateTable.getInstance().getTemplate(ClassId.MAGE); // Human Mage + template = PlayerTemplateData.getInstance().getTemplate(ClassId.MAGE); // Human Mage ct.addChar(template); - template = CharTemplateTable.getInstance().getTemplate(ClassId.ELVEN_FIGHTER); // Elf Fighter + template = PlayerTemplateData.getInstance().getTemplate(ClassId.ELVEN_FIGHTER); // Elf Fighter ct.addChar(template); - template = CharTemplateTable.getInstance().getTemplate(ClassId.ELVEN_MAGE); // Elf Mage + template = PlayerTemplateData.getInstance().getTemplate(ClassId.ELVEN_MAGE); // Elf Mage ct.addChar(template); - template = CharTemplateTable.getInstance().getTemplate(ClassId.DARK_FIGHTER); // DE Fighter + template = PlayerTemplateData.getInstance().getTemplate(ClassId.DARK_FIGHTER); // DE Fighter ct.addChar(template); - template = CharTemplateTable.getInstance().getTemplate(ClassId.DARK_MAGE); // DE Mage + template = PlayerTemplateData.getInstance().getTemplate(ClassId.DARK_MAGE); // DE Mage ct.addChar(template); - template = CharTemplateTable.getInstance().getTemplate(ClassId.ORC_FIGHTER); // Orc Fighter + template = PlayerTemplateData.getInstance().getTemplate(ClassId.ORC_FIGHTER); // Orc Fighter ct.addChar(template); - template = CharTemplateTable.getInstance().getTemplate(ClassId.ORC_MAGE); // Orc Mage + template = PlayerTemplateData.getInstance().getTemplate(ClassId.ORC_MAGE); // Orc Mage ct.addChar(template); - template = CharTemplateTable.getInstance().getTemplate(ClassId.DWARVEN_FIGHTER); // Dwarf Fighter + template = PlayerTemplateData.getInstance().getTemplate(ClassId.DWARVEN_FIGHTER); // Dwarf Fighter ct.addChar(template); // Finally diff --git a/L2J_Mobius_C6_Interlude/java/org/l2jmobius/gameserver/network/serverpackets/CustomNpcInfo.java b/L2J_Mobius_C6_Interlude/java/org/l2jmobius/gameserver/network/serverpackets/CustomNpcInfo.java index 3792ddbaeb..1bbbdddba7 100644 --- a/L2J_Mobius_C6_Interlude/java/org/l2jmobius/gameserver/network/serverpackets/CustomNpcInfo.java +++ b/L2J_Mobius_C6_Interlude/java/org/l2jmobius/gameserver/network/serverpackets/CustomNpcInfo.java @@ -16,7 +16,7 @@ */ package org.l2jmobius.gameserver.network.serverpackets; -import org.l2jmobius.gameserver.datatables.sql.CharTemplateTable; +import org.l2jmobius.gameserver.datatables.xml.PlayerTemplateData; import org.l2jmobius.gameserver.model.actor.instance.NpcInstance; public class CustomNpcInfo extends GameServerPacket @@ -76,8 +76,8 @@ public class CustomNpcInfo extends GameServerPacket writeD(_activeChar.getRunSpeed()); writeF(_activeChar.getStat().getMovementSpeedMultiplier()); writeF(_activeChar.getStat().getAttackSpeedMultiplier()); - writeF(CharTemplateTable.getInstance().getTemplate(_activeChar.getCustomNpcInstance().getClassId()).getCollisionRadius()); - writeF(CharTemplateTable.getInstance().getTemplate(_activeChar.getCustomNpcInstance().getClassId()).getCollisionHeight()); + writeF(PlayerTemplateData.getInstance().getTemplate(_activeChar.getCustomNpcInstance().getClassId()).getCollisionRadius()); + writeF(PlayerTemplateData.getInstance().getTemplate(_activeChar.getCustomNpcInstance().getClassId()).getCollisionHeight()); writeD(_activeChar.getCustomNpcInstance().getHairStyle()); writeD(_activeChar.getCustomNpcInstance().getHairColor()); writeD(_activeChar.getCustomNpcInstance().getFace());