Decompiled source of Deds Army v0.2.4

DedsArmy.dll

Decompiled 3 months ago
using System;
using System.Collections.Generic;
using System.Diagnostics;
using System.Reflection;
using System.Runtime.CompilerServices;
using System.Runtime.InteropServices;
using System.Runtime.Versioning;
using BepInEx;
using BepInEx.Configuration;
using BepInEx.Logging;
using Jotunn;
using Jotunn.Configs;
using Jotunn.Entities;
using Jotunn.Managers;
using Jotunn.Utils;
using SpawnThat.Spawners;
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("DedsArmy")]
[assembly: AssemblyDescription("")]
[assembly: AssemblyConfiguration("")]
[assembly: AssemblyCompany("")]
[assembly: AssemblyProduct("DedsArmy")]
[assembly: AssemblyCopyright("Copyright ©  2021")]
[assembly: AssemblyTrademark("")]
[assembly: ComVisible(false)]
[assembly: Guid("f8a954d0-0086-4a0d-9a01-6dec89c2830a")]
[assembly: AssemblyFileVersion("1.0.0.0")]
[assembly: TargetFramework(".NETFramework,Version=v4.8", FrameworkDisplayName = ".NET Framework 4.8")]
[assembly: AssemblyVersion("1.0.0.0")]
namespace DedsArmy;

[BepInPlugin("horemvore.DedsArmy", "DedsArmy", "0.2.5")]
[BepInIncompatibility("Azumatt.AzuDevMod")]
[NetworkCompatibility(/*Could not decode attribute arguments.*/)]
[BepInDependency(/*Could not decode attribute arguments.*/)]
internal class DedsArmy : BaseUnityPlugin
{
	public const string PluginGUID = "horemvore.DedsArmy";

	public const string PluginName = "DedsArmy";

	public const string PluginVersion = "0.2.5";

	public ConfigEntry<bool> EnableSpawns;

	public ConfigEntry<bool> UndeadEnable;

	public ConfigEntry<bool> SkeletonsEnable;

	public ConfigEntry<bool> VampireEnable;

	public ConfigEntry<bool> UndeadBossEnable;

	public AssetBundle GhoulBundle;

	public string[] prefabList = new string[17]
	{
		"Skeleton1H_RD_DA", "Skeleton2H_RD_DA", "Undead_RD_DA", "UndeadBoss_RD_DA", "UndeadCarver_RD_DA", "UndeadDesecrator_RD_DA", "UndeadReaver_RD_DA", "UndeadRipper_RD_DA", "Vampire_RD_DA", "AoE_AuraGreenFire_DA",
		"UndeadBoss_Spawn_DA", "FX_Backstab_DA", "FX_Crit_DA", "VFX_Blood_Hit_DA", "VFX_Corpse_Destruction_DA", "VFX_HitSparks_DA", "VFX_SpawnArrive_DA"
	};

	public string[] sfxList = new string[22]
	{
		"SFX_VampireAlert_DA", "SFX_VampireAttack_DA", "SFX_VampireDeath_DA", "SFX_VampireGetHit_DA", "SFX_VampireIdle_DA", "SFX_ZombieAlert_DA", "SFX_ZombieAttack_DA", "SFX_ZombieGetHit_DA", "SFX_ZombieDeath_DA", "SFX_ZombieIdle_DA",
		"SFX_SkeletonAlert_DA", "SFX_SkeletonAttack_DA", "SFX_SkeletonDeath_DA", "SFX_SkeletonGetHit_DA", "SFX_SkeletonIdle_DA", "SFX_SkeletonBossAlert_DA", "SFX_SkeletonBossAttack_DA", "SFX_SkeletonBossDeath_DA", "SFX_SkeletonBossGetHit_DA", "SFX_SkeletonBossIdle_DA",
		"SFX_SkeletonBossAttackAoE_DA", "SFX_SkeletonBossAttackSpawn_DA"
	};

	public string[] itemList = new string[34]
	{
		"Undead_Attack1_DA", "Undead_Attack2_DA", "Undead_Attack3_DA", "Undead_AttackShield1_DA", "Undead_AttackShield2_DA", "Undead_AttackShield3_DA", "Skeleton1H_Attack1_DA", "Skeleton1H_Attack2_DA", "Skeleton1H_Attack3_DA", "Skeleton2H_Attack1_DA",
		"Skeleton2H_Attack2_DA", "Skeleton2H_Attack3_DA", "Vampire_Attack1_DA", "Vampire_Attack2_DA", "Vampire_Attack3_DA", "Vampire_Attack4_DA", "Vampire_Attack5_DA", "UndeadBoss_Attack1_DA", "UndeadBoss_Attack2_DA", "UndeadBoss_Attack3_DA",
		"UndeadBoss_Attack4_DA", "UndeadBoss_Attack5_DA", "UndeadBoss_Attack6_DA", "UndeadBoss_AttackSpawn_DA", "AuraGreenFire_DA", "Trophy_Undead_DA", "Trophy_UndeadCarver_DA", "Trophy_UndeadDesecrator_DA", "Trophy_UndeadReaver_DA", "Trophy_UndeadRipper_DA",
		"Trophy_Skeleton1H_DA", "Trophy_Skeleton2H_DA", "Trophy_Vampire_DA", "Trophy_UndeadBoss_DA"
	};

	private CustomLocalization Localization;

	internal static ManualLogSource Log;

	private void CreateConfigurationValues()
	{
		//IL_002e: Unknown result type (might be due to invalid IL or missing references)
		//IL_0033: Unknown result type (might be due to invalid IL or missing references)
		//IL_003c: Expected O, but got Unknown
		//IL_003c: Unknown result type (might be due to invalid IL or missing references)
		//IL_0046: Expected O, but got Unknown
		//IL_006b: Unknown result type (might be due to invalid IL or missing references)
		//IL_0070: Unknown result type (might be due to invalid IL or missing references)
		//IL_0079: Expected O, but got Unknown
		//IL_0079: Unknown result type (might be due to invalid IL or missing references)
		//IL_0083: Expected O, but got Unknown
		//IL_00a8: Unknown result type (might be due to invalid IL or missing references)
		//IL_00ad: Unknown result type (might be due to invalid IL or missing references)
		//IL_00b6: Expected O, but got Unknown
		//IL_00b6: Unknown result type (might be due to invalid IL or missing references)
		//IL_00c0: Expected O, but got Unknown
		//IL_00e5: Unknown result type (might be due to invalid IL or missing references)
		//IL_00ea: Unknown result type (might be due to invalid IL or missing references)
		//IL_00f3: Expected O, but got Unknown
		//IL_00f3: Unknown result type (might be due to invalid IL or missing references)
		//IL_00fd: Expected O, but got Unknown
		//IL_0122: Unknown result type (might be due to invalid IL or missing references)
		//IL_0127: Unknown result type (might be due to invalid IL or missing references)
		//IL_0130: Expected O, but got Unknown
		//IL_0130: Unknown result type (might be due to invalid IL or missing references)
		//IL_013a: Expected O, but got Unknown
		((BaseUnityPlugin)this).Config.SaveOnConfigSet = true;
		EnableSpawns = ((BaseUnityPlugin)this).Config.Bind<bool>("Spawning", "Enable", true, new ConfigDescription("Enables default swamp biome spawning.", (AcceptableValueBase)null, new object[1] { (object)new ConfigurationManagerAttributes
		{
			IsAdminOnly = true
		} }));
		UndeadEnable = ((BaseUnityPlugin)this).Config.Bind<bool>("Undead Monsters", "Enable", true, new ConfigDescription("Enables Undead prefabs, must disable Spawning if disabled.", (AcceptableValueBase)null, new object[1] { (object)new ConfigurationManagerAttributes
		{
			IsAdminOnly = true
		} }));
		SkeletonsEnable = ((BaseUnityPlugin)this).Config.Bind<bool>("Skeleton Monsters", "Enable", true, new ConfigDescription("Enables Skeleton prefabs, must disable Spawning if disabled.", (AcceptableValueBase)null, new object[1] { (object)new ConfigurationManagerAttributes
		{
			IsAdminOnly = true
		} }));
		VampireEnable = ((BaseUnityPlugin)this).Config.Bind<bool>("Vampire Monster", "Enable", true, new ConfigDescription("Enables Vampire prefab, must disable Spawning if disabled.", (AcceptableValueBase)null, new object[1] { (object)new ConfigurationManagerAttributes
		{
			IsAdminOnly = true
		} }));
		UndeadBossEnable = ((BaseUnityPlugin)this).Config.Bind<bool>("Boss", "Enable", true, new ConfigDescription("Enables Undead Boss prefab. No Spawner included, down to user to use a means of their choice.", (AcceptableValueBase)null, new object[1] { (object)new ConfigurationManagerAttributes
		{
			IsAdminOnly = true
		} }));
		SynchronizationManager.OnConfigurationSynchronized += delegate(object obj, ConfigurationSynchronizationEventArgs attr)
		{
			if (attr.InitialSynchronization)
			{
				Logger.LogMessage((object)"Initial Config sync event received for Deds Army");
			}
			else
			{
				Logger.LogMessage((object)"Config sync event received for Deds Army");
			}
		};
	}

