Please disclose if any significant portion of your mod was created using AI tools by adding the 'AI Generated' category. Failing to do so may result in the mod being removed from Thunderstore.
Decompiled source of RailgunnerQOL v1.0.0
RailgunnerQOL.dll
Decompiled 10 months agousing System.Diagnostics; using System.Reflection; using System.Runtime.CompilerServices; using System.Runtime.Versioning; using System.Security; using System.Security.Permissions; using BepInEx; using EntityStates; using EntityStates.Railgunner.Backpack; using EntityStates.Railgunner.Reload; using On.EntityStates.Railgunner.Reload; using RoR2.Skills; using UnityEngine.AddressableAssets; [assembly: CompilationRelaxations(8)] [assembly: RuntimeCompatibility(WrapNonExceptionThrows = true)] [assembly: Debuggable(DebuggableAttribute.DebuggingModes.Default | DebuggableAttribute.DebuggingModes.DisableOptimizations | DebuggableAttribute.DebuggingModes.IgnoreSymbolStoreSequencePoints | DebuggableAttribute.DebuggingModes.EnableEditAndContinue)] [assembly: TargetFramework(".NETStandard,Version=v2.1", FrameworkDisplayName = "")] [assembly: AssemblyCompany("RailgunnerQOL")] [assembly: AssemblyConfiguration("Debug")] [assembly: AssemblyFileVersion("1.0.0.0")] [assembly: AssemblyInformationalVersion("1.0.0")] [assembly: AssemblyProduct("RailgunnerQOL")] [assembly: AssemblyTitle("RailgunnerQOL")] [assembly: SecurityPermission(SecurityAction.RequestMinimum, SkipVerification = true)] [assembly: AssemblyVersion("1.0.0.0")] [module: UnverifiableCode] namespace RailgunnerQOL; internal class Hook { internal static void Hooks() { //IL_0008: Unknown result type (might be due to invalid IL or missing references) //IL_0012: Expected O, but got Unknown //IL_001a: Unknown result type (might be due to invalid IL or missing references) //IL_0024: Expected O, but got Unknown //IL_002c: Unknown result type (might be due to invalid IL or missing references) //IL_0036: Expected O, but got Unknown Waiting.CanReload += new hook_CanReload(Waiting_CanReload); BoostConfirm.OnExit += new hook_OnExit(BoostConfirm_OnExit); Reloading.OnExit += new hook_OnExit(Reloading_OnExit); } private static void Reloading_OnExit(orig_OnExit orig, Reloading self) { orig.Invoke(self); if (!self.IsInBoostWindow()) { self.primarySkill.stock = ((EntityState)self).skillLocator.secondary.maxStock; } } private static void BoostConfirm_OnExit(orig_OnExit orig, BoostConfirm self) { orig.Invoke(self); self.primarySkill.stock = ((EntityState)self).skillLocator.secondary.maxStock; } private static bool Waiting_CanReload(orig_CanReload orig, Waiting self) { return (!(self.backpackStateMachine.state is Offline) && ((EntityState)self).skillLocator.primary.stock == 0) || self.scopeStateMachine.IsInMainState(); } } [BepInPlugin("com.Dragonyck.RailgunnerReloadQOL", "RailgunnerReloadQOL", "1.0.0")] public class MainPlugin : BaseUnityPlugin { public const string MODUID = "com.Dragonyck.RailgunnerReloadQOL"; public const string MODNAME = "RailgunnerReloadQOL"; public const string VERSION = "1.0.0"; private void Awake() { //IL_000c: Unknown result type (might be due to invalid IL or missing references) //IL_0011: Unknown result type (might be due to invalid IL or missing references) //IL_0024: Unknown result type (might be due to invalid IL or missing references) //IL_0029: Unknown result type (might be due to invalid IL or missing references) Hook.Hooks(); Addressables.LoadAssetAsync<SkillDef>((object)"RoR2/DLC1/Railgunner/RailgunnerBodyFireSnipeHeavy.asset").WaitForCompletion().mustKeyPress = false; Addressables.LoadAssetAsync<SkillDef>((object)"RoR2/DLC1/Railgunner/RailgunnerBodyFireSnipeLight.asset").WaitForCompletion().mustKeyPress = false; } }