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("NewTrix")]
[assembly: AssemblyConfiguration("Debug")]
[assembly: AssemblyDescription("New Tricks for Bomb Rush Cyberfunk")]
[assembly: AssemblyFileVersion("1.0.2.0")]
[assembly: AssemblyInformationalVersion("1.0.2")]
[assembly: AssemblyProduct("NewTrix")]
[assembly: AssemblyTitle("NewTrix")]
[assembly: SecurityPermission(SecurityAction.RequestMinimum, SkipVerification = true)]
[assembly: AssemblyVersion("1.0.2.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 newtrickx
{
[HarmonyPatch(typeof(VertAbility))]
internal class VertAbilityPatches
{
[HarmonyPatch("StartTrick")]
[HarmonyPrefix]
public static bool StartTrick_Prefix(VertAbility __instance)
{
//IL_0268: Unknown result type (might be due to invalid IL or missing references)
//IL_007d: Unknown result type (might be due to invalid IL or missing references)
//IL_0083: Invalid comparison between Unknown and I4
//IL_00bf: Unknown result type (might be due to invalid IL or missing references)
//IL_00c5: Invalid comparison between Unknown and I4
//IL_0131: Unknown result type (might be due to invalid IL or missing references)
//IL_0137: Invalid comparison between Unknown and I4
//IL_01a5: Unknown result type (might be due to invalid IL or missing references)
//IL_01ab: Invalid comparison between Unknown and I4
//IL_0229: Unknown result type (might be due to invalid IL or missing references)
AirTrickAbility airTrickAbility = ((Ability)__instance).p.airTrickAbility;
airTrickAbility.curTrick = ((Ability)__instance).p.InputToTrickNumber();
Console.WriteLine("incheckboosttrick with value " + ((object)(MoveStyle)(ref ((Ability)__instance).p.moveStyle)).ToString());
if (((Ability)__instance).p.CheckBoostTrick())
{
((Ability)__instance).p.PlayAnim(airTrickAbility.airBoostTrickHashes[airTrickAbility.curTrick], false, false, -1f);
if ((int)((Ability)__instance).p.moveStyle == 2)
{
if (airTrickAbility.curTrick == 1)
{
((Ability)__instance).p.PlayAnim(Animator.StringToHash("jumpTrick1"), true, false, 0f);
}
}
else if ((int)((Ability)__instance).p.moveStyle == 3)
{
if (airTrickAbility.curTrick == 1)
{
((Ability)__instance).p.PlayAnim(Animator.StringToHash("airTrick3"), true, false, 0f);
}
if (airTrickAbility.curTrick == 2)
{
((Ability)__instance).p.PlayAnim(Animator.StringToHash("jumpTrick1"), true, false, 0f);
}
}
if ((int)((Ability)__instance).p.moveStyle == 1)
{
if (airTrickAbility.curTrick == 1)
{
((Ability)__instance).p.PlayAnim(Animator.StringToHash("hitBounce"), true, false, 0f);
}
if (airTrickAbility.curTrick == 2)
{
((Ability)__instance).p.PlayAnim(Animator.StringToHash("jumpTrick1"), true, false, 0f);
}
}
else if ((int)((Ability)__instance).p.moveStyle == 0 && airTrickAbility.curTrick == 1)
{
((Ability)__instance).p.PlayAnim(Animator.StringToHash("jumpTrick1"), true, false, 0f);
}
((Ability)__instance).p.PlayVoice((AudioClipID)498, (VoicePriority)2, true);
__instance.trickScoreBuffered = true;
__instance.trickTimer = __instance.trickDuration * 1.5f;
((Ability)__instance).p.AddBoostCharge(0f - ((Ability)__instance).p.boostTrickCost);
__instance.trickType = (TrickType)2;
return false;
}
((Ability)__instance).p.PlayAnim(airTrickAbility.airTrickHashes[airTrickAbility.curTrick], false, false, -1f);
__instance.trickScoreBuffered = true;
__instance.trickTimer = __instance.trickDuration;
__instance.trickType = (TrickType)1;
return true;
}
}
}
namespace trickyclown
{
[BepInPlugin("info.mariobluegloves.trickyclown", "New Trix", "1.1.4")]
[BepInProcess("Bomb Rush Cyberfunk.exe")]
public class ATAPatchTC
{
[HarmonyPatch(typeof(AirTrickAbility), "Init")]
[HarmonyPrefix]
private static bool Init_Prefix(AirTrickAbility __instance)
{
__instance.skateboardTrickNames = new string[6] { "Backside 360 Varial", "Backflip Indy", "Method Grab", "1080", "McTwist", "1080" };
__instance.inlineTrickNames = new string[6] { "Cork 720", "Method Grab", "Abstract 360", "1080 California Roll", "Flying Fish", "Corkscrew" };
__instance.bmxTrickNames = new string[6] { "Tailwhip 360", "No Hand Backflip", "Superman Seat Grab Indian", "720 Double Backflip", "Barrel 90", "360 Backflip" };
__instance.trickingTrickNames = new string[6] { "Bullet Spin", "Backflip Grab", "Cheat 720", "Shuriken", "Corkscrew", "Shuriken" };
return true;
}
[HarmonyPatch(typeof(AirTrickAbility), "SetupBoostTrick")]
[HarmonyPrefix]
private static bool SetupBoostTrick_Prefix(AirTrickAbility __instance)
{
//IL_0032: Unknown result type (might be due to invalid IL or missing references)
//IL_0038: Invalid comparison between Unknown and I4
//IL_0074: Unknown result type (might be due to invalid IL or missing references)
//IL_007a: Invalid comparison between Unknown and I4
//IL_00e2: Unknown result type (might be due to invalid IL or missing references)
//IL_00e8: Invalid comparison between Unknown and I4
//IL_0156: Unknown result type (might be due to invalid IL or missing references)
//IL_015c: Invalid comparison between Unknown and I4
//IL_01bb: Unknown result type (might be due to invalid IL or missing references)
Console.WriteLine("MC TWIST");
((Ability)__instance).p.PlayAnim(__instance.airBoostTrickHashes[__instance.curTrick], true, false, 0f);
if ((int)((Ability)__instance).p.moveStyle == 2)
{
if (__instance.curTrick == 1)
{
((Ability)__instance).p.PlayAnim(Animator.StringToHash("jumpTrick1"), true, false, 0f);
}
}
else if ((int)((Ability)__instance).p.moveStyle == 3)
{
if (__instance.curTrick == 1)
{
((Ability)__instance).p.PlayAnim(Animator.StringToHash("airTrick3"), true, false, 0f);
}
if (__instance.curTrick == 2)
{
((Ability)__instance).p.PlayAnim(Animator.StringToHash("jumpTrick1"), true, false, 0f);
}
}
if ((int)((Ability)__instance).p.moveStyle == 1)
{
if (__instance.curTrick == 1)
{
((Ability)__instance).p.PlayAnim(Animator.StringToHash("hitBounce"), true, false, 0f);
}
if (__instance.curTrick == 2)
{
((Ability)__instance).p.PlayAnim(Animator.StringToHash("jumpTrick1"), true, false, 0f);
}
}
else if ((int)((Ability)__instance).p.moveStyle == 0 && __instance.curTrick == 1)
{
((Ability)__instance).p.PlayAnim(Animator.StringToHash("jumpTrick1"), true, false, 0f);
}
((Ability)__instance).p.PlayVoice((AudioClipID)498, (VoicePriority)2, true);
((Ability)__instance).p.ringParticles.Emit(1);
__instance.trickType = (TrickType)2;
__instance.duration *= 1.5f;
if (!((Ability)__instance).p.isAI)
{
((Ability)__instance).p.SetForwardSpeed(((Ability)__instance).p.boostSpeed);
}
((Ability)__instance).p.AddBoostCharge(0f - ((Ability)__instance).p.boostTrickCost);
return false;
}
}
[BepInPlugin("info.mariobluegloves.trickyclown", "New Trix", "1.1.4")]
[BepInProcess("Bomb Rush Cyberfunk.exe")]
public class GTAPatchTC
{
[HarmonyPatch(typeof(GroundTrickAbility), "Init")]
[HarmonyPrefix]
private static bool Init_Prefix(GroundTrickAbility __instance)
{
__instance.skateboardTrickNames = new string[6] { "Kickflip", "Backside 360 Powerspin", "360 Flip", "Handstand Flip", "Switch FS 180 Front Foot Impossible", "Handstand Flip" };
__instance.inlineSkatesTrickNames = new string[6] { "Unity Spin Cess Slide", "Duckwalk Fakie", "Back Closed Tree", "Bio", "Backslide Cess", "Bio" };
return true;
}
[HarmonyPatch(typeof(GroundTrickAbility), "DoBoostTrick")]
[HarmonyPrefix]
private static bool DoBoostTrick_Prefix(GroundTrickAbility __instance)
{
//IL_0027: Unknown result type (might be due to invalid IL or missing references)
//IL_002d: Invalid comparison between Unknown and I4
//IL_0069: Unknown result type (might be due to invalid IL or missing references)
//IL_006f: Invalid comparison between Unknown and I4
//IL_00ab: Unknown result type (might be due to invalid IL or missing references)
//IL_00b1: Invalid comparison between Unknown and I4
((Ability)__instance).p.PlayAnim(__instance.groundBoostTrickHashes[__instance.curTrick], true, false, 0f);
if ((int)((Ability)__instance).p.moveStyle == 2)
{
if (__instance.curTrick == 1)
{
((Ability)__instance).p.PlayAnim(Animator.StringToHash("groundTrick3"), true, false, 0f);
}
}
else if ((int)((Ability)__instance).p.moveStyle == 3)
{
if (__instance.curTrick == 1)
{
((Ability)__instance).p.PlayAnim(Animator.StringToHash("groundTrick3"), true, false, 0f);
}
}
else if ((int)((Ability)__instance).p.moveStyle != 1)
{
}
__instance.boostTrick = true;
((Ability)__instance).p.ringParticles.Emit(1);
__instance.duration *= 1.8f;
if (!((Ability)__instance).p.isAI)
{
((Ability)__instance).p.SetForwardSpeed(((Ability)__instance).p.boostSpeed);
}
((Ability)__instance).p.DoTrick((TrickType)5, __instance.GetTrickName(__instance.curTrick, true), __instance.curTrick);
((Ability)__instance).p.PlayVoice((AudioClipID)498, (VoicePriority)2, true);
((Ability)__instance).p.AddBoostCharge(0f - ((Ability)__instance).p.boostTrickCost);
return false;
}
}
[BepInPlugin("info.mariobluegloves.trickyclown", "New Trix", "1.1.4")]
[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.trickyclownp");
val.PatchAll(typeof(GTAPatchTC));
val.PatchAll(typeof(ATAPatchTC));
val.PatchAll();
((BaseUnityPlugin)this).Logger.LogInfo((object)"Trix R 4 Kidz");
}
}
}