Skip to content

Synchronize building conditions from the host - #345

Open
macery12 wants to merge 1 commit into
CitiesSkylinesMultiplayer:masterfrom
macery12:Building-sync
Open

macery12 wants to merge 1 commit into
CitiesSkylinesMultiplayer:masterfrom
macery12:Building-sync

Conversation

@macery12

@macery12 macery12 commented Oct 9, 2026

Copy link
Copy Markdown

Summary

Clients can miss building fires or show different sickness counts and warning icons from the host. Correcting these differences currently requires a full /sync, which interrupts gameplay.

This PR makes the host authoritative for building conditions and keeps clients updated automatically, reducing the need for manual synchronization.

Changes

  • Synchronize building fire state, damage, warnings, and household health summaries.
  • Prevent client simulation from independently changing synchronized conditions.
  • Send changes in batches and periodically refresh state to correct divergence.
  • Reject stale updates after building replacement or save reloads, and require matching synchronization versions.
  • Add /building-sync for local diagnostics.

Validation

  • Release build successful.
  • All 16 regression groups pass.
  • In-game multiplayer validation completed successfully.

Reverse engineering assisted by GPT Sol 6.1 High.

Replicate fire state, building warnings and home health summaries in bounded
batches. Bind client snapshots to building lifetimes and reject mismatched
protocol versions to prevent stale or incompatible updates.

Keep host authority during client building simulation and reset caches on
connection and level transitions. Add local diagnostics and 16 regression
groups covering serialization, identity, recovery and patch target metadata.

Validation: Release build and all regression groups pass.
In-game multiplayer validation: user confirmed the preview works correctly.
@macery12

Copy link
Copy Markdown
Author

ci is failing prior to my changes

also should refrence #125 "The different errors/issues a building can have"

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant