Decompiled source of FPS Boost REPO By JhonkiDS v1.2.0

FPSBooster.dll

Decompiled a week ago
using System;
using System.Collections;
using System.Diagnostics;
using System.Reflection;
using System.Runtime.CompilerServices;
using System.Runtime.Versioning;
using System.Security;
using System.Security.Permissions;
using BepInEx;
using BepInEx.Core.Logging.Interpolation;
using BepInEx.Logging;
using BepInEx.Unity.Mono;
using Microsoft.CodeAnalysis;
using UnityEngine;

[assembly: CompilationRelaxations(8)]
[assembly: RuntimeCompatibility(WrapNonExceptionThrows = true)]
[assembly: Debuggable(DebuggableAttribute.DebuggingModes.Default | DebuggableAttribute.DebuggingModes.DisableOptimizations | DebuggableAttribute.DebuggingModes.IgnoreSymbolStoreSequencePoints | DebuggableAttribute.DebuggingModes.EnableEditAndContinue)]
[assembly: TargetFramework(".NETFramework,Version=v4.6", FrameworkDisplayName = ".NET Framework 4.6")]
[assembly: AssemblyCompany("FPSBooster")]
[assembly: AssemblyConfiguration("Debug")]
[assembly: AssemblyFileVersion("1.0.0.0")]
[assembly: AssemblyInformationalVersion("1.0.0+3bb34374a92b6a3a43ac5ae0b013fe17a3504df8")]
[assembly: AssemblyProduct("FPSBooster")]
[assembly: AssemblyTitle("FPSBooster")]
[assembly: SecurityPermission(SecurityAction.RequestMinimum, SkipVerification = true)]
[assembly: AssemblyVersion("1.0.0.0")]
[module: UnverifiableCode]
[module: RefSafetyRules(11)]
namespace Microsoft.CodeAnalysis
{
	[CompilerGenerated]
	[Microsoft.CodeAnalysis.Embedded]
	internal sealed class EmbeddedAttribute : Attribute
	{
	}
}
namespace System.Runtime.CompilerServices
{
	[CompilerGenerated]
	[Microsoft.CodeAnalysis.Embedded]
	[AttributeUsage(AttributeTargets.Module, AllowMultiple = false, Inherited = false)]
	internal sealed class RefSafetyRulesAttribute : Attribute
	{
		public readonly int Version;

		public RefSafetyRulesAttribute(int P_0)
		{
			Version = P_0;
		}
	}
}
namespace FPSBooster
{
	[BepInPlugin("FPSBooster", "FPSBooster", "1.0.0")]
	public class Plugin : BaseUnityPlugin
	{
		internal static ManualLogSource Logger;

		private PostProcessingManager postProcessingManager;

		private void Awake()
		{
			//IL_0017: Unknown result type (might be due to invalid IL or missing references)
			//IL_001d: Expected O, but got Unknown
			Logger = ((BaseUnityPlugin)this).Logger;
			ManualLogSource logger = Logger;
			bool flag = default(bool);
			BepInExInfoLogInterpolatedStringHandler val = new BepInExInfoLogInterpolatedStringHandler(18, 1, ref flag);
			if (flag)
			{
				((BepInExLogInterpolatedStringHandler)val).AppendLiteral("Plugin ");
				((BepInExLogInterpolatedStringHandler)val).AppendFormatted<string>("FPSBooster");
				((BepInExLogInterpolatedStringHandler)val).AppendLiteral(" is loaded!");
			}
			logger.LogInfo(val);
			postProcessingManager = new PostProcessingManager(Logger);
			((MonoBehaviour)this).StartCoroutine(WaitForPlayerCoroutine());
		}

		private IEnumerator WaitForPlayerCoroutine()
		{
			while ((Object)(object)GameObject.FindGameObjectWithTag("Player") == (Object)null)
			{
				yield return null;
			}
			OptimizeGraphicsSettings();
			postProcessingManager.DisableEffects();
		}

		private void OptimizeGraphicsSettings()
		{
			QualitySettings.SetQualityLevel(0);
			Logger.LogInfo((object)"Graphics settings set to the lowest quality level.");
			QualitySettings.antiAliasing = 0;
			Logger.LogInfo((object)"Anti-aliasing disabled.");
			QualitySettings.shadowCascades = 0;
			Logger.LogInfo((object)"Shadow cascades disabled.");
			QualitySettings.shadows = (ShadowQuality)0;
			Logger.LogInfo((object)"All shadows disabled.");
			QualitySettings.masterTextureLimit = 3;
			Logger.LogInfo((object)"Texture resolution reduced.");
			QualitySettings.lodBias = 2f;
			Logger.LogInfo((object)"LOD bias increased for lower detail models.");
			QualitySettings.vSyncCount = 0;
			Application.targetFrameRate = 60;
			Logger.LogInfo((object)"V-Sync disabled and target frame rate set to 60.");
		}
	}
	public class PostProcessingManager
	{
		private ManualLogSource logger;

		public PostProcessingManager(ManualLogSource logger)
		{
			this.logger = logger;
		}

		public void DisableEffects()
		{
			CameraController[] array = Object.FindObjectsOfType<CameraController>(true);
			if (array.Length == 0)
			{
				logger.LogWarning((object)"No CameraController found in the scene.");
				return;
			}
			CameraController[] array2 = array;
			foreach (CameraController cameraController in array2)
			{
				DisableEffectByName(cameraController, "AntiAliasing");
				DisableEffectByName(cameraController, "Bloom");
				DisableEffectByName(cameraController, "DepthOfField");
			}
		}

		private void DisableEffectByName(CameraController cameraController, string effectName)
		{
			//IL_0087: Unknown result type (might be due to invalid IL or missing references)
			//IL_008e: Expected O, but got Unknown
			//IL_0042: Unknown result type (might be due to invalid IL or missing references)
			//IL_0049: Expected O, but got Unknown
			MonoBehaviour[] componentsInChildren = ((Component)cameraController).GetComponentsInChildren<MonoBehaviour>(true);
			MonoBehaviour[] array = componentsInChildren;
			bool flag = default(bool);
			foreach (MonoBehaviour val in array)
			{
				if (((object)val).GetType().Name == effectName)
				{
					((Behaviour)val).enabled = false;
					ManualLogSource val2 = logger;
					BepInExInfoLogInterpolatedStringHandler val3 = new BepInExInfoLogInterpolatedStringHandler(9, 1, ref flag);
					if (flag)
					{
						((BepInExLogInterpolatedStringHandler)val3).AppendLiteral("Disabled ");
						((BepInExLogInterpolatedStringHandler)val3).AppendFormatted<string>(effectName);
					}
					val2.LogInfo(val3);
					return;
				}
			}
			ManualLogSource val4 = logger;
			BepInExWarningLogInterpolatedStringHandler val5 = new BepInExWarningLogInterpolatedStringHandler(41, 2, ref flag);
			if (flag)
			{
				((BepInExLogInterpolatedStringHandler)val5).AppendLiteral("No ");
				((BepInExLogInterpolatedStringHandler)val5).AppendFormatted<string>(effectName);
				((BepInExLogInterpolatedStringHandler)val5).AppendLiteral(" component found in CameraController: ");
				((BepInExLogInterpolatedStringHandler)val5).AppendFormatted<string>(((Object)cameraController).name);
			}
			val4.LogWarning(val5);
		}
	}
	public static class MyPluginInfo
	{
		public const string PLUGIN_GUID = "FPSBooster";

		public const string PLUGIN_NAME = "FPSBooster";

		public const string PLUGIN_VERSION = "1.0.0";
	}
}

RemoveCameraBob.dll

Decompiled a week ago
using System;
using System.Diagnostics;
using System.Reflection;
using System.Runtime.CompilerServices;
using System.Runtime.Versioning;
using System.Security;
using System.Security.Permissions;
using BepInEx;
using BepInEx.Configuration;
using BepInEx.Logging;
using HarmonyLib;
using Microsoft.CodeAnalysis;

[assembly: CompilationRelaxations(8)]
[assembly: RuntimeCompatibility(WrapNonExceptionThrows = true)]
[assembly: Debuggable(DebuggableAttribute.DebuggingModes.IgnoreSymbolStoreSequencePoints)]
[assembly: TargetFramework(".NETStandard,Version=v2.1", FrameworkDisplayName = ".NET Standard 2.1")]
[assembly: AssemblyCompany("RemoveCameraBob")]
[assembly: AssemblyConfiguration("Release")]
[assembly: AssemblyFileVersion("0.0.1.0")]
[assembly: AssemblyInformationalVersion("0.0.1")]
[assembly: AssemblyProduct("Remove Camera Bob")]
[assembly: AssemblyTitle("RemoveCameraBob")]
[assembly: SecurityPermission(SecurityAction.RequestMinimum, SkipVerification = true)]
[assembly: AssemblyVersion("0.0.1.0")]
[module: UnverifiableCode]
[module: RefSafetyRules(11)]
namespace Microsoft.CodeAnalysis
{
	[CompilerGenerated]
	[Microsoft.CodeAnalysis.Embedded]
	internal sealed class EmbeddedAttribute : Attribute
	{
	}
}
namespace System.Runtime.CompilerServices
{
	[CompilerGenerated]
	[Microsoft.CodeAnalysis.Embedded]
	[AttributeUsage(AttributeTargets.Module, AllowMultiple = false, Inherited = false)]
	internal sealed class RefSafetyRulesAttribute : Attribute
	{
		public readonly int Version;

		public RefSafetyRulesAttribute(int P_0)
		{
			Version = P_0;
		}
	}
}
namespace RemoveCameraBob
{
	[HarmonyPatch(typeof(CameraBob))]
	internal class CameraBobPatches
	{
		[HarmonyPrefix]
		[HarmonyPatch("Update")]
		private static bool Update(CameraBob __instance)
		{
			if (Plugin.DisableCameraBob.Value)
			{
				__instance.bobUpLerpStrength = 0f;
				__instance.bobSideLerpStrength = 0f;
			}
			return true;
		}
	}
	[HarmonyPatch(typeof(CameraTilt))]
	internal class CameraTiltPatches
	{
		[HarmonyPrefix]
		[HarmonyPatch("Update")]
		private static bool Update(CameraTilt __instance)
		{
			if (Plugin.DisableCameraTilt.Value)
			{
				__instance.tiltX = 0f;
				__instance.tiltZ = 0f;
				__instance.tiltXMax = 0f;
				__instance.tiltZMax = 0f;
			}
			return true;
		}
	}
	[HarmonyPatch(typeof(CameraNoise))]
	internal class CameraNoisePatches
	{
		[HarmonyPrefix]
		[HarmonyPatch("Update")]
		private static bool Update(CameraNoise __instance)
		{
			if (Plugin.DisableCameraNoise.Value)
			{
				__instance.StrengthDefault = 0f;
			}
			return true;
		}
	}
	[HarmonyPatch(typeof(FlashlightBob))]
	internal class FlashlightPatches
	{
		[HarmonyPrefix]
		[HarmonyPatch("Update")]
		private static bool Update(FlashlightBob __instance)
		{
			if (Plugin.DisableFlashlightTilt.Value)
			{
				return false;
			}
			return true;
		}
	}
	[HarmonyPatch(typeof(FlashlightTilt))]
	internal class FlashlightTiltPatches
	{
		[HarmonyPrefix]
		[HarmonyPatch("Update")]
		private static bool Update(FlashlightTilt __instance)
		{
			if (Plugin.DisableFlashlightTilt.Value)
			{
				return false;
			}
			return true;
		}
	}
	[BepInPlugin("RemoveCameraBob", "Remove Camera Bob", "0.0.1")]
	public class Plugin : BaseUnityPlugin
	{
		public static Plugin Instance;

		internal static ManualLogSource Log;

		public static ConfigEntry<bool> DisableCameraBob;

		public static ConfigEntry<bool> DisableCameraTilt;

		public static ConfigEntry<bool> DisableFlashlightTilt;

		public static ConfigEntry<bool> DisableCameraNoise;

		private void Awake()
		{
			Instance = this;
			Log = ((BaseUnityPlugin)this).Logger;
			DisableCameraBob = ((BaseUnityPlugin)this).Config.Bind<bool>("General", "DisableCameraBob", true, "Disable camera bobbing.");
			DisableCameraTilt = ((BaseUnityPlugin)this).Config.Bind<bool>("General", "DisableCameraTilt", true, "Disable camera tilting.");
			DisableFlashlightTilt = ((BaseUnityPlugin)this).Config.Bind<bool>("General", "DisableFlashlightTilt", true, "Disable flashlight tilting.");
			DisableCameraNoise = ((BaseUnityPlugin)this).Config.Bind<bool>("General", "DisableCameraNoise", true, "Disable camera noise.");
			Log.LogInfo((object)"Plugin RemoveCameraBob is loaded!");
			Harmony.CreateAndPatchAll(typeof(Plugin), (string)null);
			Harmony.CreateAndPatchAll(typeof(CameraBobPatches), (string)null);
			Harmony.CreateAndPatchAll(typeof(CameraTiltPatches), (string)null);
			Harmony.CreateAndPatchAll(typeof(CameraNoisePatches), (string)null);
			Harmony.CreateAndPatchAll(typeof(FlashlightPatches), (string)null);
			Harmony.CreateAndPatchAll(typeof(FlashlightTiltPatches), (string)null);
		}
	}
	public static class MyPluginInfo
	{
		public const string PLUGIN_GUID = "RemoveCameraBob";

		public const string PLUGIN_NAME = "Remove Camera Bob";

		public const string PLUGIN_VERSION = "0.0.1";
	}
}

REPO_HD.dll

Decompiled a week ago
using System.Diagnostics;
using System.Reflection;
using System.Runtime.CompilerServices;
using System.Runtime.Versioning;
using BepInEx;
using BepInEx.Configuration;
using UnityEngine;

