From 16149a3087e33637e0f78a41697c0385d30f2d9e Mon Sep 17 00:00:00 2001 From: mar Date: Mon, 3 Jun 2024 16:37:01 -0400 Subject: [PATCH 1/2] update gitignore --- .gitignore | 1 + 1 file changed, 1 insertion(+) diff --git a/.gitignore b/.gitignore index 94f782a..8748f93 100644 --- a/.gitignore +++ b/.gitignore @@ -1,5 +1,6 @@ /.idea/ /.vs/ +/.vscode/ packages Releases **/bin From ba4e58502a21e203e61a56fc52dbd24e70dd2bd1 Mon Sep 17 00:00:00 2001 From: mar Date: Tue, 11 Jun 2024 13:49:49 -0400 Subject: [PATCH 2/2] fix not being able to craft stuff without enough power in creative --- DeathrunRemade/Patches/PowerPatcher.cs | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/DeathrunRemade/Patches/PowerPatcher.cs b/DeathrunRemade/Patches/PowerPatcher.cs index 68cae43..3b7a765 100644 --- a/DeathrunRemade/Patches/PowerPatcher.cs +++ b/DeathrunRemade/Patches/PowerPatcher.cs @@ -70,8 +70,8 @@ private static void ModifySolarPanelRecharge(SolarPanel __instance, ref float __ [HarmonyPatch(typeof(CrafterLogic), nameof(CrafterLogic.ConsumeEnergy))] private static bool PreventFabricatorConsumption(PowerRelay powerRelay, float amount, ref bool __result) { - // Don't do anything when NoCost cheat is active. - if (GameModeUtils.IsCheatActive(GameModeOption.NoCost)) + // Don't do anything when NoCost cheat is active or game mode is creative. + if (GameModeUtils.IsCheatActive(GameModeOption.NoCost) || (GameModeUtils.currentGameMode == GameModeOption.Creative)) return true; amount = ModifyConsumeEnergy(amount, IsInRadiation(powerRelay));