Enhance school creation and map management features by updating the API to support mod packs and map layouts. Introduce a new map snapshot protocol for efficient data handling during school sessions. Revise documentation to reflect these changes, including updates to the protocol and architecture documents. Improve UI components for mod selection and map editing, ensuring a better user experience. Update tests to validate new functionalities and ensure robustness.
This commit is contained in:
@@ -4,8 +4,18 @@ namespace HSchool.Protocol;
|
||||
public static class ProtocolConstants
|
||||
{
|
||||
/// <summary>Bumped on every breaking change to the binary layout.</summary>
|
||||
public const byte Version = 3;
|
||||
public const byte Version = 4;
|
||||
|
||||
/// <summary>Upper bound for a single WebSocket frame accepted by the server.</summary>
|
||||
public const int MaxMessageSize = 8 * 1024;
|
||||
|
||||
/// <summary>Hello locale byte: Russian. Any other value that is not <see cref="LocaleEnglish"/> is treated as this.</summary>
|
||||
public const byte LocaleRussian = 0;
|
||||
|
||||
/// <summary>Hello locale byte: English. Same value the catalog HTTP API takes as <c>lang=en</c>.</summary>
|
||||
public const byte LocaleEnglish = 1;
|
||||
|
||||
/// <summary>Catalog locale string matching the Hello byte. Unknown bytes fall back to Russian.</summary>
|
||||
public static string CatalogLocale(byte locale) =>
|
||||
locale == LocaleEnglish ? "en" : "ru";
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user