From d4caab4a1644549107626c884bedf3ad8ae2bb40 Mon Sep 17 00:00:00 2001 From: tinyhoot <78366332+tinyhoot@users.noreply.github.com> Date: Sat, 17 Feb 2024 10:13:13 +0100 Subject: [PATCH] Fix #4: Island food is properly grabbable. --- DeathrunRemade/Patches/FoodChallengePatcher.cs | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/DeathrunRemade/Patches/FoodChallengePatcher.cs b/DeathrunRemade/Patches/FoodChallengePatcher.cs index 0a3a141..3c69908 100644 --- a/DeathrunRemade/Patches/FoodChallengePatcher.cs +++ b/DeathrunRemade/Patches/FoodChallengePatcher.cs @@ -83,7 +83,8 @@ private static void ChangeFoodValues(Eatable __instance, ref float __result) [HarmonyPatch(typeof(Knife), nameof(Knife.GiveResourceOnDamage))] private static bool CancelKnifeHarvest(GameObject target) { - return AllowPickup(target); + bool allowed = AllowPickup(target); + return allowed; } /// @@ -139,7 +140,7 @@ private static bool AllowPickup(GameObject gameObject) return false; // Both remaining config options are covered with this check. - return RadiationPatcher.IsSurfaceIrradiated(); + return !RadiationPatcher.IsSurfaceIrradiated(); } } } \ No newline at end of file