	private void Awake()
	{
		Log = ((BaseUnityPlugin)this).Logger;
		CreateConfigurationValues();
		AddLocalizations();
		LoadBundle();
		AddPrefabs();
		AddSFX();
		AddItems();
		if (UndeadEnable.Value)
		{
			AddUndead();
		}
		if (SkeletonsEnable.Value)
		{
			AddSkeletons();
		}
		if (VampireEnable.Value)
		{
			AddVampire();
		}
		if (UndeadBossEnable.Value)
		{
			AddBosses();
		}
		PrefabManager.OnVanillaPrefabsAvailable += FixSFX;
		if (EnableSpawns.Value)
		{
			try
			{
				SpawnerConfigurationManager.OnConfigure += ConfigureBiomeSpawners;
			}
			catch (Exception value)
			{
				Console.WriteLine(value);
			}
		}
	}

	private void AddLocalizations()
	{
		try
		{
			Localization = LocalizationManager.Instance.GetLocalization();
			CustomLocalization localization = Localization;
			string text = "English";
			localization.AddTranslation(ref text, new Dictionary<string, string>
			{
				{ "item_trophy_undeadboss_da", "Zarathos" },
				{ "item_trophy_undeadboss_desc_da", "Animated trophy of Zarathos" },
				{ "item_trophy_vampire_da", "Vampire" },
				{ "item_trophy_vampire_desc_da", "Animated trophy of a Vampire" },
				{ "item_trophy_skeleton1h_da", "Skeleton" },
				{ "item_trophy_skeleton1h_desc_da", "Animated trophy of a Skeleton with a Sword and Shield" },
				{ "item_trophy_skeleton2h_da", "Skeleton" },
				{ "item_trophy_skeleton2h_desc_da", "Animated trophy of a Skeleton with a Two-Handed Sword" },
				{ "item_trophy_undead_da", "Undead" },
				{ "item_trophy_undead_desc_da", "Animated trophy of an Undead" },
				{ "item_trophy_undeadcarver_da", "Carver" },
				{ "item_trophy_undeadcarver_desc_da", "Animated trophy of an Undead Carver" },
				{ "item_trophy_undeaddesecrator_da", "Desecrator" },
				{ "item_trophy_undeaddesecrator_desc_da", "Animated trophy of an Undead Desecrator" },
				{ "item_trophy_undeadreaver_da", "Reaver" },
				{ "item_trophy_undeadreaver_desc_da", "Animated trophy of an Undead Reaver" },
				{ "item_trophy_undeadripper_da", "Ripper" },
				{ "item_trophy_undeadripper_desc_da", "Animated trophy of an Undead Ripper" },
				{ "enemy_undeadboss_da", "Zarathos" },
				{ "enemy_vampire_da", "Vampire" },
				{ "enemy_skeleton_da", "Cadaver" },
				{ "enemy_undead_da", "Undead" },
				{ "enemy_undeadcarver_da", "Carver" },
				{ "enemy_undeaddesecrator_da", "Desecrator" },
				{ "enemy_undeadreaver_da", "Reaver" },
				{ "enemy_undeadripper_da", "Ripper" }
			});
			CustomLocalization localization2 = Localization;
			text = "Russian";
			localization2.AddTranslation(ref text, new Dictionary<string, string>
			{
				{ "item_trophy_undeadboss_da", "Заратос" },
				{ "item_trophy_undeadboss_desc_da", "Анимированный трофей Заратоса" },
				{ "item_trophy_vampire_da", "Вампир" },
				{ "item_trophy_vampire_desc_da", "Анимированный трофей вампира" },
				{ "item_trophy_skeleton1h_da", "Скелет со щитом" },
				{ "item_trophy_skeleton1h_desc_da", "Анимированный трофей в виде скелета с мечом и щитом" },
				{ "item_trophy_skeleton2h_da", "Скелет с двуручкой" },
				{ "item_trophy_skeleton2h_desc_da", "Анимированный трофей в виде скелета с двуручным мечом" },
				{ "item_trophy_undead_da", "Зомби" },
				{ "item_trophy_undead_desc_da", "Анимированный трофей зомби" },
				{ "item_trophy_undeadcarver_da", "Резатель" },
				{ "item_trophy_undeadcarver_desc_da", "Анимированный трофей зомби-резателя" },
				{ "item_trophy_undeaddesecrator_da", "Осквернитель" },
				{ "item_trophy_undeaddesecrator_desc_da", "Анимированный трофей зомби-осквернителя" },
				{ "item_trophy_undeadreaver_da", "Опустошитель" },
				{ "item_trophy_undeadreaver_desc_da", "Анимированный трофей зомби-опустошителя" },
				{ "item_trophy_undeadripper_da", "Потрошитель" },
				{ "item_trophy_undeadripper_desc_da", "Анимированный трофей зомби-потрошителя" },
				{ "enemy_undeadboss_da", "Заратос" },
				{ "enemy_vampire_da", "Вампир" },
				{ "enemy_skeleton_da", "Скелетон" },
				{ "enemy_undead_da", "Зомби" },
				{ "enemy_undeadcarver_da", "Резатель" },
				{ "enemy_undeaddesecrator_da", "Осквернитель" },
				{ "enemy_undeadreaver_da", "Опустошитель" },
				{ "enemy_undeadripper_da", "Потрошитель" }
			});
		}
		catch (Exception arg)
		{
			((BaseUnityPlugin)this).Logger.LogWarning((object)$"Exception caught while adding Localication for Deds Army: {arg}");
		}
	}

	public void LoadBundle()
	{
		try
		{
			GhoulBundle = AssetUtils.LoadAssetBundleFromResources("dedsarmy", Assembly.GetExecutingAssembly());
		}
		catch (Exception arg)
		{
			((BaseUnityPlugin)this).Logger.LogWarning((object)$"Exception caught while loading Bundle: {arg}");
		}
	}

	private void AddPrefabs()
	{
		//IL_0022: Unknown result type (might be due to invalid IL or missing references)
		//IL_0029: Expected O, but got Unknown
		try
		{
			string[] array = prefabList;
			foreach (string text in array)
			{
				GameObject val = GhoulBundle.LoadAsset<GameObject>(text);
				CustomPrefab val2 = new CustomPrefab(val, true);
				PrefabManager.Instance.AddPrefab(val2);
				((BaseUnityPlugin)this).Logger.LogMessage((object)("Added Prefab: " + text + " to the Object database"));
			}
		}
		catch (Exception arg)
		{
			((BaseUnityPlugin)this).Logger.LogWarning((object)$"Exception caught while adding Prefabs: {arg}");
		}
	}

	private void AddSFX()
	{
		//IL_0022: Unknown result type (might be due to invalid IL or missing references)
		//IL_0029: Expected O, but got Unknown
		try
		{
			string[] array = sfxList;
			foreach (string text in array)
			{
				GameObject val = GhoulBundle.LoadAsset<GameObject>(text);
				CustomPrefab val2 = new CustomPrefab(val, false);
				PrefabManager.Instance.AddPrefab(val2);
				((BaseUnityPlugin)this).Logger.LogMessage((object)("Added Prefab: " + text + " to the Object database"));
			}
		}
		catch (Exception arg)
		{
			((BaseUnityPlugin)this).Logger.LogWarning((object)$"Exception caught while adding Prefabs: {arg}");
		}
	}

	private void AddItems()
	{
		//IL_0022: Unknown result type (might be due to invalid IL or missing references)
		//IL_0029: Expected O, but got Unknown
		try
		{
			string[] array = itemList;
			foreach (string text in array)
			{
				GameObject val = GhoulBundle.LoadAsset<GameObject>(text);
				CustomItem val2 = new CustomItem(val, true);
				ItemManager.Instance.AddItem(val2);
				((BaseUnityPlugin)this).Logger.LogMessage((object)("Added Item: " + text + " to the Object database"));
			}
		}
		catch (Exception arg)
		{
			((BaseUnityPlugin)this).Logger.LogWarning((object)$"Exception caught while adding Items: {arg}");
		}
	}

