diff --git a/sql/mangos.sql b/sql/mangos.sql index c63f3b6cf..a6748640b 100644 --- a/sql/mangos.sql +++ b/sql/mangos.sql @@ -23,7 +23,7 @@ DROP TABLE IF EXISTS `db_version`; CREATE TABLE `db_version` ( `version` varchar(120) default NULL, `creature_ai_version` varchar(120) default NULL, - `required_8140_01_mangos_spell_proc_event` bit(1) default NULL + `required_8158_01_mangos_playercreateinfo_action` bit(1) default NULL ) ENGINE=MyISAM DEFAULT CHARSET=utf8 ROW_FORMAT=FIXED COMMENT='Used DB version notes'; -- @@ -9723,7 +9723,8 @@ CREATE TABLE `playercreateinfo_action` ( `button` smallint(5) unsigned NOT NULL default '0', `action` int(11) unsigned NOT NULL default '0', `type` smallint(5) unsigned NOT NULL default '0', - KEY `playercreateinfo_race_class_index` (`race`,`class`) + KEY `playercreateinfo_race_class_index` (`race`,`class`), + PRIMARY KEY (`race`,`class`,`button`) ) ENGINE=MyISAM DEFAULT CHARSET=utf8; -- @@ -9733,22 +9734,31 @@ CREATE TABLE `playercreateinfo_action` ( LOCK TABLES `playercreateinfo_action` WRITE; /*!40000 ALTER TABLE `playercreateinfo_action` DISABLE KEYS */; INSERT INTO `playercreateinfo_action` VALUES -(1,1,1,78,0), (1,1,0,6603,0), (1,1,11,117,128), -(1,2,2,635,0), +(1,1,72,6603,0), +(1,1,73,78,0), +(1,1,82,59752,0), +(1,1,83,117,128), +(1,1,84,6603,0), +(1,1,96,6603,0), +(1,1,108,6603,0), (1,2,0,6603,0), -(1,2,1,21084,0), +(1,2,1,20154,0), +(1,2,2,635,0), +(1,2,9,59752,0), (1,2,10,159,128), (1,2,11,2070,128), +(1,4,0,6603,0), (1,4,1,1752,0), (1,4,2,2098,0), (1,4,3,2764,0), -(1,4,0,6603,0), +(1,4,10,59752,0), (1,4,11,2070,128), +(1,5,0,6603,0), (1,5,1,585,0), (1,5,2,2050,0), -(1,5,0,6603,0), +(1,5,9,59752,0), (1,5,10,159,128), (1,5,11,2070,128), (1,6,0,6603,0), @@ -9758,28 +9768,37 @@ INSERT INTO `playercreateinfo_action` VALUES (1,6,4,45902,0), (1,6,5,47541,0), (1,6,11,59752,0), +(1,8,0,6603,0), (1,8,1,133,0), (1,8,2,168,0), -(1,8,0,6603,0), +(1,8,9,59752,0), (1,8,10,159,128), (1,8,11,2070,128), +(1,9,0,6603,0), (1,9,1,686,0), (1,9,2,687,0), -(1,9,0,6603,0), +(1,9,9,59752,0), (1,9,10,159,128), (1,9,11,4604,128), -(2,1,1,78,0), (2,1,0,6603,0), -(2,1,11,117,128), -(2,3,2,75,0), -(2,3,1,2973,0), +(2,1,72,6603,0), +(2,1,73,78,0), +(2,1,74,20572,0), +(2,1,83,117,128), +(2,1,84,6603,0), +(2,1,96,6603,0), +(2,1,108,6603,0), (2,3,0,6603,0), -(2,3,11,117,128), +(2,3,1,2973,0), +(2,3,2,75,0), +(2,3,4,20572,0), (2,3,10,159,128), -(2,4,10,0,128), +(2,3,11,117,128), +(2,4,0,6603,0), (2,4,1,1752,0), (2,4,2,2098,0), -(2,4,0,6603,0), +(2,4,3,2764,0), +(2,4,4,20572,0), (2,4,11,117,128), (2,6,0,6603,0), (2,6,1,49576,0), @@ -9788,37 +9807,57 @@ INSERT INTO `playercreateinfo_action` VALUES (2,6,4,45902,0), (2,6,5,47541,0), (2,6,10,20572,0), -(2,7,2,331,0), -(2,7,1,403,0), (2,7,0,6603,0), -(2,7,11,117,128), +(2,7,1,403,0), +(2,7,2,331,0), +(2,7,3,33697,0), (2,7,10,159,128), +(2,7,11,117,128), +(2,9,0,6603,0), (2,9,1,686,0), (2,9,2,687,0), -(2,9,0,6603,0), -(2,9,11,117,128), +(2,9,3,33702,0), (2,9,10,159,128), -(3,1,1,78,0), +(2,9,11,117,128), (3,1,0,6603,0), +(3,1,1,78,0), (3,1,11,117,128), -(3,2,2,635,0), +(3,1,72,6603,0), +(3,1,73,78,0), +(3,1,74,20594,0), +(3,1,75,2481,0), +(3,1,83,117,128), +(3,1,84,6603,0), +(3,1,96,6603,0), +(3,1,108,6603,0), (3,2,0,6603,0), -(3,2,1,21084,0), +(3,2,1,20154,0), +(3,2,2,635,0), +(3,2,3,20594,0), +(3,2,4,2481,0), (3,2,10,159,128), (3,2,11,4540,128), -(3,3,2,75,0), -(3,3,1,2973,0), (3,3,0,6603,0), -(3,3,11,117,128), +(3,3,1,2973,0), +(3,3,2,75,0), +(3,3,3,20594,0), +(3,3,4,2481,0), (3,3,10,159,128), +(3,3,11,117,128), +(3,3,75,20594,0), +(3,3,76,2481,0), +(3,4,0,6603,0), (3,4,1,1752,0), (3,4,2,2098,0), (3,4,3,2764,0), -(3,4,0,6603,0), +(3,4,4,20594,0), +(3,4,5,2481,0), (3,4,11,4540,128), +(3,5,0,6603,0), (3,5,1,585,0), (3,5,2,2050,0), -(3,5,0,6603,0), +(3,5,3,20594,0), +(3,5,4,2481,0), (3,5,10,159,128), (3,5,11,4540,128), (3,6,0,6603,0), @@ -9828,22 +9867,30 @@ INSERT INTO `playercreateinfo_action` VALUES (3,6,4,45902,0), (3,6,5,47541,0), (3,6,10,2481,0), -(4,1,1,78,0), -(4,1,0,6603,0), -(4,1,11,117,128), -(4,3,2,75,0), -(4,3,1,2973,0), +(4,1,72,6603,0), +(4,1,73,6603,0), +(4,1,74,78,0), +(4,1,83,58984,0), +(4,1,84,117,128), +(4,1,85,6603,0), +(4,1,97,6603,0), +(4,1,109,6603,0), (4,3,0,6603,0), -(4,3,11,117,128), +(4,3,1,2973,0), +(4,3,2,75,0), +(4,3,3,58984,0), (4,3,10,159,128), +(4,3,11,117,128), +(4,4,0,6603,0), (4,4,1,1752,0), (4,4,2,2098,0), (4,4,3,2764,0), -(4,4,0,6603,0), +(4,4,4,58984,0), (4,4,11,4540,128), +(4,5,0,6603,0), (4,5,1,585,0), (4,5,2,2050,0), -(4,5,0,6603,0), +(4,5,3,58984,0), (4,5,10,159,128), (4,5,11,2070,128), (4,6,0,6603,0), @@ -9854,24 +9901,32 @@ INSERT INTO `playercreateinfo_action` VALUES (4,6,5,47541,0), (4,6,10,58984,0), (4,6,83,58984,0), +(4,11,0,6603,0), (4,11,1,5176,0), (4,11,2,5185,0), -(4,11,0,6603,0), +(4,11,3,58984,0), (4,11,10,159,128), (4,11,11,4536,128), -(5,1,11,4604,128), (5,1,0,6603,0), -(5,1,1,78,0), -(5,4,11,4604,128), -(5,4,3,2764,0), -(5,4,2,2098,0), -(5,4,1,1752,0), +(5,1,72,6603,0), +(5,1,73,78,0), +(5,1,74,20577,0), +(5,1,83,4604,128), +(5,1,84,6603,0), +(5,1,96,6603,0), +(5,1,108,6603,0), (5,4,0,6603,0), -(5,5,10,159,128), -(5,5,2,2050,0), -(5,5,1,585,0), -(5,5,11,4604,128), +(5,4,1,1752,0), +(5,4,2,2098,0), +(5,4,3,2764,0), +(5,4,4,20577,0), +(5,4,11,4604,128), (5,5,0,6603,0), +(5,5,1,585,0), +(5,5,2,2050,0), +(5,5,3,20577,0), +(5,5,10,159,128), +(5,5,11,4604,128), (5,6,0,6603,0), (5,6,1,49576,0), (5,6,2,45477,0), @@ -9879,26 +9934,35 @@ INSERT INTO `playercreateinfo_action` VALUES (5,6,4,45902,0), (5,6,5,47541,0), (5,6,10,20577,0), -(5,8,11,4604,128), -(5,8,10,159,128), -(5,8,2,168,0), -(5,8,1,133,0), (5,8,0,6603,0), -(5,9,1,686,0), -(5,9,10,159,128), -(5,9,2,687,0), -(5,9,11,4604,128), +(5,8,1,133,0), +(5,8,2,168,0), +(5,8,3,20577,0), +(5,8,10,159,128), +(5,8,11,4604,128), (5,9,0,6603,0), -(6,1,1,78,0), -(6,1,2,20549,0), -(6,1,11,4540,128), +(5,9,1,686,0), +(5,9,2,687,0), +(5,9,3,20577,0), +(5,9,10,159,128), +(5,9,11,4604,128), (6,1,0,6603,0), +(6,1,1,78,0), +(6,1,3,20549,0), +(6,1,72,6603,0), +(6,1,73,78,0), +(6,1,74,20549,0), +(6,1,83,4540,128), +(6,1,84,6603,0), +(6,1,96,6603,0), +(6,1,108,6603,0), +(6,3,0,6603,0), (6,3,1,2973,0), -(6,3,10,159,128), (6,3,2,75,0), (6,3,3,20549,0), +(6,3,10,159,128), (6,3,11,117,128), -(6,3,0,6603,0), +(6,3,76,20549,0), (6,6,0,6603,0), (6,6,1,49576,0), (6,6,2,45477,0), @@ -9907,26 +9971,41 @@ INSERT INTO `playercreateinfo_action` VALUES (6,6,5,47541,0), (6,6,10,20549,0), (6,6,75,20549,0), +(6,7,0,6603,0), (6,7,1,403,0), -(6,7,10,159,128), (6,7,2,331,0), (6,7,3,20549,0), +(6,7,10,159,128), (6,7,11,4604,128), -(6,7,0,6603,0), +(6,7,76,20549,0), +(6,11,0,6603,0), (6,11,1,5176,0), -(6,11,10,159,128), (6,11,2,5185,0), (6,11,3,20549,0), +(6,11,10,159,128), (6,11,11,4536,128), -(6,11,0,6603,0), -(7,1,11,117,128), -(7,1,1,78,0), +(6,11,73,6603,0), +(6,11,76,20549,0), +(6,11,85,6603,0), +(6,11,97,6603,0), +(6,11,109,6603,0), (7,1,0,6603,0), -(7,4,11,117,128), -(7,4,3,2764,0), +(7,1,1,78,0), +(7,1,10,20589,0), +(7,1,11,117,128), +(7,1,72,6603,0), +(7,1,73,78,0), +(7,1,82,20589,0), +(7,1,83,117,128), +(7,1,84,6603,0), +(7,1,96,6603,0), +(7,1,108,6603,0), +(7,4,0,6603,0), (7,4,1,1752,0), (7,4,2,2098,0), -(7,4,0,6603,0), +(7,4,3,2764,0), +(7,4,10,20589,0), +(7,4,11,117,128), (7,6,0,6603,0), (7,6,1,49576,0), (7,6,2,45477,0), @@ -9934,40 +10013,51 @@ INSERT INTO `playercreateinfo_action` VALUES (7,6,4,45902,0), (7,6,5,47541,0), (7,6,10,20589,0), +(7,6,11,117,128), (7,6,72,6603,0), (7,6,83,117,128), (7,6,84,6603,0), (7,6,96,6603,0), (7,6,108,6603,0), -(7,8,11,4536,128), +(7,8,0,6603,0), (7,8,1,133,0), (7,8,2,168,0), +(7,8,9,20589,0), (7,8,10,159,128), -(7,8,0,6603,0), -(7,9,11,4604,128), +(7,8,11,4536,128), +(7,9,0,6603,0), (7,9,1,686,0), (7,9,2,687,0), +(7,9,9,20589,0), (7,9,10,159,128), -(7,9,0,6603,0), -(8,1,11,117,128), -(8,1,1,78,0), -(8,1,3,2764,0), +(7,9,11,4604,128), (8,1,0,6603,0), -(8,3,10,159,128), -(8,3,11,4604,128), +(8,1,72,6603,0), +(8,1,73,78,0), +(8,1,74,2764,0), +(8,1,75,26296,0), +(8,1,83,117,128), +(8,1,84,6603,0), +(8,1,96,6603,0), +(8,1,108,6603,0), +(8,3,0,6603,0), (8,3,1,2973,0), (8,3,2,75,0), -(8,3,0,6603,0), -(8,4,1,1752,0), -(8,4,3,2764,0), -(8,4,2,2098,0), -(8,4,11,117,128), +(8,3,10,159,128), +(8,3,11,4604,128), +(8,3,76,20554,0), (8,4,0,6603,0), -(8,5,1,585,0), -(8,5,10,159,128), -(8,5,2,2050,0), -(8,5,11,4540,128), +(8,4,1,1752,0), +(8,4,2,2098,0), +(8,4,3,2764,0), +(8,4,11,117,128), +(8,4,76,20554,0), (8,5,0,6603,0), +(8,5,1,585,0), +(8,5,2,2050,0), +(8,5,10,159,128), +(8,5,11,4540,128), +(8,5,76,20554,0), (8,6,0,6603,0), (8,6,1,49576,0), (8,6,2,45477,0), @@ -9975,42 +10065,40 @@ INSERT INTO `playercreateinfo_action` VALUES (8,6,4,45902,0), (8,6,5,47541,0), (8,6,10,50621,0), -(8,7,1,403,0), -(8,7,10,159,128), -(8,7,2,331,0), -(8,7,11,117,128), (8,7,0,6603,0), -(8,8,1,133,0), -(8,8,10,159,128), -(8,8,2,168,0), -(8,8,11,117,128), +(8,7,1,403,0), +(8,7,2,331,0), +(8,7,10,159,128), +(8,7,11,117,128), +(8,7,76,20554,0), (8,8,0,6603,0), +(8,8,1,133,0), +(8,8,2,168,0), +(8,8,10,159,128), +(8,8,11,117,128), +(8,8,76,20554,0), (10,2,0,6603,0), (10,2,1,21084,0), (10,2,2,635,0), -(10,2,3,28734,0), -(10,2,4,28730,0), +(10,2,3,28730,0), (10,2,10,159,128), (10,2,11,20857,128), (10,3,0,6603,0), (10,3,1,2973,0), (10,3,2,75,0), -(10,3,3,28734,0), -(10,3,4,28730,0), +(10,3,3,28730,0), (10,3,10,159,128), (10,3,11,20857,128), (10,4,0,6603,0), (10,4,1,1752,0), (10,4,2,2098,0), (10,4,3,2764,0), -(10,4,4,28734,0), -(10,4,5,25046,0), +(10,4,4,25046,0), (10,4,11,20857,128), (10,5,0,6603,0), (10,5,1,585,0), (10,5,2,2050,0), -(10,5,3,28734,0), -(10,5,4,28730,0), +(10,5,3,28730,0), (10,5,10,159,128), (10,5,11,20857,128), (10,6,0,6603,0), @@ -10023,17 +10111,15 @@ INSERT INTO `playercreateinfo_action` VALUES (10,8,0,6603,0), (10,8,1,133,0), (10,8,2,168,0), -(10,8,3,28734,0), -(10,8,4,28730,0), +(10,8,3,28730,0), (10,8,10,159,128), (10,8,11,20857,128), -(10,9,11,20857,128), -(10,9,10,159,128), -(10,9,4,28730,0), -(10,9,3,28734,0), -(10,9,2,687,0), -(10,9,1,686,0), (10,9,0,6603,0), +(10,9,1,686,0), +(10,9,2,687,0), +(10,9,3,28730,0), +(10,9,10,159,128), +(10,9,11,20857,128), (11,1,0,6603,0), (11,1,72,6603,0), (11,1,73,78,0), diff --git a/sql/updates/8158_01_mangos_playercreateinfo_action.sql b/sql/updates/8158_01_mangos_playercreateinfo_action.sql new file mode 100644 index 000000000..a027fdb0d --- /dev/null +++ b/sql/updates/8158_01_mangos_playercreateinfo_action.sql @@ -0,0 +1,453 @@ +ALTER TABLE db_version CHANGE COLUMN required_8140_01_mangos_spell_proc_event required_8158_01_mangos_playercreateinfo_action bit; + +DROP TABLE IF EXISTS `playercreateinfo_action`; +CREATE TABLE `playercreateinfo_action` ( + `race` tinyint(3) unsigned NOT NULL default '0', + `class` tinyint(3) unsigned NOT NULL default '0', + `button` smallint(5) unsigned NOT NULL default '0', + `action` int(11) unsigned NOT NULL default '0', + `type` smallint(5) unsigned NOT NULL default '0', + KEY `playercreateinfo_race_class_index` (`race`,`class`), + PRIMARY KEY (`race`,`class`,`button`) +) ENGINE=MyISAM DEFAULT CHARSET=utf8; + +INSERT INTO `playercreateinfo_action` VALUES +(1,1,0,6603,0), +(1,1,11,117,128), +(1,1,72,6603,0), +(1,1,73,78,0), +(1,1,82,59752,0), +(1,1,83,117,128), +(1,1,84,6603,0), +(1,1,96,6603,0), +(1,1,108,6603,0), +(1,2,0,6603,0), +(1,2,1,20154,0), +(1,2,2,635,0), +(1,2,9,59752,0), +(1,2,10,159,128), +(1,2,11,2070,128), +(1,4,0,6603,0), +(1,4,1,1752,0), +(1,4,2,2098,0), +(1,4,3,2764,0), +(1,4,10,59752,0), +(1,4,11,2070,128), +(1,5,0,6603,0), +(1,5,1,585,0), +(1,5,2,2050,0), +(1,5,9,59752,0), +(1,5,10,159,128), +(1,5,11,2070,128), +(1,6,0,6603,0), +(1,6,1,49576,0), +(1,6,2,45477,0), +(1,6,3,45462,0), +(1,6,4,45902,0), +(1,6,5,47541,0), +(1,6,11,59752,0), +(1,8,0,6603,0), +(1,8,1,133,0), +(1,8,2,168,0), +(1,8,9,59752,0), +(1,8,10,159,128), +(1,8,11,2070,128), +(1,9,0,6603,0), +(1,9,1,686,0), +(1,9,2,687,0), +(1,9,9,59752,0), +(1,9,10,159,128), +(1,9,11,4604,128), +(2,1,0,6603,0), +(2,1,72,6603,0), +(2,1,73,78,0), +(2,1,74,20572,0), +(2,1,83,117,128), +(2,1,84,6603,0), +(2,1,96,6603,0), +(2,1,108,6603,0), +(2,3,0,6603,0), +(2,3,1,2973,0), +(2,3,2,75,0), +(2,3,4,20572,0), +(2,3,10,159,128), +(2,3,11,117,128), +(2,4,0,6603,0), +(2,4,1,1752,0), +(2,4,2,2098,0), +(2,4,3,2764,0), +(2,4,4,20572,0), +(2,4,11,117,128), +(2,6,0,6603,0), +(2,6,1,49576,0), +(2,6,2,45477,0), +(2,6,3,45462,0), +(2,6,4,45902,0), +(2,6,5,47541,0), +(2,6,10,20572,0), +(2,7,0,6603,0), +(2,7,1,403,0), +(2,7,2,331,0), +(2,7,3,33697,0), +(2,7,10,159,128), +(2,7,11,117,128), +(2,9,0,6603,0), +(2,9,1,686,0), +(2,9,2,687,0), +(2,9,3,33702,0), +(2,9,10,159,128), +(2,9,11,117,128), +(3,1,0,6603,0), +(3,1,1,78,0), +(3,1,11,117,128), +(3,1,72,6603,0), +(3,1,73,78,0), +(3,1,74,20594,0), +(3,1,75,2481,0), +(3,1,83,117,128), +(3,1,84,6603,0), +(3,1,96,6603,0), +(3,1,108,6603,0), +(3,2,0,6603,0), +(3,2,1,20154,0), +(3,2,2,635,0), +(3,2,3,20594,0), +(3,2,4,2481,0), +(3,2,10,159,128), +(3,2,11,4540,128), +(3,3,0,6603,0), +(3,3,1,2973,0), +(3,3,2,75,0), +(3,3,3,20594,0), +(3,3,4,2481,0), +(3,3,10,159,128), +(3,3,11,117,128), +(3,3,75,20594,0), +(3,3,76,2481,0), +(3,4,0,6603,0), +(3,4,1,1752,0), +(3,4,2,2098,0), +(3,4,3,2764,0), +(3,4,4,20594,0), +(3,4,5,2481,0), +(3,4,11,4540,128), +(3,5,0,6603,0), +(3,5,1,585,0), +(3,5,2,2050,0), +(3,5,3,20594,0), +(3,5,4,2481,0), +(3,5,10,159,128), +(3,5,11,4540,128), +(3,6,0,6603,0), +(3,6,1,49576,0), +(3,6,2,45477,0), +(3,6,3,45462,0), +(3,6,4,45902,0), +(3,6,5,47541,0), +(3,6,10,2481,0), +(4,1,72,6603,0), +(4,1,73,6603,0), +(4,1,74,78,0), +(4,1,83,58984,0), +(4,1,84,117,128), +(4,1,85,6603,0), +(4,1,97,6603,0), +(4,1,109,6603,0), +(4,3,0,6603,0), +(4,3,1,2973,0), +(4,3,2,75,0), +(4,3,3,58984,0), +(4,3,10,159,128), +(4,3,11,117,128), +(4,4,0,6603,0), +(4,4,1,1752,0), +(4,4,2,2098,0), +(4,4,3,2764,0), +(4,4,4,58984,0), +(4,4,11,4540,128), +(4,5,0,6603,0), +(4,5,1,585,0), +(4,5,2,2050,0), +(4,5,3,58984,0), +(4,5,10,159,128), +(4,5,11,2070,128), +(4,6,0,6603,0), +(4,6,1,49576,0), +(4,6,2,45477,0), +(4,6,3,45462,0), +(4,6,4,45902,0), +(4,6,5,47541,0), +(4,6,10,58984,0), +(4,6,83,58984,0), +(4,11,0,6603,0), +(4,11,1,5176,0), +(4,11,2,5185,0), +(4,11,3,58984,0), +(4,11,10,159,128), +(4,11,11,4536,128), +(5,1,0,6603,0), +(5,1,72,6603,0), +(5,1,73,78,0), +(5,1,74,20577,0), +(5,1,83,4604,128), +(5,1,84,6603,0), +(5,1,96,6603,0), +(5,1,108,6603,0), +(5,4,0,6603,0), +(5,4,1,1752,0), +(5,4,2,2098,0), +(5,4,3,2764,0), +(5,4,4,20577,0), +(5,4,11,4604,128), +(5,5,0,6603,0), +(5,5,1,585,0), +(5,5,2,2050,0), +(5,5,3,20577,0), +(5,5,10,159,128), +(5,5,11,4604,128), +(5,6,0,6603,0), +(5,6,1,49576,0), +(5,6,2,45477,0), +(5,6,3,45462,0), +(5,6,4,45902,0), +(5,6,5,47541,0), +(5,6,10,20577,0), +(5,8,0,6603,0), +(5,8,1,133,0), +(5,8,2,168,0), +(5,8,3,20577,0), +(5,8,10,159,128), +(5,8,11,4604,128), +(5,9,0,6603,0), +(5,9,1,686,0), +(5,9,2,687,0), +(5,9,3,20577,0), +(5,9,10,159,128), +(5,9,11,4604,128), +(6,1,0,6603,0), +(6,1,1,78,0), +(6,1,3,20549,0), +(6,1,72,6603,0), +(6,1,73,78,0), +(6,1,74,20549,0), +(6,1,83,4540,128), +(6,1,84,6603,0), +(6,1,96,6603,0), +(6,1,108,6603,0), +(6,3,0,6603,0), +(6,3,1,2973,0), +(6,3,2,75,0), +(6,3,3,20549,0), +(6,3,10,159,128), +(6,3,11,117,128), +(6,3,76,20549,0), +(6,6,0,6603,0), +(6,6,1,49576,0), +(6,6,2,45477,0), +(6,6,3,45462,0), +(6,6,4,45902,0), +(6,6,5,47541,0), +(6,6,10,20549,0), +(6,6,75,20549,0), +(6,7,0,6603,0), +(6,7,1,403,0), +(6,7,2,331,0), +(6,7,3,20549,0), +(6,7,10,159,128), +(6,7,11,4604,128), +(6,7,76,20549,0), +(6,11,0,6603,0), +(6,11,1,5176,0), +(6,11,2,5185,0), +(6,11,3,20549,0), +(6,11,10,159,128), +(6,11,11,4536,128), +(6,11,73,6603,0), +(6,11,76,20549,0), +(6,11,85,6603,0), +(6,11,97,6603,0), +(6,11,109,6603,0), +(7,1,0,6603,0), +(7,1,1,78,0), +(7,1,10,20589,0), +(7,1,11,117,128), +(7,1,72,6603,0), +(7,1,73,78,0), +(7,1,82,20589,0), +(7,1,83,117,128), +(7,1,84,6603,0), +(7,1,96,6603,0), +(7,1,108,6603,0), +(7,4,0,6603,0), +(7,4,1,1752,0), +(7,4,2,2098,0), +(7,4,3,2764,0), +(7,4,10,20589,0), +(7,4,11,117,128), +(7,6,0,6603,0), +(7,6,1,49576,0), +(7,6,2,45477,0), +(7,6,3,45462,0), +(7,6,4,45902,0), +(7,6,5,47541,0), +(7,6,10,20589,0), +(7,6,11,117,128), +(7,6,72,6603,0), +(7,6,83,117,128), +(7,6,84,6603,0), +(7,6,96,6603,0), +(7,6,108,6603,0), +(7,8,0,6603,0), +(7,8,1,133,0), +(7,8,2,168,0), +(7,8,9,20589,0), +(7,8,10,159,128), +(7,8,11,4536,128), +(7,9,0,6603,0), +(7,9,1,686,0), +(7,9,2,687,0), +(7,9,9,20589,0), +(7,9,10,159,128), +(7,9,11,4604,128), +(8,1,0,6603,0), +(8,1,72,6603,0), +(8,1,73,78,0), +(8,1,74,2764,0), +(8,1,75,26296,0), +(8,1,83,117,128), +(8,1,84,6603,0), +(8,1,96,6603,0), +(8,1,108,6603,0), +(8,3,0,6603,0), +(8,3,1,2973,0), +(8,3,2,75,0), +(8,3,10,159,128), +(8,3,11,4604,128), +(8,3,76,20554,0), +(8,4,0,6603,0), +(8,4,1,1752,0), +(8,4,2,2098,0), +(8,4,3,2764,0), +(8,4,11,117,128), +(8,4,76,20554,0), +(8,5,0,6603,0), +(8,5,1,585,0), +(8,5,2,2050,0), +(8,5,10,159,128), +(8,5,11,4540,128), +(8,5,76,20554,0), +(8,6,0,6603,0), +(8,6,1,49576,0), +(8,6,2,45477,0), +(8,6,3,45462,0), +(8,6,4,45902,0), +(8,6,5,47541,0), +(8,6,10,50621,0), +(8,7,0,6603,0), +(8,7,1,403,0), +(8,7,2,331,0), +(8,7,10,159,128), +(8,7,11,117,128), +(8,7,76,20554,0), +(8,8,0,6603,0), +(8,8,1,133,0), +(8,8,2,168,0), +(8,8,10,159,128), +(8,8,11,117,128), +(8,8,76,20554,0), +(10,2,0,6603,0), +(10,2,1,21084,0), +(10,2,2,635,0), +(10,2,3,28730,0), +(10,2,10,159,128), +(10,2,11,20857,128), +(10,3,0,6603,0), +(10,3,1,2973,0), +(10,3,2,75,0), +(10,3,3,28730,0), +(10,3,10,159,128), +(10,3,11,20857,128), +(10,4,0,6603,0), +(10,4,1,1752,0), +(10,4,2,2098,0), +(10,4,3,2764,0), +(10,4,4,25046,0), +(10,4,11,20857,128), +(10,5,0,6603,0), +(10,5,1,585,0), +(10,5,2,2050,0), +(10,5,3,28730,0), +(10,5,10,159,128), +(10,5,11,20857,128), +(10,6,0,6603,0), +(10,6,1,49576,0), +(10,6,2,45477,0), +(10,6,3,45462,0), +(10,6,4,45902,0), +(10,6,5,47541,0), +(10,6,6,50613,0), +(10,8,0,6603,0), +(10,8,1,133,0), +(10,8,2,168,0), +(10,8,3,28730,0), +(10,8,10,159,128), +(10,8,11,20857,128), +(10,9,0,6603,0), +(10,9,1,686,0), +(10,9,2,687,0), +(10,9,3,28730,0), +(10,9,10,159,128), +(10,9,11,20857,128), +(11,1,0,6603,0), +(11,1,72,6603,0), +(11,1,73,78,0), +(11,1,74,28880,0), +(11,1,83,4540,128), +(11,1,84,6603,0), +(11,1,96,6603,0), +(11,1,108,6603,0), +(11,2,0,6603,0), +(11,2,1,21084,0), +(11,2,2,635,0), +(11,2,3,59542,0), +(11,2,10,159,128), +(11,2,11,4540,128), +(11,2,83,4540,128), +(11,3,0,6603,0), +(11,3,1,2973,0), +(11,3,2,75,0), +(11,3,3,59543,0), +(11,3,10,159,128), +(11,3,11,4540,128), +(11,3,72,6603,0), +(11,3,73,2973,0), +(11,3,74,75,0), +(11,3,82,159,128), +(11,3,83,4540,128), +(11,5,0,6603,0), +(11,5,1,585,0), +(11,5,2,2050,0), +(11,5,3,59544,0), +(11,5,10,159,128), +(11,5,11,4540,128), +(11,5,83,4540,128), +(11,6,0,6603,0), +(11,6,1,49576,0), +(11,6,2,45477,0), +(11,6,3,45462,0), +(11,6,4,45902,0), +(11,6,5,47541,0), +(11,6,6,59545,0), +(11,7,0,6603,0), +(11,7,1,403,0), +(11,7,2,331,0), +(11,7,3,59547,0), +(11,7,10,159,128), +(11,7,11,4540,128), +(11,8,0,6603,0), +(11,8,1,133,0), +(11,8,2,168,0), +(11,8,3,59548,0), +(11,8,10,159,128), +(11,8,11,4540,128), +(11,8,83,4540,128); diff --git a/sql/updates/Makefile.am b/sql/updates/Makefile.am index c9002001c..d520e5679 100644 --- a/sql/updates/Makefile.am +++ b/sql/updates/Makefile.am @@ -243,6 +243,7 @@ pkgdata_DATA = \ 8112_01_mangos_spell_proc_event.sql \ 8115_01_mangos_playercreateinfo_action.sql \ 8140_01_mangos_spell_proc_event.sql \ + 8158_01_mangos_playercreateinfo_action.sql \ README ## Additional files to include when running 'make dist' @@ -466,4 +467,5 @@ EXTRA_DIST = \ 8112_01_mangos_spell_proc_event.sql \ 8115_01_mangos_playercreateinfo_action.sql \ 8140_01_mangos_spell_proc_event.sql \ + 8158_01_mangos_playercreateinfo_action.sql \ README diff --git a/src/game/AchievementMgr.cpp b/src/game/AchievementMgr.cpp index 258a3c71e..07566139e 100644 --- a/src/game/AchievementMgr.cpp +++ b/src/game/AchievementMgr.cpp @@ -138,7 +138,7 @@ bool AchievementCriteriaData::IsValid(AchievementCriteriaEntry const* criteria) case ACHIEVEMENT_CRITERIA_DATA_TYPE_T_PLAYER_DEAD: if (player_dead.own_team_flag > 1) { - sLog.outErrorDb( "Table `achievement_criteria_data` (Entry: %u Type: %u) for data type %s (%u) have wrong boolean value1 (%u).", + sLog.outErrorDb( "Table `achievement_criteria_data` (Entry: %u Type: %u) for data type ACHIEVEMENT_CRITERIA_DATA_TYPE_T_PLAYER_DEAD (%u) have wrong boolean value1 (%u).", criteria->ID, criteria->requiredType,dataType,player_dead.own_team_flag); return false; } diff --git a/src/game/DBCStores.cpp b/src/game/DBCStores.cpp index 416d4c9f9..9050a1b52 100644 --- a/src/game/DBCStores.cpp +++ b/src/game/DBCStores.cpp @@ -187,7 +187,7 @@ inline void LoadDBC(uint32& availableDbcLocales,barGoLink& bar, StoreProblemList if(f) { char buf[100]; - snprintf(buf,100," (exist, but have %d fields instead %d) Wrong client version DBC file?",storage.GetFieldCount(),strlen(storage.GetFormat())); + snprintf(buf,100," (exist, but have %d fields instead " SIZEFMTD ") Wrong client version DBC file?",storage.GetFieldCount(),strlen(storage.GetFormat())); errlist.push_back(dbc_filename + buf); fclose(f); } diff --git a/src/game/GameEventMgr.cpp b/src/game/GameEventMgr.cpp index b3ebb8935..ff4e3b732 100644 --- a/src/game/GameEventMgr.cpp +++ b/src/game/GameEventMgr.cpp @@ -504,7 +504,7 @@ void GameEventMgr::GameEventSpawn(int16 event_id) if(internal_event_id < 0 || internal_event_id >= mGameEventCreatureGuids.size()) { - sLog.outError("GameEventMgr::GameEventSpawn attempt access to out of range mGameEventCreatureGuids element %i (size: %u)",internal_event_id,mGameEventCreatureGuids.size()); + sLog.outError("GameEventMgr::GameEventSpawn attempt access to out of range mGameEventCreatureGuids element %i (size: " SIZEFMTD ")",internal_event_id,mGameEventCreatureGuids.size()); return; } @@ -537,7 +537,7 @@ void GameEventMgr::GameEventSpawn(int16 event_id) if(internal_event_id < 0 || internal_event_id >= mGameEventGameobjectGuids.size()) { - sLog.outError("GameEventMgr::GameEventSpawn attempt access to out of range mGameEventGameobjectGuids element %i (size: %u)",internal_event_id,mGameEventGameobjectGuids.size()); + sLog.outError("GameEventMgr::GameEventSpawn attempt access to out of range mGameEventGameobjectGuids element %i (size: " SIZEFMTD ")",internal_event_id,mGameEventGameobjectGuids.size()); return; } @@ -571,7 +571,7 @@ void GameEventMgr::GameEventSpawn(int16 event_id) if(internal_event_id < 0 || internal_event_id >= mGameEventPoolIds.size()) { - sLog.outError("GameEventMgr::GameEventSpawn attempt access to out of range mGameEventPoolIds element %i (size: %u)",internal_event_id,mGameEventPoolIds.size()); + sLog.outError("GameEventMgr::GameEventSpawn attempt access to out of range mGameEventPoolIds element %i (size: " SIZEFMTD ")",internal_event_id,mGameEventPoolIds.size()); return; } @@ -587,7 +587,7 @@ void GameEventMgr::GameEventUnspawn(int16 event_id) if(internal_event_id < 0 || internal_event_id >= mGameEventCreatureGuids.size()) { - sLog.outError("GameEventMgr::GameEventUnspawn attempt access to out of range mGameEventCreatureGuids element %i (size: %u)",internal_event_id,mGameEventCreatureGuids.size()); + sLog.outError("GameEventMgr::GameEventUnspawn attempt access to out of range mGameEventCreatureGuids element %i (size: " SIZEFMTD ")",internal_event_id,mGameEventCreatureGuids.size()); return; } @@ -605,7 +605,7 @@ void GameEventMgr::GameEventUnspawn(int16 event_id) if(internal_event_id < 0 || internal_event_id >= mGameEventGameobjectGuids.size()) { - sLog.outError("GameEventMgr::GameEventUnspawn attempt access to out of range mGameEventGameobjectGuids element %i (size: %u)",internal_event_id,mGameEventGameobjectGuids.size()); + sLog.outError("GameEventMgr::GameEventUnspawn attempt access to out of range mGameEventGameobjectGuids element %i (size: " SIZEFMTD ")",internal_event_id,mGameEventGameobjectGuids.size()); return; } @@ -622,7 +622,7 @@ void GameEventMgr::GameEventUnspawn(int16 event_id) } if(internal_event_id < 0 || internal_event_id >= mGameEventPoolIds.size()) { - sLog.outError("GameEventMgr::GameEventUnspawn attempt access to out of range mGameEventPoolIds element %i (size: %u)",internal_event_id,mGameEventPoolIds.size()); + sLog.outError("GameEventMgr::GameEventUnspawn attempt access to out of range mGameEventPoolIds element %i (size: " SIZEFMTD ")",internal_event_id,mGameEventPoolIds.size()); return; } diff --git a/src/game/GameObject.cpp b/src/game/GameObject.cpp index cda2b5f3f..d2d1478cc 100644 --- a/src/game/GameObject.cpp +++ b/src/game/GameObject.cpp @@ -80,7 +80,7 @@ void GameObject::CleanupsBeforeDelete() owner->RemoveGameObject(this,false); else { - char * ownerType = "creature"; + const char * ownerType = "creature"; if(IS_PLAYER_GUID(owner_guid)) ownerType = "player"; else if(IS_PET_GUID(owner_guid)) diff --git a/src/game/GridDefines.h b/src/game/GridDefines.h index 6565e0e0f..6553bebf3 100644 --- a/src/game/GridDefines.h +++ b/src/game/GridDefines.h @@ -44,7 +44,7 @@ class Player; #define MAX_NUMBER_OF_CELLS 4 #define SIZE_OF_GRID_CELL (SIZE_OF_GRIDS/MAX_NUMBER_OF_CELLS) -#define CENTER_GRID_CELL_ID 128 +#define CENTER_GRID_CELL_ID (MAX_NUMBER_OF_CELLS*MAX_NUMBER_OF_GRIDS/2) #define CENTER_GRID_CELL_OFFSET (SIZE_OF_GRID_CELL/2) #define TOTAL_NUMBER_OF_CELLS_PER_MAP (MAX_NUMBER_OF_GRIDS*MAX_NUMBER_OF_CELLS) diff --git a/src/game/Guild.cpp b/src/game/Guild.cpp index ee6c164e8..504962e4c 100644 --- a/src/game/Guild.cpp +++ b/src/game/Guild.cpp @@ -281,7 +281,7 @@ bool Guild::LoadRanksFromDB(uint32 GuildId) std::string name = m_ranks[i].name; uint32 rights = m_ranks[i].rights; CharacterDatabase.escape_string(name); - CharacterDatabase.PExecute( "INSERT INTO guild_rank (guildid,rid,rname,rights) VALUES ('%u', '%u', '%s', '%u')", GuildId, i+1, name.c_str(), rights); + CharacterDatabase.PExecute( "INSERT INTO guild_rank (guildid,rid,rname,rights) VALUES ('%u', '%u', '%s', '%u')", GuildId, uint32(i+1), name.c_str(), rights); } CharacterDatabase.CommitTransaction(); } @@ -1991,4 +1991,4 @@ bool GuildItemPosCount::isContainedIn(GuildItemPosCountVec const &vec) const return true; return false; -} +} \ No newline at end of file diff --git a/src/game/Mail.cpp b/src/game/Mail.cpp index 72c42825e..139302047 100644 --- a/src/game/Mail.cpp +++ b/src/game/Mail.cpp @@ -29,6 +29,15 @@ #include "Language.h" #include "DBCStores.h" +enum MailShowFlags +{ + MAIL_SHOW_UNK0 = 0x0001, + MAIL_SHOW_DELETE = 0x0002, // forced show delete button instead return button + MAIL_SHOW_AUCTION = 0x0004, // from old comment + MAIL_SHOW_COD = 0x0008, // show subject prefix + MAIL_SHOW_UNK4 = 0x0010, +}; + void MailItem::deleteItem( bool inDB ) { if(item) @@ -601,6 +610,14 @@ void WorldSession::HandleGetMailList(WorldPacket & recv_data ) if(data.wpos()+next_mail_size > maxPacketSize) break; + uint32 show_flags = 0; + if ((*itr)->messageType != MAIL_NORMAL) + show_flags |= MAIL_SHOW_DELETE; + if ((*itr)->messageType == MAIL_AUCTION) + show_flags |= MAIL_SHOW_AUCTION; + if ((*itr)->COD) + show_flags |= MAIL_SHOW_COD; + data << (uint16) 0x0040; // unknown 2.3.0, different values data << (uint32) (*itr)->messageID; // Message ID data << (uint8) (*itr)->messageType; // Message Type @@ -624,7 +641,7 @@ void WorldSession::HandleGetMailList(WorldPacket & recv_data ) data << (uint32) 0; // unknown data << (uint32) (*itr)->stationery; // stationery (Stationery.dbc) data << (uint32) (*itr)->money; // Gold - data << (uint32) 0x04; // unknown, 0x4 - auction, 0x10 - normal + data << (uint32) show_flags; // unknown, 0x4 - auction, 0x10 - normal // Time data << (float) ((*itr)->expire_time-time(NULL))/DAY; data << (uint32) (*itr)->mailTemplateId; // mail template (MailTemplate.dbc) diff --git a/src/game/MovementHandler.cpp b/src/game/MovementHandler.cpp index 3cbbe0e78..7e80aa8e4 100644 --- a/src/game/MovementHandler.cpp +++ b/src/game/MovementHandler.cpp @@ -227,7 +227,7 @@ void WorldSession::HandleMovementOpcodes( WorldPacket & recv_data ) if(recv_data.size() != recv_data.rpos()) { - sLog.outError("MovementHandler: player %s (guid %d, account %u) sent a packet (opcode %u) that is %u bytes larger than it should be. Kicked as cheater.", _player->GetName(), _player->GetGUIDLow(), _player->GetSession()->GetAccountId(), recv_data.GetOpcode(), recv_data.size() - recv_data.rpos()); + sLog.outError("MovementHandler: player %s (guid %d, account %u) sent a packet (opcode %u) that is " SIZEFMTD " bytes larger than it should be. Kicked as cheater.", _player->GetName(), _player->GetGUIDLow(), _player->GetSession()->GetAccountId(), recv_data.GetOpcode(), recv_data.size() - recv_data.rpos()); KickPlayer(); return; } diff --git a/src/game/ObjectMgr.h b/src/game/ObjectMgr.h index 7aeac8405..0887f457f 100644 --- a/src/game/ObjectMgr.h +++ b/src/game/ObjectMgr.h @@ -572,6 +572,7 @@ class ObjectMgr uint32 GeneratePetNumber(); uint32 CreateItemText(std::string text); + void AddItemText(uint32 itemTextId, std::string text) { mItemTexts[itemTextId] = text; } std::string GetItemText( uint32 id ) { ItemTextMap::const_iterator itr = mItemTexts.find( id ); diff --git a/src/game/Player.cpp b/src/game/Player.cpp index 3b3015ad6..c962deca1 100644 --- a/src/game/Player.cpp +++ b/src/game/Player.cpp @@ -1496,7 +1496,7 @@ bool Player::BuildEnumData( QueryResult * result, WorldPacket * p_data ) uint32 enchants = GetUInt32ValueFromArray(data, visualbase + 1); for(uint8 enchantSlot = PERM_ENCHANTMENT_SLOT; enchantSlot <= TEMP_ENCHANTMENT_SLOT; ++enchantSlot) { - if(enchant = sSpellItemEnchantmentStore.LookupEntry(enchantSlot >> enchantSlot*16)) + if(enchant = sSpellItemEnchantmentStore.LookupEntry(enchants >> enchantSlot*16)) break; } @@ -6667,7 +6667,8 @@ void Player::_ApplyItemBonuses(ItemPrototype const *proto, uint8 slot, bool appl } // Add armor bonus from ArmorDamageModifier if > 0 if (proto->ArmorDamageModifier > 0) - armor+=proto->ArmorDamageModifier; + armor += uint32(proto->ArmorDamageModifier); + if (armor) HandleStatModifier(UNIT_MOD_ARMOR, BASE_VALUE, float(armor), apply); diff --git a/src/game/PlayerDump.cpp b/src/game/PlayerDump.cpp index 5319ac8d7..1ea056260 100644 --- a/src/game/PlayerDump.cpp +++ b/src/game/PlayerDump.cpp @@ -302,19 +302,19 @@ void PlayerDumpWriter::DumpTable(std::string& dump, uint32 guid, char const*tabl // collect guids switch ( type ) { - case DTT_INVENTORY: - StoreGUID(result,3,items); break; // item guid collection - case DTT_ITEM: - StoreGUID(result,0,ITEM_FIELD_ITEM_TEXT_ID,texts); break; - // item text id collection - case DTT_PET: - StoreGUID(result,0,pets); break; // pet guid collection - case DTT_MAIL: - StoreGUID(result,0,mails); // mail id collection - StoreGUID(result,6,texts); break; // item text id collection - case DTT_MAIL_ITEM: - StoreGUID(result,1,items); break; // item guid collection - default: break; + case DTT_INVENTORY: + StoreGUID(result,3,items); break; // item guid collection + case DTT_ITEM: + StoreGUID(result,0,ITEM_FIELD_ITEM_TEXT_ID,texts); break; + // item text id collection + case DTT_PET: + StoreGUID(result,0,pets); break; // pet guid collection + case DTT_MAIL: + StoreGUID(result,0,mails); // mail id collection + StoreGUID(result,7,texts); break; // item text id collection + case DTT_MAIL_ITEM: + StoreGUID(result,1,items); break; // item guid collection + default: break; } dump += CreateDumpString(tableTo, result); @@ -452,6 +452,7 @@ DumpReturn PlayerDumpReader::LoadDump(const std::string& file, uint32 account, s std::map items; std::map mails; + std::map itemTexts; char buf[32000] = ""; typedef std::map PetIds; // old->new petid relation @@ -546,8 +547,8 @@ DumpReturn PlayerDumpReader::LoadDump(const std::string& file, uint32 account, s if (result) { delete result; - // rename on login: `at_login` field 30 in raw field list - if(!changenth(line, 30, "1")) + + if(!changenth(line, 37, "1")) // rename on login: `at_login` field 37 in raw field list ROLLBACK(DUMP_FILE_BROKEN); } } @@ -580,6 +581,8 @@ DumpReturn PlayerDumpReader::LoadDump(const std::string& file, uint32 account, s ROLLBACK(DUMP_FILE_BROKEN); if(!changetoknth(vals, ITEM_FIELD_OWNER+1, newguid)) ROLLBACK(DUMP_FILE_BROKEN); + if(!changetokGuid(vals, ITEM_FIELD_ITEM_TEXT_ID+1, itemTexts, objmgr.m_ItemTextId)) + ROLLBACK(DUMP_FILE_BROKEN); if(!changenth(line, 3, vals.c_str())) ROLLBACK(DUMP_FILE_BROKEN); break; @@ -637,10 +640,12 @@ DumpReturn PlayerDumpReader::LoadDump(const std::string& file, uint32 account, s } case DTT_MAIL: // mail { - // id,messageType,stationery,sender,receiver + // id,messageType,stationery,mailtemplate,sender,receiver,subject,itemText if(!changeGuid(line, 1, mails, objmgr.m_mailid)) ROLLBACK(DUMP_FILE_BROKEN); - if(!changenth(line, 5, newguid)) + if(!changenth(line, 6, newguid)) + ROLLBACK(DUMP_FILE_BROKEN); + if(!changeGuid(line, 8, itemTexts, objmgr.m_ItemTextId)) ROLLBACK(DUMP_FILE_BROKEN); break; } @@ -655,6 +660,18 @@ DumpReturn PlayerDumpReader::LoadDump(const std::string& file, uint32 account, s ROLLBACK(DUMP_FILE_BROKEN); break; } + case DTT_ITEM_TEXT: // item_text + { + // id + if(!changeGuid(line, 1, itemTexts, objmgr.m_ItemTextId)) + ROLLBACK(DUMP_FILE_BROKEN); + + // add it to cache + uint32 id= atoi(getnth(line,1).c_str()); + std::string text = getnth(line,2); + objmgr.AddItemText(id,text); + break; + } default: sLog.outError("Unknown dump table type: %u",type); break; @@ -668,6 +685,7 @@ DumpReturn PlayerDumpReader::LoadDump(const std::string& file, uint32 account, s objmgr.m_hiItemGuid += items.size(); objmgr.m_mailid += mails.size(); + objmgr.m_ItemTextId += itemTexts.size(); if(incHighest) ++objmgr.m_hiCharGuid; diff --git a/src/game/TemporarySummon.h b/src/game/TemporarySummon.h index 002e2da0c..28a9192f0 100644 --- a/src/game/TemporarySummon.h +++ b/src/game/TemporarySummon.h @@ -29,7 +29,7 @@ class TemporarySummon : public Creature virtual ~TemporarySummon(){}; void Update(uint32 time); void Summon(TempSummonType type, uint32 lifetime); - void UnSummon(); + void MANGOS_DLL_SPEC UnSummon(); void SaveToDB(); Unit* GetSummoner() const { return m_summoner ? ObjectAccessor::GetUnit(*this, m_summoner) : NULL; } private: diff --git a/src/game/Unit.cpp b/src/game/Unit.cpp index dd106c5fc..06ac3d8fb 100644 --- a/src/game/Unit.cpp +++ b/src/game/Unit.cpp @@ -5408,7 +5408,7 @@ bool Unit::HandleDummyAuraProc(Unit *pVictim, uint32 damage, Aura* triggeredByAu if (dummySpell->SpellFamilyFlags & UI64LIT(0x4000000000000)) { uint32 maxmana = GetMaxPower(POWER_MANA); - basepoints0 = maxmana* GetAttackTime(RANGED_ATTACK)/1000.0f/100.0f; + basepoints0 = int32(maxmana* GetAttackTime(RANGED_ATTACK)/1000.0f/100.0f); target = this; triggered_spell_id = 34075; diff --git a/src/game/WorldSession.cpp b/src/game/WorldSession.cpp index 89f6bb895..2a5d35b2b 100644 --- a/src/game/WorldSession.cpp +++ b/src/game/WorldSession.cpp @@ -78,7 +78,7 @@ WorldSession::~WorldSession() void WorldSession::SizeError(WorldPacket const& packet, uint32 size) const { - sLog.outError("Client (account %u) send packet %s (%u) with size %u but expected %u (attempt crash server?), skipped", + sLog.outError("Client (account %u) send packet %s (%u) with size " SIZEFMTD " but expected %u (attempt crash server?), skipped", GetAccountId(),LookupOpcodeName(packet.GetOpcode()),packet.GetOpcode(),packet.size(),size); } diff --git a/src/game/debugcmds.cpp b/src/game/debugcmds.cpp index feaa83651..3d12375d1 100644 --- a/src/game/debugcmds.cpp +++ b/src/game/debugcmds.cpp @@ -555,13 +555,13 @@ bool ChatHandler::HandleDebugGetItemState(const char* args) if (item->GetOwnerGUID() != player->GetGUID()) { - PSendSysMessage("queue(%d): for the an item (guid %d), the owner's guid (%d) and player's guid (%d) don't match!", i, item->GetGUIDLow(), GUID_LOPART(item->GetOwnerGUID()), player->GetGUIDLow()); + PSendSysMessage("queue(" SIZEFMTD "): for the an item (guid %d), the owner's guid (%d) and player's guid (%d) don't match!", i, item->GetGUIDLow(), GUID_LOPART(item->GetOwnerGUID()), player->GetGUIDLow()); error = true; continue; } if (item->GetQueuePos() != i) { - PSendSysMessage("queue(%d): for the an item (guid %d), the queuepos doesn't match it's position in the queue!", i, item->GetGUIDLow()); + PSendSysMessage("queue(" SIZEFMTD "): for the an item (guid %d), the queuepos doesn't match it's position in the queue!", i, item->GetGUIDLow()); error = true; continue; } @@ -570,13 +570,13 @@ bool ChatHandler::HandleDebugGetItemState(const char* args) if (test == NULL) { - PSendSysMessage("queue(%d): the bag(%d) and slot(%d) values for the item with guid %d are incorrect, the player doesn't have an item at that position!", i, item->GetBagSlot(), item->GetSlot(), item->GetGUIDLow()); + PSendSysMessage("queue(" SIZEFMTD "): the bag(%d) and slot(%d) values for the item with guid %d are incorrect, the player doesn't have an item at that position!", i, item->GetBagSlot(), item->GetSlot(), item->GetGUIDLow()); error = true; continue; } if (test != item) { - PSendSysMessage("queue(%d): the bag(%d) and slot(%d) values for the item with guid %d are incorrect, the item with guid %d is there instead!", i, item->GetBagSlot(), item->GetSlot(), item->GetGUIDLow(), test->GetGUIDLow()); + PSendSysMessage("queue(" SIZEFMTD "): the bag(%d) and slot(%d) values for the item with guid %d are incorrect, the item with guid %d is there instead!", i, item->GetBagSlot(), item->GetSlot(), item->GetGUIDLow(), test->GetGUIDLow()); error = true; continue; } } diff --git a/src/shared/Common.h b/src/shared/Common.h index 4edd6e7f8..2296b3864 100644 --- a/src/shared/Common.h +++ b/src/shared/Common.h @@ -146,6 +146,8 @@ #define SI64FMTD ACE_INT64_FORMAT_SPECIFIER #define SI64LIT(N) ACE_INT64_LITERAL(N) +#define SIZEFMTD ACE_SIZE_T_FORMAT_SPECIFIER + inline float finiteAlways(float f) { return finite(f) ? f : 0.0f; } #define atol(a) strtoul( a, NULL, 10) diff --git a/src/shared/ProgressBar.cpp b/src/shared/ProgressBar.cpp index b66890129..65fb65e42 100644 --- a/src/shared/ProgressBar.cpp +++ b/src/shared/ProgressBar.cpp @@ -16,6 +16,8 @@ * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA */ +#include + #include "ProgressBar.h" char const* const barGoLink::empty = " "; diff --git a/src/shared/ProgressBar.h b/src/shared/ProgressBar.h index f889ee0fd..aaffcf9f7 100644 --- a/src/shared/ProgressBar.h +++ b/src/shared/ProgressBar.h @@ -18,7 +18,6 @@ #ifndef MANGOSSERVER_PROGRESSBAR_H #define MANGOSSERVER_PROGRESSBAR_H -#include #include "Platform/Define.h" class MANGOS_DLL_SPEC barGoLink diff --git a/src/shared/revision_nr.h b/src/shared/revision_nr.h index ff2b133ff..138a0b067 100644 --- a/src/shared/revision_nr.h +++ b/src/shared/revision_nr.h @@ -1,4 +1,4 @@ #ifndef __REVISION_NR_H__ #define __REVISION_NR_H__ - #define REVISION_NR "8147" + #define REVISION_NR "8159" #endif // __REVISION_NR_H__ diff --git a/win/mangosdVC80.sln b/win/mangosdVC80.sln index 0814ffe8e..e6a220763 100644 --- a/win/mangosdVC80.sln +++ b/win/mangosdVC80.sln @@ -9,7 +9,6 @@ Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "shared", "VC80\shared.vcpro ProjectSection(ProjectDependencies) = postProject {BF6F5D0E-33A5-4E23-9E7D-DD481B7B5B9E} = {BF6F5D0E-33A5-4E23-9E7D-DD481B7B5B9E} {AD537C9A-FECA-1BAD-6757-8A6348EA12C8} = {AD537C9A-FECA-1BAD-6757-8A6348EA12C8} - {262199E8-EEDF-4700-A1D1-E9CC901CF480} = {262199E8-EEDF-4700-A1D1-E9CC901CF480} {8072769E-CF10-48BF-B9E1-12752A5DAC6E} = {8072769E-CF10-48BF-B9E1-12752A5DAC6E} {803F488E-4C5A-4866-8D5C-1E6C03C007C2} = {803F488E-4C5A-4866-8D5C-1E6C03C007C2} {8F1DEA42-6A5B-4B62-839D-C141A7BFACF2} = {8F1DEA42-6A5B-4B62-839D-C141A7BFACF2} @@ -92,18 +91,6 @@ Global {A3A04E47-43A2-4C08-90B3-029CEF558594}.Release|Win32.Build.0 = Release|Win32 {A3A04E47-43A2-4C08-90B3-029CEF558594}.Release|x64.ActiveCfg = Release|x64 {A3A04E47-43A2-4C08-90B3-029CEF558594}.Release|x64.Build.0 = Release|x64 - {262199E8-EEDF-4700-A1D1-E9CC901CF480}.Debug_NoPCH|Win32.ActiveCfg = Debug_NoPCH|Win32 - {262199E8-EEDF-4700-A1D1-E9CC901CF480}.Debug_NoPCH|Win32.Build.0 = Debug_NoPCH|Win32 - {262199E8-EEDF-4700-A1D1-E9CC901CF480}.Debug_NoPCH|x64.ActiveCfg = Debug_NoPCH|x64 - {262199E8-EEDF-4700-A1D1-E9CC901CF480}.Debug_NoPCH|x64.Build.0 = Debug_NoPCH|x64 - {262199E8-EEDF-4700-A1D1-E9CC901CF480}.Debug|Win32.ActiveCfg = Debug|Win32 - {262199E8-EEDF-4700-A1D1-E9CC901CF480}.Debug|Win32.Build.0 = Debug|Win32 - {262199E8-EEDF-4700-A1D1-E9CC901CF480}.Debug|x64.ActiveCfg = Debug|x64 - {262199E8-EEDF-4700-A1D1-E9CC901CF480}.Debug|x64.Build.0 = Debug|x64 - {262199E8-EEDF-4700-A1D1-E9CC901CF480}.Release|Win32.ActiveCfg = Release|Win32 - {262199E8-EEDF-4700-A1D1-E9CC901CF480}.Release|Win32.Build.0 = Release|Win32 - {262199E8-EEDF-4700-A1D1-E9CC901CF480}.Release|x64.ActiveCfg = Release|x64 - {262199E8-EEDF-4700-A1D1-E9CC901CF480}.Release|x64.Build.0 = Release|x64 {8F1DEA42-6A5B-4B62-839D-C141A7BFACF2}.Debug_NoPCH|Win32.ActiveCfg = Debug_NoPCH|Win32 {8F1DEA42-6A5B-4B62-839D-C141A7BFACF2}.Debug_NoPCH|Win32.Build.0 = Debug_NoPCH|Win32 {8F1DEA42-6A5B-4B62-839D-C141A7BFACF2}.Debug_NoPCH|x64.ActiveCfg = Debug_NoPCH|x64 diff --git a/win/mangosdVC90.sln b/win/mangosdVC90.sln index 400b92635..266b2100d 100644 --- a/win/mangosdVC90.sln +++ b/win/mangosdVC90.sln @@ -12,7 +12,6 @@ Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "shared", "VC90\shared.vcpro {803F488E-4C5A-4866-8D5C-1E6C03C007C2} = {803F488E-4C5A-4866-8D5C-1E6C03C007C2} {BD537C9A-FECA-1BAD-6757-8A6348EA12C8} = {BD537C9A-FECA-1BAD-6757-8A6348EA12C8} {8072769E-CF10-48BF-B9E1-12752A5DAC6E} = {8072769E-CF10-48BF-B9E1-12752A5DAC6E} - {262199E8-EEDF-4700-A1D1-E9CC901CF480} = {262199E8-EEDF-4700-A1D1-E9CC901CF480} EndProjectSection EndProject Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "mangosd", "VC90\mangosd.vcproj", "{A3A04E47-43A2-4C08-90B3-029CEF558594}" @@ -92,18 +91,6 @@ Global {A3A04E47-43A2-4C08-90B3-029CEF558594}.Release|Win32.Build.0 = Release|Win32 {A3A04E47-43A2-4C08-90B3-029CEF558594}.Release|x64.ActiveCfg = Release|x64 {A3A04E47-43A2-4C08-90B3-029CEF558594}.Release|x64.Build.0 = Release|x64 - {262199E8-EEDF-4700-A1D1-E9CC901CF480}.Debug_NoPCH|Win32.ActiveCfg = Debug_NoPCH|Win32 - {262199E8-EEDF-4700-A1D1-E9CC901CF480}.Debug_NoPCH|Win32.Build.0 = Debug_NoPCH|Win32 - {262199E8-EEDF-4700-A1D1-E9CC901CF480}.Debug_NoPCH|x64.ActiveCfg = Debug_NoPCH|x64 - {262199E8-EEDF-4700-A1D1-E9CC901CF480}.Debug_NoPCH|x64.Build.0 = Debug_NoPCH|x64 - {262199E8-EEDF-4700-A1D1-E9CC901CF480}.Debug|Win32.ActiveCfg = Debug|Win32 - {262199E8-EEDF-4700-A1D1-E9CC901CF480}.Debug|Win32.Build.0 = Debug|Win32 - {262199E8-EEDF-4700-A1D1-E9CC901CF480}.Debug|x64.ActiveCfg = Debug|x64 - {262199E8-EEDF-4700-A1D1-E9CC901CF480}.Debug|x64.Build.0 = Debug|x64 - {262199E8-EEDF-4700-A1D1-E9CC901CF480}.Release|Win32.ActiveCfg = Release|Win32 - {262199E8-EEDF-4700-A1D1-E9CC901CF480}.Release|Win32.Build.0 = Release|Win32 - {262199E8-EEDF-4700-A1D1-E9CC901CF480}.Release|x64.ActiveCfg = Release|x64 - {262199E8-EEDF-4700-A1D1-E9CC901CF480}.Release|x64.Build.0 = Release|x64 {8F1DEA42-6A5B-4B62-839D-C141A7BFACF2}.Debug_NoPCH|Win32.ActiveCfg = Debug_NoPCH|Win32 {8F1DEA42-6A5B-4B62-839D-C141A7BFACF2}.Debug_NoPCH|Win32.Build.0 = Debug_NoPCH|Win32 {8F1DEA42-6A5B-4B62-839D-C141A7BFACF2}.Debug_NoPCH|x64.ActiveCfg = Debug_NoPCH|x64