Decompiled source of InstantParkSearcher v1.0.0

Mods/InstantParkSearcher.dll

Decompiled 4 months ago
using System.Diagnostics;
using System.Reflection;
using System.Runtime.CompilerServices;
using System.Runtime.InteropServices;
using System.Runtime.Versioning;
using InstantParkSearcher;
using MelonLoader;
using RUMBLE.Environment;
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(main), "Instant Park Searcher", "1.0.0", "UlvakSkillz", null)]
[assembly: MelonGame("Buckethead Entertainment", "RUMBLE")]
[assembly: AssemblyTitle("InstantParkSearcher")]
[assembly: AssemblyDescription("")]
[assembly: AssemblyConfiguration("")]
[assembly: AssemblyCompany("")]
[assembly: AssemblyProduct("InstantParkSearcher")]
[assembly: AssemblyCopyright("Copyright ©  2024")]
[assembly: AssemblyTrademark("")]
[assembly: ComVisible(false)]
[assembly: Guid("c7782c7f-af24-4ef0-94b4-d1a4292ae989")]
[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 InstantParkSearcher;

public class main : MelonMod
{
	private ParkBoardGymVariant parkBoardGymVariant;

	private string currentScene = "";

	private bool sceneChanged = false;

	public override void OnFixedUpdate()
	{
		if (!sceneChanged)
		{
			return;
		}
		try
		{
			if (currentScene == "Gym")
			{
				parkBoardGymVariant = GameObject.Find("--------------LOGIC--------------/Heinhouser products/Parkboard").GetComponent<ParkBoardGymVariant>();
				parkBoardGymVariant.OnHostJoinSliderChanged(1);
				parkBoardGymVariant.OnFindRandomParkPressed();
				sceneChanged = false;
			}
		}
		catch
		{
		}
	}

	public override void OnSceneWasLoaded(int buildIndex, string sceneName)
	{
		currentScene = sceneName;
		sceneChanged = true;
	}
}