	private void AddBosses()
	{
		//IL_0015: Unknown result type (might be due to invalid IL or missing references)
		//IL_001b: Expected O, but got Unknown
		//IL_0024: Unknown result type (might be due to invalid IL or missing references)
		//IL_0029: 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_003d: Unknown result type (might be due to invalid IL or missing references)
		//IL_0045: Unknown result type (might be due to invalid IL or missing references)
		//IL_0052: Expected O, but got Unknown
		//IL_0054: Unknown result type (might be due to invalid IL or missing references)
		//IL_0059: Unknown result type (might be due to invalid IL or missing references)
		//IL_0065: Unknown result type (might be due to invalid IL or missing references)
		//IL_006e: Unknown result type (might be due to invalid IL or missing references)
		//IL_0077: Unknown result type (might be due to invalid IL or missing references)
		//IL_0084: Expected O, but got Unknown
		//IL_0086: Unknown result type (might be due to invalid IL or missing references)
		//IL_008b: Unknown result type (might be due to invalid IL or missing references)
		//IL_0097: Unknown result type (might be due to invalid IL or missing references)
		//IL_00a0: Unknown result type (might be due to invalid IL or missing references)
		//IL_00a9: Unknown result type (might be due to invalid IL or missing references)
		//IL_00b6: Expected O, but got Unknown
		//IL_00b8: Unknown result type (might be due to invalid IL or missing references)
		//IL_00bd: Unknown result type (might be due to invalid IL or missing references)
		//IL_00c9: Unknown result type (might be due to invalid IL or missing references)
		//IL_00d2: Unknown result type (might be due to invalid IL or missing references)
		//IL_00db: Unknown result type (might be due to invalid IL or missing references)
		//IL_00e8: Expected O, but got Unknown
		//IL_00ea: Unknown result type (might be due to invalid IL or missing references)
		//IL_00ef: Unknown result type (might be due to invalid IL or missing references)
		//IL_00fb: Unknown result type (might be due to invalid IL or missing references)
		//IL_0104: Unknown result type (might be due to invalid IL or missing references)
		//IL_010d: Unknown result type (might be due to invalid IL or missing references)
		//IL_011a: Expected O, but got Unknown
		//IL_011c: Unknown result type (might be due to invalid IL or missing references)
		//IL_0121: Unknown result type (might be due to invalid IL or missing references)
		//IL_012d: Unknown result type (might be due to invalid IL or missing references)
		//IL_0136: 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_014c: Expected O, but got Unknown
		//IL_014e: 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_015f: Unknown result type (might be due to invalid IL or missing references)
		//IL_0168: Unknown result type (might be due to invalid IL or missing references)
		//IL_0171: Unknown result type (might be due to invalid IL or missing references)
		//IL_017e: Expected O, but got Unknown
		//IL_0180: Unknown result type (might be due to invalid IL or missing references)
		//IL_0185: Unknown result type (might be due to invalid IL or missing references)
		//IL_0191: Unknown result type (might be due to invalid IL or missing references)
		//IL_019a: Unknown result type (might be due to invalid IL or missing references)
		//IL_01a6: Unknown result type (might be due to invalid IL or missing references)
		//IL_01b3: Expected O, but got Unknown
		//IL_01b9: Unknown result type (might be due to invalid IL or missing references)
		//IL_01bf: Expected O, but got Unknown
		try
		{
			GameObject val = GhoulBundle.LoadAsset<GameObject>("UndeadBoss_DA");
			CreatureConfig val2 = new CreatureConfig();
			val2.DropConfigs = (DropConfig[])(object)new DropConfig[8]
			{
				new DropConfig
				{
					Item = "Trophy_UndeadBoss_DA",
					MinAmount = 1,
					MaxAmount = 1,
					Chance = 100f
				},
				new DropConfig
				{
					Item = "IronScrap",
					MinAmount = 10,
					MaxAmount = 20,
					Chance = 75f
				},
				new DropConfig
				{
					Item = "IronOre",
					MinAmount = 10,
					MaxAmount = 20,
					Chance = 75f
				},
				new DropConfig
				{
					Item = "Turnip",
					MinAmount = 10,
					MaxAmount = 20,
					Chance = 75f
				},
				new DropConfig
				{
					Item = "TurnipSeeds",
					MinAmount = 10,
					MaxAmount = 20,
					Chance = 75f
				},
				new DropConfig
				{
					Item = "Bloodbag",
					MinAmount = 10,
					MaxAmount = 20,
					Chance = 75f
				},
				new DropConfig
				{
					Item = "Guck",
					MinAmount = 10,
					MaxAmount = 20,
					Chance = 75f
				},
				new DropConfig
				{
					Item = "Coins",
					MinAmount = 110,
					MaxAmount = 220,
					Chance = 100f
				}
			};
			CustomCreature val3 = new CustomCreature(val, true, val2);
			CreatureManager.Instance.AddCreature(val3);
		}
		catch (Exception arg)
		{
			((BaseUnityPlugin)this).Logger.LogWarning((object)$"Exception caught while adding custom boss for Ded's Army: {arg}");
		}
		finally
		{
			GhoulBundle.Unload(false);
		}
	}

	private void AddVampire()
	{
		//IL_0015: Unknown result type (might be due to invalid IL or missing references)
		//IL_001b: Expected O, but got Unknown
		//IL_0024: Unknown result type (might be due to invalid IL or missing references)
		//IL_0029: 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_003d: Unknown result type (might be due to invalid IL or missing references)
		//IL_0045: Unknown result type (might be due to invalid IL or missing references)
		//IL_0052: Expected O, but got Unknown
		//IL_0054: Unknown result type (might be due to invalid IL or missing references)
		//IL_0059: Unknown result type (might be due to invalid IL or missing references)
		//IL_0065: Unknown result type (might be due to invalid IL or missing references)
		//IL_006d: Unknown result type (might be due to invalid IL or missing references)
		//IL_0075: Unknown result type (might be due to invalid IL or missing references)
		//IL_0082: Expected O, but got Unknown
		//IL_0084: Unknown result type (might be due to invalid IL or missing references)
		//IL_0089: Unknown result type (might be due to invalid IL or missing references)
		//IL_0095: Unknown result type (might be due to invalid IL or missing references)
		//IL_009d: Unknown result type (might be due to invalid IL or missing references)
		//IL_00a5: Unknown result type (might be due to invalid IL or missing references)
		//IL_00b2: Expected O, but got Unknown
		//IL_00b4: Unknown result type (might be due to invalid IL or missing references)
		//IL_00b9: Unknown result type (might be due to invalid IL or missing references)
		//IL_00c5: Unknown result type (might be due to invalid IL or missing references)
		//IL_00cd: Unknown result type (might be due to invalid IL or missing references)
		//IL_00d5: Unknown result type (might be due to invalid IL or missing references)
		//IL_00e2: Expected O, but got Unknown
		//IL_00e4: Unknown result type (might be due to invalid IL or missing references)
		//IL_00e9: Unknown result type (might be due to invalid IL or missing references)
		//IL_00f5: Unknown result type (might be due to invalid IL or missing references)
		//IL_00fd: 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_0112: Expected O, but got Unknown
		//IL_0114: Unknown result type (might be due to invalid IL or missing references)
		//IL_0119: Unknown result type (might be due to invalid IL or missing references)
		//IL_0125: Unknown result type (might be due to invalid IL or missing references)
		//IL_012d: Unknown result type (might be due to invalid IL or missing references)
		//IL_0135: Unknown result type (might be due to invalid IL or missing references)
		//IL_0142: Expected O, but got Unknown
		//IL_0144: Unknown result type (might be due to invalid IL or missing references)
		//IL_0149: Unknown result type (might be due to invalid IL or missing references)
		//IL_0155: Unknown result type (might be due to invalid IL or missing references)
		//IL_015e: Unknown result type (might be due to invalid IL or missing references)
		//IL_0167: Unknown result type (might be due to invalid IL or missing references)
		//IL_0174: Expected O, but got Unknown
		//IL_017a: Unknown result type (might be due to invalid IL or missing references)
		//IL_0180: Expected O, but got Unknown
		try
		{
			GameObject val = GhoulBundle.LoadAsset<GameObject>("Vampire_DA");
			CreatureConfig val2 = new CreatureConfig();
			val2.DropConfigs = (DropConfig[])(object)new DropConfig[7]
			{
				new DropConfig
				{
					Item = "Trophy_Vampire_DA",
					MinAmount = 1,
					MaxAmount = 1,
					Chance = 5f
				},
				new DropConfig
				{
					Item = "IronScrap",
					MinAmount = 1,
					MaxAmount = 2,
					Chance = 5f
				},
				new DropConfig
				{
					Item = "IronOre",
					MinAmount = 1,
					MaxAmount = 2,
					Chance = 3f
				},
				new DropConfig
				{
					Item = "Turnip",
					MinAmount = 1,
					MaxAmount = 2,
					Chance = 15f
				},
				new DropConfig
				{
					Item = "TurnipSeeds",
					MinAmount = 1,
					MaxAmount = 2,
					Chance = 10f
				},
				new DropConfig
				{
					Item = "Bloodbag",
					MinAmount = 2,
					MaxAmount = 5,
					Chance = 75f
				},
				new DropConfig
				{
					Item = "Coins",
					MinAmount = 11,
					MaxAmount = 22,
					Chance = 100f
				}
			};
			CustomCreature val3 = new CustomCreature(val, true, val2);
			CreatureManager.Instance.AddCreature(val3);
		}
		catch (Exception arg)
		{
			((BaseUnityPlugin)this).Logger.LogWarning((object)$"Exception caught while adding custom vampire for Ded's Army: {arg}");
		}
	}

