Decompiled source of BenjaPet v1.0.0

BenjaPet.dll

Decompiled 8 months ago
using System;
using System.Diagnostics;
using System.Reflection;
using System.Runtime.CompilerServices;
using System.Runtime.InteropServices;
using System.Runtime.Versioning;
using BepInEx;
using Configgy;
using UnityEngine;

[assembly: CompilationRelaxations(8)]
[assembly: RuntimeCompatibility(WrapNonExceptionThrows = true)]
[assembly: Debuggable(DebuggableAttribute.DebuggingModes.Default | DebuggableAttribute.DebuggingModes.DisableOptimizations | DebuggableAttribute.DebuggingModes.IgnoreSymbolStoreSequencePoints | DebuggableAttribute.DebuggingModes.EnableEditAndContinue)]
[assembly: AssemblyTitle("UKIdk")]
[assembly: AssemblyDescription("")]
[assembly: AssemblyConfiguration("")]
[assembly: AssemblyCompany("")]
[assembly: AssemblyProduct("UKIdk")]
[assembly: AssemblyCopyright("Copyright ©  2024")]
[assembly: AssemblyTrademark("")]
[assembly: ComVisible(false)]
[assembly: Guid("128d6f9a-7b62-4e8a-afd1-257aa556161d")]
[assembly: AssemblyFileVersion("1.0.0.0")]
[assembly: TargetFramework(".NETFramework,Version=v4.7.2", FrameworkDisplayName = ".NET Framework 4.7.2")]
[assembly: AssemblyVersion("1.0.0.0")]
namespace BenjaPet;

[BepInPlugin("DolfeMods.Ultrakill.BenjaPet", "BenjaPet", "1.0.0")]
[BepInDependency(/*Could not decode attribute arguments.*/)]
public class Class1 : BaseUnityPlugin
{
	[Configgable("", "How to use (Description)", 0, "Spawn a KITR cat using spawner arm down then switch weapons then go to the terminal and navigate to enemies then earthmover then open up the configgy menu and press the activate Eathmover pet button")]
	private static ConfigToggle Button = new ConfigToggle(false);

	[Configgable("", "Activate Earthmover Pet", 1, "Follow How to use to make this work")]
	private static ConfigButton Button1 = new ConfigButton((Action)EthmvrToCat, "Activate Earthmover Pet");

	[Configgable("", "Bite Damage higher values is higher damage", 1, "self explanatory")]
	private static ConfigInputField<float> BiteDmg = new ConfigInputField<float>(50f, (Func<float, bool>)null, (Func<string, ValueTuple<bool, float>>)null);

	[Configgable("", "Update Bite Damage", 1, "To prevent lag this is a callable method")]
	private static ConfigButton Button3 = new ConfigButton((Action)UpdateDamage, "Update Bite Damage");

	public static ConfigBuilder ConfigBuilder { get; private set; }

	private void Awake()
	{
		//IL_000b: Unknown result type (might be due to invalid IL or missing references)
		//IL_0015: Expected O, but got Unknown
		ConfigBuilder = new ConfigBuilder("DolfeMods.Ultrakill.BenjaPet", "BenjaPet");
		ConfigBuilder.BuildAll();
	}

	private static void EthmvrToCat()
	{
		//IL_0021: Unknown result type (might be due to invalid IL or missing references)
		//IL_0027: Unknown result type (might be due to invalid IL or missing references)
		//IL_0064: Unknown result type (might be due to invalid IL or missing references)
		//IL_007b: Unknown result type (might be due to invalid IL or missing references)
		//IL_009b: Unknown result type (might be due to invalid IL or missing references)
		GameObject val = GameObject.Find("Centaur Preview Variant(Clone)");
		((Behaviour)val.GetComponent<Spin>()).enabled = false;
		val.transform.rotation = default(Quaternion);
		GameObject val2 = GameObject.Find("KITR(Clone)");
		GameObject val3 = GameObject.Find("kitr_test_2");
		val3.SetActive(false);
		val.transform.parent = val2.transform;
		val.transform.localPosition = Vector3.zero;
		val.transform.rotation = val2.transform.rotation;
		val.transform.localScale = new Vector3(0.2f, 0.2f, 0.2f);
	}

	private static void UpdateDamage()
	{
		GameObject val = GameObject.Find("BiteZone");
		val.GetComponent<HurtZone>().enemyDamageOverride = ((ConfigValueElement<float>)(object)BiteDmg).Value;
	}
}