using System.Diagnostics;
using System.Reflection;
using System.Runtime.CompilerServices;
using System.Runtime.InteropServices;
using System.Runtime.Versioning;
using BepInEx;
using Configgy;
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("HardFPS")]
[assembly: AssemblyDescription("")]
[assembly: AssemblyConfiguration("")]
[assembly: AssemblyCompany("")]
[assembly: AssemblyProduct("HardFPS")]
[assembly: AssemblyCopyright("Copyright © 2025")]
[assembly: AssemblyTrademark("")]
[assembly: ComVisible(false)]
[assembly: Guid("88231d0a-98df-4511-ba9b-d9158bdc3eb3")]
[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 HardFPS;
[BepInPlugin("D1g1tal.HardFPS", "HardFPS", "1.0.0")]
public class HardFPSUKPlugin : BaseUnityPlugin
{
[Configgable("", "Mod enabled", 0, null)]
public static bool enab = true;
[Configgable("", "Minimum FPS", 0, null)]
public static int MinFPS = 5;
private void Awake()
{
//IL_0003: Unknown result type (might be due to invalid IL or missing references)
//IL_0009: Expected O, but got Unknown
ConfigBuilder val = new ConfigBuilder((string)null, (string)null);
val.BuildAll();
}
private void Update()
{
if (Application.isPlaying && enab && (Object)(object)MonoSingleton<NewMovement>.Instance != (Object)null)
{
NewMovement instance = MonoSingleton<NewMovement>.Instance;
int num = instance.hp;
if (num <= MinFPS)
{
num = MinFPS;
}
Application.targetFrameRate = num;
}
if (!enab)
{
Application.targetFrameRate = 0;
}
}
}