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:
Aaron Kimbrell
2026-11-10 19:11:29 -06:00
parent ca7d166c0b
commit dbe0722095
9 changed files with 139 additions and 35 deletions

View File

@@ -204,6 +204,7 @@ json ToJson(const GameMessages::ReportBug& m);
json ToJson(const GameMessages::VerifyAck& m);
json ToJson(const GameMessages::Help& m);
json ToJson(const GameMessages::DisplayGuildCreateBox& m);
json ToJson(const GameMessages::GetEditorLevel& m);
json ToJson(const GameMessages::OpenPropertyVendor& m);
json ToJson(const GameMessages::OpenPropertyManagement& m);
json ToJson(const GameMessages::DownloadPropertyData& m);
@@ -1806,6 +1807,12 @@ json ToJson(const GameMessages::DisplayGuildCreateBox& m) {
j["bShow"] = ToJson(m.bShow);
return j;
}
json ToJson(const GameMessages::GetEditorLevel& m) {
json j = json::object();
j["editorEnabled"] = ToJson(m.editorEnabled);
j["editorLevel"] = ToJson(m.editorLevel);
return j;
}
json ToJson(const GameMessages::OpenPropertyVendor& m) {
json j = json::object();
return j;
@@ -2724,6 +2731,7 @@ const std::vector<Entry>& Entries() {
{ MessageType::Game::VERIFY_ACK, eDirection::TO_CLIENT, "VerifyAck", &ReadWith<GameMessages::VerifyAck> },
{ MessageType::Game::HELP, eDirection::TO_CLIENT, "Help", &ReadWith<GameMessages::Help> },
{ MessageType::Game::DISPLAY_GUILD_CREATE_BOX, eDirection::TO_CLIENT, "DisplayGuildCreateBox", &ReadWith<GameMessages::DisplayGuildCreateBox> },
{ MessageType::Game::GET_EDITOR_LEVEL, eDirection::TO_SERVER, "GetEditorLevel", &ReadWith<GameMessages::GetEditorLevel> },
{ MessageType::Game::OPEN_PROPERTY_VENDOR, eDirection::TO_CLIENT, "OpenPropertyVendor", &ReadWith<GameMessages::OpenPropertyVendor> },
{ MessageType::Game::OPEN_PROPERTY_MANAGEMENT, eDirection::TO_CLIENT, "OpenPropertyManagement", &ReadWith<GameMessages::OpenPropertyManagement> },
{ MessageType::Game::DOWNLOAD_PROPERTY_DATA, eDirection::TO_CLIENT, "DownloadPropertyData", &ReadWith<GameMessages::DownloadPropertyData> },