Adapted for web

This commit is contained in:
Vladislav Khorev committed 2026-11-09 17:20:04 +06:00
commit 3fe21230cc
20 files changed
+241 -72

No files matched your search

+6 -4
View File
@@ -135,17 +135,19 @@ excluded from the diagnostic deterministic hash.
## Build Configuration
Networking is enabled only for Windows:
Networking is enabled for Windows and the Emscripten web client:
- `proj-windows/CMakeLists.txt` defines `NETWORK`, compiles the WebSocket client
and remote host, and links `ws2_32` and `mswsock`.
- `server/CMakeLists.txt` defines `NETWORK` for the Windows `GameServer`, compiles
the WebSocket server, and links the Windows socket libraries.
- Linux, Android, and Web builds do not define `NETWORK` and do not compile the
- `proj-web/CMakeLists.txt` defines `NETWORK`, compiles the shared protocol,
replica, and remote-host code, and links Emscripten's `websocket.js` library.
`WebsocketGameClient.cpp` selects the browser WebSocket API on Emscripten; it
does not use Boost.Asio or Boost.Beast there.
- Linux and Android builds do not define `NETWORK` and do not compile the
network transport.
The previous Web-build `NETWORK` definition was removed.
## Running
Build the server: