Decompiled source of MVP RicksGarage Shop v1.0.2

MVP_RicksGarage_ShopMod.dll

Decompiled 11 hours ago
using System;
using System.Diagnostics;
using System.IO;
using System.Reflection;
using System.Runtime.CompilerServices;
using System.Runtime.InteropServices;
using System.Runtime.Versioning;
using BepInEx;
using Empress_ShopLoaderAPI;
using HarmonyLib;
using UnityEngine;
using UnityEngine.SceneManagement;

[assembly: CompilationRelaxations(8)]
[assembly: RuntimeCompatibility(WrapNonExceptionThrows = true)]
[assembly: Debuggable(DebuggableAttribute.DebuggingModes.Default | DebuggableAttribute.DebuggingModes.DisableOptimizations | DebuggableAttribute.DebuggingModes.IgnoreSymbolStoreSequencePoints | DebuggableAttribute.DebuggingModes.EnableEditAndContinue)]
[assembly: AssemblyTitle("MVP_RicksGarage_ShopMod")]
[assembly: AssemblyDescription("")]
[assembly: AssemblyConfiguration("")]
[assembly: AssemblyCompany("")]
[assembly: AssemblyProduct("MVP_RicksGarage_ShopMod")]
[assembly: AssemblyCopyright("Copyright ©  2026")]
[assembly: AssemblyTrademark("")]
[assembly: ComVisible(false)]
[assembly: Guid("e8f80e92-e634-45b9-b864-129e1a259952")]
[assembly: AssemblyFileVersion("1.0.0.0")]
[assembly: TargetFramework(".NETFramework,Version=v4.8", FrameworkDisplayName = ".NET Framework 4.8")]
[assembly: AssemblyVersion("1.0.0.0")]
[BepInPlugin("dev.thatdrw.mvp.ricksgarageshopmod", "MVP RicksGarage ShopMod", "1.0.0")]
[BepInDependency(/*Could not decode attribute arguments.*/)]
public class MVP_RicksGarage_ShopMod : BaseUnityPlugin
{
	private void Awake()
	{
		//IL_0017: Unknown result type (might be due to invalid IL or missing references)
		//IL_001d: Expected O, but got Unknown
		((BaseUnityPlugin)this).Logger.LogInfo((object)"Plugin loaded, preparing initialization.");
		Harmony val = new Harmony("dev.thatdrw.mvp.ricksgarageshopmod");
		val.PatchAll();
		SceneManager.sceneLoaded += OnSceneLoaded;
		HookShopAPI();
	}

	private void HookShopAPI()
	{
		string text = Path.Combine(Path.GetDirectoryName(((BaseUnityPlugin)this).Info.Location), "mvp_ricksgarageshopmod_bundle");
		AssetBundle val = AssetBundle.LoadFromFile(text);
		if (!((Object)(object)val == (Object)null))
		{
			GameObject val2 = val.LoadAsset<GameObject>("Shop Generic N - RicksGarage Shop");
			if ((Object)(object)val2 != (Object)null)
			{
				ShopAPI.RegisterShop(val2, "DaRealMVP/RicksGarage");
			}
		}
	}

	private void OnSceneLoaded(Scene scene, LoadSceneMode mode)
	{
		//IL_0038: Unknown result type (might be due to invalid IL or missing references)
		//IL_003e: Expected O, but got Unknown
		((BaseUnityPlugin)this).Logger.LogInfo((object)("Scene loaded: " + ((Scene)(ref scene)).name));
		if ((Object)(object)GameObject.Find("MVPRicksGarageShopModHandler") == (Object)null)
		{
			GameObject val = new GameObject("MVPRicksGarageShopModHandler");
			val.AddComponent<MVP_RicksGarage_ShopModHandler>();
			Object.DontDestroyOnLoad((Object)(object)val);
		}
	}

	private void Start()
	{
	}

	private void Update()
	{
	}
}
public class MVP_RicksGarage_ShopModHandler : MonoBehaviour
{
	private bool levelInitialized;

	private object levelGeneratorInstance;

	private Type levelGeneratorType;

	private void Update()
	{
		LogKeyInputs();
	}

	private void LogKeyInputs()
	{
		//IL_001f: Unknown result type (might be due to invalid IL or missing references)
		//IL_0024: Unknown result type (might be due to invalid IL or missing references)
		//IL_0026: Unknown result type (might be due to invalid IL or missing references)
		foreach (KeyCode value in Enum.GetValues(typeof(KeyCode)))
		{
			if (!Input.GetKeyDown(value))
			{
			}
		}
	}

	public void OnClickVendingMachineA()
	{
		Debug.Log((object)"VendingMachineA's button was pressed!");
	}

	public void OnClickVendingMachineB()
	{
		Debug.Log((object)"VendingMachineB's button was pressed!");
	}
}