Open drNovikov opened 8 years ago
Tested /gc fleet stop on my PC, and it seemed to work (unlike the server). Stopped the ship instantly.
Logged on again, the issue is reproduceable. Ship did not stop with thrusters off, while on my local PC it stopped instantly (seemed to flicker the thrusters for a split second, but not enough to decelerate the ship).
The code that does this is right here: https://github.com/stackcollision/GardenConquest/blob/0a22c8cb4027c5c051d8c719b70869879b68ca62/Data/Scripts/GardenConquest/Messaging/RequestProcessor.cs#L145
It sounds like gridToStop.Physics.ClearSpeed();
is failing to propagate the stop to the clients. We should probably look for a way to fix this, but yes if we force thrusters on (and the grid is powered), that should stop this problem, since thruster sync seems to work pretty well.
It also sounds like we need to set an override on gyrscopes to stop things from rotating.
If it fails to propagate the message to the clients, does this mean the server and the clients have different speeds and positions of the ship?
Submitted a pull request that:
Tested it on my local PC, works as expected.
If it fails to propagate the message to the clients, does this mean the server and the clients have different speeds and positions of the ship?
Very likely yes.
Submitted a pull request
Thank you!!!!
If very likely yes, than it's potentially destructive!
I decided to investigate other player's report on misbehaving /gc fleet stop and tried to see how it works myself.
Just tested this on my B.O.B. while sitting in its cockpit. /gc fleet stop turned on inertial dampeners but did not turn on thrusters, which, of course, did not effectively stop the ship.
I'd suggest turning on thrusters and disabling all overrides (same with gyroscopes), like I do in my "Emergency Stop" script here: http://steamcommunity.com/sharedfiles/filedetails/?id=515022499