From cb723a31f991c78bf943cb70baa8c342bb59a858 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E9=83=91=E4=BD=A9=E8=8C=B9?= Date: Tue, 21 Mar 2023 09:32:28 -0600 Subject: [PATCH] Add config option for Naxx40 Strath Entrance requirement --- conf/individualProgression.conf.dist | 11 +++++++++++ src/IndividualProgression.cpp | 1 + src/IndividualProgression.h | 2 +- src/naxx40Scripts/instance_naxxramas.cpp | 3 ++- 4 files changed, 15 insertions(+), 2 deletions(-) diff --git a/conf/individualProgression.conf.dist b/conf/individualProgression.conf.dist index b58f1ac..8b74d08 100644 --- a/conf/individualProgression.conf.dist +++ b/conf/individualProgression.conf.dist @@ -129,6 +129,17 @@ IndividualProgression.HunterPetLevelFix = 1 IndividualProgression.RequirePreAQQuests = 1 # +# IndividualProgression.RequireNaxxStrathEntrance +# Description: If enabled, requires players to first enter Naxx 40 through the original beta entrance in the back of Stratholme +# before being able to use the teleportation crystal in EPL. This is consistent behavior with other Vanilla raids (MC, BL). +# If disabled, players can enter Naxx 40 through the crystal as soon as they are attuned and they have reached the correct +# progression level - no Stratholme run will be required. +# Default: 1 - Enabled +# 0 - Disabled +# + +IndividualProgression.RequireNaxxStrathEntrance = 1 +# # # # IndividualProgression.MoltenCore.ManualRuneHandling diff --git a/src/IndividualProgression.cpp b/src/IndividualProgression.cpp index 0755065..0b09228 100644 --- a/src/IndividualProgression.cpp +++ b/src/IndividualProgression.cpp @@ -293,6 +293,7 @@ private: sIndividualProgression->questXpFix = sConfigMgr->GetOption("IndividualProgression.QuestXPFix", true); sIndividualProgression->hunterPetLevelFix = sConfigMgr->GetOption("IndividualProgression.HunterPetLevelFix", true); sIndividualProgression->requirePreAQQuests = sConfigMgr->GetOption("IndividualProgression.RequirePreAQQuests", true); + sIndividualProgression->requireNaxxStrath = sConfigMgr->GetOption("IndividualProgression.RequireNaxxStrathEntrance", true); sIndividualProgression->enforceGroupRules = sConfigMgr->GetOption("IndividualProgression.EnforceGroupRules", true); sIndividualProgression->fishingFix = sConfigMgr->GetOption("IndividualProgression.FishingFix", true); sIndividualProgression->simpleConfigOverride = sConfigMgr->GetOption("IndividualProgression.SimpleConfigOverride", true); diff --git a/src/IndividualProgression.h b/src/IndividualProgression.h index 11ca99a..034eb07 100644 --- a/src/IndividualProgression.h +++ b/src/IndividualProgression.h @@ -143,7 +143,7 @@ public: std::map customProgressionMap; questXpMapType questXpMap; float vanillaPowerAdjustment, vanillaHealthAdjustment, tbcPowerAdjustment, tbcHealthAdjustment, vanillaHealingAdjustment, tbcHealingAdjustment, previousGearTuning; - bool enabled, questXpFix, hunterPetLevelFix, requirePreAQQuests, enforceGroupRules, fishingFix, simpleConfigOverride, questMoneyAtLevelCap, repeatableVanillaQuestsXp, disableDefaultProgression, earlyDungeonSet2; + bool enabled, questXpFix, hunterPetLevelFix, requirePreAQQuests, enforceGroupRules, fishingFix, simpleConfigOverride, questMoneyAtLevelCap, repeatableVanillaQuestsXp, disableDefaultProgression, earlyDungeonSet2, requireNaxxStrath; int progressionLimit, startingProgression, tbcRacesProgressionLevel, deathKnightProgressionLevel, deathKnightStartingProgression; bool hasPassedProgression(Player* player, ProgressionState state) const; diff --git a/src/naxx40Scripts/instance_naxxramas.cpp b/src/naxx40Scripts/instance_naxxramas.cpp index ca26ee1..3a0a3bc 100644 --- a/src/naxx40Scripts/instance_naxxramas.cpp +++ b/src/naxx40Scripts/instance_naxxramas.cpp @@ -25,6 +25,7 @@ #include "ObjectMgr.h" #include "GameObjectAI.h" #include "naxxramas.h" +#include "IndividualProgression.h" const float HeiganPos[2] = {2796, -3707}; const float HeiganEruptionSlope[3] = @@ -1354,7 +1355,7 @@ public: bool OnGossipHello(Player* player, GameObject* go) override { - if (player->GetQuestStatus(NAXX40_ENTRANCE_FLAG) == QUEST_STATUS_REWARDED && isAttuned(player)) + if ((!sIndividualProgression->requireNaxxStrath || player->GetQuestStatus(NAXX40_ENTRANCE_FLAG) == QUEST_STATUS_REWARDED) && isAttuned(player)) { player->SetRaidDifficulty(RAID_DIFFICULTY_10MAN_HEROIC); player->TeleportTo(533, 3005.51f, -3434.64f, 304.195f, 6.2831f);