feat: expand multiplayer, chat, and release support

- add network NPC synchronization and dialogue interactions
- add world bulletin publishing and display
- improve authentication, session refresh, and appearance sync
- synchronize player direction and movement animations
- improve input focus and progressive Web loading
- add macOS/Windows builds and deployment configuration
- include required fonts, shaders, and runtime assets
This commit is contained in:
2026-09-08 21:37:43 +08:00
parent 175621f66c
commit fc6c3c1bd3
87 changed files with 4546 additions and 506 deletions

24
deploy/Caddyfile.example Normal file
View File

@@ -0,0 +1,24 @@
whaletown.novamailio.com {
root * /var/www/whale-town-front-v2/build/site
@playWithoutSlash path /play
@wasm path *.wasm
@pack path *.pck
redir @playWithoutSlash /play/ 308
handle_path /play/* {
root * /var/www/whale-town-front-v2/build/site/play
header @wasm Content-Type application/wasm
header @pack Content-Type application/octet-stream
file_server
}
handle /downloads/* {
header Content-Disposition "attachment"
file_server
}
handle {
file_server
}
}

129
deploy/Caddyfile.production Normal file
View File

@@ -0,0 +1,129 @@
# Existing Sub2API and blog sites on the Singapore host.
api.novamailio.com {
@long_stream path /v1/responses /responses
handle @long_stream {
reverse_proxy 127.0.0.1:8080 {
flush_interval -1
stream_close_delay 5m
transport http {
keepalive 30s
keepalive_interval 15s
keepalive_idle_conns_per_host 128
}
}
}
handle {
reverse_proxy 127.0.0.1:8080
}
}
xiangking.novamailio.com {
root * /var/www/xiangking-blog
encode zstd gzip
@assets path /assets/*
header @assets Cache-Control "public, max-age=31536000, immutable"
file_server
}
whaletown.novamailio.com {
log {
output file /var/log/caddy/whaletown-access.json {
roll_size 100MiB
roll_keep 10
roll_keep_for 720h
}
format json
}
encode zstd gzip
root * /var/www/whaletown/site
header {
X-Content-Type-Options nosniff
Referrer-Policy strict-origin-when-cross-origin
}
@immutable_pack {
path /play/packs/*.pck
file {path}
}
header @immutable_pack {
Cache-Control "public, max-age=31536000, immutable"
Content-Type "application/octet-stream"
}
@immutable_admin path /admin/assets/*
header @immutable_admin Cache-Control "public, max-age=31536000, immutable"
@pack_manifest path /play/packs/manifest.json
header @pack_manifest Cache-Control "no-cache"
@runtime path /play/index.js /play/index.wasm /play/index-*.pck /play/index.audio*.js
header @runtime Cache-Control "public, max-age=14400"
@html path / /index.html /play /play/ /play/index.html /admin /admin/ /admin/index.html
header @html Cache-Control "no-cache"
@play_without_slash path /play
redir @play_without_slash /play/ 308
handle_path /play/* {
root * /var/www/whaletown/site/play
file_server
}
@game path /game*
handle @game {
reverse_proxy http://124.221.77.216 {
header_up Host 124.221.77.216
}
}
@location path /location-broadcast
handle @location {
reverse_proxy http://124.221.77.216 {
header_up Host 124.221.77.216
}
}
@notice path /ws/notice
handle @notice {
reverse_proxy http://124.221.77.216 {
header_up Host 124.221.77.216
}
}
@account_assets path /assets/account/*
handle @account_assets {
reverse_proxy http://124.221.77.216 {
header_up Host 124.221.77.216
}
}
redir /api /api/
handle /api/* {
reverse_proxy http://124.221.77.216 {
header_up Host 124.221.77.216
}
}
redir /admin /admin/
handle_path /admin/* {
root * /var/www/whaletown/admin
try_files {path} /index.html
file_server
}
handle /downloads/* {
header Content-Disposition "attachment"
file_server
}
handle {
file_server
}
}

View File

@@ -0,0 +1,89 @@
whaletown.novamailio.com {
log {
output file /var/log/caddy/whaletown-access.json {
roll_size 20MiB
roll_keep 5
roll_keep_for 168h
}
format json
}
encode zstd gzip
root * /var/www/whaletown/site
header {
X-Content-Type-Options nosniff
Referrer-Policy strict-origin-when-cross-origin
}
@play path /play/*
header @play {
Cross-Origin-Opener-Policy same-origin
Cross-Origin-Embedder-Policy require-corp
}
@immutable_pack {
path /play/packs/*.pck
file {path}
}
header @immutable_pack {
Cache-Control "public, max-age=31536000, immutable"
Content-Type "application/octet-stream"
}
@pack_manifest path /play/packs/manifest.json
header @pack_manifest Cache-Control "no-cache"
@runtime path /play/index.js /play/index.wasm /play/index-*.pck /play/index.audio*.js
header @runtime Cache-Control "public, max-age=14400"
@html path / /index.html /play /play/ /play/index.html
header @html Cache-Control "no-cache"
@play_without_slash path /play
redir @play_without_slash /play/ 308
handle_path /play/* {
root * /var/www/whaletown/site/play
file_server
}
@game path /game*
handle @game {
reverse_proxy http://124.221.77.216 {
header_up Host 124.221.77.216
}
}
@location path /location-broadcast
handle @location {
reverse_proxy http://124.221.77.216 {
header_up Host 124.221.77.216
}
}
@notice path /ws/notice
handle @notice {
reverse_proxy http://124.221.77.216 {
header_up Host 124.221.77.216
}
}
@account_assets path /assets/account/*
handle @account_assets {
reverse_proxy http://124.221.77.216 {
header_up Host 124.221.77.216
}
}
redir /api /api/
handle /api/* {
reverse_proxy http://124.221.77.216 {
header_up Host 124.221.77.216
}
}
handle {
file_server
}
}

View File

@@ -0,0 +1,89 @@
162-251-94-42.sslip.io {
log {
output file /var/log/caddy/whaletown-access.json {
roll_size 20MiB
roll_keep 5
roll_keep_for 168h
}
format json
}
encode zstd gzip
root * /var/www/whaletown/site
header {
X-Content-Type-Options nosniff
Referrer-Policy strict-origin-when-cross-origin
}
@play path /play/*
header @play {
Cross-Origin-Opener-Policy same-origin
Cross-Origin-Embedder-Policy require-corp
}
@immutable_pack {
path /play/packs/*.pck
file {path}
}
header @immutable_pack {
Cache-Control "public, max-age=31536000, immutable"
Content-Type "application/octet-stream"
}
@pack_manifest path /play/packs/manifest.json
header @pack_manifest Cache-Control "no-cache"
@runtime path /play/index.js /play/index.wasm /play/index-*.pck /play/index.audio*.js
header @runtime Cache-Control "public, max-age=14400"
@html path / /index.html /play /play/ /play/index.html
header @html Cache-Control "no-cache"
@play_without_slash path /play
redir @play_without_slash /play/ 308
handle_path /play/* {
root * /var/www/whaletown/site/play
file_server
}
@game path /game*
handle @game {
reverse_proxy http://124.221.77.216 {
header_up Host 124.221.77.216
}
}
@location path /location-broadcast
handle @location {
reverse_proxy http://124.221.77.216 {
header_up Host 124.221.77.216
}
}
@notice path /ws/notice
handle @notice {
reverse_proxy http://124.221.77.216 {
header_up Host 124.221.77.216
}
}
@account_assets path /assets/account/*
handle @account_assets {
reverse_proxy http://124.221.77.216 {
header_up Host 124.221.77.216
}
}
redir /api /api/
handle /api/* {
reverse_proxy http://124.221.77.216 {
header_up Host 124.221.77.216
}
}
handle {
file_server
}
}

View File

@@ -1,6 +1,6 @@
server {
listen 80;
server_name whaletown.xinghangee.icu;
server_name whaletown.novamailio.com;
root /var/www/whale-town-front-v2/build/web;
index index.html;