diff options
author | Shauren <shauren.trinity@gmail.com> | 2022-07-17 20:23:37 +0200 |
---|---|---|
committer | Shauren <shauren.trinity@gmail.com> | 2022-07-17 20:23:37 +0200 |
commit | cb99b08b86f8773563276bf16ccc2210003b056b (patch) | |
tree | 9284c0abae36e5f779b97b968463de4a9d86db8f /src/server/scripts/Commands | |
parent | b8e52fd90bdab6e720d13e44c64483945e139fa2 (diff) |
Core/Players: Fixed ExploredZones size and PLAYER_EXPLORED_ZONES_SIZE desync
Diffstat (limited to 'src/server/scripts/Commands')
-rw-r--r-- | src/server/scripts/Commands/cs_misc.cpp | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/src/server/scripts/Commands/cs_misc.cpp b/src/server/scripts/Commands/cs_misc.cpp index cf9d34bfa1c..ceec104b317 100644 --- a/src/server/scripts/Commands/cs_misc.cpp +++ b/src/server/scripts/Commands/cs_misc.cpp @@ -1127,7 +1127,7 @@ public: return false; } - uint32 offset = area->AreaBit / 64; + uint32 offset = area->AreaBit / PLAYER_EXPLORED_ZONES_BITS; if (offset >= PLAYER_EXPLORED_ZONES_SIZE) { handler->SendSysMessage(LANG_BAD_VALUE); @@ -1135,7 +1135,7 @@ public: return false; } - uint64 val = UI64LIT(1) << (area->AreaBit % 64); + uint64 val = UI64LIT(1) << (area->AreaBit % PLAYER_EXPLORED_ZONES_BITS); playerTarget->AddExploredZones(offset, val); handler->SendSysMessage(LANG_EXPLORE_AREA); @@ -1167,7 +1167,7 @@ public: return false; } - uint32 offset = area->AreaBit / 64; + uint32 offset = area->AreaBit / PLAYER_EXPLORED_ZONES_BITS; if (offset >= PLAYER_EXPLORED_ZONES_SIZE) { handler->SendSysMessage(LANG_BAD_VALUE); @@ -1175,7 +1175,7 @@ public: return false; } - uint64 val = UI64LIT(1) << (area->AreaBit % 64); + uint64 val = UI64LIT(1) << (area->AreaBit % PLAYER_EXPLORED_ZONES_BITS); playerTarget->RemoveExploredZones(offset, val); handler->SendSysMessage(LANG_UNEXPLORE_AREA); |