mirror of
https://github.com/araxiaonline/TrinityCore.git
synced 2026-06-13 11:43:18 -04:00
Core/ChatCommands: make ExactSequence more readable
(cherry picked from commit feaaa595ca)
This commit is contained in:
@@ -164,7 +164,7 @@ public:
|
||||
return true;
|
||||
}
|
||||
|
||||
static bool HandleDebugWarModeFactionBalanceCommand(ChatHandler* handler, Variant<uint32, ExactSequence<'a','l','l','i','a','n','c','e'>, ExactSequence<'h','o','r','d','e'>, ExactSequence<'n','e','u','t','r','a','l'>, ExactSequence<'o','f','f'>> command, Optional<int32> rewardValue)
|
||||
static bool HandleDebugWarModeFactionBalanceCommand(ChatHandler* handler, Variant<uint32, EXACT_SEQUENCE("alliance"), EXACT_SEQUENCE("horde"), EXACT_SEQUENCE("neutral"), EXACT_SEQUENCE("off")> command, Optional<int32> rewardValue)
|
||||
{
|
||||
// USAGE: .debug pvp fb <alliance|horde|neutral|off> [pct]
|
||||
// neutral Sets faction balance off.
|
||||
@@ -1227,7 +1227,7 @@ public:
|
||||
return true;
|
||||
}
|
||||
|
||||
static bool HandleDebugBoundaryCommand(ChatHandler* handler, Optional<ExactSequence<'f', 'i', 'l','l'>> fill, Optional<uint32> durationArg)
|
||||
static bool HandleDebugBoundaryCommand(ChatHandler* handler, Optional<EXACT_SEQUENCE("fill")> fill, Optional<uint32> durationArg)
|
||||
{
|
||||
Player* player = handler->GetPlayer();
|
||||
if (!player)
|
||||
@@ -1351,7 +1351,7 @@ public:
|
||||
return true;
|
||||
}
|
||||
|
||||
static bool HandleDebugNearGraveyard(ChatHandler* handler, Optional<ExactSequence<'l', 'i', 'n', 'k', 'e', 'd'>> linked)
|
||||
static bool HandleDebugNearGraveyard(ChatHandler* handler, Optional<EXACT_SEQUENCE("linked")> linked)
|
||||
{
|
||||
Player* player = handler->GetPlayer();
|
||||
WorldSafeLocsEntry const* nearestLoc = nullptr;
|
||||
@@ -1399,7 +1399,7 @@ public:
|
||||
return true;
|
||||
}
|
||||
|
||||
static bool HandleDebugInstanceSpawns(ChatHandler* handler, Variant<uint32, ExactSequence<'e', 'x', 'p', 'l', 'a', 'i', 'n'>> optArg)
|
||||
static bool HandleDebugInstanceSpawns(ChatHandler* handler, Variant<uint32, EXACT_SEQUENCE("explain")> optArg)
|
||||
{
|
||||
Player const* const player = handler->GetPlayer();
|
||||
if (!player)
|
||||
@@ -1407,10 +1407,10 @@ public:
|
||||
|
||||
bool explain = false;
|
||||
uint32 groupID = 0;
|
||||
if (optArg.holds_alternative<ExactSequence<'e', 'x', 'p', 'l', 'a', 'i', 'n'>>())
|
||||
explain = true;
|
||||
else
|
||||
if (optArg.holds_alternative<uint32>())
|
||||
groupID = optArg.get<uint32>();
|
||||
else
|
||||
explain = true;
|
||||
|
||||
if (groupID && !sObjectMgr->GetSpawnGroupData(groupID))
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user