From af8e1bd6ca2f350123924fdf6c0e88a30b3ddb67 Mon Sep 17 00:00:00 2001 From: RMROC451 Date: Sun, 24 Aug 2025 20:25:44 -0500 Subject: [PATCH] Fix issue with inverted boolean and params out of order; version increment --- Assembly.version | 2 +- TweaksAndThings/Extensions/Car_Extensions.cs | 2 +- .../AutoEngineerOrdersHelper_SendAutoEngineerCommand_Patch.cs | 4 ++-- 3 files changed, 4 insertions(+), 4 deletions(-) diff --git a/Assembly.version b/Assembly.version index 5953cd0..df0e54f 100644 --- a/Assembly.version +++ b/Assembly.version @@ -2,6 +2,6 @@ 2 1 - 1 + 2 \ No newline at end of file diff --git a/TweaksAndThings/Extensions/Car_Extensions.cs b/TweaksAndThings/Extensions/Car_Extensions.cs index 21fc3e8..4865af5 100644 --- a/TweaksAndThings/Extensions/Car_Extensions.cs +++ b/TweaksAndThings/Extensions/Car_Extensions.cs @@ -108,7 +108,7 @@ public static class Car_Extensions private static Car? FindMyCaboose(this Car car, float timeNeeded, bool decrement = false, bool requireLoad = true) => ( car.CarCaboose() ?? car.CarsNearCurrentCar(timeNeeded, decrement).FindNearestCabooseFromNearbyCars() - )?.CabooseWithSufficientCrewHours(timeNeeded, decrement); + )?.CabooseWithSufficientCrewHours(timeNeeded: timeNeeded, requireLoad:requireLoad, decrement: decrement); public static Car? CabooseWithSufficientCrewHours(this Car car, float timeNeeded, bool requireLoad, bool decrement = false) { diff --git a/TweaksAndThings/Patches/AutoEngineerOrdersHelper_SendAutoEngineerCommand_Patch.cs b/TweaksAndThings/Patches/AutoEngineerOrdersHelper_SendAutoEngineerCommand_Patch.cs index 0f5ac19..9f84153 100644 --- a/TweaksAndThings/Patches/AutoEngineerOrdersHelper_SendAutoEngineerCommand_Patch.cs +++ b/TweaksAndThings/Patches/AutoEngineerOrdersHelper_SendAutoEngineerCommand_Patch.cs @@ -72,7 +72,7 @@ internal class AutoEngineerOrdersHelper_SendAutoEngineerCommand_Patch Func noCaboose = () => { - bool output = (bool)TrainController.Shared.SelectedLocomotive.FindMyCabooseSansLoadRequirement(); + bool output = TrainController.Shared.SelectedLocomotive.FindMyCabooseSansLoadRequirement() == null; logMessage += $"\ncaboose? {!output}"; return output; }; @@ -87,7 +87,7 @@ internal class AutoEngineerOrdersHelper_SendAutoEngineerCommand_Patch logMessage += $"\nGovern AE? {output}"; - _log.Debug(logMessage); + _log.Information(logMessage); return output; }