Skip to content
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

Enhanced Config Handling, New Category, and Vanilla Dungeon Support #40

Closed
wants to merge 8 commits into from
Closed
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
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@
#Generic
#

*.conf
.directory
.mailmap
*.orig
Expand Down
8 changes: 8 additions & 0 deletions conf/mod-zone-difficulty.conf.dist
Original file line number Diff line number Diff line change
Expand Up @@ -68,3 +68,11 @@ ModZoneDifficulty.Mythicmode.HpModifier = 2.0
# 1 - Enabled

ModZoneDifficulty.Mythicmode.InNormalDungeons = 0

#
# ModZoneDifficulty.LfgAllowed
# Description: Enable or disable mythic mode for LFG dungeons.
# Default: 0 - Disabled
# 1 - Enabled

ModZoneDifficulty.LfgAllowed = 0
64 changes: 64 additions & 0 deletions data/backups/15062024_qeme_backup_reward_items_for_T9.sql
Original file line number Diff line number Diff line change
@@ -0,0 +1,64 @@
DELETE FROM `zone_difficulty_mythicmode_rewards` WHERE `ContentType`=9 AND `Entry`=13583 AND `Enchant`=0;
INSERT INTO `zone_difficulty_mythicmode_rewards` (`ContentType`, `ItemType`, `Entry`, `Price`, `Enchant`, `EnchantSlot`, `Achievement`, `Enabled`, `Comment`) VALUES (9, 7, 13583, 20, 0, 0, 0, 1, 'Panda Cub for clearing all T4 raids on Mythicmode');
DELETE FROM `zone_difficulty_mythicmode_rewards` WHERE `ContentType`=9 AND `Entry`=28774 AND `Enchant`=0;
INSERT INTO `zone_difficulty_mythicmode_rewards` (`ContentType`, `ItemType`, `Entry`, `Price`, `Enchant`, `EnchantSlot`, `Achievement`, `Enabled`, `Comment`) VALUES (9, 6, 28774, 10, 0, 0, 0, 1, 'Glaive of the Pit +14 AP');
DELETE FROM `zone_difficulty_mythicmode_rewards` WHERE `ContentType`=9 AND `Entry`=28775 AND `Enchant`=0;
INSERT INTO `zone_difficulty_mythicmode_rewards` (`ContentType`, `ItemType`, `Entry`, `Price`, `Enchant`, `EnchantSlot`, `Achievement`, `Enabled`, `Comment`) VALUES (9, 4, 28775, 10, 0, 0, 0, 1, 'Thundering Greathelm +14 AP');
DELETE FROM `zone_difficulty_mythicmode_rewards` WHERE `ContentType`=9 AND `Entry`=28776 AND `Enchant`=0;
INSERT INTO `zone_difficulty_mythicmode_rewards` (`ContentType`, `ItemType`, `Entry`, `Price`, `Enchant`, `EnchantSlot`, `Achievement`, `Enabled`, `Comment`) VALUES (9, 3, 28776, 10, 0, 0, 0, 1, 'Liar\'s Tongue Gloves +14 AP');
DELETE FROM `zone_difficulty_mythicmode_rewards` WHERE `ContentType`=9 AND `Entry`=28777 AND `Enchant`=0;
INSERT INTO `zone_difficulty_mythicmode_rewards` (`ContentType`, `ItemType`, `Entry`, `Price`, `Enchant`, `EnchantSlot`, `Achievement`, `Enabled`, `Comment`) VALUES (9, 1, 28777, 10, 0, 0, 0, 1, 'Cloak of the Pit Stalker +7 SP');
DELETE FROM `zone_difficulty_mythicmode_rewards` WHERE `ContentType`=9 AND `Entry`=28778 AND `Enchant`=0;
INSERT INTO `zone_difficulty_mythicmode_rewards` (`ContentType`, `ItemType`, `Entry`, `Price`, `Enchant`, `EnchantSlot`, `Achievement`, `Enabled`, `Comment`) VALUES (9, 3, 28778, 10, 0, 0, 0, 1, 'Terror Pit Girdle +14 AP');
DELETE FROM `zone_difficulty_mythicmode_rewards` WHERE `ContentType`=9 AND `Entry`=28779 AND `Enchant`=0;
INSERT INTO `zone_difficulty_mythicmode_rewards` (`ContentType`, `ItemType`, `Entry`, `Price`, `Enchant`, `EnchantSlot`, `Achievement`, `Enabled`, `Comment`) VALUES (9, 4, 28779, 10, 0, 0, 0, 1, 'Girdle of the Endless Pit +14 AP');
DELETE FROM `zone_difficulty_mythicmode_rewards` WHERE `ContentType`=9 AND `Entry`=28780 AND `Enchant`=0;
INSERT INTO `zone_difficulty_mythicmode_rewards` (`ContentType`, `ItemType`, `Entry`, `Price`, `Enchant`, `EnchantSlot`, `Achievement`, `Enabled`, `Comment`) VALUES (9, 2, 28780, 10, 0, 0, 0, 1, 'Soul-Eater\'s Handwraps +7 SP');
DELETE FROM `zone_difficulty_mythicmode_rewards` WHERE `ContentType`=9 AND `Entry`=28781 AND `Enchant`=0;
INSERT INTO `zone_difficulty_mythicmode_rewards` (`ContentType`, `ItemType`, `Entry`, `Price`, `Enchant`, `EnchantSlot`, `Achievement`, `Enabled`, `Comment`) VALUES (9, 6, 28781, 10, 0, 0, 0, 1, 'Karaborian Talisman +7 SP');
DELETE FROM `zone_difficulty_mythicmode_rewards` WHERE `ContentType`=9 AND `Entry`=28782 AND `Enchant`=0;
INSERT INTO `zone_difficulty_mythicmode_rewards` (`ContentType`, `ItemType`, `Entry`, `Price`, `Enchant`, `EnchantSlot`, `Achievement`, `Enabled`, `Comment`) VALUES (9, 6, 28782, 10, 0, 0, 0, 1, 'Crystalheart Pulse-Staff +7 SP');
DELETE FROM `zone_difficulty_mythicmode_rewards` WHERE `ContentType`=9 AND `Entry`=28783 AND `Enchant`=0;
INSERT INTO `zone_difficulty_mythicmode_rewards` (`ContentType`, `ItemType`, `Entry`, `Price`, `Enchant`, `EnchantSlot`, `Achievement`, `Enabled`, `Comment`) VALUES (9, 6, 28783, 10, 0, 0, 0, 1, 'Eredar Wand of Obliteration +7 SP');
DELETE FROM `zone_difficulty_mythicmode_rewards` WHERE `ContentType`=9 AND `Entry`=28789 AND `Enchant`=0;
INSERT INTO `zone_difficulty_mythicmode_rewards` (`ContentType`, `ItemType`, `Entry`, `Price`, `Enchant`, `EnchantSlot`, `Achievement`, `Enabled`, `Comment`) VALUES (9, 1, 28789, 10, 0, 0, 0, 1, 'Eye of Magtheridon +7 SP');
DELETE FROM `zone_difficulty_mythicmode_rewards` WHERE `ContentType`=9 AND `Entry`=28794 AND `Enchant`=0;
INSERT INTO `zone_difficulty_mythicmode_rewards` (`ContentType`, `ItemType`, `Entry`, `Price`, `Enchant`, `EnchantSlot`, `Achievement`, `Enabled`, `Comment`) VALUES (9, 6, 28794, 10, 0, 0, 0, 1, 'Axe of the Gronn Lords +14 AP');
DELETE FROM `zone_difficulty_mythicmode_rewards` WHERE `ContentType`=9 AND `Entry`=28795 AND `Enchant`=0;
INSERT INTO `zone_difficulty_mythicmode_rewards` (`ContentType`, `ItemType`, `Entry`, `Price`, `Enchant`, `EnchantSlot`, `Achievement`, `Enabled`, `Comment`) VALUES (9, 4, 28795, 10, 0, 0, 0, 1, 'Bladespire Warbands +14 AP');
DELETE FROM `zone_difficulty_mythicmode_rewards` WHERE `ContentType`=9 AND `Entry`=28796 AND `Enchant`=0;
INSERT INTO `zone_difficulty_mythicmode_rewards` (`ContentType`, `ItemType`, `Entry`, `Price`, `Enchant`, `EnchantSlot`, `Achievement`, `Enabled`, `Comment`) VALUES (9, 3, 28796, 10, 0, 0, 0, 1, 'Malefic Mask of the Shadows +14 AP');
DELETE FROM `zone_difficulty_mythicmode_rewards` WHERE `ContentType`=9 AND `Entry`=28797 AND `Enchant`=0;
INSERT INTO `zone_difficulty_mythicmode_rewards` (`ContentType`, `ItemType`, `Entry`, `Price`, `Enchant`, `EnchantSlot`, `Achievement`, `Enabled`, `Comment`) VALUES (9, 1, 28797, 10, 0, 0, 0, 1, 'Brute Cloak of the Ogre-Magi +7 SP');
DELETE FROM `zone_difficulty_mythicmode_rewards` WHERE `ContentType`=9 AND `Entry`=28799 AND `Enchant`=0;
INSERT INTO `zone_difficulty_mythicmode_rewards` (`ContentType`, `ItemType`, `Entry`, `Price`, `Enchant`, `EnchantSlot`, `Achievement`, `Enabled`, `Comment`) VALUES (9, 2, 28799, 10, 0, 0, 0, 1, 'Belt of Divine Inspiration +7 SP');
DELETE FROM `zone_difficulty_mythicmode_rewards` WHERE `ContentType`=9 AND `Entry`=28800 AND `Enchant`=0;
INSERT INTO `zone_difficulty_mythicmode_rewards` (`ContentType`, `ItemType`, `Entry`, `Price`, `Enchant`, `EnchantSlot`, `Achievement`, `Enabled`, `Comment`) VALUES (9, 6, 28800, 10, 0, 0, 0, 1, 'Hammer of the Naaru +14 AP');
DELETE FROM `zone_difficulty_mythicmode_rewards` WHERE `ContentType`=9 AND `Entry`=28801 AND `Enchant`=0;
INSERT INTO `zone_difficulty_mythicmode_rewards` (`ContentType`, `ItemType`, `Entry`, `Price`, `Enchant`, `EnchantSlot`, `Achievement`, `Enabled`, `Comment`) VALUES (9, 3, 28801, 10, 0, 0, 0, 1, 'Maulgar\'s Warhelm +14 AP');
DELETE FROM `zone_difficulty_mythicmode_rewards` WHERE `ContentType`=9 AND `Entry`=28802 AND `Enchant`=0;
INSERT INTO `zone_difficulty_mythicmode_rewards` (`ContentType`, `ItemType`, `Entry`, `Price`, `Enchant`, `EnchantSlot`, `Achievement`, `Enabled`, `Comment`) VALUES (9, 6, 28802, 10, 0, 0, 0, 1, 'Bloodmaw Magus-Blade +7 SP');
DELETE FROM `zone_difficulty_mythicmode_rewards` WHERE `ContentType`=9 AND `Entry`=28803 AND `Enchant`=0;
INSERT INTO `zone_difficulty_mythicmode_rewards` (`ContentType`, `ItemType`, `Entry`, `Price`, `Enchant`, `EnchantSlot`, `Achievement`, `Enabled`, `Comment`) VALUES (9, 3, 28803, 10, 0, 0, 0, 1, 'Cowl of Nature\'s Breath +7 SP');
DELETE FROM `zone_difficulty_mythicmode_rewards` WHERE `ContentType`=9 AND `Entry`=28804 AND `Enchant`=0;
INSERT INTO `zone_difficulty_mythicmode_rewards` (`ContentType`, `ItemType`, `Entry`, `Price`, `Enchant`, `EnchantSlot`, `Achievement`, `Enabled`, `Comment`) VALUES (9, 2, 28804, 10, 0, 0, 0, 1, 'Collar of Cho\'gall +7 SP');
DELETE FROM `zone_difficulty_mythicmode_rewards` WHERE `ContentType`=9 AND `Entry`=28810 AND `Enchant`=0;
INSERT INTO `zone_difficulty_mythicmode_rewards` (`ContentType`, `ItemType`, `Entry`, `Price`, `Enchant`, `EnchantSlot`, `Achievement`, `Enabled`, `Comment`) VALUES (9, 3, 28810, 10, 0, 0, 0, 1, 'Windshear Boots +7 SP');
DELETE FROM `zone_difficulty_mythicmode_rewards` WHERE `ContentType`=9 AND `Entry`=28822 AND `Enchant`=0;
INSERT INTO `zone_difficulty_mythicmode_rewards` (`ContentType`, `ItemType`, `Entry`, `Price`, `Enchant`, `EnchantSlot`, `Achievement`, `Enabled`, `Comment`) VALUES (9, 1, 28822, 10, 0, 0, 0, 1, 'Teeth of Gruul +7 SP');
DELETE FROM `zone_difficulty_mythicmode_rewards` WHERE `ContentType`=9 AND `Entry`=28823 AND `Enchant`=0;
INSERT INTO `zone_difficulty_mythicmode_rewards` (`ContentType`, `ItemType`, `Entry`, `Price`, `Enchant`, `EnchantSlot`, `Achievement`, `Enabled`, `Comment`) VALUES (9, 1, 28823, 10, 0, 0, 0, 1, 'Eye of Gruul +7 SP');
DELETE FROM `zone_difficulty_mythicmode_rewards` WHERE `ContentType`=9 AND `Entry`=28824 AND `Enchant`=0;
INSERT INTO `zone_difficulty_mythicmode_rewards` (`ContentType`, `ItemType`, `Entry`, `Price`, `Enchant`, `EnchantSlot`, `Achievement`, `Enabled`, `Comment`) VALUES (9, 4, 28824, 10, 0, 0, 0, 1, 'Gauntlets of Martial Perfection +14 AP');
DELETE FROM `zone_difficulty_mythicmode_rewards` WHERE `ContentType`=9 AND `Entry`=28825 AND `Enchant`=0;
INSERT INTO `zone_difficulty_mythicmode_rewards` (`ContentType`, `ItemType`, `Entry`, `Price`, `Enchant`, `EnchantSlot`, `Achievement`, `Enabled`, `Comment`) VALUES (9, 6, 28825, 10, 0, 0, 0, 1, 'Aldori Legacy Defender +14 AP');
DELETE FROM `zone_difficulty_mythicmode_rewards` WHERE `ContentType`=9 AND `Entry`=28826 AND `Enchant`=0;
INSERT INTO `zone_difficulty_mythicmode_rewards` (`ContentType`, `ItemType`, `Entry`, `Price`, `Enchant`, `EnchantSlot`, `Achievement`, `Enabled`, `Comment`) VALUES (9, 6, 28826, 10, 0, 0, 0, 1, 'Shuriken of Negation +14 AP');
DELETE FROM `zone_difficulty_mythicmode_rewards` WHERE `ContentType`=9 AND `Entry`=28827 AND `Enchant`=0;
INSERT INTO `zone_difficulty_mythicmode_rewards` (`ContentType`, `ItemType`, `Entry`, `Price`, `Enchant`, `EnchantSlot`, `Achievement`, `Enabled`, `Comment`) VALUES (9, 3, 28827, 10, 0, 0, 0, 1, 'Gauntlets of the Dragonslayer +14 AP');
DELETE FROM `zone_difficulty_mythicmode_rewards` WHERE `ContentType`=9 AND `Entry`=28828 AND `Enchant`=0;
INSERT INTO `zone_difficulty_mythicmode_rewards` (`ContentType`, `ItemType`, `Entry`, `Price`, `Enchant`, `EnchantSlot`, `Achievement`, `Enabled`, `Comment`) VALUES (9, 3, 28828, 10, 0, 0, 0, 1, 'Gronn-Stitched Girdle +14 AP');
DELETE FROM `zone_difficulty_mythicmode_rewards` WHERE `ContentType`=9 AND `Entry`=28830 AND `Enchant`=0;
INSERT INTO `zone_difficulty_mythicmode_rewards` (`ContentType`, `ItemType`, `Entry`, `Price`, `Enchant`, `EnchantSlot`, `Achievement`, `Enabled`, `Comment`) VALUES (9, 1, 28830, 10, 0, 0, 0, 1, 'Dragonspine Trophy +14 AP');
DELETE FROM `zone_difficulty_mythicmode_rewards` WHERE `ContentType`=9 AND `Entry`=29458 AND `Enchant`=0;
INSERT INTO `zone_difficulty_mythicmode_rewards` (`ContentType`, `ItemType`, `Entry`, `Price`, `Enchant`, `EnchantSlot`, `Achievement`, `Enabled`, `Comment`) VALUES (9, 6, 29458, 10, 0, 0, 0, 1, 'Aegis of the Vindicator +7 SP');
3 changes: 3 additions & 0 deletions data/sql/updates/world/2024_06_03_qeme-add-gm-col.sql
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
-- Column to flag log entry for GM/Dev players.
ALTER TABLE zone_difficulty_encounter_logs
ADD COLUMN IF NOT EXISTS IsDev TINYINT(3) NULL DEFAULT 0 COMMENT '';
3 changes: 3 additions & 0 deletions data/sql/updates/world/2024_0_29_qeme-rfk-heroic.sql
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
-- let all normal dungeon creatures spawn in heroic mode as well
UPDATE creature SET spawnMask = 3 WHERE map = 47

