using System.Diagnostics;
using System.Reflection;
using System.Runtime.CompilerServices;
using System.Runtime.InteropServices;
using System.Runtime.Versioning;
using BepInEx;
using BepInEx.Logging;
using Diversity;
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("Addranor_LethalMods")]
[assembly: AssemblyDescription("")]
[assembly: AssemblyConfiguration("")]
[assembly: AssemblyCompany("")]
[assembly: AssemblyProduct("Addranor_LethalMods")]
[assembly: AssemblyCopyright("Copyright © 2024")]
[assembly: AssemblyTrademark("")]
[assembly: ComVisible(false)]
[assembly: Guid("618bb71b-6c52-47ac-b69f-b692dcdbf318")]
[assembly: AssemblyFileVersion("1.0.0.0")]
[assembly: TargetFramework(".NETFramework,Version=v4.8", FrameworkDisplayName = ".NET Framework 4.8")]
[assembly: AssemblyVersion("1.0.0.0")]
namespace Addranor_LethalMods;
[BepInPlugin("AddranorLive-Addranor_LethalMods", "Addranor_LethalMods", "0.0.1.0")]
public class Plugin : BaseUnityPlugin
{
internal const string modGUID = "AddranorLive-Addranor_LethalMods";
internal const string modName = "Addranor_LethalMods";
internal const string modVersion = "0.0.1.0";
internal readonly Harmony harmony = new Harmony("AddranorLive-Addranor_LethalMods");
internal static ManualLogSource Logger;
internal static Plugin Instance;
private void Awake()
{
if ((Object)(object)Instance == (Object)null)
{
Instance = this;
}
Logger = ((BaseUnityPlugin)this).Logger;
harmony.PatchAll(typeof(PlayerControllerB_Patch));
}
}
public class PlayerControllerB_Patch
{
private static bool fullDarknessFixed;
[HarmonyPatch(typeof(PlayerControllerB), "Update")]
[HarmonyPostfix]
private static void FullDarknessPatch(PlayerControllerB __instance)
{
if (Configuration.fullDarkness.Value)
{
__instance.nightVision.intensity = 366.9317f;
}
}
}