mirror of
https://github.com/DarkflameUniverse/DarkflameServer.git
synced 2025-08-04 09:44:10 +00:00
breakout object bits into scoped enum (#997)
* breakout object bits into enum class tested that things still work as expected use the inplace set bits where appropiate * add inline
This commit is contained in:
@@ -64,6 +64,7 @@
|
||||
#include "AMFFormat.h"
|
||||
#include "NiPoint3.h"
|
||||
#include "eServerDisconnectIdentifiers.h"
|
||||
#include "eObjectBits.h"
|
||||
|
||||
#include "ZCompression.h"
|
||||
|
||||
@@ -968,8 +969,8 @@ void HandlePacket(Packet* packet) {
|
||||
|
||||
LWOOBJID playerID = 0;
|
||||
inStream.Read(playerID);
|
||||
playerID = GeneralUtils::ClearBit(playerID, OBJECT_BIT_CHARACTER);
|
||||
playerID = GeneralUtils::ClearBit(playerID, OBJECT_BIT_PERSISTENT);
|
||||
GeneralUtils::ClearBit(playerID, eObjectBits::CHARACTER);
|
||||
GeneralUtils::ClearBit(playerID, eObjectBits::PERSISTENT);
|
||||
|
||||
auto user = UserManager::Instance()->GetUser(packet->systemAddress);
|
||||
|
||||
@@ -1123,8 +1124,8 @@ void HandlePacket(Packet* packet) {
|
||||
//Send message:
|
||||
{
|
||||
LWOOBJID blueprintID = res->getUInt(1);
|
||||
blueprintID = GeneralUtils::SetBit(blueprintID, OBJECT_BIT_CHARACTER);
|
||||
blueprintID = GeneralUtils::SetBit(blueprintID, OBJECT_BIT_PERSISTENT);
|
||||
GeneralUtils::SetBit(blueprintID, eObjectBits::CHARACTER);
|
||||
GeneralUtils::SetBit(blueprintID, eObjectBits::PERSISTENT);
|
||||
|
||||
CBITSTREAM;
|
||||
PacketUtils::WriteHeader(bitStream, CLIENT, MSG_CLIENT_BLUEPRINT_SAVE_RESPONSE);
|
||||
|
Reference in New Issue
Block a user