2 changes: 2 additions & 0 deletions src/ZoneDifficulty.h
Original file line number Diff line number Diff line change
Expand Up @@ -102,6 +102,7 @@ uint32 const ITEMTYPE_LEATHER = 3;
uint32 const ITEMTYPE_MAIL = 4;
uint32 const ITEMTYPE_PLATE = 5;
uint32 const ITEMTYPE_WEAPONS = 6;
uint32 const ITEMTYPE_OTHER = 7;

uint32 const TARGET_NONE = 0;
uint32 const TARGET_SELF = 1;
Expand Down Expand Up @@ -147,6 +148,7 @@ class ZoneDifficulty
float MythicmodeHpModifier{ 2.0 };
bool MythicmodeEnable{ false };
bool MythicmodeInNormalDungeons{ false };
bool LfgAllowed{ false }; // Config value for mythicmode on/off in LFG dungeons
std::vector<uint32> DailyHeroicQuests;
std::map<uint32, uint32> HeroicTBCQuestMapList;
std::map<uint32, uint8> EncounterCounter;
Expand Down
32 changes: 23 additions & 9 deletions src/mod_zone_difficulty_handler.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -66,6 +66,10 @@ void ZoneDifficulty::LoadMapDifficultySettings()
HeroicTBCQuestMapList[554] = 11386; // The Mechanar
HeroicTBCQuestMapList[545] = 11370; // The Steamvault

