Store job/shop values and vehicle switch states for late joiners (2.9.2)
WorldVars and VehicleControls were only relayed; players joining later only got them with the next save pull. They are now stored in world.json (cleared with a new save) and appended to the world snapshot (old clients ignore it). Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
@@ -448,6 +448,8 @@ public sealed class GameServer
|
||||
case MsgType.MoneyDelta: world.ApplyMoney(m.Payload); break;
|
||||
case MsgType.DoorState: world.ApplyDoor(m.Payload); break;
|
||||
case MsgType.VarSync: world.ApplyVars(m.Payload); break;
|
||||
case MsgType.WorldVars: world.ApplyJobVars(m.Payload); break;
|
||||
case MsgType.VehicleControls: world.ApplyControls(m.Payload); break;
|
||||
case MsgType.SpawnItem:
|
||||
if (!c.IsAdmin) return; // nur Admins dürfen Items spawnen
|
||||
world.AddSpawn(m.Payload);
|
||||
|
||||
Reference in New Issue
Block a user