Refactor project structure and update documentation. Replace PixiJS with plain DOM for UI rendering, enhance README with game features, and revise protocol documentation for HTTP API. Remove unused files and streamline client code for better maintainability.
This commit is contained in:
@@ -1,20 +1,11 @@
|
||||
namespace HSchool.Protocol;
|
||||
|
||||
/// <summary>Wire-format constants shared by the server and the browser client.</summary>
|
||||
public static class ProtocolConstants
|
||||
{
|
||||
/// <summary>Bumped on every breaking change to the binary layout.</summary>
|
||||
public const byte Version = 1;
|
||||
|
||||
/// <summary>Upper bound for a single WebSocket frame accepted by the server.</summary>
|
||||
public const int MaxMessageSize = 64 * 1024;
|
||||
|
||||
/// <summary>Bytes of a single entity inside a snapshot payload.</summary>
|
||||
public const int EntitySnapshotSize = sizeof(uint) + sizeof(byte) + (sizeof(float) * 3) + sizeof(uint);
|
||||
|
||||
/// <summary>Bytes of the snapshot header: message type + tick + entity count.</summary>
|
||||
public const int SnapshotHeaderSize = sizeof(byte) + sizeof(uint) + sizeof(ushort);
|
||||
|
||||
/// <summary>Maximum UTF-8 byte length of a player name.</summary>
|
||||
public const int MaxPlayerNameBytes = 32;
|
||||
}
|
||||
namespace HSchool.Protocol;
|
||||
|
||||
/// <summary>Wire-format constants shared by the server and the browser client.</summary>
|
||||
public static class ProtocolConstants
|
||||
{
|
||||
/// <summary>Bumped on every breaking change to the binary layout.</summary>
|
||||
public const byte Version = 3;
|
||||
|
||||
/// <summary>Upper bound for a single WebSocket frame accepted by the server.</summary>
|
||||
public const int MaxMessageSize = 8 * 1024;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user