	private void AddSkeletons()
	{
		//IL_0015: Unknown result type (might be due to invalid IL or missing references)
		//IL_001c: Expected O, but got Unknown
		//IL_0026: Unknown result type (might be due to invalid IL or missing references)
		//IL_002b: Unknown result type (might be due to invalid IL or missing references)
		//IL_0037: 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_0047: Unknown result type (might be due to invalid IL or missing references)
		//IL_0054: Expected O, but got Unknown
		//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_0067: Unknown result type (might be due to invalid IL or missing references)
		//IL_006f: Unknown result type (might be due to invalid IL or missing references)
		//IL_0077: Unknown result type (might be due to invalid IL or missing references)
		//IL_0084: Expected O, but got Unknown
		//IL_0086: Unknown result type (might be due to invalid IL or missing references)
		//IL_008b: Unknown result type (might be due to invalid IL or missing references)
		//IL_0097: Unknown result type (might be due to invalid IL or missing references)
		//IL_009f: Unknown result type (might be due to invalid IL or missing references)
		//IL_00a7: Unknown result type (might be due to invalid IL or missing references)
		//IL_00b4: Expected O, but got Unknown
		//IL_00b6: Unknown result type (might be due to invalid IL or missing references)
		//IL_00bb: Unknown result type (might be due to invalid IL or missing references)
		//IL_00c7: Unknown result type (might be due to invalid IL or missing references)
		//IL_00cf: Unknown result type (might be due to invalid IL or missing references)
		//IL_00d7: Unknown result type (might be due to invalid IL or missing references)
		//IL_00e4: Expected O, but got Unknown
		//IL_00e6: Unknown result type (might be due to invalid IL or missing references)
		//IL_00eb: Unknown result type (might be due to invalid IL or missing references)
		//IL_00f7: Unknown result type (might be due to invalid IL or missing references)
		//IL_00ff: Unknown result type (might be due to invalid IL or missing references)
		//IL_0107: Unknown result type (might be due to invalid IL or missing references)
		//IL_0114: Expected O, but got Unknown
		//IL_0116: Unknown result type (might be due to invalid IL or missing references)
		//IL_011b: Unknown result type (might be due to invalid IL or missing references)
		//IL_0127: Unknown result type (might be due to invalid IL or missing references)
		//IL_012f: Unknown result type (might be due to invalid IL or missing references)
		//IL_0137: Unknown result type (might be due to invalid IL or missing references)
		//IL_0144: Expected O, but got Unknown
		//IL_0146: Unknown result type (might be due to invalid IL or missing references)
		//IL_014b: Unknown result type (might be due to invalid IL or missing references)
		//IL_0157: Unknown result type (might be due to invalid IL or missing references)
		//IL_0160: Unknown result type (might be due to invalid IL or missing references)
		//IL_0169: Unknown result type (might be due to invalid IL or missing references)
		//IL_0176: Expected O, but got Unknown
		//IL_017d: Unknown result type (might be due to invalid IL or missing references)
		//IL_0183: Expected O, but got Unknown
		//IL_01a2: Unknown result type (might be due to invalid IL or missing references)
		//IL_01a9: Expected O, but got Unknown
		//IL_01b3: Unknown result type (might be due to invalid IL or missing references)
		//IL_01b8: Unknown result type (might be due to invalid IL or missing references)
		//IL_01c4: Unknown result type (might be due to invalid IL or missing references)
		//IL_01cc: Unknown result type (might be due to invalid IL or missing references)
		//IL_01d4: Unknown result type (might be due to invalid IL or missing references)
		//IL_01e1: Expected O, but got Unknown
		//IL_01e3: Unknown result type (might be due to invalid IL or missing references)
		//IL_01e8: Unknown result type (might be due to invalid IL or missing references)
		//IL_01f4: Unknown result type (might be due to invalid IL or missing references)
		//IL_01fc: Unknown result type (might be due to invalid IL or missing references)
		//IL_0204: Unknown result type (might be due to invalid IL or missing references)
		//IL_0211: Expected O, but got Unknown
		//IL_0213: Unknown result type (might be due to invalid IL or missing references)
		//IL_0218: Unknown result type (might be due to invalid IL or missing references)
		//IL_0224: Unknown result type (might be due to invalid IL or missing references)
		//IL_022c: Unknown result type (might be due to invalid IL or missing references)
		//IL_0234: Unknown result type (might be due to invalid IL or missing references)
		//IL_0241: Expected O, but got Unknown
		//IL_0243: Unknown result type (might be due to invalid IL or missing references)
		//IL_0248: Unknown result type (might be due to invalid IL or missing references)
		//IL_0254: Unknown result type (might be due to invalid IL or missing references)
		//IL_025c: Unknown result type (might be due to invalid IL or missing references)
		//IL_0264: Unknown result type (might be due to invalid IL or missing references)
		//IL_0271: Expected O, but got Unknown
		//IL_0273: Unknown result type (might be due to invalid IL or missing references)
		//IL_0278: Unknown result type (might be due to invalid IL or missing references)
		//IL_0284: Unknown result type (might be due to invalid IL or missing references)
		//IL_028c: Unknown result type (might be due to invalid IL or missing references)
		//IL_0294: Unknown result type (might be due to invalid IL or missing references)
		//IL_02a1: Expected O, but got Unknown
		//IL_02a3: Unknown result type (might be due to invalid IL or missing references)
		//IL_02a8: Unknown result type (might be due to invalid IL or missing references)
		//IL_02b4: Unknown result type (might be due to invalid IL or missing references)
		//IL_02bc: Unknown result type (might be due to invalid IL or missing references)
		//IL_02c4: Unknown result type (might be due to invalid IL or missing references)
		//IL_02d1: Expected O, but got Unknown
		//IL_02d3: Unknown result type (might be due to invalid IL or missing references)
		//IL_02d8: Unknown result type (might be due to invalid IL or missing references)
		//IL_02e4: Unknown result type (might be due to invalid IL or missing references)
		//IL_02ed: Unknown result type (might be due to invalid IL or missing references)
		//IL_02f6: Unknown result type (might be due to invalid IL or missing references)
		//IL_0303: Expected O, but got Unknown
		//IL_030a: Unknown result type (might be due to invalid IL or missing references)
		//IL_0310: Expected O, but got Unknown
		try
		{
			GameObject val = GhoulBundle.LoadAsset<GameObject>("Skeleton1H_DA");
			CreatureConfig val2 = new CreatureConfig();
			val2.DropConfigs = (DropConfig[])(object)new DropConfig[7]
			{
				new DropConfig
				{
					Item = "Trophy_Skeleton1H_DA",
					MinAmount = 1,
					MaxAmount = 1,
					Chance = 5f
				},
				new DropConfig
				{
					Item = "IronScrap",
					MinAmount = 1,
					MaxAmount = 2,
					Chance = 5f
				},
				new DropConfig
				{
					Item = "IronOre",
					MinAmount = 1,
					MaxAmount = 2,
					Chance = 3f
				},
				new DropConfig
				{
					Item = "Turnip",
					MinAmount = 1,
					MaxAmount = 2,
					Chance = 15f
				},
				new DropConfig
				{
					Item = "TurnipSeeds",
					MinAmount = 1,
					MaxAmount = 2,
					Chance = 10f
				},
				new DropConfig
				{
					Item = "BoneFragments",
					MinAmount = 2,
					MaxAmount = 5,
					Chance = 75f
				},
				new DropConfig
				{
					Item = "Coins",
					MinAmount = 11,
					MaxAmount = 22,
					Chance = 100f
				}
			};
			CustomCreature val3 = new CustomCreature(val, true, val2);
			CreatureManager.Instance.AddCreature(val3);
			GameObject val4 = GhoulBundle.LoadAsset<GameObject>("Skeleton2H_DA");
			val2 = new CreatureConfig();
			val2.DropConfigs = (DropConfig[])(object)new DropConfig[7]
			{
				new DropConfig
				{
					Item = "Trophy_Skeleton2H_DA",
					MinAmount = 1,
					MaxAmount = 1,
					Chance = 5f
				},
				new DropConfig
				{
					Item = "IronScrap",
					MinAmount = 1,
					MaxAmount = 2,
					Chance = 5f
				},
				new DropConfig
				{
					Item = "IronOre",
					MinAmount = 1,
					MaxAmount = 2,
					Chance = 3f
				},
				new DropConfig
				{
					Item = "Turnip",
					MinAmount = 1,
					MaxAmount = 2,
					Chance = 15f
				},
				new DropConfig
				{
					Item = "TurnipSeeds",
					MinAmount = 1,
					MaxAmount = 2,
					Chance = 10f
				},
				new DropConfig
				{
					Item = "BoneFragments",
					MinAmount = 2,
					MaxAmount = 5,
					Chance = 75f
				},
				new DropConfig
				{
					Item = "Coins",
					MinAmount = 11,
					MaxAmount = 22,
					Chance = 100f
				}
			};
			CustomCreature val5 = new CustomCreature(val4, true, val2);
			CreatureManager.Instance.AddCreature(val5);
		}
		catch (Exception arg)
		{
			((BaseUnityPlugin)this).Logger.LogWarning((object)$"Exception caught while adding custom skeletons for Ded's Army: {arg}");
		}
	}

