using System.Diagnostics;
using System.Reflection;
using System.Runtime.CompilerServices;
using System.Runtime.Versioning;
using BeetleUtils;
using Il2Cpp;
using Il2CppFMODUnity;
using MelonLoader;
using UnityEngine;
[assembly: CompilationRelaxations(8)]
[assembly: RuntimeCompatibility(WrapNonExceptionThrows = true)]
[assembly: Debuggable(DebuggableAttribute.DebuggingModes.Default | DebuggableAttribute.DebuggingModes.DisableOptimizations | DebuggableAttribute.DebuggingModes.IgnoreSymbolStoreSequencePoints | DebuggableAttribute.DebuggingModes.EnableEditAndContinue)]
[assembly: MelonInfo(typeof(Schizo), "SchizoUpdate", "1.0.0", "Spike", null)]
[assembly: TargetFramework(".NETCoreApp,Version=v6.0", FrameworkDisplayName = ".NET 6.0")]
[assembly: AssemblyCompany("LagTest")]
[assembly: AssemblyConfiguration("Debug")]
[assembly: AssemblyFileVersion("1.0.0.0")]
[assembly: AssemblyInformationalVersion("1.0.0")]
[assembly: AssemblyProduct("LagTest")]
[assembly: AssemblyTitle("LagTest")]
[assembly: AssemblyVersion("1.0.0.0")]
public class Schizo : MelonMod
{
private float chancePerSecond = 0.1f;
public override void OnLateInitializeMelon()
{
RuntimeManager.LoadBank("Master", false);
RuntimeManager.LoadBank("Master.strings", false);
}
public override void OnUpdate()
{
//IL_0020: Unknown result type (might be due to invalid IL or missing references)
//IL_0025: Unknown result type (might be due to invalid IL or missing references)
//IL_0039: Unknown result type (might be due to invalid IL or missing references)
//IL_003f: 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_008a: Unknown result type (might be due to invalid IL or missing references)
BeetleActor[] allBeetles = BeetleUtils.GetAllBeetles();
BeetleActor localBeetle = BeetleUtils.GetLocalBeetle();
if ((Object)(object)localBeetle == (Object)null)
{
return;
}
Vector3 position = ((Component)localBeetle).transform.position;
BeetleActor[] array = allBeetles;
foreach (BeetleActor val in array)
{
if (((NetworkActor)val).Team != ((NetworkActor)localBeetle).Team)
{
position = ((Component)val).transform.position;
}
}
if (Random.value < chancePerSecond * Time.deltaTime)
{
RuntimeManager.PlayOneShot("event:/SFX/DungBall/Dungball_Size/Dungball_Merge_Max", position);
}
}
}