// Category 1
EncounterCounter[47] = 5; // Razorfen Kraul
EncounterCounter[90] = 5; // Gnomeregan

// Category 8
EncounterCounter[542] = 3; // Blood Furnace
EncounterCounter[543] = 3; // Hellfire Ramparts
Expand Down Expand Up @@ -96,6 +100,7 @@ void ZoneDifficulty::LoadMapDifficultySettings()
sZoneDifficulty->ItemIcons[ITEMTYPE_MAIL] = "|TInterface\\icons\\inv_chest_chain_13:15|t ";
sZoneDifficulty->ItemIcons[ITEMTYPE_PLATE] = "|TInterface\\icons\\inv_chest_plate12:15|t ";
sZoneDifficulty->ItemIcons[ITEMTYPE_WEAPONS] = "|TInterface\\icons\\inv_mace_25:15|t |TInterface\\icons\\inv_shield_27:15|t |TInterface\\icons\\inv_weapon_crossbow_04:15|t ";
sZoneDifficulty->ItemIcons[ITEMTYPE_OTHER] = "|TInterface\\icons\\inv_jewelcrafting_shadowspirit_01:15|t ";

if (QueryResult result = WorldDatabase.Query("SELECT * FROM zone_difficulty_info"))
{
Expand Down Expand Up @@ -268,13 +273,13 @@ void ZoneDifficulty::LoadMapDifficultySettings()
if (data.Chance != 0 && data.Spell != 0 && ((data.Target >= 1 && data.Target <= 6) || data.Target == 18))
{
sZoneDifficulty->MythicmodeAI[creatureEntry].push_back(data);
LOG_INFO("module", "MOD-ZONE-DIFFICULTY: New AI for entry {} with spell {}", creatureEntry, data.Spell);
//LOG_INFO("module", "MOD-ZONE-DIFFICULTY: New AI for entry {} with spell {}", creatureEntry, data.Spell);
}
else
{
LOG_ERROR("module", "MOD-ZONE-DIFFICULTY: Unknown type for `Target`: {} in zone_difficulty_mythicmode_ai", data.Target);
}
//LOG_INFO("module", "MOD-ZONE-DIFFICULTY: New creature with entry: {} has exception for hp: {}", creatureEntry, hpModifier);
////LOG_INFO("module", "MOD-ZONE-DIFFICULTY: New creature with entry: {} has exception for hp: {}", creatureEntry, hpModifier);
}
} while (result->NextRow());
}
Expand Down Expand Up @@ -319,7 +324,7 @@ void ZoneDifficulty::LoadMapDifficultySettings()
//LOG_INFO("module", "MOD-ZONE-DIFFICULTY: Loading tier reward with entry {} has enchant {} in slot {}. contentType: {} itemType: {}", data.Entry, data.Enchant, data.EnchantSlot, contentType, itemType);
}
}
//LOG_INFO("module", "MOD-ZONE-DIFFICULTY: Total items in Rewards map: {}.", i);
////LOG_INFO("module", "MOD-ZONE-DIFFICULTY: Total items in Rewards map: {}.", i);
} while (result->NextRow());
}
else
Expand All @@ -343,7 +348,7 @@ void ZoneDifficulty::LoadMythicmodeInstanceData()
/* debugging
* for (int i = 0; i < int(instanceIDs.size()); i++)
* {
* LOG_INFO("module", "MOD-ZONE-DIFFICULTY: ZoneDifficulty::LoadMythicmodeInstanceData: id {} exists: {}:", i, instanceIDs[i]);
* //LOG_INFO("module", "MOD-ZONE-DIFFICULTY: ZoneDifficulty::LoadMythicmodeInstanceData: id {} exists: {}:", i, instanceIDs[i]);
* }
* end debugging
*/
Expand All @@ -356,7 +361,7 @@ void ZoneDifficulty::LoadMythicmodeInstanceData()

