Import pvpstats sql and fix previous updates with ALTER TABLE

Please test
This commit is contained in:
Yehonal
2016-08-08 13:00:17 +02:00
parent 83c9046ae3
commit e54bfb31e4
4 changed files with 44 additions and 3 deletions

View File

@@ -0,0 +1,35 @@
ALTER TABLE characters_db_version CHANGE COLUMN 2016_07_30_00 2016_08_08_00 bit;
CREATE TABLE IF NOT EXISTS `battleground_deserters` (
`guid` INT(10) UNSIGNED NOT NULL COMMENT 'characters.guid',
`type` TINYINT(3) UNSIGNED NOT NULL COMMENT 'type of the desertion',
`datetime` DATETIME NOT NULL COMMENT 'datetime of the desertion'
);
CREATE TABLE IF NOT EXISTS `pvpstats_battlegrounds` (
`id` bigint(20) unsigned NOT NULL AUTO_INCREMENT,
`winner_faction` tinyint(4) NOT NULL,
`bracket_id` tinyint(3) unsigned NOT NULL,
`type` tinyint(3) unsigned NOT NULL,
`date` datetime NOT NULL,
PRIMARY KEY (`id`)
) ENGINE=InnoDB AUTO_INCREMENT=8298 DEFAULT CHARSET=latin1;
CREATE TABLE IF NOT EXISTS `pvpstats_players` (
`battleground_id` bigint(20) unsigned NOT NULL,
`character_guid` int(10) unsigned NOT NULL,
`winner` bit(1) NOT NULL,
`score_killing_blows` mediumint(8) unsigned NOT NULL,
`score_deaths` mediumint(8) unsigned NOT NULL,
`score_honorable_kills` mediumint(8) unsigned NOT NULL,
`score_bonus_honor` mediumint(8) unsigned NOT NULL,
`score_damage_done` mediumint(8) unsigned NOT NULL,
`score_healing_done` mediumint(8) unsigned NOT NULL,
`attr_1` mediumint(8) unsigned NOT NULL DEFAULT '0',
`attr_2` mediumint(8) unsigned NOT NULL DEFAULT '0',
`attr_3` mediumint(8) unsigned NOT NULL DEFAULT '0',
`attr_4` mediumint(8) unsigned NOT NULL DEFAULT '0',
`attr_5` mediumint(8) unsigned NOT NULL DEFAULT '0',
PRIMARY KEY (`battleground_id`,`character_guid`)
) ENGINE=InnoDB DEFAULT CHARSET=latin1;

View File

@@ -1,3 +1,5 @@
ALTER TABLE world_db_version CHANGE COLUMN 2016_07_14_00 2016_07_28_00 bit;
-- loot for mindless servant 26536 in utgarde pinnacle
DELETE FROM `creature_loot_template` WHERE (Entry = 26536);
INSERT INTO `creature_loot_template` (`Entry`, `Item`, `ChanceOrQuestChance`, `LootMode`, `GroupId`, `mincountOrRef`, `maxcount`) VALUES
@@ -12,4 +14,4 @@ INSERT INTO `creature_loot_template` (`Entry`, `Item`, `ChanceOrQuestChance`, `L
(26536, 37068, 0.69, 1, 1, 1, 1),
(26536, 37069, 0.69, 1, 1, 1, 1),
(26536, 37070, 0.69, 1, 1, 1, 1),
(26536, 45912, 0.1, 1, 1, 1, 1);
(26536, 45912, 0.1, 1, 1, 1, 1);

View File

@@ -1,3 +1,5 @@
ALTER TABLE world_db_version CHANGE COLUMN 2016_07_28_00 2016_08_01_00 bit;
UPDATE creature_template SET faction = 14 WHERE faction != 35 and entry in (
35572,35569,35571,35570,35617,34705,34702,34701,34657,34703,35329,35328,35331,35330,
35332,35314,35326,35325,35323,35327,35119,35518,34928,35517,35309,35305,35307,35451,35004,35005,35545,35564,33628,36085,36090,36084,35517,35490,36089,35518,36091,36087,36086,36083,36082,36088,35310,35308,35546,35568,35306);
35332,35314,35326,35325,35323,35327,35119,35518,34928,35517,35309,35305,35307,35451,35004,35005,35545,35564,33628,36085,36090,36084,35517,35490,36089,35518,36091,36087,36086,36083,36082,36088,35310,35308,35546,35568,35306);

View File

@@ -1 +1,3 @@
DELETE from spell_area where spell = 60815 and area = 14;
ALTER TABLE world_db_version CHANGE COLUMN 2016_08_01_00 2016_08_03_00 bit;
DELETE from spell_area where spell = 60815 and area = 14;