mirror of
https://github.com/mod-playerbots/azerothcore-wotlk.git
synced 2026-02-15 08:16:08 +00:00
chore(DB/SQL): Correct file to comply with standards (#14953)
This commit is contained in:
@@ -9,13 +9,13 @@ Table structure for table `pet_name_generation_locale` */
|
||||
|
||||
DROP TABLE IF EXISTS `pet_name_generation_locale`;
|
||||
CREATE TABLE `pet_name_generation_locale` (
|
||||
`id` mediumint(8) unsigned NOT NULL AUTO_INCREMENT,
|
||||
`locale` varchar(4) NOT NULL,
|
||||
`word` tinytext NOT NULL,
|
||||
`entry` mediumint(8) unsigned NOT NULL DEFAULT '0',
|
||||
`half` tinyint(3) unsigned NOT NULL DEFAULT '0',
|
||||
`ID` mediumint unsigned NOT NULL,
|
||||
`Locale` varchar(4) NOT NULL,
|
||||
`Word` tinytext NOT NULL,
|
||||
`Entry` mediumint unsigned NOT NULL DEFAULT '0',
|
||||
`Half` tinyint unsigned NOT NULL DEFAULT '0',
|
||||
PRIMARY KEY (`ID`,`locale`)
|
||||
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 ROW_FORMAT=COMPACT;
|
||||
);
|
||||
|
||||
INSERT INTO `pet_name_generation_locale` (`id`, `locale`, `word`, `entry`, `half`) VALUES (261, 'esES', 'piedras', 26125, 1),
|
||||
(262, 'esES', 'rocas', 26125, 1),
|
||||
@@ -123,4 +123,3 @@ INSERT INTO `pet_name_generation_locale` (`id`, `locale`, `word`, `entry`, `half
|
||||
(311, 'esMX', 'Captura', 26125, 0),
|
||||
(312, 'esMX', 'Bebe', 26125, 0),
|
||||
(313, 'esMX', 'Rebana', 26125, 0);
|
||||
|
||||
|
||||
@@ -453,7 +453,7 @@ void ObjectMgr::LoadPetNamesLocales()
|
||||
uint32 oldMSTime = getMSTime();
|
||||
|
||||
// 0 1 2 3
|
||||
QueryResult result = WorldDatabase.Query("SELECT locale, word, entry, half FROM pet_name_generation_locale");
|
||||
QueryResult result = WorldDatabase.Query("SELECT Locale, Word, Entry, Half FROM pet_name_generation_locale");
|
||||
|
||||
if (!result)
|
||||
{
|
||||
@@ -474,9 +474,13 @@ void ObjectMgr::LoadPetNamesLocales()
|
||||
bool half = fields[3].Get<bool>();
|
||||
std::pair<uint32, LocaleConstant> pairkey = std::make_pair(entry, locale);
|
||||
if (half)
|
||||
{
|
||||
_petHalfLocaleName1[pairkey].push_back(word);
|
||||
}
|
||||
else
|
||||
{
|
||||
_petHalfLocaleName0[pairkey].push_back(word);
|
||||
}
|
||||
++count;
|
||||
} while (result->NextRow());
|
||||
|
||||
|
||||
Reference in New Issue
Block a user