Possibly fix vehicle eye bug (#11525)

This commit is contained in:
Leon Friedrich
2022-09-26 17:50:32 +13:00
committed by GitHub
parent 023d311125
commit 788dbda53d

View File

@@ -60,7 +60,9 @@ namespace Content.Client.Vehicle
private void OnRiderHandleState(EntityUid uid, RiderComponent component, ref ComponentHandleState args)
{
// Server should only be sending states for our entity.
if (uid != _playerManager.LocalPlayer?.ControlledEntity)
return;
if (args.Current is not RiderComponentState state) return;
component.Vehicle = state.Entity;