This repository has been archived by the owner on Jul 27, 2020. It is now read-only.
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
* Updated the remaining headers, and updated sturcture.(see docs) * Updated Preample Readme so copyright info for GPL is uptodate. DB: Cleaned up SQL(dir) abit of organization never hurts anyone ;)
- Loading branch information
Aptiva
authored and
Aptiva
committed
Jan 17, 2012
1 parent
10d114b
commit afe4dec
Showing
532 changed files
with
7,869 additions
and
6,037 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
28 changes: 14 additions & 14 deletions
28
...updates/1208_01_realmd_account_access.sql → ...es/auth/1208_01_realmd_account_access.sql
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,14 +1,14 @@ | ||
-- Table structure for `account_access` | ||
DROP TABLE IF EXISTS `account_access`; | ||
CREATE TABLE `account_access` ( | ||
`id` int(11) unsigned NOT NULL, | ||
`gmlevel` tinyint(3) unsigned NOT NULL, | ||
`RealmID` int(11) NOT NULL default '-1', | ||
PRIMARY KEY (`id`,`RealmID`) | ||
) ENGINE=InnoDB DEFAULT CHARSET=utf8 ROW_FORMAT=DYNAMIC; | ||
-- export current gm account to the new table | ||
-- RealmID -1 = all realms | ||
INSERT INTO `account_access` (id, gmlevel, RealmID) | ||
SELECT `id`, `gmlevel`, -1 FROM `account` WHERE `gmlevel` > 0; | ||
-- Remove the gmlevel field from account | ||
ALTER TABLE account DROP COLUMN `gmlevel`; | ||
-- Table structure for `account_access` | ||
DROP TABLE IF EXISTS `account_access`; | ||
CREATE TABLE `account_access` ( | ||
`id` int(11) unsigned NOT NULL, | ||
`gmlevel` tinyint(3) unsigned NOT NULL, | ||
`RealmID` int(11) NOT NULL default '-1', | ||
PRIMARY KEY (`id`,`RealmID`) | ||
) ENGINE=InnoDB DEFAULT CHARSET=utf8 ROW_FORMAT=DYNAMIC; | ||
-- export current gm account to the new table | ||
-- RealmID -1 = all realms | ||
INSERT INTO `account_access` (id, gmlevel, RealmID) | ||
SELECT `id`, `gmlevel`, -1 FROM `account` WHERE `gmlevel` > 0; | ||
-- Remove the gmlevel field from account | ||
ALTER TABLE account DROP COLUMN `gmlevel`; |
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,11 @@ | ||
DROP TABLE IF EXISTS `gm_surveys`; | ||
CREATE TABLE `gm_surveys` ( | ||
`surveyid` int(10) NOT NULL auto_increment, | ||
`AppropriateAnswer` tinyint(3) UNSIGNED NOT NULL DEFAULT '0' COMMENT 'Did the GM provide an appropriate answer or solution to your question/problem?', | ||
`Understandability` tinyint(3) UNSIGNED NOT NULL DEFAULT '0' COMMENT 'How easy was it to understand and/or follow the information provided?', | ||
`GMRating` tinyint(3) UNSIGNED NOT NULL DEFAULT '0' COMMENT 'Was the GM knowledgeable, respectful and empathetic during your interactions?', | ||
`ResponseTime` tinyint(3) UNSIGNED NOT NULL DEFAULT '0' COMMENT 'How would you rate the response time to address your petition?', | ||
`OverallGMExperience` tinyint(3) UNSIGNED NOT NULL DEFAULT '0' COMMENT 'How would you rate the overall experience with the GM that assisted you with your petition?', | ||
`comment` longtext, | ||
PRIMARY KEY (`surveyid`) | ||
) ENGINE=InnoDB DEFAULT CHARSET=utf8 ROW_FORMAT=DYNAMIC COMMENT='Player System'; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
ALTER TABLE `gm_tickets` ADD COLUMN `escalated` int(11) NOT NULL DEFAULT '0' AFTER `comment`; | ||
ALTER TABLE `gm_tickets` ADD COLUMN `viewed` int(11) NOT NULL DEFAULT '0' AFTER `escalated`; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
ALTER TABLE `characters` | ||
ADD COLUMN `deleteInfos_Account` int(11) UNSIGNED default NULL AFTER arena_pending_points, | ||
ADD COLUMN `deleteInfos_Name` varchar(12) default NULL AFTER deleteInfos_Account, | ||
ADD COLUMN `deleteDate` bigint(20) default NULL AFTER deleteInfos_Name; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,54 @@ | ||
ALTER TABLE characters | ||
ADD COLUMN `arenaPoints` int(10) UNSIGNED NOT NULL default '0' AFTER arena_pending_points, | ||
ADD COLUMN `totalHonorPoints` int(10) UNSIGNED NOT NULL default '0' AFTER arenaPoints, | ||
ADD COLUMN `todayHonorPoints` int(10) UNSIGNED NOT NULL default '0' AFTER totalHonorPoints, | ||
ADD COLUMN `yesterdayHonorPoints` int(10) UNSIGNED NOT NULL default '0' AFTER todayHonorPoints, | ||
ADD COLUMN `totalKills` int(10) UNSIGNED NOT NULL default '0' AFTER yesterdayHonorPoints, | ||
ADD COLUMN `todayKills` smallint(5) UNSIGNED NOT NULL default '0' AFTER totalKills, | ||
ADD COLUMN `yesterdayKills` smallint(5) UNSIGNED NOT NULL default '0' AFTER todayKills, | ||
ADD COLUMN `chosenTitle` int(10) UNSIGNED NOT NULL default '0' AFTER yesterdayKills, | ||
ADD COLUMN `watchedFaction` int(10) UNSIGNED NOT NULL default '0' AFTER chosenTitle, | ||
ADD COLUMN `drunk` smallint(5) UNSIGNED NOT NULL default '0' AFTER watchedFaction, | ||
ADD COLUMN `health` int(10) UNSIGNED NOT NULL default '0' AFTER drunk, | ||
ADD COLUMN `powerMana` int(10) UNSIGNED NOT NULL default '0' AFTER health, | ||
ADD COLUMN `powerRage` int(10) UNSIGNED NOT NULL default '0' AFTER powerMana, | ||
ADD COLUMN `powerFocus` int(10) UNSIGNED NOT NULL default '0' AFTER powerRage, | ||
ADD COLUMN `powerEnergy` int(10) UNSIGNED NOT NULL default '0' AFTER powerFocus, | ||
ADD COLUMN `powerHappiness` int(10) UNSIGNED NOT NULL default '0' AFTER powerEnergy; | ||
|
||
UPDATE IGNORE characters SET | ||
arenaPoints = arena_pending_points + | ||
SUBSTRING(data, length(SUBSTRING_INDEX(data, ' ', 1563))+2, length(SUBSTRING_INDEX(data, ' ', 1563+1))- length(SUBSTRING_INDEX(data, ' ', 1563)) - 1), | ||
totalHonorPoints = | ||
SUBSTRING(data, length(SUBSTRING_INDEX(data, ' ', 1562))+2, length(SUBSTRING_INDEX(data, ' ', 1562+1))- length(SUBSTRING_INDEX(data, ' ', 1562)) - 1), | ||
todayHonorPoints = | ||
SUBSTRING(data, length(SUBSTRING_INDEX(data, ' ', 1515))+2, length(SUBSTRING_INDEX(data, ' ', 1515+1))- length(SUBSTRING_INDEX(data, ' ', 1515)) - 1), | ||
yesterdayHonorPoints = | ||
SUBSTRING(data, length(SUBSTRING_INDEX(data, ' ', 1516))+2, length(SUBSTRING_INDEX(data, ' ', 1516+1))- length(SUBSTRING_INDEX(data, ' ', 1516)) - 1), | ||
totalKills = | ||
SUBSTRING(data, length(SUBSTRING_INDEX(data, ' ', 1517))+2, length(SUBSTRING_INDEX(data, ' ', 1517+1))- length(SUBSTRING_INDEX(data, ' ', 1517)) - 1), | ||
todayKills = | ||
SUBSTRING(data, length(SUBSTRING_INDEX(data, ' ', 1514))+2, length(SUBSTRING_INDEX(data, ' ', 1514+1))- length(SUBSTRING_INDEX(data, ' ', 1514)) - 1) & 0x0000FFFF, | ||
yesterdayKills = | ||
(SUBSTRING(data, length(SUBSTRING_INDEX(data, ' ', 1514))+2, length(SUBSTRING_INDEX(data, ' ', 1514+1))- length(SUBSTRING_INDEX(data, ' ', 1514)) - 1) & 0xFFFF0000) >> 16, | ||
chosenTitle = | ||
SUBSTRING(data, length(SUBSTRING_INDEX(data, ' ', 648))+2, length(SUBSTRING_INDEX(data, ' ', 648+1))- length(SUBSTRING_INDEX(data, ' ', 648)) - 1), | ||
watchedFaction = | ||
SUBSTRING(data, length(SUBSTRING_INDEX(data, ' ', 1519))+2, length(SUBSTRING_INDEX(data, ' ', 1519+1))- length(SUBSTRING_INDEX(data, ' ', 1519)) - 1), | ||
drunk = | ||
SUBSTRING(data, length(SUBSTRING_INDEX(data, ' ', 241))+2, length(SUBSTRING_INDEX(data, ' ', 241+1))- length(SUBSTRING_INDEX(data, ' ', 241)) - 1) & 0xFFFE, | ||
health = | ||
SUBSTRING(data, length(SUBSTRING_INDEX(data, ' ', 22))+2, length(SUBSTRING_INDEX(data, ' ', 22+1))- length(SUBSTRING_INDEX(data, ' ', 22)) - 1), | ||
powerMana = | ||
SUBSTRING(data, length(SUBSTRING_INDEX(data, ' ', 23))+2, length(SUBSTRING_INDEX(data, ' ', 23+1))- length(SUBSTRING_INDEX(data, ' ', 23)) - 1), | ||
powerRage = | ||
SUBSTRING(data, length(SUBSTRING_INDEX(data, ' ', 24))+2, length(SUBSTRING_INDEX(data, ' ', 24+1))- length(SUBSTRING_INDEX(data, ' ', 24)) - 1), | ||
powerFocus = | ||
SUBSTRING(data, length(SUBSTRING_INDEX(data, ' ', 25))+2, length(SUBSTRING_INDEX(data, ' ', 25+1))- length(SUBSTRING_INDEX(data, ' ', 25)) - 1), | ||
powerEnergy = | ||
SUBSTRING(data, length(SUBSTRING_INDEX(data, ' ', 26))+2, length(SUBSTRING_INDEX(data, ' ', 26+1))- length(SUBSTRING_INDEX(data, ' ', 26)) - 1), | ||
powerHappiness = | ||
SUBSTRING(data, length(SUBSTRING_INDEX(data, ' ', 27))+2, length(SUBSTRING_INDEX(data, ' ', 27+1))- length(SUBSTRING_INDEX(data, ' ', 27)) - 1); | ||
|
||
ALTER TABLE characters | ||
DROP COLUMN arena_pending_points; |
46 changes: 46 additions & 0 deletions
46
sql/updates/characters/1479_characters_character_skills.sql
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,46 @@ | ||
DROP TABLE IF EXISTS `character_skills`; | ||
CREATE TABLE `character_skills` ( | ||
`guid` int(11) unsigned NOT NULL COMMENT 'Global Unique Identifier', | ||
`skill` mediumint(9) unsigned NOT NULL, | ||
`value` int(11) unsigned NOT NULL, | ||
`max` mediumint(9) unsigned NOT NULL, | ||
i mediumint(9), | ||
PRIMARY KEY (`guid`,`skill`,`i`) | ||
) ENGINE=InnoDB DEFAULT CHARSET=utf8 ROW_FORMAT=DYNAMIC COMMENT='Player System'; | ||
|
||
DROP TABLE IF EXISTS temp_skills; | ||
CREATE TABLE temp_skills ( | ||
i int(11) unsigned NOT NULL, | ||
PRIMARY KEY (i) | ||
); | ||
INSERT INTO temp_skills VALUES | ||
( 0),( 1),( 2),( 3),( 4),( 5),( 6),( 7),( 8),( 9),(10),(11),(12),(13),(14),(15),(16),(17),(18),(19), | ||
(20),(21),(22),(23),(24),(25),(26),(27),(28),(29),(30),(31),(32),(33),(34),(35),(36),(37),(38),(39), | ||
(40),(41),(42),(43),(44),(45),(46),(47),(48),(49),(50),(51),(52),(53),(54),(55),(56),(57),(58),(59), | ||
(60),(61),(62),(63),(64),(65),(66),(67),(68),(69),(70),(71),(72),(73),(74),(75),(76),(77),(78),(79), | ||
(80),(81),(82),(83),(84),(85),(86),(87),(88),(89),(90),(91),(92),(93),(94),(95),(96),(97),(98),(99), | ||
(100),(101),(102),(103),(104),(105),(106),(107),(108),(109),(110),(111),(112),(113),(114),(115),(116),(117),(118),(119), | ||
(120),(121),(122),(123),(124),(125),(126),(127); | ||
|
||
INSERT INTO character_skills SELECT | ||
guid, | ||
((SUBSTRING(data, length(SUBSTRING_INDEX(data, ' ', 928+3*i))+2, length(SUBSTRING_INDEX(data, ' ', 928+3*i+1))- length(SUBSTRING_INDEX(data, ' ', 928+3*i)) - 1)) & 0xFFFF) as skill, | ||
(SUBSTRING(data, length(SUBSTRING_INDEX(data, ' ', 928+3*i+1))+2, length(SUBSTRING_INDEX(data, ' ', 928+3*i+2))- length(SUBSTRING_INDEX(data, ' ', 928+3*i+1)) - 1)) as value, | ||
(0) as max, | ||
i | ||
FROM characters, temp_skills; | ||
|
||
DELETE FROM character_skills WHERE skill = 0; | ||
DROP TABLE IF EXISTS temp_skills; | ||
|
||
UPDATE character_skills | ||
SET max = ((value & 0xFFFF0000) >> 16); | ||
|
||
UPDATE character_skills | ||
SET value = (value & 0xFFFF); | ||
|
||
ALTER IGNORE TABLE character_skills | ||
CHANGE COLUMN value value mediumint(9) unsigned NOT NULL, | ||
DROP PRIMARY KEY, | ||
ADD PRIMARY KEY (guid,skill), | ||
DROP COLUMN i; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,39 @@ | ||
ALTER TABLE `corpse` | ||
ADD COLUMN `displayId` int(10) unsigned NOT NULL default '0' AFTER `map`, | ||
ADD COLUMN `itemCache` text NOT NULL AFTER `displayId`, | ||
ADD COLUMN `bytes1` int(10) unsigned NOT NULL default '0' AFTER `itemCache`, | ||
ADD COLUMN `bytes2` int(10) unsigned NOT NULL default '0' AFTER `bytes1`, | ||
ADD COLUMN `guild` int(10) unsigned NOT NULL default '0' AFTER `bytes2`, | ||
ADD COLUMN `flags` int(10) unsigned NOT NULL default '0' AFTER `guild`, | ||
ADD COLUMN `dynFlags` int(10) unsigned NOT NULL default '0' AFTER `flags`; | ||
|
||
UPDATE `corpse` SET | ||
`displayId` = SUBSTRING(`data`, | ||
length(SUBSTRING_INDEX(`data`,' ',10))+2, | ||
length(SUBSTRING_INDEX(`data`,' ',10+1))-length(SUBSTRING_INDEX(data,' ',10))-1), | ||
|
||
`itemCache` = SUBSTRING(`data`, | ||
length(SUBSTRING_INDEX(`data`,' ',11))+2, | ||
length(SUBSTRING_INDEX(`data`,' ',29+1))-length(SUBSTRING_INDEX(data,' ',11))-1), | ||
|
||
`bytes1` = SUBSTRING(`data`, | ||
length(SUBSTRING_INDEX(`data`,' ',30))+2, | ||
length(SUBSTRING_INDEX(`data`,' ',30+1))-length(SUBSTRING_INDEX(data,' ',30))-1), | ||
|
||
`bytes2` = SUBSTRING(`data`, | ||
length(SUBSTRING_INDEX(`data`,' ',31))+2, | ||
length(SUBSTRING_INDEX(`data`,' ',31+1))-length(SUBSTRING_INDEX(data,' ',31))-1), | ||
|
||
`guild` = SUBSTRING(`data`, | ||
length(SUBSTRING_INDEX(`data`,' ',32))+2, | ||
length(SUBSTRING_INDEX(`data`,' ',32+1))-length(SUBSTRING_INDEX(data,' ',32))-1), | ||
|
||
`flags` = SUBSTRING(`data`, | ||
length(SUBSTRING_INDEX(`data`,' ',33))+2, | ||
length(SUBSTRING_INDEX(`data`,' ',33+1))-length(SUBSTRING_INDEX(data,' ',33))-1), | ||
|
||
`dynFlags` = SUBSTRING(`data`, | ||
length(SUBSTRING_INDEX(`data`,' ',34))+2, | ||
length(SUBSTRING_INDEX(`data`,' ',34+1))-length(SUBSTRING_INDEX(data,' ',34))-1); | ||
|
||
ALTER TABLE `corpse` DROP `data`; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
ALTER TABLE `characters` ADD COLUMN `instance_id` int(11) unsigned NOT NULL default '0' AFTER `map`; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
ALTER TABLE characters ADD gender TINYINT UNSIGNED NOT NULL default '0' AFTER class; | ||
ALTER TABLE characters ADD level TINYINT UNSIGNED NOT NULL default '0' AFTER gender; | ||
ALTER TABLE characters ADD xp INT UNSIGNED NOT NULL default '0' AFTER level; | ||
ALTER TABLE characters ADD money INT UNSIGNED NOT NULL default '0' AFTER xp; | ||
ALTER TABLE characters ADD playerBytes INT UNSIGNED NOT NULL default '0' AFTER money; | ||
ALTER TABLE characters ADD playerBytes2 INT UNSIGNED NOT NULL default '0' AFTER playerBytes; | ||
ALTER TABLE characters ADD playerFlags INT UNSIGNED NOT NULL default '0' AFTER playerBytes2; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,9 @@ | ||
UPDATE characters SET | ||
gender = (CAST(SUBSTRING_INDEX(SUBSTRING_INDEX(data, ' ', 37), ' ', -1) AS UNSIGNED) & 0xFF0000) >> 16, | ||
level = CAST(SUBSTRING_INDEX(SUBSTRING_INDEX(data, ' ', 35), ' ', -1) AS UNSIGNED), | ||
xp = CAST(SUBSTRING_INDEX(SUBSTRING_INDEX(data, ' ', 927), ' ', -1) AS UNSIGNED), | ||
money = CAST(SUBSTRING_INDEX(SUBSTRING_INDEX(data, ' ', 1462), ' ', -1) AS UNSIGNED), | ||
playerBytes = CAST(SUBSTRING_INDEX(SUBSTRING_INDEX(data, ' ', 240), ' ', -1) AS UNSIGNED), | ||
playerBytes2 = CAST(SUBSTRING_INDEX(SUBSTRING_INDEX(data, ' ', 241), ' ', -1) AS UNSIGNED), | ||
playerFlags = CAST(SUBSTRING_INDEX(SUBSTRING_INDEX(data, ' ', 237), ' ', -1) AS UNSIGNED) | ||
WHERE LENGTH(SUBSTRING_INDEX(data, ' ', 1592)) < LENGTH(data) && LENGTH(data) <= LENGTH(SUBSTRING_INDEX(data, ' ', 1593)); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
ALTER TABLE character_spell DROP slot; | ||
ALTER TABLE pet_spell DROP slot; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
DROP TABLE IF EXISTS `cheaters`; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
ALTER TABLE `pet_aura` DROP PRIMARY KEY; | ||
ALTER TABLE `pet_aura` ADD PRIMARY KEY (`guid`,`caster_guid`,`spell`,`effect_index`); | ||
|
||
ALTER TABLE `character_aura` DROP PRIMARY KEY; | ||
ALTER TABLE `character_aura` ADD PRIMARY KEY (`guid`,`caster_guid`,`spell`,`effect_index`); |
Oops, something went wrong.