8000 [pull] master from TrinityCore:master by pull[bot] · Pull Request #364 · Mu-L/TrinityCore · GitHub
[go: up one dir, main page]
More Web Proxy on the site http://driver.im/
Skip to content

[pull] master from TrinityCore:master #364

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Jun 27, 2025
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
52 changes: 51 additions & 1 deletion sql/base/auth_database.sql
Original file line number Diff line number Diff line change
Expand Up @@ -360,6 +360,55 @@ LOCK TABLES `battlenet_account_mounts` WRITE;
/*!40000 ALTER TABLE `battlenet_account_mounts` ENABLE KEYS */;
UNLOCK TABLES;

--
-- Table structure for table `battlenet_account_player_data_element`
--

DROP TABLE IF EXISTS `battlenet_account_player_data_element`;
/*!40101 SET @saved_cs_client = @@character_set_client */;
/*!50503 SET character_set_client = utf8mb4 */;
CREATE TABLE `battlenet_account_player_data_element` (
`battlenetAccountId` int unsigned NOT NULL,
`playerDataElementCharacterId` int unsigned NOT NULL,
`floatValue` float DEFAULT NULL,
`int64Value` bigint DEFAULT NULL,
PRIMARY KEY (`battlenetAccountId`,`playerDataElementCharacterId`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci;
/*!40101 SET character_set_client = @saved_cs_client */;

--
-- Dumping data for table `battlenet_account_player_data_element`
--

LOCK TABLES `battlenet_account_player_data_element` WRITE;
/*!40000 ALTER TABLE `battlenet_account_player_data_element` DISABLE KEYS */;
/*!40000 ALTER TABLE `battlenet_account_player_data_element` ENABLE KEYS */;
UNLOCK TABLES;

--
-- Table structure for table `battlenet_account_player_data_flag`
--

DROP TABLE IF EXISTS `battlenet_account_player_data_flag`;
/*!40101 SET @saved_cs_client = @@character_set_client */;
/*!50503 SET character_set_client = utf8mb4 */;
CREATE TABLE `battlenet_account_player_data_flag` (
`battlenetAccountId` int unsigned NOT NULL,
`storageIndex` int unsigned NOT NULL,
`mask` bigint unsigned NOT NULL,
PRIMARY KEY (`battlenetAccountId`,`storageIndex`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci;
/*!40101 SET character_set_client = @saved_cs_client */;

--
-- Dumping data for table `battlenet_account_player_data_flag`
--

LOCK TABLES `battlenet_account_player_data_flag` WRITE;
/*!40000 ALTER TABLE `battlenet_account_player_data_flag` DISABLE KEYS */;
/*!40000 ALTER TABLE `battlenet_account_player_data_flag` ENABLE KEYS */;
UNLOCK TABLES;

--
-- Table structure for table `battlenet_account_toys`
--
Expand Down Expand Up @@ -3658,7 +3707,8 @@ INSERT INTO `updates` VALUES
('2025_06_05_02_auth.sql','C2B67F688AC54CF6994F4709D0ECE692C968F346','RELEASED','2025-06-05 16:22:53',0),
('2025_06_18_00_auth.sql','AB5F6069BD37C93050022700F1C4B814D9D139C1','RELEASED','2025-06-17 23:13:05',0),
('2025_06_19_00_auth.sql','1C0ACAEEFC934F91F44C113E6CD9D7A40ED1C979','RELEASED','2025-06-18 22:51:15',0),
('2025_06_25_00_auth.sql','27DC7FB423FFB3788082CCFC18D5432650B09FB3','RELEASED','2025-06-25 01:15:04',0);
('2025_06_25_00_auth.sql','27DC7FB423FFB3788082CCFC18D5432650B09FB3','RELEASED','2025-06-25 01:15:04',0),
('2025_06_27_00_auth.sql','243C89DFED0058323EF9690D124C1F20036D461B','RELEASED','2025-06-27 14:22:49',0);
/*!40000 ALTER TABLE `updates` ENABLE KEYS */;
UNLOCK TABLES;

Expand Down
52 changes: 51 additions & 1 deletion sql/base/characters_database.sql
Original file line number Diff line number Diff line change
Expand Up @@ -1225,6 +1225,55 @@ LOCK TABLES `character_pet_declinedname` WRITE;
/*!40000 ALTER TABLE `character_pet_declinedname` ENABLE KEYS */;
UNLOCK TABLES;

--
-- Table structure for table `character_player_data_element`
--

DROP TABLE IF EXISTS `character_player_data_element`;
/*!40101 SET @saved_cs_client = @@character_set_client */;
/*!50503 SET character_set_client = utf8mb4 */;
CREATE TABLE `character_player_data_element` (
`characterGuid` bigint unsigned NOT NULL,
`playerDataElementCharacterId` int unsigned NOT NULL,
`floatValue` float DEFAULT NULL,
`int64Value` bigint DEFAULT NULL,
PRIMARY KEY (`characterGuid`,`playerDataElementCharacterId`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci;
/*!40101 SET character_set_client = @saved_cs_client */;

--
-- Dumping data for table `character_player_data_element`
--

LOCK TABLES `character_player_data_element` WRITE;
/*!40000 ALTER TABLE `character_player_data_element` DISABLE KEYS */;
/*!40000 ALTER TABLE `character_player_data_element` ENABLE KEYS */;
UNLOCK TABLES;

--
-- Table structure for table `character_player_data_flag`
--

DROP TABLE IF EXISTS `character_player_data_flag`;
/*!40101 SET @saved_cs_client = @@character_set_client */;
/*!50503 SET character_set_client = utf8mb4 */;
CREATE TABLE `character_player_data_flag` (
`characterGuid` bigint unsigned NOT NULL,
`storageIndex` int unsigned NOT NULL,
`mask` bigint unsigned NOT NULL,
PRIMARY KEY (`characterGuid`,`storageIndex`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci;
/*!40101 SET character_set_client = @saved_cs_client */;

--
-- Dumping data for table `character_player_data_flag`
--

LOCK TABLES `character_player_data_flag` WRITE;
/*!40000 ALTER TABLE `character_player_data_flag` DISABLE KEYS */;
/*!40000 ALTER TABLE `character_player_data_flag` ENABLE KEYS */;
UNLOCK TABLES;

--
-- Table structure for table `character_pvp_talent`
--
Expand Down Expand Up @@ -3781,7 +3830,8 @@ INSERT INTO `updates` VALUES
('2024_12_22_00_characters.sql','A2F24564430C5BCC96C279E843FA3548B1F831EE','ARCHIVED','2024-12-22 02:56:17',0),
('2025_01_04_00_characters.sql','403E8B642A67765A04A0A4D5BC0752288208079C','ARCHIVED','2025-01-04 16:31:39',0),
('2025_03_29_00_characters.sql','6A49C236D0B8CCD8A5B6B51F60E116B3380772D7','ARCHIVED','2025-03-29 01:12:13',0),
('2025_05_31_00_characters.sql','C240EB5C4008B6AA0514802A18D7DD875680DE82','ARCHIVED','2025-05-31 19:45:56',0);
('2025_05_31_00_characters.sql','C240EB5C4008B6AA0514802A18D7DD875680DE82','ARCHIVED','2025-05-31 19:45:56',0),
('2025_06_27_00_characters.sql','35088BA5BA4BD3B7FAAD6FD4FAE38E52A5B71CD8','RELEASED','2025-06-27 14:22:08',0);
/*!40000 ALTER TABLE `updates` ENABLE KEYS */;
UNLOCK TABLES;

Expand Down
22 changes: 22 additions & 0 deletions sql/updates/auth/master/2025_06_27_00_auth.sql
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
--
-- Table structure for table `battlenet_account_player_data_element`
--
DROP TABLE IF EXISTS `battlenet_account_player_data_element`;
CREATE TABLE `battlenet_account_player_data_element` (
`battlenetAccountId` int unsigned NOT NULL,
`playerDataElementAccountId` int unsigned NOT NULL,
`floatValue` float DEFAULT NULL,
`int64Value` bigint DEFAULT NULL,
PRIMARY KEY (`battlenetAccountId`,`playerDataElementAccountId`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci;

--
-- Table structure for table `battlenet_account_player_data_flag`
--
DROP TABLE IF EXISTS `battlenet_account_player_data_flag`;
CREATE TABLE `battlenet_account_player_data_flag` (
`battlenetAccountId` int unsigned NOT NULL,
`storageIndex` int unsigned NOT NULL,
`mask` bigint unsigned NOT NULL,
PRIMARY KEY (`battlenetAccountId`,`storageIndex`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci;
22 changes: 22 additions & 0 deletions sql/updates/characters/master/2025_06_27_00_characters.sql
9E88
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
--
-- Table structure for table `character_player_data_element`
--
DROP TABLE IF EXISTS `character_player_data_element`;
CREATE TABLE `character_player_data_element` (
`characterGuid` bigint unsigned NOT NULL,
`playerDataElementCharacterId` int unsigned NOT NULL,
`floatValue` float DEFAULT NULL,
`int64Value` bigint DEFAULT NULL,
PRIMARY KEY (`characterGuid`,`playerDataElementCharacterId`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci;

--
-- Table structure for table `character_player_data_flag`
--
DROP TABLE IF EXISTS `character_player_data_flag`;
CREATE TABLE `character_player_data_flag` (
`characterGuid` bigint unsigned NOT NULL,
`storageIndex` int unsigned NOT NULL,
`mask` bigint unsigned NOT NULL,
PRIMARY KEY (`characterGuid`,`storageIndex`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci;
47 changes: 47 additions & 0 deletions sql/updates/hotfixes/master/2025_06_27_00_hotfixes.sql
Original file line number Diff line number Diff line change
@@ -0,0 +1,47 @@
--
-- Table structure for table `player_data_element_account`
--
DROP TABLE IF EXISTS `player_data_element_account`;
CREATE TABLE `player_data_element_account` (
`ID` int unsigned NOT NULL DEFAULT '0',
`StorageIndex` int NOT NULL DEFAULT '0',
`Type` int NOT NULL DEFAULT '0',
`VerifiedBuild` int NOT NULL DEFAULT '0',
PRIMARY KEY (`ID`,`VerifiedBuild`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci;

--
-- Table structure for table `player_data_element_character`
--
DROP TABLE IF EXISTS `player_data_element_character`;
CREATE TABLE `player_data_element_character` (
`ID` int unsigned NOT NULL DEFAULT '0',
`StorageIndex` int NOT NULL DEFAULT '0',
`Type` int NOT NULL DEFAULT '0',
`VerifiedBuild` int NOT NULL DEFAULT '0',
PRIMARY KEY (`ID`,`VerifiedBuild`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci;

--
-- Table structure for table `player_data_flag_account`
--
DROP TABLE IF EXISTS `player_data_flag_account`;
CREATE TABLE `player_data_flag_account` (
`ID` int unsigned NOT NULL DEFAULT '0',
`StorageIndex` int NOT NULL DEFAULT '0',
`Unknown1107` int NOT NULL DEFAULT '0',
`VerifiedBuild` int NOT NULL DEFAULT '0',
PRIMARY KEY (`ID`,`VerifiedBuild`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci;

--
-- Table structure for table `player_data_flag_character`
--
DROP TABLE IF EXISTS `player_data_flag_character`;
CREATE TABLE `player_data_flag_character` (
`ID` int unsigned NOT NULL DEFAULT '0',
`StorageIndex` int NOT NULL DEFAULT '0',
`Unknown1107` int NOT NULL DEFAULT '0',
`VerifiedBuild` int NOT NULL DEFAULT '0',
PRIMARY KEY (`ID`,`VerifiedBuild`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci;
Original file line number Diff line number Diff line change
Expand Up @@ -796,6 +796,13 @@ void CharacterDatabaseConnection::DoPrepareStatements()
PrepareStatement(CHAR_UPD_CHARACTER_INSTANCE_LOCK_FORCE_EXPIRE, "UPDATE character_instance_lock SET expiryTime = ?, extended = 0 WHERE guid = ? AND mapId = ? AND lockId = ?", CONNECTION_ASYNC);
PrepareStatement(CHAR_DEL_INSTANCE, "DELETE FROM instance WHERE instanceId = ?", CONNECTION_ASYNC);
PrepareStatement(CHAR_INS_INSTANCE, "INSERT INTO instance (instanceId, data, completedEncountersMask, entranceWorldSafeLocId) VALUES (?, ?, ?, ?)", CONNECTION_ASYNC);

PrepareStatement(CHAR_SEL_PLAYER_DATA_ELEMENTS_CHARACTER, "SELECT playerDataElementCharacterId, floatValue, int64Value FROM character_player_data_element WHERE characterGuid = ?", CONNECTION_ASYNC);
PrepareStatement(CHAR_DEL_PLAYER_DATA_ELEMENTS_CHARACTER, "DELETE FROM character_player_data_element WHERE characterGuid = ? AND playerDataElementCharacterId = ?", CONNECTION_ASYNC);
PrepareStatement(CHAR_INS_PLAYER_DATA_ELEMENTS_CHARACTER, "INSERT INTO character_player_data_element (characterGuid, playerDataElementCharacterId, floatValue, int64Value) VALUES (?, ?, ?, ?)", CONNECTION_ASYNC);
PrepareStatement(CHAR_SEL_PLAYER_DATA_FLAGS_CHARACTER, "SELECT storageIndex, mask FROM character_player_data_flag WHERE characterGuid = ?", CONNECTION_ASYNC);
PrepareStatement(CHAR_DEL_PLAYER_DATA_FLAGS_CHARACTER, "DELETE FROM character_player_data_flag WHERE characterGuid = ? AND storageIndex = ?", CONNECTION_ASYNC);
PrepareStatement(CHAR_INS_PLAYER_DATA_FLAGS_CHARACTER, "INSERT INTO character_player_data_flag (characterGuid, storageIndex, mask) VALUES (?, ?, ?)", CONNECTION_ASYNC);
}

CharacterDatabaseConnection::CharacterDatabaseConnection(MySQLConnectionInfo& connInfo, ConnectionFlags connectionFlags) : MySQLConnection(connInfo, connectionFlags)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -650,6 +650,13 @@ enum CharacterDatabaseStatements : uint32
CHAR_DEL_INSTANCE,
CHAR_INS_INSTANCE,

CHAR_SEL_PLAYER_DATA_ELEMENTS_CHARACTER,
CHAR_DEL_PLAYER_DATA_ELEMENTS_CHARACTER,
CHAR_INS_PLAYER_DATA_ELEMENTS_CHARACTER,
CHAR_SEL_PLAYER_DATA_FLAGS_CHARACTER,
CHAR_DEL_PLAYER_DATA_FLAGS_CHARACTER,
CHAR_INS_PLAYER_DATA_FLAGS_CHARACTER,

MAX_CHARACTERDATABASE_STATEMENTS
};

Expand Down
20 changes: 20 additions & 0 deletions src/server/database/Database/Implementation/HotfixDatabase.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -1320,6 +1320,26 @@ void HotfixDatabaseConnection::DoPrepareStatements()
PREPARE_LOCALE_STMT(HOTFIX_SEL_PLAYER_CONDITION, "SELECT ID, FailureDescription_lang FROM player_condition_locale WHERE (`VerifiedBuild` > 0) = ?"
" AND locale = ?", CONNECTION_SYNCH);

// PlayerDataElementAccount.db2
PrepareStatement(HOTFIX_SEL_PLAYER_DATA_ELEMENT_ACCOUNT, "SELECT ID, StorageIndex, Type FROM player_data_element_account"
" WHERE (`VerifiedBuild` > 0) = ?", CONNECTION_SYNCH);
PREPARE_MAX_ID_STMT(HOTFIX_SEL_PLAYER_DATA_ELEMENT_ACCOUNT, "SELECT MAX(ID) + 1 FROM player_data_element_account", CONNECTION_SYNCH);

// PlayerDataElementCharacter.db2
PrepareStatement(HOTFIX_SEL_PLAYER_DATA_ELEMENT_CHARACTER, "SELECT ID, StorageIndex, Type FROM player_data_element_character"
" WHERE (`VerifiedBuild` > 0) = ?", CONNECTION_SYNCH);
PREPARE_MAX_ID_STMT(HOTFIX_SEL_PLAYER_DATA_ELEMENT_CHARACTER, "SELECT MAX(ID) + 1 FROM player_data_element_character", CONNECTION_SYNCH);

// PlayerDataFlagAccount.db2
PrepareStatement(HOTFIX_SEL_PLAYER_DATA_FLAG_ACCOUNT, "SELECT ID, StorageIndex, Unknown1107 FROM player_data_flag_account"
" WHERE (`VerifiedBuild` > 0) = ?", CONNECTION_SYNCH);
PREPARE_MAX_ID_STMT(HOTFIX_SEL_PLAYER_DATA_FLAG_ACCOUNT, "SELECT MAX(ID) + 1 FROM player_data_flag_account", CONNECTION_SYNCH);

// PlayerDataFlagCharacter.db2
PrepareStatement(HOTFIX_SEL_PLAYER_DATA_FLAG_CHARACTER, "SELECT ID, StorageIndex, Unknown1107 FROM player_data_flag_character"
" WHERE (`VerifiedBuild` > 0) = ?", CONNECTION_SYNCH);
PREPARE_MAX_ID_STMT(HOTFIX_SEL_PLAYER_DATA_FLAG_CHARACTER, "SELECT MAX(ID) + 1 FROM player_data_flag_character", CONNECTION_SYNCH);

// PowerDisplay.db2
PrepareStatement(HOTFIX_SEL_POWER_DISPLAY, "SELECT ID, GlobalStringBaseTag, ActualType, Red, Green, Blue FROM power_display"
" WHERE (`VerifiedBuild` > 0) = ?", CONNECTION_SYNCH);
Expand Down
12 changes: 12 additions & 0 deletions src/server/database/Database/Implementation/HotfixDatabase.h
Original file line number Diff line number Diff line change
Expand Up @@ -756,6 +756,18 @@ enum HotfixDatabaseStatements : uint32
HOTFIX_SEL_PLAYER_CONDITION_MAX_ID,
HOTFIX_SEL_PLAYER_CONDITION_LOCALE,

HOTFIX_SEL_PLAYER_DATA_ELEMENT_ACCOUNT,
HOTFIX_SEL_PLAYER_DATA_ELEMENT_ACCOUNT_MAX_ID,

HOTFIX_SEL_PLAYER_DATA_ELEMENT_CHARACTER,
HOTFIX_SEL_PLAYER_DATA_ELEMENT_CHARACTER_MAX_ID,

HOTFIX_SEL_PLAYER_DATA_FLAG_ACCOUNT,
HOTFIX_SEL_PLAYER_DATA_FLAG_ACCOUNT_MAX_ID,

HOTFIX_SEL_PLAYER_DATA_FLAG_CHARACTER,
HOTFIX_SEL_PLAYER_DATA_FLAG_CHARACTER_MAX_ID,

HOTFIX_SEL_POWER_DISPLAY,
HOTFIX_SEL_POWER_DISPLAY_MAX_ID,

Expand Down
7 changes: 7 additions & 0 deletions src/server/database/Database/Implementation/LoginDatabase.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -196,6 +196,13 @@ void LoginDatabaseConnection::DoPrepareStatements()
"ON DUPLICATE KEY UPDATE isFavorite = VALUES(isFavorite)", CONNECTION_ASYNC);
PrepareStatement(LOGIN_UPD_BNET_WARBAND_SCENE, "UPDATE battlenet_account_warband_scenes SET isFavorite = ?, hasFanfare = ? WHERE battlenetAccountId = ? AND warbandSceneId = ?", CONNECTION_ASYNC);
PrepareStatement(LOGIN_DEL_BNET_WARBAND_SCENE, "DELETE FROM battlenet_account_warband_scenes WHERE battlenetAccountId = ? AND warbandSceneId = ?", CONNECTION_ASYNC);

PrepareStatement(LOGIN_SEL_BNET_PLAYER_DATA_ELEMENTS_ACCOUNT, "SELECT playerDataElementAccountId, floatValue, int64Value FROM battlenet_account_player_data_element WHERE battlenetAccountId = ?", CONNECTION_ASYNC);
PrepareStatement(LOGIN_DEL_BNET_PLAYER_DATA_ELEMENTS_ACCOUNT, "DELETE FROM battlenet_account_player_data_element WHERE battlenetAccountId = ? AND playerDataElementAccountId = ?", CONNECTION_ASYNC);
PrepareStatement(LOGIN_INS_BNET_PLAYER_DATA_ELEMENTS_ACCOUNT, "INSERT INTO battlenet_account_player_data_element (battlenetAccountId, playerDataElementAccountId, floatValue, int64Value) VALUES (?, ?, ?, ?)", CONNECTION_ASYNC);
PrepareStatement(LOGIN_SEL_BNET_PLAYER_DATA_FLAGS_ACCOUNT, "SELECT storageIndex, mask FROM battlenet_account_player_data_flag WHERE battlenetAccountId = ?", CONNECTION_ASYNC);
PrepareStatement(LOGIN_DEL_BNET_PLAYER_DATA_FLAGS_ACCOUNT, "DELETE FROM battlenet_account_player_data_flag WHERE battlenetAccountId = ? AND storageIndex = ?", CONNECTION_ASYNC);
PrepareStatement(LOGIN_INS_BNET_PLAYER_DATA_FLAGS_ACCOUNT, "INSERT INTO battlenet_account_player_data_flag (battlenetAccountId, storageIndex, mask) VALUES (?, ?, ?)", CONNECTION_ASYNC);
}

LoginDatabaseConnection::LoginDatabaseConnection(MySQLConnectionInfo& connInfo, ConnectionFlags connectionFlags) : MySQLConnection(connInfo, connectionFlags)
Expand Down
7 changes: 7 additions & 0 deletions src/server/database/Database/Implementation/LoginDatabase.h
Original file line number Diff line number Diff line change
Expand Up @@ -181,6 +181,13 @@ enum LoginDatabaseStatements : uint32
LOGIN_UPD_BNET_WARBAND_SCENE,
LOGIN_DEL_BNET_WARBAND_SCENE,

LOGIN_SEL_BNET_PLAYER_DATA_ELEMENTS_ACCOUNT,
LOGIN_DEL_BNET_PLAYER_DATA_ELEMENTS_ACCOUNT,
LOGIN_INS_BNET_PLAYER_DATA_ELEMENTS_ACCOUNT,
LOGIN_SEL_BNET_PLAYER_DATA_FLAGS_ACCOUNT,
LOGIN_DEL_BNET_PLAYER_DATA_FLAGS_ACCOUNT,
LOGIN_INS_BNET_PLAYER_DATA_FLAGS_ACCOUNT,

MAX_LOGINDATABASE_STATEMENTS
};

Expand Down
14 changes: 14 additions & 0 deletions src/server/game/Achievements/CriteriaHandler.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -3988,6 +3988,14 @@ bool CriteriaHandler::ModifierSatisfied(ModifierTreeEntry const* modifier, uint6
if (referencePlayer->GetPositionZ() >= reqValue)
return false;
break;
case ModifierTreeType::PlayerDataFlagAccountIsSet: // 378
if (!referencePlayer->HasDataFlagAccount(reqValue))
return false;
break;
case ModifierTreeType::PlayerDataFlagCharacterIsSet: // 379
if (!referencePlayer->HasDataFlagCharacter(reqValue))
return false;
break;
case ModifierTreeType::PlayerIsOnMapWithExpansion: // 380
{
MapEntry const* mapEntry = referencePlayer->GetMap()->GetEntry();
Expand Down Expand Up @@ -4022,6 +4030,12 @@ bool CriteriaHandler::ModifierSatisfied(ModifierTreeEntry const* modifier, uint6
return false;
break;
}
case ModifierTreeType::PlayerDataElementCharacterBetween: // 390
return std::visit([&]<typename T>(T value) { return value >= T(secondaryAsset) && value <= T(tertiaryAsset); },
referencePlayer->GetDataElementCharacter(reqValue));
case ModifierTreeType::PlayerDataElementAccountBetween: // 391
return std::visit([&]<typename T>(T value) { return value >= T(secondaryAsset) && value <= T(tertiaryAsset); },
referencePlayer->GetDataElementAccount(reqValue));
case ModifierTreeType::PlayerHasCompletedQuestOrIsReadyToTurnIn: // 392
{
QuestStatus status = referencePlayer->GetQuestStatus(reqValue);
Expand Down
Loading
0