	private void AddUndead()
	{
		//IL_0015: Unknown result type (might be due to invalid IL or missing references)
		//IL_001c: Expected O, but got Unknown
		//IL_0026: Unknown result type (might be due to invalid IL or missing references)
		//IL_002b: Unknown result type (might be due to invalid IL or missing references)
		//IL_0037: 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_0047: Unknown result type (might be due to invalid IL or missing references)
		//IL_0054: Expected O, but got Unknown
		//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_0067: Unknown result type (might be due to invalid IL or missing references)
		//IL_006f: Unknown result type (might be due to invalid IL or missing references)
		//IL_0077: Unknown result type (might be due to invalid IL or missing references)
		//IL_0084: Expected O, but got Unknown
		//IL_0086: Unknown result type (might be due to invalid IL or missing references)
		//IL_008b: Unknown result type (might be due to invalid IL or missing references)
		//IL_0097: Unknown result type (might be due to invalid IL or missing references)
		//IL_009f: Unknown result type (might be due to invalid IL or missing references)
		//IL_00a7: Unknown result type (might be due to invalid IL or missing references)
		//IL_00b4: Expected O, but got Unknown
		//IL_00b6: Unknown result type (might be due to invalid IL or missing references)
		//IL_00bb: Unknown result type (might be due to invalid IL or missing references)
		//IL_00c7: Unknown result type (might be due to invalid IL or missing references)
		//IL_00cf: Unknown result type (might be due to invalid IL or missing references)
		//IL_00d7: Unknown result type (might be due to invalid IL or missing references)
		//IL_00e4: Expected O, but got Unknown
		//IL_00e6: Unknown result type (might be due to invalid IL or missing references)
		//IL_00eb: Unknown result type (might be due to invalid IL or missing references)
		//IL_00f7: Unknown result type (might be due to invalid IL or missing references)
		//IL_00ff: Unknown result type (might be due to invalid IL or missing references)
		//IL_0107: Unknown result type (might be due to invalid IL or missing references)
		//IL_0114: Expected O, but got Unknown
		//IL_0116: Unknown result type (might be due to invalid IL or missing references)
		//IL_011b: Unknown result type (might be due to invalid IL or missing references)
		//IL_0127: Unknown result type (might be due to invalid IL or missing references)
		//IL_012f: Unknown result type (might be due to invalid IL or missing references)
		//IL_0137: Unknown result type (might be due to invalid IL or missing references)
		//IL_0144: Expected O, but got Unknown
		//IL_0146: Unknown result type (might be due to invalid IL or missing references)
		//IL_014b: Unknown result type (might be due to invalid IL or missing references)
		//IL_0157: Unknown result type (might be due to invalid IL or missing references)
		//IL_015f: Unknown result type (might be due to invalid IL or missing references)
		//IL_0167: Unknown result type (might be due to invalid IL or missing references)
		//IL_0174: Expected O, but got Unknown
		//IL_0176: Unknown result type (might be due to invalid IL or missing references)
		//IL_017b: Unknown result type (might be due to invalid IL or missing references)
		//IL_0187: Unknown result type (might be due to invalid IL or missing references)
		//IL_0190: Unknown result type (might be due to invalid IL or missing references)
		//IL_0199: Unknown result type (might be due to invalid IL or missing references)
		//IL_01a6: Expected O, but got Unknown
		//IL_01ad: Unknown result type (might be due to invalid IL or missing references)
		//IL_01b3: Expected O, but got Unknown
		//IL_01d2: Unknown result type (might be due to invalid IL or missing references)
		//IL_01d9: Expected O, but got Unknown
		//IL_01e3: Unknown result type (might be due to invalid IL or missing references)
		//IL_01e8: Unknown result type (might be due to invalid IL or missing references)
		//IL_01f4: Unknown result type (might be due to invalid IL or missing references)
		//IL_01fc: Unknown result type (might be due to invalid IL or missing references)
		//IL_0204: Unknown result type (might be due to invalid IL or missing references)
		//IL_0211: Expected O, but got Unknown
		//IL_0213: Unknown result type (might be due to invalid IL or missing references)
		//IL_0218: Unknown result type (might be due to invalid IL or missing references)
		//IL_0224: Unknown result type (might be due to invalid IL or missing references)
		//IL_022c: Unknown result type (might be due to invalid IL or missing references)
		//IL_0234: Unknown result type (might be due to invalid IL or missing references)
		//IL_0241: Expected O, but got Unknown
		//IL_0243: Unknown result type (might be due to invalid IL or missing references)
		//IL_0248: Unknown result type (might be due to invalid IL or missing references)
		//IL_0254: Unknown result type (might be due to invalid IL or missing references)
		//IL_025c: Unknown result type (might be due to invalid IL or missing references)
		//IL_0264: Unknown result type (might be due to invalid IL or missing references)
		//IL_0271: Expected O, but got Unknown
		//IL_0273: Unknown result type (might be due to invalid IL or missing references)
		//IL_0278: Unknown result type (might be due to invalid IL or missing references)
		//IL_0284: Unknown result type (might be due to invalid IL or missing references)
		//IL_028c: Unknown result type (might be due to invalid IL or missing references)
		//IL_0294: Unknown result type (might be due to invalid IL or missing references)
		//IL_02a1: Expected O, but got Unknown
		//IL_02a3: Unknown result type (might be due to invalid IL or missing references)
		//IL_02a8: Unknown result type (might be due to invalid IL or missing references)
		//IL_02b4: Unknown result type (might be due to invalid IL or missing references)
		//IL_02bc: Unknown result type (might be due to invalid IL or missing references)
		//IL_02c4: Unknown result type (might be due to invalid IL or missing references)
		//IL_02d1: Expected O, but got Unknown
		//IL_02d3: Unknown result type (might be due to invalid IL or missing references)
		//IL_02d8: Unknown result type (might be due to invalid IL or missing references)
		//IL_02e4: Unknown result type (might be due to invalid IL or missing references)
		//IL_02ec: Unknown result type (might be due to invalid IL or missing references)
		//IL_02f4: Unknown result type (might be due to invalid IL or missing references)
		//IL_0301: Expected O, but got Unknown
		//IL_0303: Unknown result type (might be due to invalid IL or missing references)
		//IL_0308: Unknown result type (might be due to invalid IL or missing references)
		//IL_0314: Unknown result type (might be due to invalid IL or missing references)
		//IL_031c: Unknown result type (might be due to invalid IL or missing references)
		//IL_0324: Unknown result type (might be due to invalid IL or missing references)
		//IL_0331: Expected O, but got Unknown
		//IL_0333: Unknown result type (might be due to invalid IL or missing references)
		//IL_0338: Unknown result type (might be due to invalid IL or missing references)
		//IL_0344: Unknown result type (might be due to invalid IL or missing references)
		//IL_034d: Unknown result type (might be due to invalid IL or missing references)
		//IL_0356: Unknown result type (might be due to invalid IL or missing references)
		//IL_0363: Expected O, but got Unknown
		//IL_036a: Unknown result type (might be due to invalid IL or missing references)
		//IL_0370: Expected O, but got Unknown
		//IL_0391: Unknown result type (might be due to invalid IL or missing references)
		//IL_0398: Expected O, but got Unknown
		//IL_03a2: Unknown result type (might be due to invalid IL or missing references)
		//IL_03a7: Unknown result type (might be due to invalid IL or missing references)
		//IL_03b3: Unknown result type (might be due to invalid IL or missing references)
		//IL_03bb: Unknown result type (might be due to invalid IL or missing references)
		//IL_03c3: Unknown result type (might be due to invalid IL or missing references)
		//IL_03d0: Expected O, but got Unknown
		//IL_03d2: Unknown result type (might be due to invalid IL or missing references)
		//IL_03d7: Unknown result type (might be due to invalid IL or missing references)
		//IL_03e3: Unknown result type (might be due to invalid IL or missing references)
		//IL_03eb: Unknown result type (might be due to invalid IL or missing references)
		//IL_03f3: Unknown result type (might be due to invalid IL or missing references)
		//IL_0400: Expected O, but got Unknown
		//IL_0402: Unknown result type (might be due to invalid IL or missing references)
		//IL_0407: Unknown result type (might be due to invalid IL or missing references)
		//IL_0413: Unknown result type (might be due to invalid IL or missing references)
		//IL_041b: Unknown result type (might be due to invalid IL or missing references)
		//IL_0423: Unknown result type (might be due to invalid IL or missing references)
		//IL_0430: Expected O, but got Unknown
		//IL_0432: Unknown result type (might be due to invalid IL or missing references)
		//IL_0437: Unknown result type (might be due to invalid IL or missing references)
		//IL_0443: Unknown result type (might be due to invalid IL or missing references)
		//IL_044b: Unknown result type (might be due to invalid IL or missing references)
		//IL_0453: Unknown result type (might be due to invalid IL or missing references)
		//IL_0460: Expected O, but got Unknown
		//IL_0462: Unknown result type (might be due to invalid IL or missing references)
		//IL_0467: Unknown result type (might be due to invalid IL or missing references)
		//IL_0473: Unknown result type (might be due to invalid IL or missing references)
		//IL_047b: Unknown result type (might be due to invalid IL or missing references)
		//IL_0483: Unknown result type (might be due to invalid IL or missing references)
		//IL_0490: Expected O, but got Unknown
		//IL_0492: Unknown result type (might be due to invalid IL or missing references)
		//IL_0497: Unknown result type (might be due to invalid IL or missing references)
		//IL_04a3: Unknown result type (might be due to invalid IL or missing references)
		//IL_04ab: Unknown result type (might be due to invalid IL or missing references)
		//IL_04b3: Unknown result type (might be due to invalid IL or missing references)
		//IL_04c0: Expected O, but got Unknown
		//IL_04c2: Unknown result type (might be due to invalid IL or missing references)
		//IL_04c7: Unknown result type (might be due to invalid IL or missing references)
		//IL_04d3: Unknown result type (might be due to invalid IL or missing references)
		//IL_04db: Unknown result type (might be due to invalid IL or missing references)
		//IL_04e3: Unknown result type (might be due to invalid IL or missing references)
		//IL_04f0: Expected O, but got Unknown
		//IL_04f2: Unknown result type (might be due to invalid IL or missing references)
		//IL_04f7: Unknown result type (might be due to invalid IL or missing references)
		//IL_0503: Unknown result type (might be due to invalid IL or missing references)
		//IL_050c: Unknown result type (might be due to invalid IL or missing references)
		//IL_0515: Unknown result type (might be due to invalid IL or missing references)
		//IL_0522: Expected O, but got Unknown
		//IL_0529: Unknown result type (might be due to invalid IL or missing references)
		//IL_0530: Expected O, but got Unknown
		//IL_0552: Unknown result type (might be due to invalid IL or missing references)
		//IL_0559: Expected O, but got Unknown
		//IL_0563: Unknown result type (might be due to invalid IL or missing references)
		//IL_0568: Unknown result type (might be due to invalid IL or missing references)
		//IL_0574: Unknown result type (might be due to invalid IL or missing references)
		//IL_057c: Unknown result type (might be due to invalid IL or missing references)
		//IL_0584: Unknown result type (might be due to invalid IL or missing references)
		//IL_0591: Expected O, but got Unknown
		//IL_0593: Unknown result type (might be due to invalid IL or missing references)
		//IL_0598: Unknown result type (might be due to invalid IL or missing references)
		//IL_05a4: Unknown result type (might be due to invalid IL or missing references)
		//IL_05ac: Unknown result type (might be due to invalid IL or missing references)
		//IL_05b4: Unknown result type (might be due to invalid IL or missing references)
		//IL_05c1: Expected O, but got Unknown
		//IL_05c3: Unknown result type (might be due to invalid IL or missing references)
		//IL_05c8: Unknown result type (might be due to invalid IL or missing references)
		//IL_05d4: Unknown result type (might be due to invalid IL or missing references)
		//IL_05dc: Unknown result type (might be due to invalid IL or missing references)
		//IL_05e4: Unknown result type (might be due to invalid IL or missing references)
		//IL_05f1: Expected O, but got Unknown
		//IL_05f3: Unknown result type (might be due to invalid IL or missing references)
		//IL_05f8: Unknown result type (might be due to invalid IL or missing references)
		//IL_0604: Unknown result type (might be due to invalid IL or missing references)
		//IL_060c: Unknown result type (might be due to invalid IL or missing references)
		//IL_0614: Unknown result type (might be due to invalid IL or missing references)
		//IL_0621: Expected O, but got Unknown
		//IL_0623: Unknown result type (might be due to invalid IL or missing references)
		//IL_0628: Unknown result type (might be due to invalid IL or missing references)
		//IL_0634: Unknown result type (might be due to invalid IL or missing references)
		//IL_063c: Unknown result type (might be due to invalid IL or missing references)
		//IL_0644: Unknown result type (might be due to invalid IL or missing references)
		//IL_0651: Expected O, but got Unknown
		//IL_0653: Unknown result type (might be due to invalid IL or missing references)
		//IL_0658: Unknown result type (might be due to invalid IL or missing references)
		//IL_0664: Unknown result type (might be due to invalid IL or missing references)
		//IL_066c: Unknown result type (might be due to invalid IL or missing references)
		//IL_0674: Unknown result type (might be due to invalid IL or missing references)
		//IL_0681: Expected O, but got Unknown
		//IL_0683: Unknown result type (might be due to invalid IL or missing references)
		//IL_0688: Unknown result type (might be due to invalid IL or missing references)
		//IL_0694: Unknown result type (might be due to invalid IL or missing references)
		//IL_069c: Unknown result type (might be due to invalid IL or missing references)
		//IL_06a4: Unknown result type (might be due to invalid IL or missing references)
		//IL_06b1: Expected O, but got Unknown
		//IL_06b3: Unknown result type (might be due to invalid IL or missing references)
		//IL_06b8: Unknown result type (might be due to invalid IL or missing references)
		//IL_06c4: Unknown result type (might be due to invalid IL or missing references)
		//IL_06cd: Unknown result type (might be due to invalid IL or missing references)
		//IL_06d6: Unknown result type (might be due to invalid IL or missing references)
		//IL_06e3: Expected O, but got Unknown
		//IL_06ea: Unknown result type (might be due to invalid IL or missing references)
		//IL_06f1: Expected O, but got Unknown
		//IL_0713: Unknown result type (might be due to invalid IL or missing references)
		//IL_071a: Expected O, but got Unknown
		//IL_0724: Unknown result type (might be due to invalid IL or missing references)
		//IL_0729: Unknown result type (might be due to invalid IL or missing references)
		//IL_0735: Unknown result type (might be due to invalid IL or missing references)
		//IL_073d: Unknown result type (might be due to invalid IL or missing references)
		//IL_0745: Unknown result type (might be due to invalid IL or missing references)
		//IL_0752: Expected O, but got Unknown
		//IL_0754: Unknown result type (might be due to invalid IL or missing references)
		//IL_0759: Unknown result type (might be due to invalid IL or missing references)
		//IL_0765: Unknown result type (might be due to invalid IL or missing references)
		//IL_076d: Unknown result type (might be due to invalid IL or missing references)
		//IL_0775: Unknown result type (might be due to invalid IL or missing references)
		//IL_0782: Expected O, but got Unknown
		//IL_0784: Unknown result type (might be due to invalid IL or missing references)
		//IL_0789: Unknown result type (might be due to invalid IL or missing references)
		//IL_0795: Unknown result type (might be due to invalid IL or missing references)
		//IL_079d: Unknown result type (might be due to invalid IL or missing references)
		//IL_07a5: Unknown result type (might be due to invalid IL or missing references)
		//IL_07b2: Expected O, but got Unknown
		//IL_07b4: Unknown result type (might be due to invalid IL or missing references)
		//IL_07b9: Unknown result type (might be due to invalid IL or missing references)
		//IL_07c5: Unknown result type (might be due to invalid IL or missing references)
		//IL_07cd: Unknown result type (might be due to invalid IL or missing references)
		//IL_07d5: Unknown result type (might be due to invalid IL or missing references)
		//IL_07e2: Expected O, but got Unknown
		//IL_07e4: Unknown result type (might be due to invalid IL or missing references)
		//IL_07e9: Unknown result type (might be due to invalid IL or missing references)
		//IL_07f5: Unknown result type (might be due to invalid IL or missing references)
		//IL_07fd: Unknown result type (might be due to invalid IL or missing references)
		//IL_0805: Unknown result type (might be due to invalid IL or missing references)
		//IL_0812: Expected O, but got Unknown
		//IL_0814: Unknown result type (might be due to invalid IL or missing references)
		//IL_0819: Unknown result type (might be due to invalid IL or missing references)
		//IL_0825: Unknown result type (might be due to invalid IL or missing references)
		//IL_082d: Unknown result type (might be due to invalid IL or missing references)
		//IL_0835: Unknown result type (might be due to invalid IL or missing references)
		//IL_0842: Expected O, but got Unknown
		//IL_0844: Unknown result type (might be due to invalid IL or missing references)
		//IL_0849: Unknown result type (might be due to invalid IL or missing references)
		//IL_0855: Unknown result type (might be due to invalid IL or missing references)
		//IL_085d: Unknown result type (might be due to invalid IL or missing references)
		//IL_0865: Unknown result type (might be due to invalid IL or missing references)
		//IL_0872: Expected O, but got Unknown
		//IL_0874: Unknown result type (might be due to invalid IL or missing references)
		//IL_0879: Unknown result type (might be due to invalid IL or missing references)
		//IL_0885: Unknown result type (might be due to invalid IL or missing references)
		//IL_088e: Unknown result type (might be due to invalid IL or missing references)
		//IL_0897: Unknown result type (might be due to invalid IL or missing references)
		//IL_08a4: Expected O, but got Unknown
		//IL_08ab: Unknown result type (might be due to invalid IL or missing references)
		//IL_08b2: Expected O, but got Unknown
		try
		{
			GameObject val = GhoulBundle.LoadAsset<GameObject>("Undead_DA");
			CreatureConfig val2 = new CreatureConfig();
			val2.DropConfigs = (DropConfig[])(object)new DropConfig[8]
			{
				new DropConfig
				{
					Item = "Trophy_Undead_DA",
					MinAmount = 1,
					MaxAmount = 1,
					Chance = 5f
				},
				new DropConfig
				{
					Item = "IronScrap",
					MinAmount = 1,
					MaxAmount = 2,
					Chance = 5f
				},
				new DropConfig
				{
					Item = "IronOre",
					MinAmount = 1,
					MaxAmount = 2,
					Chance = 3f
				},
				new DropConfig
				{
					Item = "Turnip",
					MinAmount = 1,
					MaxAmount = 2,
					Chance = 15f
				},
				new DropConfig
				{
					Item = "TurnipSeeds",
					MinAmount = 1,
					MaxAmount = 2,
					Chance = 10f
				},
				new DropConfig
				{
					Item = "Ooze",
					MinAmount = 1,
					MaxAmount = 3,
					Chance = 75f
				},
				new DropConfig
				{
					Item = "Guck",
					MinAmount = 1,
					MaxAmount = 3,
					Chance = 25f
				},
				new DropConfig
				{
					Item = "Coins",
					MinAmount = 11,
					MaxAmount = 22,
					Chance = 100f
				}
			};
			CustomCreature val3 = new CustomCreature(val, true, val2);
			CreatureManager.Instance.AddCreature(val3);
			GameObject val4 = GhoulBundle.LoadAsset<GameObject>("UndeadCarver_DA");
			val2 = new CreatureConfig();
			val2.DropConfigs = (DropConfig[])(object)new DropConfig[8]
			{
				new DropConfig
				{
					Item = "Trophy_UndeadCarver_DA",
					MinAmount = 1,
					MaxAmount = 1,
					Chance = 5f
				},
				new DropConfig
				{
					Item = "IronScrap",
					MinAmount = 1,
					MaxAmount = 2,
					Chance = 5f
				},
				new DropConfig
				{
					Item = "IronOre",
					MinAmount = 1,
					MaxAmount = 2,
					Chance = 3f
				},
				new DropConfig
				{
					Item = "Turnip",
					MinAmount = 1,
					MaxAmount = 2,
					Chance = 15f
				},
				new DropConfig
				{
					Item = "TurnipSeeds",
					MinAmount = 1,
					MaxAmount = 2,
					Chance = 10f
				},
				new DropConfig
				{
					Item = "Ooze",
					MinAmount = 1,
					MaxAmount = 3,
					Chance = 75f
				},
				new DropConfig
				{
					Item = "Guck",
					MinAmount = 1,
					MaxAmount = 3,
					Chance = 25f
				},
				new DropConfig
				{
					Item = "Coins",
					MinAmount = 11,
					MaxAmount = 22,
					Chance = 100f
				}
			};
			CustomCreature val5 = new CustomCreature(val4, true, val2);
			CreatureManager.Instance.AddCreature(val5);
			GameObject val6 = GhoulBundle.LoadAsset<GameObject>("UndeadDesecrator_DA");
			val2 = new CreatureConfig();
			val2.DropConfigs = (DropConfig[])(object)new DropConfig[8]
			{
				new DropConfig
				{
					Item = "Trophy_UndeadDesecrator_DA",
					MinAmount = 1,
					MaxAmount = 1,
					Chance = 5f
				},
				new DropConfig
				{
					Item = "IronScrap",
					MinAmount = 1,
					MaxAmount = 2,
					Chance = 5f
				},
				new DropConfig
				{
					Item = "IronOre",
					MinAmount = 1,
					MaxAmount = 2,
					Chance = 3f
				},
				new DropConfig
				{
					Item = "Turnip",
					MinAmount = 1,
					MaxAmount = 2,
					Chance = 15f
				},
				new DropConfig
				{
					Item = "TurnipSeeds",
					MinAmount = 1,
					MaxAmount = 2,
					Chance = 10f
				},
				new DropConfig
				{
					Item = "Ooze",
					MinAmount = 1,
					MaxAmount = 3,
					Chance = 75f
				},
				new DropConfig
				{
					Item = "Guck",
					MinAmount = 1,
					MaxAmount = 3,
					Chance = 25f
				},
				new DropConfig
				{
					Item = "Coins",
					MinAmount = 11,
					MaxAmount = 22,
					Chance = 100f
				}
			};
			CustomCreature val7 = new CustomCreature(val6, true, val2);
			CreatureManager.Instance.AddCreature(val7);
			GameObject val8 = GhoulBundle.LoadAsset<GameObject>("UndeadReaver_DA");
			val2 = new CreatureConfig();
			val2.DropConfigs = (DropConfig[])(object)new DropConfig[8]
			{
				new DropConfig
				{
					Item = "Trophy_UndeadReaver_DA",
					MinAmount = 1,
					MaxAmount = 1,
					Chance = 5f
				},
				new DropConfig
				{
					Item = "IronScrap",
					MinAmount = 1,
					MaxAmount = 2,
					Chance = 5f
				},
				new DropConfig
				{
					Item = "IronOre",
					MinAmount = 1,
					MaxAmount = 2,
					Chance = 3f
				},
				new DropConfig
				{
					Item = "Turnip",
					MinAmount = 1,
					MaxAmount = 2,
					Chance = 15f
				},
				new DropConfig
				{
					Item = "TurnipSeeds",
					MinAmount = 1,
					MaxAmount = 2,
					Chance = 10f
				},
				new DropConfig
				{
					Item = "Ooze",
					MinAmount = 1,
					MaxAmount = 3,
					Chance = 75f
				},
				new DropConfig
				{
					Item = "Guck",
					MinAmount = 1,
					MaxAmount = 3,
					Chance = 25f
				},
				new DropConfig
				{
					Item = "Coins",
					MinAmount = 11,
					MaxAmount = 22,
					Chance = 100f
				}
			};
			CustomCreature val9 = new CustomCreature(val8, true, val2);
			CreatureManager.Instance.AddCreature(val9);
			GameObject val10 = GhoulBundle.LoadAsset<GameObject>("UndeadRipper_DA");
			val2 = new CreatureConfig();
			val2.DropConfigs = (DropConfig[])(object)new DropConfig[8]
			{
				new DropConfig
				{
					Item = "Trophy_UndeadRipper_DA",
					MinAmount = 1,
					MaxAmount = 1,
					Chance = 5f
				},
				new DropConfig
				{
					Item = "IronScrap",
					MinAmount = 1,
					MaxAmount = 2,
					Chance = 5f
				},
				new DropConfig
				{
					Item = "IronOre",
					MinAmount = 1,
					MaxAmount = 2,
					Chance = 3f
				},
				new DropConfig
				{
					Item = "Turnip",
					MinAmount = 1,
					MaxAmount = 2,
					Chance = 15f
				},
				new DropConfig
				{
					Item = "TurnipSeeds",
					MinAmount = 1,
					MaxAmount = 2,
					Chance = 10f
				},
				new DropConfig
				{
					Item = "Ooze",
					MinAmount = 1,
					MaxAmount = 3,
					Chance = 75f
				},
				new DropConfig
				{
					Item = "Guck",
					MinAmount = 1,
					MaxAmount = 3,
					Chance = 25f
				},
				new DropConfig
				{
					Item = "Coins",
					MinAmount = 11,
					MaxAmount = 22,
					Chance = 100f
				}
			};
			CustomCreature val11 = new CustomCreature(val10, true, val2);
			CreatureManager.Instance.AddCreature(val11);
		}
		catch (Exception arg)
		{
			((BaseUnityPlugin)this).Logger.LogWarning((object)$"Exception caught while adding custom undead for Ded's Army: {arg}");
		}
	}

