Hello, I have been making a vehicle from scratch with server authority in mind and have found multiple bugs with the current implementation, with one being game breaking. Here is the place file where you can try out the chassis and test each bug: Server-Authoritive-Vehicle-Place.rbxl (101.5 KB)
To test the vehicle with server authority disabled, open ReplicatedStorage.CarSystem.CarSystemServer, jump to the onOccupantChanged function, then comment out the start/stop lines and uncomment the SetNetworkOwner line.
VectorForce instances causing levitation in live servers
The chassis runs under the realistic units provided from this webpage, specifically the provided gravity, weight and torque values. This works great, however changing Workspace.Gravity is not ideal because it affects character physics as well, so what the chassis does is instead make a VectorForce on every assembly to compensate, with the final result being the chassis’s physics behaving the same as if Workspace.Gravity was set to 35.
The bug I found occurs with server authority and in live servers only. When joining a game with these forces, the car floats up into the air, then is brought back down, then goes back up, repeating forever.
Prediction cannot handle moving attachments
The vehicle steers by changing an attachments orientation to a desired angle. The attachment is used as the top attachment for a SpringConstraint and a CylindricalConstraint. This method works great with SetNetworkOwner however it does not with Server Authorities prediction. This is not caused by input delay and you can confirm that by setting SteerTime to a longer number.
Pre-spawned vehicles appear in different locations in new public servers
In the test place provided, I have had multiple (albeit rare) cases where I spawned in, only to find the cars I positioned by spawn to be in a different place, maybe they somehow got flung there during server creation?
Getting out of a car sometimes lets you see the void for a split second
This one is pretty self explanatory.