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 HarmonyLib; using Microsoft.CodeAnalysis; using Reptile; 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.2", FrameworkDisplayName = ".NET Framework 4.6.2")] [assembly: AssemblyCompany("HFMS")] [assembly: AssemblyConfiguration("Debug")] [assembly: AssemblyFileVersion("3.0.0.0")] [assembly: AssemblyInformationalVersion("3.0.0")] [assembly: AssemblyProduct("Haiders Freaky Movement Stuff")] [assembly: AssemblyTitle("HFMS")] [assembly: SecurityPermission(SecurityAction.RequestMinimum, SkipVerification = true)] [assembly: AssemblyVersion("3.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 HFMS { [HarmonyPatch(typeof(Player))] public class PlayerPatch { public static Player pp; private static float lastx; private static float lastz; private static Quaternion movdir; [HarmonyPostfix] [HarmonyPatch("LateUpdatePlayer")] public static void Postfix(Player __instance) { //IL_0019: Unknown result type (might be due to invalid IL or missing references) //IL_001e: Unknown result type (might be due to invalid IL or missing references) //IL_0032: Unknown result type (might be due to invalid IL or missing references) //IL_0037: Unknown result type (might be due to invalid IL or missing references) //IL_003c: Unknown result type (might be due to invalid IL or missing references) //IL_0056: Unknown result type (might be due to invalid IL or missing references) //IL_005b: Unknown result type (might be due to invalid IL or missing references) //IL_0074: Unknown result type (might be due to invalid IL or missing references) if (!__instance.isAI) { pp = __instance; if (pp.moveInput != Vector3.zero) { movdir = Quaternion.LookRotation(pp.moveInput); } if (Plugin.FreakMov2.Value && pp.moveInput != Vector3.zero) { pp.tf.rotation = movdir; } } } [HarmonyPostfix] [HarmonyPatch("FixedUpdatePlayer")] public static void Postfix1(Player __instance) { //IL_0016: Unknown result type (might be due to invalid IL or missing references) //IL_0032: Unknown result type (might be due to invalid IL or missing references) //IL_00b0: Unknown result type (might be due to invalid IL or missing references) //IL_00bf: Unknown result type (might be due to invalid IL or missing references) //IL_006e: Unknown result type (might be due to invalid IL or missing references) //IL_0087: Unknown result type (might be due to invalid IL or missing references) if (__instance.isAI) { return; } if (Input.GetKey(Plugin.CancelButton.Value)) { __instance.StopCurrentAbility(); } if (Input.GetKey(Plugin.LockUpButton.Value)) { if (lastx == 0f && lastz == 0f) { lastx = pp.tf.position.x; lastz = pp.tf.position.z; } pp.tf.position = new Vector3(lastx, pp.tf.position.y, lastz); } else { lastx = 0f; lastz = 0f; } } } [BepInPlugin("HFMS", "Haiders Freaky Movement Stuff", "3.0.0")] public class Plugin : BaseUnityPlugin { public static Harmony Harmony; public static Player p; public static ConfigEntry CancelButton; public static ConfigEntry LockUpButton; public static ConfigEntry FreakMov2; private void Awake() { //IL_0006: Unknown result type (might be due to invalid IL or missing references) //IL_0010: Expected O, but got Unknown Harmony = new Harmony("HFMS.Harmony"); Harmony.PatchAll(); Debug.Log((object)"hello world"); CancelButton = ((BaseUnityPlugin)this).Config.Bind("bindings", "Cancel Button", (KeyCode)0, "button to cancel the current ability"); LockUpButton = ((BaseUnityPlugin)this).Config.Bind("bindings", "Stay in Place Button", (KeyCode)0, "button to stop moving forward"); FreakMov2 = ((BaseUnityPlugin)this).Config.Bind("freaking", "FreakMov Two", false, "Characters rotation is the same as you movementinput rotation"); } private void Update() { } } public static class MyPluginInfo { public const string PLUGIN_GUID = "HFMS"; public const string PLUGIN_NAME = "Haiders Freaky Movement Stuff"; public const string PLUGIN_VERSION = "3.0.0"; } }