mirror of
https://github.com/ZhengPeiRu21/mod-individual-progression
synced 2025-11-29 23:44:51 +08:00
Merge pull request #79 from wobgob/origin-story
Fix starting progression and dungeon teleports
This commit is contained in:
@@ -25,7 +25,7 @@ bool IndividualProgression::isBeforeProgression(Player* player, ProgressionState
|
|||||||
|
|
||||||
void IndividualProgression::UpdateProgressionState(Player* player, ProgressionState newState) const
|
void IndividualProgression::UpdateProgressionState(Player* player, ProgressionState newState) const
|
||||||
{
|
{
|
||||||
if (progressionLimit && newState >= progressionLimit)
|
if (progressionLimit && newState > progressionLimit)
|
||||||
return;
|
return;
|
||||||
uint8 currentState = player->GetPlayerSetting("mod-individual-progression", SETTING_PROGRESSION_STATE).value;
|
uint8 currentState = player->GetPlayerSetting("mod-individual-progression", SETTING_PROGRESSION_STATE).value;
|
||||||
if (newState > currentState)
|
if (newState > currentState)
|
||||||
|
|||||||
@@ -9,6 +9,7 @@
|
|||||||
#include "GameObjectAI.h"
|
#include "GameObjectAI.h"
|
||||||
#include "MapMgr.h"
|
#include "MapMgr.h"
|
||||||
#include "ObjectAccessor.h"
|
#include "ObjectAccessor.h"
|
||||||
|
#include "ObjectMgr.h"
|
||||||
#include "Group.h"
|
#include "Group.h"
|
||||||
#include "Pet.h"
|
#include "Pet.h"
|
||||||
#include "DBCEnums.h"
|
#include "DBCEnums.h"
|
||||||
|
|||||||
@@ -202,6 +202,19 @@ public:
|
|||||||
{
|
{
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
InstanceTemplate const* instanceTemplate = sObjectMgr->GetInstanceTemplate(mapid);
|
||||||
|
if (instanceTemplate)
|
||||||
|
{
|
||||||
|
if (instanceTemplate->Parent == MAP_OUTLANDS && !sIndividualProgression->hasPassedProgression(player, PROGRESSION_NAXX40))
|
||||||
|
{
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
if (instanceTemplate->Parent == MAP_NORTHREND && !sIndividualProgression->hasPassedProgression(player, PROGRESSION_TBC_TIER_5))
|
||||||
|
{
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
}
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user