new-horizons/NewHorizons/Patches/BrambleProjectionFixPatches.cs
Nick c114e75297 Revert "Reorganize"
This reverts commit 27f4222702e2e75e0c782b3f8162f3a38eddcb64.
2024-03-22 17:06:31 -04:00

27 lines
769 B
C#

using HarmonyLib;
namespace NewHorizons.Patches;
/// <summary>
/// Bug fix from the Outsider
/// </summary>
[HarmonyPatch]
internal class BrambleProjectionFixPatches
{
[HarmonyPrefix]
[HarmonyPatch(typeof(FogWarpVolume), nameof(FogWarpVolume.WarpDetector))]
public static bool FogWarpVolume_WarpDetector()
{
// Do not warp the player if they have entered the fog via a projection
return !PlayerState.UsingNomaiRemoteCamera();
}
[HarmonyPrefix]
[HarmonyPatch(typeof(FogWarpDetector), nameof(FogWarpDetector.FixedUpdate))]
public static bool FogWarpDetector_FixedUpdate()
{
// Do not warp the player if they have entered the fog via a projection
return !PlayerState.UsingNomaiRemoteCamera();
}
}