mirror of
https://github.com/TrinityCore/TrinityCore.git
synced 2026-01-19 17:05:44 +01:00
Core/Players: Allow disabling creating characters in Exile's Reach by disabling map 2175
This commit is contained in:
@@ -327,6 +327,8 @@ bool IsDisabledFor(DisableType type, uint32 entry, WorldObject const* ref, uint8
|
||||
}
|
||||
case DISABLE_TYPE_MAP:
|
||||
case DISABLE_TYPE_LFG_MAP:
|
||||
if (!ref)
|
||||
return true;
|
||||
if (Player const* player = ref->ToPlayer())
|
||||
{
|
||||
MapEntry const* mapEntry = sMapStore.LookupEntry(entry);
|
||||
|
||||
@@ -20,6 +20,7 @@
|
||||
#include "BattlenetRpcErrorCodes.h"
|
||||
#include "CharacterTemplateDataStore.h"
|
||||
#include "ClientConfigPackets.h"
|
||||
#include "DisableMgr.h"
|
||||
#include "GameTime.h"
|
||||
#include "ObjectMgr.h"
|
||||
#include "RBAC.h"
|
||||
@@ -49,6 +50,10 @@ void WorldSession::SendAuthResponse(uint32 code, bool queued, uint32 queuePos)
|
||||
response.SuccessInfo->Templates.push_back(&templ.second);
|
||||
|
||||
response.SuccessInfo->AvailableClasses = &sObjectMgr->GetClassExpansionRequirements();
|
||||
|
||||
// TEMPORARY - prevent creating characters in uncompletable zone
|
||||
// This has the side effect of disabling Exile's Reach choice clientside without actually forcing character templates
|
||||
response.SuccessInfo->ForceCharacterTemplate = DisableMgr::IsDisabledFor(DISABLE_TYPE_MAP, 2175 /*Exile's Reach*/, nullptr);
|
||||
}
|
||||
|
||||
if (queued)
|
||||
|
||||
Reference in New Issue
Block a user