mirror of
https://github.com/openfrontio/OpenFrontIO.git
synced 2026-06-21 13:40:46 +00:00
1dd00f6264
Terrain was uploaded once at game start and treated as static — water nukes (land → water conversion) mutated the sim's terrain bytes but the rendered terrain stayed dry. Plumbed a delta path: TerrainPass and RailroadPass each get applyTerrainDelta(refs, bytes), Renderer + GameView forward, and WebGLFrameBuilder pushes each tick from gameView.recentlyUpdatedTerrainTiles(). Per-tile encoding is shared via the new encodeTerrainTile helper in ColorUtils so the startup full-map build and the per-tile delta updates can't drift.