[assembly: CompilationRelaxations(8)]
[assembly: RuntimeCompatibility(WrapNonExceptionThrows = true)]
[assembly: Debuggable(DebuggableAttribute.DebuggingModes.IgnoreSymbolStoreSequencePoints)]
[assembly: TargetFramework(".NETFramework,Version=v4.8", FrameworkDisplayName = ".NET Framework 4.8")]
[assembly: AssemblyCompany("REPO_HD")]
[assembly: AssemblyConfiguration("Release")]
[assembly: AssemblyFileVersion("1.0.0.0")]
[assembly: AssemblyInformationalVersion("1.0.0")]
[assembly: AssemblyProduct("REPO_HD")]
[assembly: AssemblyTitle("REPO_HD")]
[assembly: AssemblyVersion("1.0.0.0")]
namespace REPO_HD;

[BepInPlugin("com.darkangel.repohd", "REPO_HD", "1.0.0")]
public class GraphicsMod : BaseUnityPlugin
{
	private ConfigEntry<float> resolutionScale;

	private ConfigEntry<int> textureQuality;

	private ConfigEntry<int> antiAliasing;

	private ConfigEntry<bool> enableVSync;

	private ConfigEntry<int> shadowQuality;

	private ConfigEntry<int> shadowResolution;

	private ConfigEntry<float> shadowDistance;

	private ConfigEntry<int> anisotropicFiltering;

	private ConfigEntry<bool> softParticles;

	private ConfigEntry<bool> realtimeReflectionProbes;

	private ConfigEntry<bool> billboardsFaceCamera;

	private void Awake()
	{
		resolutionScale = ((BaseUnityPlugin)this).Config.Bind<float>("Graphics", "Resolution Scale", 0.1f, "Scales the render resolution (0.5 to 2.0).");
		textureQuality = ((BaseUnityPlugin)this).Config.Bind<int>("Graphics", "Texture Quality", 0, "Texture quality level (0 = Low, 1 = Medium, 2 = High).");
		antiAliasing = ((BaseUnityPlugin)this).Config.Bind<int>("Graphics", "Anti-Aliasing", 0, "Anti-aliasing level (0 = Off, 1 = 2x, 2 = 4x, 3 = 8x).");
		enableVSync = ((BaseUnityPlugin)this).Config.Bind<bool>("Graphics", "Enable VSync", false, "Enable or disable VSync.");
		shadowQuality = ((BaseUnityPlugin)this).Config.Bind<int>("Shadows", "Shadow Quality", 0, "Shadow quality level (0 = Disabled, 1 = Hard Only, 2 = Hard and Soft).");
		shadowResolution = ((BaseUnityPlugin)this).Config.Bind<int>("Shadows", "Shadow Resolution", 0, "Shadow resolution level (0 = Low, 1 = Medium, 2 = High, 3 = Very High).");
		shadowDistance = ((BaseUnityPlugin)this).Config.Bind<float>("Shadows", "Shadow Distance", 0f, "Maximum shadow drawing distance.");
		anisotropicFiltering = ((BaseUnityPlugin)this).Config.Bind<int>("Textures", "Anisotropic Filtering", 0, "Anisotropic filtering level (0 = Disabled, 1 = Enabled, 2 = Force Enable).");
		softParticles = ((BaseUnityPlugin)this).Config.Bind<bool>("Effects", "Soft Particles", false, "Enable or disable soft particles.");
		realtimeReflectionProbes = ((BaseUnityPlugin)this).Config.Bind<bool>("Lighting", "Realtime Reflection Probes", false, "Enable or disable realtime reflection probes.");
		billboardsFaceCamera = ((BaseUnityPlugin)this).Config.Bind<bool>("Rendering", "Billboards Face Camera", false, "Enable or disable billboards facing the camera.");
		ApplyGraphicsSettings();
	}

	private void ApplyGraphicsSettings()
	{
		int num = 768;
		Screen.SetResolution((int)(1366f * resolutionScale.Value), (int)((float)num * resolutionScale.Value), Screen.fullScreen);
		QualitySettings.globalTextureMipmapLimit = 3 - textureQuality.Value;
		QualitySettings.antiAliasing = antiAliasing.Value switch
		{
			0 => 0, 
			1 => 2, 
			2 => 4, 
			3 => 8, 
			_ => 2, 
		};
		QualitySettings.vSyncCount = (enableVSync.Value ? 1 : 0);
		QualitySettings.shadows = (ShadowQuality)shadowQuality.Value;
		QualitySettings.shadowResolution = (ShadowResolution)shadowResolution.Value;
		QualitySettings.shadowDistance = shadowDistance.Value;
		QualitySettings.anisotropicFiltering = (AnisotropicFiltering)anisotropicFiltering.Value;
		QualitySettings.softParticles = softParticles.Value;
		QualitySettings.realtimeReflectionProbes = realtimeReflectionProbes.Value;
		QualitySettings.billboardsFaceCameraPosition = billboardsFaceCamera.Value;
		((BaseUnityPlugin)this).Logger.LogInfo((object)"Graphics settings applied!");
	}
}