aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--sql/updates/hotfixes/cata_classic/2024_06_02_00_hotfixes.sql121
-rw-r--r--src/server/database/Database/Implementation/HotfixDatabase.cpp16
-rw-r--r--src/server/database/Database/Implementation/HotfixDatabase.h10
-rw-r--r--src/server/game/DataStores/DB2LoadInfo.h46
-rw-r--r--src/server/game/DataStores/DB2Stores.cpp6
-rw-r--r--src/server/game/DataStores/DB2Stores.h3
-rw-r--r--src/server/game/DataStores/DB2Structure.h30
7 files changed, 232 insertions, 0 deletions
diff --git a/sql/updates/hotfixes/cata_classic/2024_06_02_00_hotfixes.sql b/sql/updates/hotfixes/cata_classic/2024_06_02_00_hotfixes.sql
new file mode 100644
index 00000000000..a807547b9d8
--- /dev/null
+++ b/sql/updates/hotfixes/cata_classic/2024_06_02_00_hotfixes.sql
@@ -0,0 +1,121 @@
+--
+-- Table structure for table `talent_tab`
+--
+
+DROP TABLE IF EXISTS `talent_tab`;
+/*!40101 SET @saved_cs_client = @@character_set_client */;
+/*!50503 SET character_set_client = utf8mb4 */;
+CREATE TABLE `talent_tab` (
+ `ID` int(10) unsigned NOT NULL DEFAULT '0',
+ `Name` text,
+ `BackgroundFile` text,
+ `Description` text,
+ `OrderIndex` int(11) NOT NULL DEFAULT '0',
+ `RaceMask` int(11) NOT NULL DEFAULT '0',
+ `ClassMask` int(11) NOT NULL DEFAULT '0',
+ `CategoryEnumID` int(11) NOT NULL DEFAULT '0',
+ `SpellIconID` int(11) NOT NULL DEFAULT '0',
+ `RoleMask` int(11) NOT NULL DEFAULT '0',
+ `MasterySpellID1` int(11) NOT NULL DEFAULT '0',
+ `MasterySpellID2` int(11) NOT NULL DEFAULT '0',
+ `VerifiedBuild` int(11) NOT NULL DEFAULT '0',
+ PRIMARY KEY (`ID`,`VerifiedBuild`)
+) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci;
+/*!40101 SET character_set_client = @saved_cs_client */;
+
+--
+-- Dumping data for table `talent_tab`
+--
+
+LOCK TABLES `talent_tab` WRITE;
+/*!40000 ALTER TABLE `talent_tab` DISABLE KEYS */;
+/*!40000 ALTER TABLE `talent_tab` ENABLE KEYS */;
+UNLOCK TABLES;
+
+--
+-- Table structure for table `talent_tab_locale`
+--
+
+DROP TABLE IF EXISTS `talent_tab_locale`;
+/*!40101 SET @saved_cs_client = @@character_set_client */;
+/*!50503 SET character_set_client = utf8mb4 */;
+CREATE TABLE `talent_tab_locale` (
+ `ID` int(10) unsigned NOT NULL DEFAULT '0',
+ `locale` varchar(4) NOT NULL,
+ `Name_lang` text,
+ `Description_lang` text,
+ `VerifiedBuild` int(11) NOT NULL DEFAULT '0',
+ PRIMARY KEY (`ID`,`locale`,`VerifiedBuild`)
+) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci
+/*!50500 PARTITION BY LIST COLUMNS(locale)
+(PARTITION deDE VALUES IN ('deDE') ENGINE = InnoDB,
+ PARTITION esES VALUES IN ('esES') ENGINE = InnoDB,
+ PARTITION esMX VALUES IN ('esMX') ENGINE = InnoDB,
+ PARTITION frFR VALUES IN ('frFR') ENGINE = InnoDB,
+ PARTITION itIT VALUES IN ('itIT') ENGINE = InnoDB,
+ PARTITION koKR VALUES IN ('koKR') ENGINE = InnoDB,
+ PARTITION ptBR VALUES IN ('ptBR') ENGINE = InnoDB,
+ PARTITION ruRU VALUES IN ('ruRU') ENGINE = InnoDB,
+ PARTITION zhCN VALUES IN ('zhCN') ENGINE = InnoDB,
+ PARTITION zhTW VALUES IN ('zhTW') ENGINE = InnoDB) */;
+/*!40101 SET character_set_client = @saved_cs_client */;
+
+--
+-- Dumping data for table `talent_tab_locale`
+--
+
+LOCK TABLES `talent_tab_locale` WRITE;
+/*!40000 ALTER TABLE `talent_tab_locale` DISABLE KEYS */;
+/*!40000 ALTER TABLE `talent_tab_locale` ENABLE KEYS */;
+UNLOCK TABLES;
+
+--
+-- Table structure for table `talent_tree_primary_spells`
+--
+
+DROP TABLE IF EXISTS `talent_tree_primary_spells`;
+/*!40101 SET @saved_cs_client = @@character_set_client */;
+/*!50503 SET character_set_client = utf8mb4 */;
+CREATE TABLE `talent_tree_primary_spells` (
+ `ID` int(10) unsigned NOT NULL DEFAULT '0',
+ `TalentTabID` int(11) NOT NULL DEFAULT '0',
+ `SpellID` int(11) NOT NULL DEFAULT '0',
+ `Flags` int(11) NOT NULL DEFAULT '0',
+ `VerifiedBuild` int(11) NOT NULL DEFAULT '0',
+ PRIMARY KEY (`ID`,`VerifiedBuild`)
+) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci;
+/*!40101 SET character_set_client = @saved_cs_client */;
+
+--
+-- Dumping data for table `talent_tree_primary_spells`
+--
+
+LOCK TABLES `talent_tree_primary_spells` WRITE;
+/*!40000 ALTER TABLE `talent_tree_primary_spells` DISABLE KEYS */;
+/*!40000 ALTER TABLE `talent_tree_primary_spells` ENABLE KEYS */;
+UNLOCK TABLES;
+
+--
+-- Table structure for table `glyph_slot`
+--
+
+DROP TABLE IF EXISTS `glyph_slot`;
+/*!40101 SET @saved_cs_client = @@character_set_client */;
+/*!50503 SET character_set_client = utf8mb4 */;
+CREATE TABLE `glyph_slot` (
+ `ID` int(10) unsigned NOT NULL DEFAULT '0',
+ `Tooltip` int(11) NOT NULL DEFAULT '0',
+ `Type` int(10) unsigned NOT NULL DEFAULT '0',
+ `VerifiedBuild` int(11) NOT NULL DEFAULT '0',
+ PRIMARY KEY (`ID`,`VerifiedBuild`)
+) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci;
+/*!40101 SET character_set_client = @saved_cs_client */;
+
+--
+-- Dumping data for table `glyph_slot`
+--
+
+LOCK TABLES `glyph_slot` WRITE;
+/*!40000 ALTER TABLE `glyph_slot` DISABLE KEYS */;
+/*!40000 ALTER TABLE `glyph_slot` ENABLE KEYS */;
+UNLOCK TABLES;
diff --git a/src/server/database/Database/Implementation/HotfixDatabase.cpp b/src/server/database/Database/Implementation/HotfixDatabase.cpp
index 7547ce06034..5d12b9a8a73 100644
--- a/src/server/database/Database/Implementation/HotfixDatabase.cpp
+++ b/src/server/database/Database/Implementation/HotfixDatabase.cpp
@@ -708,6 +708,10 @@ void HotfixDatabaseConnection::DoPrepareStatements()
PrepareStatement(HOTFIX_SEL_GLYPH_BINDABLE_SPELL, "SELECT ID, SpellID, GlyphPropertiesID FROM glyph_bindable_spell WHERE (`VerifiedBuild` > 0) = ?", CONNECTION_SYNCH);
PREPARE_MAX_ID_STMT(HOTFIX_SEL_GLYPH_BINDABLE_SPELL, "SELECT MAX(ID) + 1 FROM glyph_bindable_spell", CONNECTION_SYNCH);
+ // GlyphSlot.db2
+ PrepareStatement(HOTFIX_SEL_GLYPH_SLOT, "SELECT ID, Tooltip, Type FROM glyph_slot WHERE (`VerifiedBuild` > 0) = ?", CONNECTION_SYNCH);
+ PREPARE_MAX_ID_STMT(HOTFIX_SEL_GLYPH_SLOT, "SELECT MAX(ID) + 1 FROM glyph_slot", CONNECTION_SYNCH);
+
// GlyphProperties.db2
PrepareStatement(HOTFIX_SEL_GLYPH_PROPERTIES, "SELECT ID, SpellID, GlyphType, GlyphExclusiveCategoryID, SpellIconFileDataID, GlyphSlotFlags"
" FROM glyph_properties WHERE (`VerifiedBuild` > 0) = ?", CONNECTION_SYNCH);
@@ -1626,6 +1630,18 @@ void HotfixDatabaseConnection::DoPrepareStatements()
PREPARE_MAX_ID_STMT(HOTFIX_SEL_TALENT, "SELECT MAX(ID) + 1 FROM talent", CONNECTION_SYNCH);
PREPARE_LOCALE_STMT(HOTFIX_SEL_TALENT, "SELECT ID, Description_lang FROM talent_locale WHERE (`VerifiedBuild` > 0) = ? AND locale = ?", CONNECTION_SYNCH);
+ // TalentTab.db2
+ PrepareStatement(HOTFIX_SEL_TALENT_TAB, "SELECT ID, Name, BackgroundFile, Description, OrderIndex, RaceMask, ClassMask, CategoryEnumID, "
+ "SpellIconID, RoleMask, MasterySpellID1, MasterySpellID2 FROM talent_tab WHERE (`VerifiedBuild` > 0) = ?", CONNECTION_SYNCH);
+ PREPARE_MAX_ID_STMT(HOTFIX_SEL_TALENT_TAB, "SELECT MAX(ID) + 1 FROM talent_tab", CONNECTION_SYNCH);
+ PREPARE_LOCALE_STMT(HOTFIX_SEL_TALENT_TAB, "SELECT ID, Name_lang, Description_lang FROM talent_tab_locale WHERE (`VerifiedBuild` > 0) = ?"
+ " AND locale = ?", CONNECTION_SYNCH);
+
+ // TalentTreePrimarySpells.db2
+ PrepareStatement(HOTFIX_SEL_TALENT_TREE_PRIMARY_SPELLS, "SELECT ID, TalentTabID, SpellID, Flags FROM talent_tree_primary_spells"
+ " WHERE (`VerifiedBuild` > 0) = ?", CONNECTION_SYNCH);
+ PREPARE_MAX_ID_STMT(HOTFIX_SEL_TALENT_TREE_PRIMARY_SPELLS, "SELECT MAX(ID) + 1 FROM talent_tree_primary_spells", CONNECTION_SYNCH);
+
// TaxiNodes.db2
PrepareStatement(HOTFIX_SEL_TAXI_NODES, "SELECT Name, PosX, PosY, PosZ, MapOffsetX, MapOffsetY, FlightMapOffsetX, FlightMapOffsetY, ID, "
"ContinentID, ConditionID, CharacterBitNumber, Flags, UiTextureKitID, Facing, SpecialIconConditionID, VisibilityConditionID, "
diff --git a/src/server/database/Database/Implementation/HotfixDatabase.h b/src/server/database/Database/Implementation/HotfixDatabase.h
index a479832b0da..5b3487d6f2c 100644
--- a/src/server/database/Database/Implementation/HotfixDatabase.h
+++ b/src/server/database/Database/Implementation/HotfixDatabase.h
@@ -407,6 +407,9 @@ enum HotfixDatabaseStatements : uint32
HOTFIX_SEL_GLYPH_BINDABLE_SPELL,
HOTFIX_SEL_GLYPH_BINDABLE_SPELL_MAX_ID,
+ HOTFIX_SEL_GLYPH_SLOT,
+ HOTFIX_SEL_GLYPH_SLOT_MAX_ID,
+
HOTFIX_SEL_GLYPH_PROPERTIES,
HOTFIX_SEL_GLYPH_PROPERTIES_MAX_ID,
@@ -935,6 +938,13 @@ enum HotfixDatabaseStatements : uint32
HOTFIX_SEL_TALENT_MAX_ID,
HOTFIX_SEL_TALENT_LOCALE,
+ HOTFIX_SEL_TALENT_TAB,
+ HOTFIX_SEL_TALENT_TAB_MAX_ID,
+ HOTFIX_SEL_TALENT_TAB_LOCALE,
+
+ HOTFIX_SEL_TALENT_TREE_PRIMARY_SPELLS,
+ HOTFIX_SEL_TALENT_TREE_PRIMARY_SPELLS_MAX_ID,
+
HOTFIX_SEL_TAXI_NODES,
HOTFIX_SEL_TAXI_NODES_MAX_ID,
HOTFIX_SEL_TAXI_NODES_LOCALE,
diff --git a/src/server/game/DataStores/DB2LoadInfo.h b/src/server/game/DataStores/DB2LoadInfo.h
index a74b2880537..9f0a4f684ee 100644
--- a/src/server/game/DataStores/DB2LoadInfo.h
+++ b/src/server/game/DataStores/DB2LoadInfo.h
@@ -2180,6 +2180,18 @@ struct GlyphBindableSpellLoadInfo
static constexpr DB2LoadInfo Instance{ Fields, 3, &GlyphBindableSpellMeta::Instance, HOTFIX_SEL_GLYPH_BINDABLE_SPELL };
};
+struct GlyphSlotLoadInfo
+{
+ static constexpr DB2FieldMeta Fields[3] =
+ {
+ { false, FT_INT, "ID" },
+ { true, FT_INT, "Tooltip" },
+ { false, FT_INT, "Type" },
+ };
+
+ static constexpr DB2LoadInfo Instance{ Fields, 3, &GlyphSlotMeta::Instance, HOTFIX_SEL_GLYPH_SLOT };
+};
+
struct GlyphPropertiesLoadInfo
{
static constexpr DB2FieldMeta Fields[6] =
@@ -5433,6 +5445,40 @@ struct TalentLoadInfo
static constexpr DB2LoadInfo Instance{ Fields, 28, &TalentMeta::Instance, HOTFIX_SEL_TALENT };
};
+struct TalentTabLoadInfo
+{
+ static constexpr DB2FieldMeta Fields[12] =
+ {
+ { false, FT_INT, "ID" },
+ { false, FT_STRING, "Name" },
+ { false, FT_STRING_NOT_LOCALIZED, "BackgroundFile" },
+ { false, FT_STRING, "Description" },
+ { true, FT_INT, "OrderIndex" },
+ { true, FT_INT, "RaceMask" },
+ { true, FT_INT, "ClassMask" },
+ { true, FT_INT, "CategoryEnumID" },
+ { true, FT_INT, "SpellIconID" },
+ { true, FT_INT, "RoleMask" },
+ { true, FT_INT, "MasterySpellID1" },
+ { true, FT_INT, "MasterySpellID2" },
+ };
+
+ static constexpr DB2LoadInfo Instance{ Fields, 12, &TalentTabMeta::Instance, HOTFIX_SEL_TALENT_TAB };
+};
+
+struct TalentTreePrimarySpellsLoadInfo
+{
+ static constexpr DB2FieldMeta Fields[4] =
+ {
+ { false, FT_INT, "ID" },
+ { true, FT_INT, "TalentTabID" },
+ { true, FT_INT, "SpellID" },
+ { true, FT_INT, "Flags" },
+ };
+
+ static constexpr DB2LoadInfo Instance{ Fields, 4, &TalentTreePrimarySpellsMeta::Instance, HOTFIX_SEL_TALENT_TREE_PRIMARY_SPELLS };
+};
+
struct TaxiNodesLoadInfo
{
static constexpr DB2FieldMeta Fields[19] =
diff --git a/src/server/game/DataStores/DB2Stores.cpp b/src/server/game/DataStores/DB2Stores.cpp
index d97549502ab..2dcf5334799 100644
--- a/src/server/game/DataStores/DB2Stores.cpp
+++ b/src/server/game/DataStores/DB2Stores.cpp
@@ -152,6 +152,7 @@ DB2Storage<GarrSiteLevelPlotInstEntry> sGarrSiteLevelPlotInstStore("Gar
DB2Storage<GarrTalentTreeEntry> sGarrTalentTreeStore("GarrTalentTree.db2", &GarrTalentTreeLoadInfo::Instance);
DB2Storage<GemPropertiesEntry> sGemPropertiesStore("GemProperties.db2", &GemPropertiesLoadInfo::Instance);
DB2Storage<GlyphBindableSpellEntry> sGlyphBindableSpellStore("GlyphBindableSpell.db2", &GlyphBindableSpellLoadInfo::Instance);
+DB2Storage<GlyphSlotEntry> sGlyphSlotStore("GlyphSlot.db2", &GlyphSlotLoadInfo::Instance);
DB2Storage<GlyphPropertiesEntry> sGlyphPropertiesStore("GlyphProperties.db2", &GlyphPropertiesLoadInfo::Instance);
DB2Storage<GlyphRequiredSpecEntry> sGlyphRequiredSpecStore("GlyphRequiredSpec.db2", &GlyphRequiredSpecLoadInfo::Instance);
DB2Storage<GossipNPCOptionEntry> sGossipNPCOptionStore("GossipNPCOption.db2", &GossipNpcOptionLoadInfo::Instance);
@@ -315,6 +316,8 @@ DB2Storage<SpellXSpellVisualEntry> sSpellXSpellVisualStore("SpellXS
DB2Storage<SummonPropertiesEntry> sSummonPropertiesStore("SummonProperties.db2", &SummonPropertiesLoadInfo::Instance);
DB2Storage<TactKeyEntry> sTactKeyStore("TactKey.db2", &TactKeyLoadInfo::Instance);
DB2Storage<TalentEntry> sTalentStore("Talent.db2", &TalentLoadInfo::Instance);
+DB2Storage<TalentTabEntry> sTalentTabStore("TalentTab.db2", &TalentTabLoadInfo::Instance);
+DB2Storage<TalentTreePrimarySpellsEntry> sTalentTreePrimarySpellsStore("TalentTreePrimarySpells.db2", &TalentTreePrimarySpellsLoadInfo::Instance);
DB2Storage<TaxiNodesEntry> sTaxiNodesStore("TaxiNodes.db2", &TaxiNodesLoadInfo::Instance);
DB2Storage<TaxiPathEntry> sTaxiPathStore("TaxiPath.db2", &TaxiPathLoadInfo::Instance);
DB2Storage<TaxiPathNodeEntry> sTaxiPathNodeStore("TaxiPathNode.db2", &TaxiPathNodeLoadInfo::Instance);
@@ -732,6 +735,7 @@ uint32 DB2Manager::LoadStores(std::string const& dataPath, LocaleConstant defaul
LOAD_DB2(sGarrTalentTreeStore);
LOAD_DB2(sGemPropertiesStore);
LOAD_DB2(sGlyphBindableSpellStore);
+ LOAD_DB2(sGlyphSlotStore);
LOAD_DB2(sGlyphPropertiesStore);
LOAD_DB2(sGlyphRequiredSpecStore);
LOAD_DB2(sGossipNPCOptionStore);
@@ -895,6 +899,8 @@ uint32 DB2Manager::LoadStores(std::string const& dataPath, LocaleConstant defaul
LOAD_DB2(sSummonPropertiesStore);
LOAD_DB2(sTactKeyStore);
LOAD_DB2(sTalentStore);
+ LOAD_DB2(sTalentTabStore);
+ LOAD_DB2(sTalentTreePrimarySpellsStore);
LOAD_DB2(sTaxiNodesStore);
LOAD_DB2(sTaxiPathStore);
LOAD_DB2(sTaxiPathNodeStore);
diff --git a/src/server/game/DataStores/DB2Stores.h b/src/server/game/DataStores/DB2Stores.h
index 67f56064f54..704aa304cbb 100644
--- a/src/server/game/DataStores/DB2Stores.h
+++ b/src/server/game/DataStores/DB2Stores.h
@@ -122,6 +122,7 @@ TC_GAME_API extern DB2Storage<GarrSiteLevelEntry> sGarrSiteLev
TC_GAME_API extern DB2Storage<GarrSiteLevelPlotInstEntry> sGarrSiteLevelPlotInstStore;
TC_GAME_API extern DB2Storage<GarrTalentTreeEntry> sGarrTalentTreeStore;
TC_GAME_API extern DB2Storage<GemPropertiesEntry> sGemPropertiesStore;
+TC_GAME_API extern DB2Storage<GlyphSlotEntry> sGlyphSlotStore;
TC_GAME_API extern DB2Storage<GlyphPropertiesEntry> sGlyphPropertiesStore;
TC_GAME_API extern DB2Storage<GossipNPCOptionEntry> sGossipNPCOptionStore;
TC_GAME_API extern DB2Storage<GuildColorBackgroundEntry> sGuildColorBackgroundStore;
@@ -252,6 +253,8 @@ TC_GAME_API extern DB2Storage<SpellVisualKitEntry> sSpellVisual
TC_GAME_API extern DB2Storage<SpellXSpellVisualEntry> sSpellXSpellVisualStore;
TC_GAME_API extern DB2Storage<SummonPropertiesEntry> sSummonPropertiesStore;
TC_GAME_API extern DB2Storage<TalentEntry> sTalentStore;
+TC_GAME_API extern DB2Storage<TalentTabEntry> sTalentTabStore;
+TC_GAME_API extern DB2Storage<TalentTreePrimarySpellsEntry> sTalentTreePrimarySpellsStore;
TC_GAME_API extern DB2Storage<TaxiNodesEntry> sTaxiNodesStore;
TC_GAME_API extern DB2Storage<TaxiPathEntry> sTaxiPathStore;
TC_GAME_API extern DB2Storage<TaxiPathNodeEntry> sTaxiPathNodeStore;
diff --git a/src/server/game/DataStores/DB2Structure.h b/src/server/game/DataStores/DB2Structure.h
index 18fa184e3e7..81b2bc9f6b9 100644
--- a/src/server/game/DataStores/DB2Structure.h
+++ b/src/server/game/DataStores/DB2Structure.h
@@ -1838,6 +1838,13 @@ struct GlyphBindableSpellEntry
uint32 GlyphPropertiesID;
};
+struct GlyphSlotEntry
+{
+ uint32 ID;
+ int32 Tooltip;
+ uint32 Type;
+};
+
struct GlyphPropertiesEntry
{
uint32 ID;
@@ -3852,6 +3859,29 @@ struct TalentEntry
std::array<int32, 3> PrereqRank;
};
+struct TalentTabEntry
+{
+ uint32 ID;
+ LocalizedString Name;
+ char const* BackgroundFile;
+ LocalizedString Description;
+ int32 OrderIndex;
+ int32 RaceMask;
+ int32 ClassMask;
+ int32 CategoryEnumID;
+ int32 SpellIconID;
+ int32 RoleMask;
+ std::array<int32, 2> MasterySpellID;
+};
+
+struct TalentTreePrimarySpellsEntry
+{
+ uint32 ID;
+ int32 TalentTabID;
+ int32 SpellID;
+ int32 Flags;
+};
+
struct TaxiNodesEntry
{
LocalizedString Name;