Decompiled source of FumoPacks v1.3.2

plugins/FumoPacks.dll

Decompiled a day ago
using System;
using System.Collections.Generic;
using System.Diagnostics;
using System.Linq;
using System.Reflection;
using System.Runtime.CompilerServices;
using System.Runtime.Versioning;
using System.Security;
using System.Security.Permissions;
using Agents;
using BepInEx;
using BepInEx.Core.Logging.Interpolation;
using BepInEx.Logging;
using BepInEx.Unity.IL2CPP;
using CellMenu;
using GameData;
using Gear;
using Il2CppInterop.Runtime.InteropTypes.Arrays;
using LevelGeneration;
using Microsoft.CodeAnalysis;
using Player;
using TheArchive;
using TheArchive.Core;
using TheArchive.Core.Attributes.Feature;
using TheArchive.Core.Attributes.Feature.Members;
using TheArchive.Core.Attributes.Feature.Patches;
using TheArchive.Core.Attributes.Feature.Settings;
using TheArchive.Core.FeaturesAPI;
using TheArchive.Core.FeaturesAPI.Components;
using TheArchive.Core.FeaturesAPI.Settings;
using TheArchive.Core.Localization;
using TheArchive.Interfaces;
using UnityEngine;

[assembly: CompilationRelaxations(8)]
[assembly: RuntimeCompatibility(WrapNonExceptionThrows = true)]
[assembly: Debuggable(DebuggableAttribute.DebuggingModes.IgnoreSymbolStoreSequencePoints)]
[assembly: TargetFramework(".NETCoreApp,Version=v6.0", FrameworkDisplayName = ".NET 6.0")]
[assembly: AssemblyCompany("FumoPacks")]
[assembly: AssemblyConfiguration("Release")]
[assembly: AssemblyFileVersion("1.0.0.0")]
[assembly: AssemblyInformationalVersion("1.0.0+218b0183e4ceabe771e957d2798728c2aa01bd55")]
[assembly: AssemblyProduct("FumoPacks")]
[assembly: AssemblyTitle("FumoPacks")]
[assembly: TargetPlatform("Windows7.0")]
[assembly: SupportedOSPlatform("Windows7.0")]
[assembly: SecurityPermission(SecurityAction.RequestMinimum, SkipVerification = true)]
[assembly: AssemblyVersion("1.0.0.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 FumoPacks
{
	[EnableFeatureByDefault]
	public class IAmえっとJapaneseGoblin : Feature
	{
		public class あかあおきいろのOnisAndMore
		{
			[FSHeader("Fumos", true)]
			[FSDisplayName("Ammo Packs")]
			public DoYouHaveAけいのたかとびおにごろし.DokiDokiWakuWaku AmmoFumo { get; set; } = DoYouHaveAけいのたかとびおにごろし.DokiDokiWakuWaku.Youmu;


			[FSDisplayName("MediPacks")]
			public DoYouHaveAけいのたかとびおにごろし.DokiDokiWakuWaku MediFumo { get; set; } = DoYouHaveAけいのたかとびおにごろし.DokiDokiWakuWaku.Eirin;


			[FSDisplayName("Tool Refill Packs")]
			public DoYouHaveAけいのたかとびおにごろし.DokiDokiWakuWaku ToolFumo { get; set; } = DoYouHaveAけいのたかとびおにごろし.DokiDokiWakuWaku.Nitori;


			[FSDisplayName("Disinfection Pack")]
			public DoYouHaveAけいのたかとびおにごろし.DokiDokiWakuWaku DisFumo { get; set; } = DoYouHaveAけいのたかとびおにごろし.DokiDokiWakuWaku.Cirno;


			[FSDisplayName("Extra Funky Settings")]
			public bool Funky { get; set; }

			[FSHeader("Audio", true)]
			[FSDisplayName("Yukkuri 'Fumo' on Pick Up")]
			[FSDescription("Plays the Yukkuri 'Fumo' sound clip upon picking up a resource pack")]
			public bool Pickup { get; set; }

			[FSDisplayName("On Use")]
			[FSDescription("For select fumos play a custom sound when using them")]
			public bool Use { get; set; }

			[FSDisplayName("While Held")]
			[FSDescription("Plays Bad Apple™ while holding a fumo")]
			public bool Held { get; set; }

			[FSHeader("Fixes", true)]
			[FSDisplayName("Fumo Storage Container Fix")]
			[FSDescription("Reorientates lockers and boxes so the fumos aren't clipping into them")]
			public bool LockFix { get; set; } = true;


			[FSDisplayName("Fumo Name Fix")]
			[FSDescription("Removes the hard coding of from resource packs to replace the sub name with the name of the fumo")]
			public bool NameFix { get; set; } = true;


			[FSDisplayName("Fumo Reset Button")]
			[FSDescription("Press this button to reset the item spawn manager for fumos to change without resetting\r\n<color=#FF0000>WARNING!!! DO NOT PRESS IN LEVEL")]
			public FButton FumoReset { get; set; } = new FButton("RESET FUMOS", "FumoReset", (Action)null, false);

		}

		[ArchivePatch(/*Could not decode attribute arguments.*/)]
		internal static class HighVividChartreuseGreenOni
		{
			internal static void Prefix(LG_WeakResourceContainer __instance)
			{
				//IL_0368: Unknown result type (might be due to invalid IL or missing references)
				//IL_037c: Unknown result type (might be due to invalid IL or missing references)
				//IL_039d: Unknown result type (might be due to invalid IL or missing references)
				//IL_03b1: Unknown result type (might be due to invalid IL or missing references)
				//IL_03d2: Unknown result type (might be due to invalid IL or missing references)
				//IL_03e6: Unknown result type (might be due to invalid IL or missing references)
				//IL_0043: Unknown result type (might be due to invalid IL or missing references)
				//IL_0057: 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_0091: Unknown result type (might be due to invalid IL or missing references)
				//IL_00b7: Unknown result type (might be due to invalid IL or missing references)
				//IL_00cb: Unknown result type (might be due to invalid IL or missing references)
				//IL_00f1: Unknown result type (might be due to invalid IL or missing references)
				//IL_0105: Unknown result type (might be due to invalid IL or missing references)
				//IL_012b: Unknown result type (might be due to invalid IL or missing references)
				//IL_013f: Unknown result type (might be due to invalid IL or missing references)
				//IL_0165: Unknown result type (might be due to invalid IL or missing references)
				//IL_0179: Unknown result type (might be due to invalid IL or missing references)
				//IL_0452: Unknown result type (might be due to invalid IL or missing references)
				//IL_04a5: Unknown result type (might be due to invalid IL or missing references)
				//IL_01eb: Unknown result type (might be due to invalid IL or missing references)
				//IL_0251: Unknown result type (might be due to invalid IL or missing references)
				//IL_0339: Unknown result type (might be due to invalid IL or missing references)
				//IL_02c7: Unknown result type (might be due to invalid IL or missing references)
				if (!Settings.LockFix)
				{
					return;
				}
				if (__instance.m_isLocker)
				{
					Transform transform = ((Component)__instance).gameObject.transform;
					Dictionary<int, (string, int, Vector3, Quaternion)> dictionary = new Dictionary<int, (string, int, Vector3, Quaternion)>();
					dictionary[1] = ("Shelf 1a", 1, new Vector3(0f, 0f, 0.03f), Quaternion.Euler(217.02f, -267.879f, 88.322f));
					dictionary[2] = ("Shelf 1b", 3, new Vector3(-0.028f, -0.094f, 0.034f), Quaternion.Euler(223.132f, -92.32098f, -88.322f));
					dictionary[3] = ("Shelf 2", 4, new Vector3(0.025f, -0.084f, 0.014f), Quaternion.Euler(-88.131f, -9.566f, 188.474f));
					dictionary[4] = ("Shelf 3", 5, new Vector3(-0.108f, -0.037f, 0.014f), Quaternion.Euler(260.561f, 77.31599f, 103.1f));
					dictionary[5] = ("Shelf 4", 7, new Vector3(0.005f, -0.028f, 0.0308f), Quaternion.Euler(264.07f, -71.54199f, -108.026f));
					dictionary[6] = ("Shelf 5", 8, new Vector3(-0.031f, -0.1249f, 0.0558f), Quaternion.Euler(269.079f, -89.091f, -90.15601f));
					for (int i = 1; i < 7; i++)
					{
						transform.Find($"PickupAligns/{dictionary[i].Item1}/resourcepack {dictionary[i].Item2}").localPosition = dictionary[i].Item3;
						transform.Find($"PickupAligns/{dictionary[i].Item1}/resourcepack {dictionary[i].Item2}").localRotation = dictionary[i].Item4;
						if (i < 6 && i > 2)
						{
							transform.Find($"PickupAligns/{dictionary[i].Item1}/resourcepack {dictionary[i].Item2}").localScale = new Vector3(0.9f, 0.9f, 0.9f);
						}
						if (i == 6)
						{
							transform.Find($"PickupAligns/{dictionary[i].Item1}/resourcepack {dictionary[i].Item2}").localScale = new Vector3(1.5f, 1.5f, 1.5f);
						}
					}
				}
				else
				{
					Dictionary<int, (Vector3, Quaternion)> dictionary2 = new Dictionary<int, (Vector3, Quaternion)>();
					dictionary2[1] = (new Vector3(0f, -0.0787f, 0.15f), Quaternion.Euler(-90f, -90f, -90f));
					dictionary2[2] = (new Vector3(0.132f, 0.067f, 0.1522f), Quaternion.Euler(187.75f, 90f, 90f));
					dictionary2[3] = (new Vector3(-0.1322f, 0f, 0.1522f), Quaternion.Euler(0f, 90f, 90f));
					for (int j = 1; j < 4; j++)
					{
						Transform transform2 = ((Component)__instance).gameObject.transform;
						transform2.Find($"PickupALigns/Compartment {j}/resourcepack {j}").localPosition = dictionary2[j].Item1;
						transform2.Find($"PickupALigns/Compartment {j}/resourcepack {j}").localRotation = dictionary2[j].Item2;
					}
				}
			}
		}

		[ArchivePatch(/*Could not decode attribute arguments.*/)]
		internal static class SexyMediumVioletOni
		{
			internal static void Postfix(PUI_Inventory __instance, BackpackItem bpItem, InventorySlot selectedSlot = 0)
			{
				//IL_0019: Unknown result type (might be due to invalid IL or missing references)
				//IL_001e: 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_002d: Unknown result type (might be due to invalid IL or missing references)
				//IL_0035: Unknown result type (might be due to invalid IL or missing references)
				//IL_0042: Unknown result type (might be due to invalid IL or missing references)
				if (Settings.NameFix)
				{
					Item instance = bpItem.Instance;
					InventorySlot inventorySlot = instance.ItemDataBlock.inventorySlot;
					if (__instance.m_inventorySlots.ContainsKey(inventorySlot) && selectedSlot == ((Il2CppArrayBase<InventorySlot>)(object)__instance.m_slotGUIOrder)[4])
					{
						__instance.m_inventorySlots[inventorySlot].SetDetailedName(((GameDataBlockBase<ItemDataBlock>)(object)instance.ItemDataBlock).name);
					}
				}
			}
		}

		[ArchivePatch(/*Could not decode attribute arguments.*/)]
		internal static class むらさきだいだいしゃくなげおに
		{
			internal static void Postfix()
			{
				DoYouHaveAけいのたかとびおにごろし.DokiDokiWakuWaku ammoFumo = Settings.AmmoFumo;
				DoYouHaveAけいのたかとびおにごろし.DokiDokiWakuWaku mediFumo = Settings.MediFumo;
				DoYouHaveAけいのたかとびおにごろし.DokiDokiWakuWaku toolFumo = Settings.ToolFumo;
				DoYouHaveAけいのたかとびおにごろし.DokiDokiWakuWaku disFumo = Settings.DisFumo;
				Dictionary<DoYouHaveAけいのたかとびおにごろし.DokiDokiWakuWaku, (string, string, string)> muneGaTakanaru = DoYouHaveAけいのたかとびおにごろし.MuneGaTakanaru;
				foreach (KeyValuePair<uint, (string, string, string, string, DoYouHaveAけいのたかとびおにごろし.DokiDokiWakuWaku)> item in new Dictionary<uint, (string, string, string, string, DoYouHaveAけいのたかとびおにごろし.DokiDokiWakuWaku)>
				{
					[101u] = (muneGaTakanaru[ammoFumo].Item1, muneGaTakanaru[ammoFumo].Item2, muneGaTakanaru[ammoFumo].Item3, "Ammopack/FumoPackWeaponPickup.prefab", ammoFumo),
					[102u] = (muneGaTakanaru[mediFumo].Item1, muneGaTakanaru[mediFumo].Item2, muneGaTakanaru[mediFumo].Item3, "Medipack/FumoMediPackPickup.prefab", mediFumo),
					[127u] = (muneGaTakanaru[toolFumo].Item1, muneGaTakanaru[toolFumo].Item2, muneGaTakanaru[toolFumo].Item3, "Tool Refill/FumoPackToolPickup.prefab", toolFumo),
					[132u] = (muneGaTakanaru[disFumo].Item1, muneGaTakanaru[disFumo].Item2, muneGaTakanaru[disFumo].Item3, "Disinfection/FumoPackFunkyPickup.prefab", disFumo)
				})
				{
					if (DoYouHaveAけいのたかとびおにごろし.FumoNameReorder.Contains(item.Value.Item1))
					{
						((GameDataBlockBase<ItemDataBlock>)(object)GameDataBlockBase<ItemDataBlock>.GetBlock(item.Key)).name = item.Value.Item2 + " " + item.Value.Item1;
					}
					else
					{
						((GameDataBlockBase<ItemDataBlock>)(object)GameDataBlockBase<ItemDataBlock>.GetBlock(item.Key)).name = item.Value.Item1 + " " + item.Value.Item2;
					}
					if (DoYouHaveAけいのたかとびおにごろし.FumoReskinDirFix.Contains(item.Value.Item5))
					{
						switch (item.Value.Item5)
						{
						case DoYouHaveAけいのたかとびおにごろし.DokiDokiWakuWaku.Bee_Marisa:
							GameDataBlockBase<ItemDataBlock>.GetBlock(item.Key).FirstPersonPrefabs[1] = "Assets/TouhouFoxFucker/FumoPacks/" + item.Value.Item3 + "/Bee Marisa/Bee Marisa.prefab";
							GameDataBlockBase<ItemDataBlock>.GetBlock(item.Key).ThirdPersonPrefabs[1] = "Assets/TouhouFoxFucker/FumoPacks/" + item.Value.Item3 + "/Bee Marisa/Bee Marisa_thirdperson.prefab";
							GameDataBlockBase<ItemDataBlock>.GetBlock(item.Key).PickupPrefabs[0] = "Assets/TouhouFoxFucker/FumoPacks/" + item.Value.Item3 + "/Bee Marisa/" + item.Value.Item4;
							break;
						case DoYouHaveAけいのたかとびおにごろし.DokiDokiWakuWaku.Blue_Reimu:
							GameDataBlockBase<ItemDataBlock>.GetBlock(item.Key).FirstPersonPrefabs[1] = "Assets/TouhouFoxFucker/FumoPacks/" + item.Value.Item3 + "/Blue Reimu/Blue Reimu.prefab";
							GameDataBlockBase<ItemDataBlock>.GetBlock(item.Key).ThirdPersonPrefabs[1] = "Assets/TouhouFoxFucker/FumoPacks/" + item.Value.Item3 + "/Blue Reimu/Blue Reimu_thirdperson.prefab";
							GameDataBlockBase<ItemDataBlock>.GetBlock(item.Key).PickupPrefabs[0] = "Assets/TouhouFoxFucker/FumoPacks/" + item.Value.Item3 + "/Blue Reimu/" + item.Value.Item4;
							break;
						case DoYouHaveAけいのたかとびおにごろし.DokiDokiWakuWaku.Inu_Sakuya:
							GameDataBlockBase<ItemDataBlock>.GetBlock(item.Key).FirstPersonPrefabs[1] = "Assets/TouhouFoxFucker/FumoPacks/" + item.Value.Item3 + "/Dog Sakuya/Dog Sakuya.prefab";
							GameDataBlockBase<ItemDataBlock>.GetBlock(item.Key).ThirdPersonPrefabs[1] = "Assets/TouhouFoxFucker/FumoPacks/" + item.Value.Item3 + "/Dog Sakuya/Dog Sakuya_thirdperson.prefab";
							GameDataBlockBase<ItemDataBlock>.GetBlock(item.Key).PickupPrefabs[0] = "Assets/TouhouFoxFucker/FumoPacks/" + item.Value.Item3 + "/Dog Sakuya/" + item.Value.Item4;
							break;
						case DoYouHaveAけいのたかとびおにごろし.DokiDokiWakuWaku.Yuuma_Custom:
							GameDataBlockBase<ItemDataBlock>.GetBlock(item.Key).FirstPersonPrefabs[1] = "Assets/TouhouFoxFucker/FumoPacks/" + item.Value.Item3 + "/Yuuma Custom/Yuuma Custom.prefab";
							GameDataBlockBase<ItemDataBlock>.GetBlock(item.Key).ThirdPersonPrefabs[1] = "Assets/TouhouFoxFucker/FumoPacks/" + item.Value.Item3 + "/Yuuma Custom/Yuuma Custom_thirdperson.prefab";
							GameDataBlockBase<ItemDataBlock>.GetBlock(item.Key).PickupPrefabs[0] = "Assets/TouhouFoxFucker/FumoPacks/" + item.Value.Item3 + "/Yuuma Custom/" + item.Value.Item4;
							break;
						case DoYouHaveAけいのたかとびおにごろし.DokiDokiWakuWaku.Tiny_Devil_Mistress_Remilia:
							GameDataBlockBase<ItemDataBlock>.GetBlock(item.Key).FirstPersonPrefabs[1] = "Assets/TouhouFoxFucker/FumoPacks/" + item.Value.Item3 + "/Tiny Devil Mistress Remilia/Tiny Devil Mistress Remilia.prefab";
							GameDataBlockBase<ItemDataBlock>.GetBlock(item.Key).ThirdPersonPrefabs[1] = "Assets/TouhouFoxFucker/FumoPacks/" + item.Value.Item3 + "/Tiny Devil Mistress Remilia/Tiny Devil Mistress Remilia_thirdperson.prefab";
							GameDataBlockBase<ItemDataBlock>.GetBlock(item.Key).PickupPrefabs[0] = "Assets/TouhouFoxFucker/FumoPacks/" + item.Value.Item3 + "/Tiny Devil Mistress Remilia/" + item.Value.Item4;
							break;
						case DoYouHaveAけいのたかとびおにごろし.DokiDokiWakuWaku.Vampire_Pursuing_The_Hunter_Flandre:
							GameDataBlockBase<ItemDataBlock>.GetBlock(item.Key).FirstPersonPrefabs[1] = "Assets/TouhouFoxFucker/FumoPacks/" + item.Value.Item3 + "/Vampire Pursuing the Hunter Flandre/Vampire Pursuing the Hunter Flandre.prefab";
							GameDataBlockBase<ItemDataBlock>.GetBlock(item.Key).ThirdPersonPrefabs[1] = "Assets/TouhouFoxFucker/FumoPacks/" + item.Value.Item3 + "/Vampire Pursuing the Hunter Flandre/Vampire Pursuing the Hunter Flandre_thirdperson.prefab";
							GameDataBlockBase<ItemDataBlock>.GetBlock(item.Key).PickupPrefabs[0] = "Assets/TouhouFoxFucker/FumoPacks/" + item.Value.Item3 + "/Vampire Pursuing the Hunter Flandre/" + item.Value.Item4;
							break;
						case DoYouHaveAけいのたかとびおにごろし.DokiDokiWakuWaku.Tiny_Ghost_Mistress_Yuyuko:
							GameDataBlockBase<ItemDataBlock>.GetBlock(item.Key).FirstPersonPrefabs[1] = "Assets/TouhouFoxFucker/FumoPacks/" + item.Value.Item3 + "/Tiny Ghost Mistress Yuyuko/Tiny Ghost Mistress Yuyuko.prefab";
							GameDataBlockBase<ItemDataBlock>.GetBlock(item.Key).ThirdPersonPrefabs[1] = "Assets/TouhouFoxFucker/FumoPacks/" + item.Value.Item3 + "/Tiny Ghost Mistress Yuyuko/Tiny Ghost Mistress Yuyuko_thirdperson.prefab";
							GameDataBlockBase<ItemDataBlock>.GetBlock(item.Key).PickupPrefabs[0] = "Assets/TouhouFoxFucker/FumoPacks/" + item.Value.Item3 + "/Tiny Ghost Mistress Yuyuko/" + item.Value.Item4;
							break;
						}
					}
					else
					{
						GameDataBlockBase<ItemDataBlock>.GetBlock(item.Key).FirstPersonPrefabs[1] = $"Assets/TouhouFoxFucker/FumoPacks/{item.Value.Item3}/{item.Value.Item1}/{item.Value.Item1}.prefab";
						GameDataBlockBase<ItemDataBlock>.GetBlock(item.Key).ThirdPersonPrefabs[1] = $"Assets/TouhouFoxFucker/FumoPacks/{item.Value.Item3}/{item.Value.Item1}/{item.Value.Item1}_thirdperson.prefab";
						GameDataBlockBase<ItemDataBlock>.GetBlock(item.Key).PickupPrefabs[0] = $"Assets/TouhouFoxFucker/FumoPacks/{item.Value.Item3}/{item.Value.Item1}/{item.Value.Item4}";
					}
					GameDataBlockBase<ItemDataBlock>.GetBlock(item.Key).LeftHandGripAnim = "DisinfectionPack_idle";
					GameDataBlockBase<ItemDataBlock>.GetBlock(item.Key).RightHandGripAnim = "DisinfectionPack_idle";
				}
				if (Settings.Funky)
				{
					string text = "Assets/TouhouFoxFucker/FumoPacks/Extra Funky/";
					ItemDataBlock block = GameDataBlockBase<ItemDataBlock>.GetBlock(133u);
					block.publicName = "Yukkuri Turbine";
					block.FirstPersonPrefabs[1] = text + "Yukkuri Turbine/YukkuriTurbine.prefab";
					block.ThirdPersonPrefabs[1] = text + "Yukkuri Turbine/YukkuriTurbine.prefab";
					block.PickupPrefabs[1] = text + "Yukkuri Turbine/YukkuriTurbine_Pickup.prefab";
					ItemDataBlock block2 = GameDataBlockBase<ItemDataBlock>.GetBlock(139u);
					block2.publicName = "Mini Hakkero";
					block2.FirstPersonPrefabs[0] = text + "Mini Hakkero/Mini Hakkero_FirstPerson.prefab";
					block2.ThirdPersonPrefabs[0] = text + "Mini Hakkero/Mini Hakkero.prefab";
					block2.PickupPrefabs[0] = text + "Mini Hakkero/Mini Hakkero_Pickup.prefab";
					block2.InstancePrefabs[0] = text + "Mini Hakkero/Mini Hakkero_Instance.prefab";
					ItemDataBlock block3 = GameDataBlockBase<ItemDataBlock>.GetBlock(117u);
					block3.publicName = "Snail Cirno";
					block3.FirstPersonPrefabs[1] = text + "Snail Cirno/Snailno.prefab";
					block3.ThirdPersonPrefabs[0] = text + "Snail Cirno/Snailno_thirdperson.prefab";
					block3.PickupPrefabs[0] = text + "Snail Cirno/Snailno_Pickup.prefab";
					block3.InstancePrefabs[0] = text + "Snail Cirno/Snailno_Instance.prefab";
					block3.InstancePrefabs[1] = text + "Snail Cirno/Snailno_Activated.prefab";
					block3.LeftHandGripAnim = "DisinfectionPack_idle";
					block3.RightHandGripAnim = "DisinfectionPack_idle";
					ItemDataBlock block4 = GameDataBlockBase<ItemDataBlock>.GetBlock(114u);
					block4.publicName = "Cirnoprism";
					block4.FirstPersonPrefabs[1] = text + "Cirnoprism/Consumable_GlowStick.prefab";
					block4.ThirdPersonPrefabs[0] = text + "Cirnoprism/Consumable_GlowStick_third.prefab";
					block4.PickupPrefabs[0] = text + "Cirnoprism/Consumable_GlowStick_Pickup.prefab";
					block4.InstancePrefabs[0] = text + "Cirnoprism/Consumable_GlowStick_Instance.prefab";
					block4.InstancePrefabs[1] = text + "Cirnoprism/Consumable_GlowStick_lit.prefab";
					ItemDataBlock block5 = GameDataBlockBase<ItemDataBlock>.GetBlock(115u);
					block5.publicName = "Fumo Jar";
					block5.FirstPersonPrefabs[1] = text + "JAR/cumjar.prefab";
					block5.ThirdPersonPrefabs[0] = text + "JAR/cumjar_third.prefab";
					block5.PickupPrefabs[0] = text + "JAR/cumjarPickup.prefab";
					block5.InstancePrefabs[1] = text + "JAR/cumjar.prefab";
				}
			}
		}

		[ArchivePatch(/*Could not decode attribute arguments.*/)]
		internal static class らららいえるかなとぅないひゃっきやぎょう
		{
			internal static void Postfix(ePickupItemStatus status, PlayerAgent player, bool isRecall, ResourcePackPickup __instance)
			{
				//IL_0015: Unknown result type (might be due to invalid IL or missing references)
				//IL_0017: Invalid comparison between Unknown and I4
				//IL_002c: Unknown result type (might be due to invalid IL or missing references)
				//IL_0031: Unknown result type (might be due to invalid IL or missing references)
				//IL_0032: Unknown result type (might be due to invalid IL or missing references)
				//IL_0044: Expected I4, but got Unknown
				//IL_0044: Unknown result type (might be due to invalid IL or missing references)
				//IL_0047: Invalid comparison between Unknown and I4
				if (!Settings.Pickup)
				{
					return;
				}
				uint num = 2527293770u;
				if ((int)status != 1 || isRecall || !((Object)(object)player != (Object)null))
				{
					return;
				}
				eResourceContainerSpawnType packType = __instance.m_packType;
				switch ((int)packType)
				{
				default:
					if ((int)packType == 9 && ((Agent)player).IsLocallyOwned)
					{
						player.Sound.Post(num, true);
					}
					break;
				case 0:
					if (((Agent)player).IsLocallyOwned)
					{
						player.Sound.Post(num, true);
					}
					break;
				case 1:
					if (((Agent)player).IsLocallyOwned)
					{
						player.Sound.Post(num, true);
					}
					break;
				case 2:
					if (((Agent)player).IsLocallyOwned)
					{
						player.Sound.Post(num, true);
					}
					break;
				}
			}
		}

		[ArchivePatch(/*Could not decode attribute arguments.*/)]
		internal static class HighTensionJapaneseGoblin
		{
			internal static void Postfix(ResourcePackFirstPerson __instance)
			{
				//IL_0145: Unknown result type (might be due to invalid IL or missing references)
				//IL_014a: Unknown result type (might be due to invalid IL or missing references)
				//IL_014c: Unknown result type (might be due to invalid IL or missing references)
				//IL_0150: Unknown result type (might be due to invalid IL or missing references)
				//IL_0153: Unknown result type (might be due to invalid IL or missing references)
				//IL_0155: Invalid comparison between Unknown and I4
				//IL_0157: Unknown result type (might be due to invalid IL or missing references)
				//IL_015b: Invalid comparison between Unknown and I4
				//IL_017d: Unknown result type (might be due to invalid IL or missing references)
				//IL_0183: Invalid comparison between Unknown and I4
				Dictionary<DoYouHaveAけいのたかとびおにごろし.DokiDokiWakuWaku, (string name, string surname, string Game)> muneGaTakanaru = DoYouHaveAけいのたかとびおにごろし.MuneGaTakanaru;
				string item = muneGaTakanaru[Settings.AmmoFumo].name;
				string item2 = muneGaTakanaru[Settings.MediFumo].name;
				string item3 = muneGaTakanaru[Settings.ToolFumo].name;
				string item4 = muneGaTakanaru[Settings.DisFumo].name;
				string[] array = new string[4] { item, item2, item3, item4 };
				uint[] array2 = new uint[0];
				for (int i = 0; i < array.Length; i++)
				{
					switch (array[i])
					{
					case "Alice":
						array2[i] = 839819315u;
						break;
					case "Cirno":
						array2[i] = 1900220284u;
						break;
					case "Flandre":
						array2[i] = 2931383634u;
						break;
					case "Marisa":
						array2[i] = 1442397667u;
						break;
					case "Reimu":
						array2[i] = 2713817120u;
						break;
					case "Suika:":
						array2[i] = 2995046728u;
						break;
					}
				}
				if (!Settings.Use)
				{
					return;
				}
				eResourceContainerSpawnType packType = __instance.m_packType;
				if ((int)packType != 0)
				{
					if (packType - 1 > 1)
					{
						if ((int)packType == 9 && __instance.m_actionReceiver != null)
						{
							CM_PageBase.PostSound(array2[3], "");
						}
					}
					else if (__instance.m_actionReceiver != null)
					{
						if ((int)__instance.m_packType == 2)
						{
							CM_PageBase.PostSound(array2[2], "");
						}
						else
						{
							CM_PageBase.PostSound(array2[0], "");
						}
					}
				}
				else if (__instance.m_actionReceiver != null)
				{
					CM_PageBase.PostSound(array2[1], "");
				}
			}
		}

		[ArchivePatch(/*Could not decode attribute arguments.*/)]
		internal static class DrunkHappyどんどんへべれけ
		{
			internal static void Postfix()
			{
				if (Settings.Held)
				{
					CM_PageBase.PostSound(4101038034u, "");
				}
			}
		}

		[ArchivePatch(/*Could not decode attribute arguments.*/)]
		internal static class IAmえぇとJapaneseGoblin
		{
			internal static void Postfix()
			{
				if (Settings.Held)
				{
					CM_PageBase.PostSound(935152106u, "");
				}
			}
		}

		public override string Name => "FumoPacks";

		public override FeatureGroup Group => FeatureGroups.GetOrCreateModuleGroup("", (GroupLocalization)null);

		[FeatureConfig]
		public static あかあおきいろのOnisAndMore Settings { get; set; }

		public override void OnButtonPressed(ButtonSetting setting)
		{
			if (setting.ButtonID.Contains("FumoReset"))
			{
				Logger.Info("The fumos have been reset!");
				GameDataInit.ReInitialize();
				ItemSpawnManager.SetupItemPrefabs();
			}
		}
	}
	[BepInPlugin("HatsuneFucker.FumoPacks.Funky", "FumoPacks", "1.3.2")]
	[BepInDependency(/*Could not decode attribute arguments.*/)]
	internal class WeAreJapaneseGoblin : BasePlugin, IArchiveModule
	{
		public ILocalizationService LocalizationService { get; set; }

		public IArchiveLogger Logger { get; set; }

		public override void Load()
		{
			ArchiveMod.RegisterArchiveModule(typeof(WeAreJapaneseGoblin));
			((BasePlugin)this).Log.LogMessage((object)"Hold on a second!\r\nWhat the heck is Scarlet Police doing right here!?\r\nDance battle is our Ghetto's freezing hot spring\r\nI'll never allow anyone to hinder us!\r\nI'll show you that! My footwork!");
		}

		public void Init()
		{
		}
	}
	public class DoYouHaveAけいのたかとびおにごろし
	{
		public enum DokiDokiWakuWaku
		{
			Reimu_PC98,
			Yuuka,
			Rumia,
			Cirno,
			Meiling,
			Patchouli,
			Sakuya,
			Inu_Sakuya,
			Remilia,
			Kourindou_Remilia,
			Tiny_Devil_Mistress_Remilia,
			Flandre,
			Vampire_Pursuing_The_Hunter_Flandre,
			Chen,
			Alice,
			Shanghai,
			Youmu,
			Yuyuko,
			Tiny_Ghost_Mistress_Yuyuko,
			Ran,
			Yukari,
			Kourindou_Yukari,
			Suika,
			Reimu,
			Blue_Reimu,
			Kourindou_Reimu,
			Marisa,
			Bee_Marisa,
			Tewi,
			Reisen,
			Eirin,
			Mokou,
			Nitori,
			Momiji,
			Aya,
			Sanae,
			Suwako,
			Tenshi,
			Tenshi_No_Hat,
			Parsee,
			Satori,
			Orin,
			Utsuho,
			Koishi,
			Kogasa,
			Nue,
			Mononobe_No_Futo,
			Toyosatomimi_No_Miko,
			HataNoKokoro,
			Kasen,
			Junko,
			Shion,
			Joon,
			Keiki,
			Yuuma_Custom,
			Mike,
			Tsukasa,
			Rinnosuke
		}

		public static Dictionary<DokiDokiWakuWaku, (string name, string surname, string Game)> MuneGaTakanaru = new Dictionary<DokiDokiWakuWaku, (string, string, string)>
		{
			{
				DokiDokiWakuWaku.Reimu_PC98,
				("Reimu", "Hakurei", "LLS")
			},
			{
				DokiDokiWakuWaku.Yuuka,
				("Yuuka", "Kazami", "LLS")
			},
			{
				DokiDokiWakuWaku.Rumia,
				("Rumia", "", "EoSD")
			},
			{
				DokiDokiWakuWaku.Cirno,
				("Cirno", "", "EoSD")
			},
			{
				DokiDokiWakuWaku.Meiling,
				("Meiling", "Hong", "EoSD")
			},
			{
				DokiDokiWakuWaku.Patchouli,
				("Patchouli", "Knowledge", "EoSD")
			},
			{
				DokiDokiWakuWaku.Sakuya,
				("Sakuya", "Izayoi", "EoSD")
			},
			{
				DokiDokiWakuWaku.Remilia,
				("Remilia", "Scarlet", "EoSD")
			},
			{
				DokiDokiWakuWaku.Flandre,
				("Flandre", "Scarlet", "EoSD")
			},
			{
				DokiDokiWakuWaku.Chen,
				("Chen", "", "PCB")
			},
			{
				DokiDokiWakuWaku.Alice,
				("Alice", "Margatroid", "PCB")
			},
			{
				DokiDokiWakuWaku.Shanghai,
				("Shanghai", "", "PCB")
			},
			{
				DokiDokiWakuWaku.Youmu,
				("Youmu", "Konpaku", "PCB")
			},
			{
				DokiDokiWakuWaku.Yuyuko,
				("Yuyuko", "Saigyouji", "PCB")
			},
			{
				DokiDokiWakuWaku.Ran,
				("Ran", "Yakumo", "PCB")
			},
			{
				DokiDokiWakuWaku.Yukari,
				("Yukari", "Yakumo", "PCB")
			},
			{
				DokiDokiWakuWaku.Suika,
				("Suika", "Ibuki", "Side Games")
			},
			{
				DokiDokiWakuWaku.Reimu,
				("Reimu", "Hakurei", "IN")
			},
			{
				DokiDokiWakuWaku.Marisa,
				("Marisa", "Kirisame", "IN")
			},
			{
				DokiDokiWakuWaku.Tewi,
				("Tewi", "Inaba", "IN")
			},
			{
				DokiDokiWakuWaku.Reisen,
				("Reisen", "Udongein Inaba", "IN")
			},
			{
				DokiDokiWakuWaku.Eirin,
				("Eirin", "Yagokoro", "IN")
			},
			{
				DokiDokiWakuWaku.Mokou,
				("Mokou", "Fujiwara no", "IN")
			},
			{
				DokiDokiWakuWaku.Nitori,
				("Nitori", "Kawashiro", "MoF")
			},
			{
				DokiDokiWakuWaku.Momiji,
				("Momiji", "Inubashiri", "MoF")
			},
			{
				DokiDokiWakuWaku.Aya,
				("Aya", "Shimeimaru", "MoF")
			},
			{
				DokiDokiWakuWaku.Sanae,
				("Sanae", "Kochiya", "MoF")
			},
			{
				DokiDokiWakuWaku.Suwako,
				("Suwako", "Moriya", "MoF")
			},
			{
				DokiDokiWakuWaku.Tenshi,
				("Tenshi", "Hinanawi", "Side Games")
			},
			{
				DokiDokiWakuWaku.Tenshi_No_Hat,
				("Tenshi", "Hinanawi", "Side Games")
			},
			{
				DokiDokiWakuWaku.Parsee,
				("Parsee", "Mizuhashi", "SA")
			},
			{
				DokiDokiWakuWaku.Satori,
				("Satori", "Komeiji", "SA")
			},
			{
				DokiDokiWakuWaku.Orin,
				("Rin", "Kaenbyou", "SA")
			},
			{
				DokiDokiWakuWaku.Utsuho,
				("Utsuho", "Reiuji", "SA")
			},
			{
				DokiDokiWakuWaku.Koishi,
				("Koishi", "Komeiji", "SA")
			},
			{
				DokiDokiWakuWaku.Kogasa,
				("Kogasa", "Tatara", "UFO")
			},
			{
				DokiDokiWakuWaku.Nue,
				("Nue", "Houjuu", "UFO")
			},
			{
				DokiDokiWakuWaku.Mononobe_No_Futo,
				("Mononobe no Futo", "", "10D")
			},
			{
				DokiDokiWakuWaku.Toyosatomimi_No_Miko,
				("Toyosatomimi no Miko", "", "10D")
			},
			{
				DokiDokiWakuWaku.HataNoKokoro,
				("Kokoro", "Hata no", "Side Games")
			},
			{
				DokiDokiWakuWaku.Kasen,
				("Kasen", "Ibaraki", "Side Games")
			},
			{
				DokiDokiWakuWaku.Junko,
				("Junko", "", "LoLK")
			},
			{
				DokiDokiWakuWaku.Joon,
				("Joon", "Yorigami", "Side Games")
			},
			{
				DokiDokiWakuWaku.Shion,
				("Shion", "Yorigami", "Side Games")
			},
			{
				DokiDokiWakuWaku.Keiki,
				("Keiki", "Haniyasushin", "WBaWC")
			},
			{
				DokiDokiWakuWaku.Mike,
				("Mike", "Goutokuji", "UM")
			},
			{
				DokiDokiWakuWaku.Tsukasa,
				("Tsukasa", "Kudamaki", "UM")
			},
			{
				DokiDokiWakuWaku.Blue_Reimu,
				("Reimu", "Hakurei", "Reskins")
			},
			{
				DokiDokiWakuWaku.Bee_Marisa,
				("Marisa", "Kirisame", "Reskins")
			},
			{
				DokiDokiWakuWaku.Inu_Sakuya,
				("Sakuya", "Izayoi", "Reskins")
			},
			{
				DokiDokiWakuWaku.Yuuma_Custom,
				("Yuuma", "Toutetsu", "Reskins")
			},
			{
				DokiDokiWakuWaku.Tiny_Devil_Mistress_Remilia,
				("Remilia", "Scarlet", "Reskins")
			},
			{
				DokiDokiWakuWaku.Vampire_Pursuing_The_Hunter_Flandre,
				("Flandre", "Scarlet", "Reskins")
			},
			{
				DokiDokiWakuWaku.Tiny_Ghost_Mistress_Yuyuko,
				("Yuyuko", "Saigyouji", "Reskins")
			},
			{
				DokiDokiWakuWaku.Rinnosuke,
				("Rinnosuke", "Morichika", "Manga")
			},
			{
				DokiDokiWakuWaku.Kourindou_Reimu,
				("Reimu", "Hakurei", "Kourindou")
			},
			{
				DokiDokiWakuWaku.Kourindou_Remilia,
				("Remilia", "Scarlet", "Kourindou")
			},
			{
				DokiDokiWakuWaku.Kourindou_Yukari,
				("Yukari", "Yakumo", "Kourindou")
			}
		};

		public static string[] FumoNameReorder = new string[12]
		{
			"Yuuka", "Meiling", "Youmu", "Reimu", "Mokou", "Eiki", "Kanako", "Nue", "Futo", "Miko",
			"Kokoro", "Yuuma"
		};

		public static DokiDokiWakuWaku[] FumoReskinDirFix = new DokiDokiWakuWaku[7]
		{
			DokiDokiWakuWaku.Bee_Marisa,
			DokiDokiWakuWaku.Blue_Reimu,
			DokiDokiWakuWaku.Inu_Sakuya,
			DokiDokiWakuWaku.Yuuma_Custom,
			DokiDokiWakuWaku.Tiny_Devil_Mistress_Remilia,
			DokiDokiWakuWaku.Vampire_Pursuing_The_Hunter_Flandre,
			DokiDokiWakuWaku.Tiny_Ghost_Mistress_Yuyuko
		};
	}
	internal static class Logger
	{
		private static readonly ManualLogSource _Logger;

		static Logger()
		{
			//IL_0005: Unknown result type (might be due to invalid IL or missing references)
			//IL_000f: Expected O, but got Unknown
			_Logger = new ManualLogSource("Scarlet Police");
			Logger.Sources.Add((ILogSource)(object)_Logger);
		}

		private static string Format(object msg)
		{
			return msg.ToString();
		}

		public static void Info(BepInExInfoLogInterpolatedStringHandler handler)
		{
			_Logger.LogInfo(handler);
		}

		public static void Info(string str)
		{
			_Logger.LogMessage((object)str);
		}

		public static void Info(object data)
		{
			_Logger.LogMessage((object)Format(data));
		}

		public static void Debug(BepInExDebugLogInterpolatedStringHandler handler)
		{
			_Logger.LogDebug(handler);
		}

		public static void Debug(string str)
		{
			_Logger.LogDebug((object)str);
		}

		public static void Debug(object data)
		{
			_Logger.LogDebug((object)Format(data));
		}

		public static void Error(BepInExErrorLogInterpolatedStringHandler handler)
		{
			_Logger.LogError(handler);
		}

		public static void Error(string str)
		{
			_Logger.LogError((object)str);
		}

		public static void Error(object data)
		{
			_Logger.LogError((object)Format(data));
		}

		public static void Fatal(BepInExFatalLogInterpolatedStringHandler handler)
		{
			_Logger.LogFatal(handler);
		}

		public static void Fatal(string str)
		{
			_Logger.LogFatal((object)str);
		}

		public static void Fatal(object data)
		{
			_Logger.LogFatal((object)Format(data));
		}

		public static void Warn(BepInExWarningLogInterpolatedStringHandler handler)
		{
			_Logger.LogWarning(handler);
		}

		public static void Warn(string str)
		{
			_Logger.LogWarning((object)str);
		}

		public static void Warn(object data)
		{
			_Logger.LogWarning((object)Format(data));
		}

		[Conditional("DEBUG")]
		public static void DebugOnly(object data)
		{
		}
	}
}