17
0
mirror of https://github.com/MaSzyna-EU07/maszyna.git synced 2026-10-17 13:19:20 +02:00

multiplayer: the session imposes the settings that decide the physics

server_hello.config had been a TODO carrying a zero, and every peer ran with
whatever its own eu07.ini happened to say - including a vehicle physics thread
count, which makes the order vehicles are stepped in depend on how threads get
scheduled.

- the handshake now carries a bitfield of the settings that change how the
  physics comes out (full physics, realistic control) and a joining peer takes
  them on, saying in the log what changed
- a multiplayer session runs the vehicle physics on one thread on every peer,
  host included

Settings that only affect what a player sees or how comfortable the controls
feel stay with the player; only what alters the outcome belongs in here.
This commit is contained in:
2026-09-06 19:58:28 +00:00
parent 30fa68cfd8
commit 65159b9546
5 changed files with 58 additions and 2 deletions

View File

@@ -1578,6 +1578,9 @@ bool eu07_application::init_network()
// create network manager
m_network.emplace();
// settings a session cannot run without, whichever side we are on
network::enforce_session_settings();
// the host takes part in the session like any other peer, with an identity of its
// own, so that crew and permission handling needs no special case for it
if (!Global.network_client)