if (instanceIDs[InstanceId])
{
LOG_INFO("module", "MOD-ZONE-DIFFICULTY: Loading from DB for instanceId {}: MythicmodeOn = {}", InstanceId, MythicmodeOn);
//LOG_INFO("module", "MOD-ZONE-DIFFICULTY: Loading from DB for instanceId {}: MythicmodeOn = {}", InstanceId, MythicmodeOn);
sZoneDifficulty->MythicmodeInstanceData[InstanceId] = MythicmodeOn;
}
else
Expand Down Expand Up @@ -415,11 +420,11 @@ void ZoneDifficulty::LoadMythicmodeScoreData()
{
for (int i = 0; i < sZoneDifficulty->EncounterCounter[MapId]; ++i)
{
LOG_INFO("module", "MOD-ZONE-DIFFICULTY: Initializing player record for PlayerGuid {} in MapId {} for BossId {}: False", PlayerGuid, MapId, i);
//LOG_INFO("module", "MOD-ZONE-DIFFICULTY: Initializing player record for PlayerGuid {} in MapId {} for BossId {}: False", PlayerGuid, MapId, i);
sZoneDifficulty->Logs[PlayerGuid][MapId][i] = false;
}
}
LOG_INFO("module", "MOD-ZONE-DIFFICULTY: Setting player record for PlayerGuid {} in MapId {} for BossId {}: True", PlayerGuid, MapId, BossID);
//LOG_INFO("module", "MOD-ZONE-DIFFICULTY: Setting player record for PlayerGuid {} in MapId {} for BossId {}: True", PlayerGuid, MapId, BossID);
sZoneDifficulty->Logs[PlayerGuid][MapId][BossID] = true;
} while (result->NextRow());
}
Expand Down Expand Up @@ -471,6 +476,9 @@ std::string ZoneDifficulty::GetItemTypeString(uint32 type)
case ITEMTYPE_WEAPONS:
typestring = "Weapons and Shields";
break;
case ITEMTYPE_OTHER:
typestring = "Emblem, Vanity, Consumables, and other items";
break;
default:
LOG_ERROR("module", "MOD-ZONE-DIFFICULTY: Unknown type {} in ZoneDifficulty::GetItemTypeString.", type);
}
Expand Down Expand Up @@ -574,7 +582,7 @@ void ZoneDifficulty::AddMythicmodeScore(Map* map, uint32 type, uint32 score)

//if (sZoneDifficulty->IsDebugInfoEnabled)
//{
// LOG_INFO("module", "MOD-ZONE-DIFFICULTY: Player {} new score: {}", player->GetName(), sZoneDifficulty->MythicmodeScore[player->GetGUID().GetCounter()][type]);
// //LOG_INFO("module", "MOD-ZONE-DIFFICULTY: Player {} new score: {}", player->GetName(), sZoneDifficulty->MythicmodeScore[player->GetGUID().GetCounter()][type]);
//}

std::string typestring = sZoneDifficulty->GetContentTypeString(type);
Expand All @@ -594,7 +602,7 @@ void ZoneDifficulty::DeductMythicmodeScore(Player* player, uint32 type, uint32 s
// NULL check happens in the calling function
if (sZoneDifficulty->IsDebugInfoEnabled)
{
LOG_INFO("module", "MOD-ZONE-DIFFICULTY: Reducing score with type {} from player with guid {} by {}.", type, player->GetGUID().GetCounter(), score);
//LOG_INFO("module", "MOD-ZONE-DIFFICULTY: Reducing score with type {} from player with guid {} by {}.", type, player->GetGUID().GetCounter(), score);
}
sZoneDifficulty->MythicmodeScore[player->GetGUID().GetCounter()][type] = sZoneDifficulty->MythicmodeScore[player->GetGUID().GetCounter()][type] - score;
CharacterDatabase.Execute("REPLACE INTO zone_difficulty_mythicmode_score VALUES({}, {}, {})", player->GetGUID().GetCounter(), type, sZoneDifficulty->MythicmodeScore[player->GetGUID().GetCounter()][type]);
Expand Down Expand Up @@ -673,12 +681,15 @@ bool ZoneDifficulty::IsMythicmodeMap(uint32 mapId)
{
if (!sZoneDifficulty->MythicmodeEnable)
{
//LOG_INFO("module", "MOD-ZONE-DIFFICULTY: Mythicmode is disabled.");
return false;
}
if (sZoneDifficulty->MythicmodeLoot.find(mapId) == sZoneDifficulty->MythicmodeLoot.end())
{
//LOG_INFO("module", "MOD-ZONE-DIFFICULTY: No Mythicmode data found for mapId {}.", mapId);
return false;
}
//LOG_INFO("module", "MOD-ZONE-DIFFICULTY: Mythicmode data found for mapId {}.", mapId);
return true;
}

Expand Down Expand Up @@ -1008,6 +1019,9 @@ bool ZoneDifficulty::HasCompletedFullTier(uint32 category, uint32 playerGuid)
std::vector<uint32> MapList;
switch (category)
{
case TYPE_VANILLA:
MapList = { 47, 90 };
break;
case TYPE_HEROIC_TBC:
//585 is Magister's Terrace. Only add when released.
MapList = { 269, 540, 542, 543, 545, 547, 546, 552, 553, 554, 555, 556, 557, 558, 560/*, 585*/ };
Expand Down
Loading
Loading