mirror of
https://github.com/DarkflameUniverse/DarkflameServer.git
synced 2026-11-14 07:47:13 +00:00
feat(character): the editor level is the account's GM level, and the client is told it
A character's editor level is its account's GM level for accounts at editor_gm_level or above, and 0 for everyone else (it was 1 or 0). It is written as the save's edit attribute, sent with the character after the GM level (the editor flag, then the level) and given in answer to the GetEditorLevel game message. Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com>
This commit is contained in:
@@ -222,6 +222,7 @@ namespace {
|
||||
{ TOGGLE_GHOST_REFERENCE_OVERRIDE, []() { return std::make_unique<ToggleGhostReferenceOverride>(); } },
|
||||
{ SET_GHOST_REFERENCE_POSITION, []() { return std::make_unique<SetGhostReferencePosition>(); } },
|
||||
{ MODIFY_GHOSTING_DISTANCE, []() { return std::make_unique<ModifyGhostingDistance>(); } },
|
||||
{ GET_EDITOR_LEVEL, []() { return std::make_unique<GetEditorLevel>(); } },
|
||||
};
|
||||
};
|
||||
|
||||
@@ -270,8 +271,7 @@ void GameMessageHandler::HandleMessage(RakNet::BitStream& inStream, const System
|
||||
}
|
||||
|
||||
// The Happy Flower editor's messages, logged always until the server handles them (what a client sends while editing)
|
||||
const bool isHappyFlower = messageID == MessageType::Game::GET_EDITOR_LEVEL
|
||||
|| (messageID >= MessageType::Game::HF_ATTRIBUTES_PUSH && messageID <= MessageType::Game::HF_GETS_WANT_PATH);
|
||||
const bool isHappyFlower = messageID >= MessageType::Game::HF_ATTRIBUTES_PUSH && messageID <= MessageType::Game::HF_GETS_WANT_PATH;
|
||||
if (isHappyFlower) LOG("Received unhandled Happy Flower GM: %4i, %s", messageID, StringifiedEnum::ToString(messageID).data());
|
||||
else LOG_DEBUG("Received Unknown GM with ID: %4i, %s", messageID, StringifiedEnum::ToString(messageID).data());
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user