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 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", FrameworkDisplayName = "")]
[assembly: AssemblyCompany("NoShoes")]
[assembly: AssemblyConfiguration("Debug")]
[assembly: AssemblyDescription("NO SHOEZ")]
[assembly: AssemblyFileVersion("4.2.0.0")]
[assembly: AssemblyInformationalVersion("4.2.0")]
[assembly: AssemblyProduct("NoShoes")]
[assembly: AssemblyTitle("NoShoes")]
[assembly: SecurityPermission(SecurityAction.RequestMinimum, SkipVerification = true)]
[assembly: AssemblyVersion("4.2.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 noshoes
{
[BepInPlugin("info.mariobluegloves.noshoes", "noshoes", "4.2.0")]
[BepInProcess("Bomb Rush Cyberfunk.exe")]
public class GriTAPatchNS
{
[HarmonyPatch(typeof(GrindAbility), "SetToLine")]
[HarmonyPrefix]
private static bool GriTAPatchPreFix(GrindAbility __instance, GrindLine setGrindLine)
{
//IL_0007: Unknown result type (might be due to invalid IL or missing references)
//IL_000d: Invalid comparison between Unknown and I4
//IL_00cc: Unknown result type (might be due to invalid IL or missing references)
//IL_00d2: Invalid comparison between Unknown and I4
//IL_00da: Unknown result type (might be due to invalid IL or missing references)
//IL_00e0: Invalid comparison between Unknown and I4
//IL_0119: Unknown result type (might be due to invalid IL or missing references)
//IL_011f: Invalid comparison between Unknown and I4
//IL_0155: Unknown result type (might be due to invalid IL or missing references)
//IL_015b: Invalid comparison between Unknown and I4
//IL_0194: Unknown result type (might be due to invalid IL or missing references)
//IL_0199: Unknown result type (might be due to invalid IL or missing references)
//IL_01bb: Unknown result type (might be due to invalid IL or missing references)
//IL_01c0: Unknown result type (might be due to invalid IL or missing references)
//IL_01c3: Unknown result type (might be due to invalid IL or missing references)
//IL_01d4: Unknown result type (might be due to invalid IL or missing references)
//IL_01ec: Unknown result type (might be due to invalid IL or missing references)
//IL_01ed: Unknown result type (might be due to invalid IL or missing references)
//IL_01f2: Unknown result type (might be due to invalid IL or missing references)
//IL_01ff: Unknown result type (might be due to invalid IL or missing references)
//IL_023e: Unknown result type (might be due to invalid IL or missing references)
//IL_022e: Unknown result type (might be due to invalid IL or missing references)
//IL_0230: Unknown result type (might be due to invalid IL or missing references)
//IL_0296: Unknown result type (might be due to invalid IL or missing references)
//IL_02b9: Unknown result type (might be due to invalid IL or missing references)
//IL_02f9: Unknown result type (might be due to invalid IL or missing references)
//IL_02fe: Unknown result type (might be due to invalid IL or missing references)
//IL_02ff: Unknown result type (might be due to invalid IL or missing references)
//IL_0301: Unknown result type (might be due to invalid IL or missing references)
//IL_0306: Unknown result type (might be due to invalid IL or missing references)
//IL_0308: Unknown result type (might be due to invalid IL or missing references)
//IL_0333: Unknown result type (might be due to invalid IL or missing references)
//IL_0335: Unknown result type (might be due to invalid IL or missing references)
//IL_033a: Unknown result type (might be due to invalid IL or missing references)
//IL_0381: Unknown result type (might be due to invalid IL or missing references)
//IL_0382: Unknown result type (might be due to invalid IL or missing references)
//IL_0387: Unknown result type (might be due to invalid IL or missing references)
//IL_038a: Unknown result type (might be due to invalid IL or missing references)
//IL_038c: Unknown result type (might be due to invalid IL or missing references)
//IL_0397: Unknown result type (might be due to invalid IL or missing references)
//IL_039a: Unknown result type (might be due to invalid IL or missing references)
//IL_039f: Unknown result type (might be due to invalid IL or missing references)
//IL_0358: Unknown result type (might be due to invalid IL or missing references)
//IL_0362: Unknown result type (might be due to invalid IL or missing references)
//IL_0367: Unknown result type (might be due to invalid IL or missing references)
//IL_036c: Unknown result type (might be due to invalid IL or missing references)
//IL_0371: Unknown result type (might be due to invalid IL or missing references)
//IL_0375: Unknown result type (might be due to invalid IL or missing references)
//IL_037a: Unknown result type (might be due to invalid IL or missing references)
if ((int)((Ability)__instance).p.moveStyle > 0)
{
__instance.timeSinceLastNode = 0f;
__instance.speedTarget = ((Ability)__instance).p.stats.grindSpeed;
bool flag = false;
if (!((Ability)__instance).p.usingEquippedMovestyle)
{
flag = true;
((Ability)__instance).p.SwitchToEquippedMovestyle(true, false, true, true);
}
__instance.speed = Mathf.Max(((Ability)__instance).p.boosting ? ((Ability)__instance).p.boostSpeed : ((Ability)__instance).p.stats.grindSpeed, ((Ability)__instance).p.GetForwardSpeed());
__instance.startTrickNames = __instance.trickingStartTrickNames;
__instance.trickNames = __instance.trickingTrickNames;
__instance.trickStandardDuration = __instance.trickingTrickDuration;
if ((int)((Ability)__instance).p.moveStyle == 2 || (int)((Ability)__instance).p.moveStyle == 4)
{
__instance.startTrickNames = __instance.skateboardStartTrickNames;
__instance.trickNames = __instance.skateboardTrickNames;
__instance.trickStandardDuration = __instance.skateboardTrickDuration;
}
else if ((int)((Ability)__instance).p.moveStyle == 3)
{
__instance.startTrickNames = __instance.inlineStartTrickNames;
__instance.trickNames = __instance.inlineTrickNames;
__instance.trickStandardDuration = __instance.trickingTrickDuration;
}
else if ((int)((Ability)__instance).p.moveStyle == 1)
{
__instance.startTrickNames = __instance.bmxStartTrickNames;
__instance.trickNames = __instance.bmxTrickNames;
__instance.trickStandardDuration = __instance.bmxTrickDuration;
}
Vector3 position = ((Ability)__instance).p.tf.position;
((Ability)__instance).p.motor.HaveCollision(false);
((Ability)__instance).p.ForceUnground(true);
Vector3 playerDirForLine = __instance.GetPlayerDirForLine(setGrindLine);
__instance.nextNode = setGrindLine.GetNextNode(playerDirForLine);
((Ability)__instance).p.SetVelocity(Vector3.zero);
((Ability)__instance).p.ResetVisualRot();
Vector3 val = setGrindLine.SnapPosToLine(position);
((Ability)__instance).p.motor.SetPositionTeleport(val);
__instance.grindLine = setGrindLine;
__instance.lastPath = __instance.grindLine.Path;
__instance.posOnLine = (__instance.justFollowNodes ? __instance.grindLine.GetRelativePosOnLine(val, __instance.nextNode) : __instance.grindLine.GetRelativePosOnLine(val, playerDirForLine));
if (Object.op_Implicit((Object)(object)__instance.grindLine.attachedToEnemyGrindLine))
{
__instance.grindingOnEnemy = __instance.grindLine.attachedToEnemyGrindLine;
__instance.grindingOnEnemy.BeingGrindedByPlayer = true;
}
AudioManager audioManager = ((Ability)__instance).p.AudioManager;
audioManager.PlaySfxGameplay(setGrindLine.sfxCollection, (AudioClipID)327, ((Ability)__instance).p.playerOneShotAudioSource, 0f);
audioManager.PlaySfxGameplayLooping(setGrindLine.sfxCollection, (AudioClipID)11, ((Ability)__instance).p.playerGrindLoopAudioSource, 0f, 0f);
((Ability)__instance).p.anim.SetFloat(__instance.grindBoostHash, 0f);
__instance.grindTilt = (__instance.grindTiltBuffer = Vector2.zero);
__instance.grindTiltBufferTimer = 0f;
__instance.softCornerBoost = false;
((Ability)__instance).p.ActivateAbility((Ability)(object)__instance);
__instance.normal = __instance.grindLine.GetNormalAtPos(val);
if (__instance.grindLine.isPole)
{
Vector3 val2 = Vector3.ProjectOnPlane(((Ability)__instance).p.dir * -1f, Vector3.up);
__instance.normal = ((Vector3)(ref val2)).normalized;
}
Vector3 val3 = (__instance.preGrindDir = setGrindLine.GetLineDir(playerDirForLine));
((Ability)__instance).p.SetRotHard(Quaternion.LookRotation(val3, __instance.normal));
__instance.StartGrindTrick(true, flag);
}
return false;
}
}
[BepInPlugin("info.mariobluegloves.noshoes", "noshoes", "4.2.0")]
[BepInProcess("Bomb Rush Cyberfunk.exe")]
public class VertAbilityPatches : BaseUnityPlugin
{
private void Awake()
{
//IL_0006: Unknown result type (might be due to invalid IL or missing references)
//IL_000c: Expected O, but got Unknown
Harmony val = new Harmony("info.mariobluegloves.noshoesp");
val.PatchAll(typeof(GriTAPatchNS));
((BaseUnityPlugin)this).Logger.LogInfo((object)"Soap Shoes successfully switched with Converse");
}
}
}