	private void FixSFX()
	{
		try
		{
			AudioSource prefab = Cache.GetPrefab<AudioSource>("sfx_arrow_hit");
			string[] array = sfxList;
			foreach (string text in array)
			{
				GameObject prefab2 = Cache.GetPrefab<GameObject>(text);
				prefab2.GetComponent<AudioSource>().outputAudioMixerGroup = prefab.outputAudioMixerGroup;
				((BaseUnityPlugin)this).Logger.LogMessage((object)("Audio Mixer set on: " + text));
			}
		}
		catch
		{
			Debug.LogWarning((object)"Deds Army: SFX Fix Failed");
		}
	}

	public static void ConfigureBiomeSpawners(ISpawnerConfigurationCollection config)
	{
		try
		{
			ConfigureWorldSpawner(config);
		}
		catch (Exception ex)
		{
			Console.WriteLine("Something went horribly wrong adding spawners for Ded's Army: " + ex.Message + "\nStackTrace:\n" + ex.StackTrace);
		}
	}

	private static void ConfigureWorldSpawner(ISpawnerConfigurationCollection config)
	{
		try
		{
			ISpawnerConfigurationCollectionWorldSpawnerExtensions.ConfigureWorldSpawner(config, 27107u).SetPrefabName("Vampire_DA").SetTemplateName("Vampire")
				.SetConditionBiomes((Biome[])(object)new Biome[1] { (Biome)2 })
				.SetSpawnChance(12f)
				.SetSpawnInterval(TimeSpan.FromSeconds(350.0))
				.SetPackSizeMin(1u)
				.SetPackSizeMax(2u)
				.SetMaxSpawned(2u)
				.SetConditionAltitudeMin(-0.25f)
				.SetSpawnAtDistanceToPlayerMin(75f)
				.SetSpawnAtDistanceToPlayerMax(125f)
				.SetConditionRequiredGlobalKey("defeated_bonemass");
			ISpawnerConfigurationCollectionWorldSpawnerExtensions.ConfigureWorldSpawner(config, 27106u).SetPrefabName("Skeleton2H_DA").SetTemplateName("Skeleton")
				.SetConditionBiomes((Biome[])(object)new Biome[1] { (Biome)2 })
				.SetSpawnChance(12f)
				.SetSpawnInterval(TimeSpan.FromSeconds(350.0))
				.SetPackSizeMin(1u)
				.SetPackSizeMax(2u)
				.SetMaxSpawned(2u)
				.SetConditionAltitudeMin(-0.25f)
				.SetSpawnAtDistanceToPlayerMin(75f)
				.SetSpawnAtDistanceToPlayerMax(125f)
				.SetConditionRequiredGlobalKey("defeated_bonemass");
			ISpawnerConfigurationCollectionWorldSpawnerExtensions.ConfigureWorldSpawner(config, 27105u).SetPrefabName("Skeleton1H_DA").SetTemplateName("Skeleton")
				.SetConditionBiomes((Biome[])(object)new Biome[1] { (Biome)2 })
				.SetSpawnChance(12f)
				.SetSpawnInterval(TimeSpan.FromSeconds(350.0))
				.SetPackSizeMin(1u)
				.SetPackSizeMax(2u)
				.SetMaxSpawned(2u)
				.SetConditionAltitudeMin(-0.25f)
				.SetSpawnAtDistanceToPlayerMin(75f)
				.SetSpawnAtDistanceToPlayerMax(125f)
				.SetConditionRequiredGlobalKey("defeated_bonemass");
			ISpawnerConfigurationCollectionWorldSpawnerExtensions.ConfigureWorldSpawner(config, 27104u).SetPrefabName("UndeadDesecrator_DA").SetTemplateName("Undead")
				.SetConditionBiomes((Biome[])(object)new Biome[1] { (Biome)2 })
				.SetSpawnChance(12f)
				.SetSpawnInterval(TimeSpan.FromSeconds(350.0))
				.SetPackSizeMin(1u)
				.SetPackSizeMax(2u)
				.SetMaxSpawned(2u)
				.SetConditionAltitudeMin(-0.25f)
				.SetSpawnAtDistanceToPlayerMin(75f)
				.SetSpawnAtDistanceToPlayerMax(125f)
				.SetConditionRequiredGlobalKey("defeated_bonemass");
			ISpawnerConfigurationCollectionWorldSpawnerExtensions.ConfigureWorldSpawner(config, 27103u).SetPrefabName("UndeadReaver_DA").SetTemplateName("Undead")
				.SetConditionBiomes((Biome[])(object)new Biome[1] { (Biome)2 })
				.SetSpawnChance(12f)
				.SetSpawnInterval(TimeSpan.FromSeconds(350.0))
				.SetPackSizeMin(1u)
				.SetPackSizeMax(2u)
				.SetMaxSpawned(2u)
				.SetConditionAltitudeMin(-0.25f)
				.SetSpawnAtDistanceToPlayerMin(75f)
				.SetSpawnAtDistanceToPlayerMax(125f)
				.SetConditionRequiredGlobalKey("defeated_bonemass");
			ISpawnerConfigurationCollectionWorldSpawnerExtensions.ConfigureWorldSpawner(config, 27102u).SetPrefabName("UndeadRipper_DA").SetTemplateName("Undead")
				.SetConditionBiomes((Biome[])(object)new Biome[1] { (Biome)2 })
				.SetSpawnChance(12f)
				.SetSpawnInterval(TimeSpan.FromSeconds(350.0))
				.SetPackSizeMin(1u)
				.SetPackSizeMax(2u)
				.SetMaxSpawned(2u)
				.SetConditionAltitudeMin(-0.25f)
				.SetSpawnAtDistanceToPlayerMin(75f)
				.SetSpawnAtDistanceToPlayerMax(125f)
				.SetConditionRequiredGlobalKey("defeated_bonemass");
			ISpawnerConfigurationCollectionWorldSpawnerExtensions.ConfigureWorldSpawner(config, 27101u).SetPrefabName("UndeadCarver_DA").SetTemplateName("Undead")
				.SetConditionBiomes((Biome[])(object)new Biome[1] { (Biome)2 })
				.SetSpawnChance(12f)
				.SetSpawnInterval(TimeSpan.FromSeconds(350.0))
				.SetPackSizeMin(1u)
				.SetPackSizeMax(2u)
				.SetMaxSpawned(2u)
				.SetConditionAltitudeMin(-0.25f)
				.SetSpawnAtDistanceToPlayerMin(75f)
				.SetSpawnAtDistanceToPlayerMax(125f)
				.SetConditionRequiredGlobalKey("defeated_bonemass");
			ISpawnerConfigurationCollectionWorldSpawnerExtensions.ConfigureWorldSpawner(config, 27100u).SetPrefabName("Undead_DA").SetTemplateName("Undead")
				.SetConditionBiomes((Biome[])(object)new Biome[1] { (Biome)2 })
				.SetSpawnChance(12f)
				.SetSpawnInterval(TimeSpan.FromSeconds(350.0))
				.SetPackSizeMin(1u)
				.SetPackSizeMax(2u)
				.SetMaxSpawned(2u)
				.SetConditionAltitudeMin(-0.25f)
				.SetSpawnAtDistanceToPlayerMin(75f)
				.SetSpawnAtDistanceToPlayerMax(125f)
				.SetConditionRequiredGlobalKey("defeated_bonemass");
		}
		catch (Exception ex)
		{
			Log.LogError((object)ex);
		}
	}
}