using System.Diagnostics;
using System.Reflection;
using System.Runtime.CompilerServices;
using System.Runtime.InteropServices;
using System.Runtime.Versioning;
using BepInEx;
using BepInEx.Logging;
using GameNetcodeStuff;
using HarmonyLib;
using UnityEngine;
[assembly: CompilationRelaxations(8)]
[assembly: RuntimeCompatibility(WrapNonExceptionThrows = true)]
[assembly: Debuggable(DebuggableAttribute.DebuggingModes.Default | DebuggableAttribute.DebuggingModes.DisableOptimizations | DebuggableAttribute.DebuggingModes.IgnoreSymbolStoreSequencePoints | DebuggableAttribute.DebuggingModes.EnableEditAndContinue)]
[assembly: AssemblyTitle("ReachForTheStars")]
[assembly: AssemblyDescription("")]
[assembly: AssemblyConfiguration("")]
[assembly: AssemblyCompany("")]
[assembly: AssemblyProduct("ReachForTheStars")]
[assembly: AssemblyCopyright("Copyright © 2024")]
[assembly: AssemblyTrademark("")]
[assembly: ComVisible(false)]
[assembly: Guid("46921f63-41fd-4eb6-8cc5-e5ca0e310d5d")]
[assembly: AssemblyFileVersion("1.0.0.0")]
[assembly: TargetFramework(".NETFramework,Version=v4.7.2", FrameworkDisplayName = ".NET Framework 4.7.2")]
[assembly: AssemblyVersion("1.0.0.0")]
namespace ReachForTheStars
{
[BepInPlugin("Juggernaut.ReachForTheStars", "ReachForTheStars", "1.0.0.0")]
public class ReachBase : BaseUnityPlugin
{
private const string modGUID = "Juggernaut.ReachForTheStars";
private const string modName = "ReachForTheStars";
private const string modVersion = "1.0.0.0";
private readonly Harmony harmony = new Harmony("Juggernaut.ReachForTheStars");
private static ReachBase Instance;
internal ManualLogSource mls;
private void Awake()
{
if ((Object)(object)Instance == (Object)null)
{
Instance = this;
}
mls = Logger.CreateLogSource("Juggernaut.ReachForTheStars");
mls.LogInfo((object)"Reach enabled :3");
harmony.PatchAll(Assembly.GetExecutingAssembly());
}
}
}
namespace ReachForTheStars.Patches2
{
[HarmonyPatch(typeof(PlayerControllerB))]
internal class PlayerControllerBPatch2
{
[HarmonyPatch(typeof(PlayerControllerB))]
internal class PlayerControllerPatch
{
[HarmonyPatch("Update")]
[HarmonyPostfix]
private static void ReachPatch(ref float ___grabDistance)
{
___grabDistance = float.PositiveInfinity;
}
}
[HarmonyPatch(typeof(PlayerControllerB))]
[HarmonyPatch("BeginGrabObject")]
internal class BeginGrabObjectPatch
{
[HarmonyPrefix]
private static bool Prefix(PlayerControllerB __instance)
{
return true;
}
}
private const float INFINITE_DISTANCE = float.PositiveInfinity;
}
}