mirror of
https://github.com/rmroc451/TweaksAndThings.git
synced 2025-12-16 01:09:38 -06:00
one more of the ill fated traincontroller shared usages while on host processing.
This commit is contained in:
@@ -34,8 +34,7 @@ internal class AutoEngineerPlanner_HandleCommand_Patch
|
||||
{
|
||||
TweaksAndThingsPlugin tweaksAndThings = SingletonPluginBase<TweaksAndThingsPlugin>.Shared;
|
||||
if (!tweaksAndThings.IsEnabled() || !tweaksAndThings.SafetyFirst() || (sender.IsRemote && !tweaksAndThings.SafetyFirstClientEnforce()) || command.MaxSpeedMph <= governedSpeed) return true;
|
||||
BaseLocomotive loco = TrainController.Shared.SelectedLocomotive;
|
||||
if (TrainController.Shared.TryGetCarForId(command.LocomotiveId, out Car c)) loco = (BaseLocomotive)c;
|
||||
BaseLocomotive loco = __instance._locomotive;
|
||||
|
||||
if (SafetyFirstGoverningApplies(loco))
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user