using System;
using System.Collections.Generic;
using System.Diagnostics;
using System.IO;
using System.Reflection;
using System.Runtime.CompilerServices;
using System.Runtime.Versioning;
using System.Security;
using System.Security.Permissions;
using BepInEx;
using BepInEx.Configuration;
using BepInEx.Logging;
using BrianGriffonDog.NetcodePatcher;
using HarmonyLib;
using LethalConfig.ConfigItems;
using LethalConfig.ConfigItems.Options;
using LethalLib.Modules;
using Microsoft.CodeAnalysis;
using On;
using UnityEngine;
[assembly: CompilationRelaxations(8)]
[assembly: RuntimeCompatibility(WrapNonExceptionThrows = true)]
[assembly: Debuggable(DebuggableAttribute.DebuggingModes.Default | DebuggableAttribute.DebuggingModes.DisableOptimizations | DebuggableAttribute.DebuggingModes.IgnoreSymbolStoreSequencePoints | DebuggableAttribute.DebuggingModes.EnableEditAndContinue)]
[assembly: TargetFramework(".NETStandard,Version=v2.1", FrameworkDisplayName = ".NET Standard 2.1")]
[assembly: AssemblyCompany("bcs4313")]
[assembly: AssemblyConfiguration("Debug")]
[assembly: AssemblyDescription("Adds a suspicious looking pill that is very good for you")]
[assembly: AssemblyFileVersion("1.0.0")]
[assembly: AssemblyInformationalVersion("1.0.0+cd9e2c801759e115bb3ab98ef537ed8ed3634744")]
[assembly: AssemblyProduct("BrianGriffonDog")]
[assembly: AssemblyTitle("BrianGriffonDog")]
[assembly: SecurityPermission(SecurityAction.RequestMinimum, SkipVerification = true)]
[assembly: AssemblyVersion("1.0.0.0")]
[module: UnverifiableCode]
[module: RefSafetyRules(11)]
[module: NetcodePatchedAssembly]
internal class <Module>
{
static <Module>()
{
}
}
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 BrianGriffon.src
{
[BepInDependency(/*Could not decode attribute arguments.*/)]
[BepInDependency(/*Could not decode attribute arguments.*/)]
[BepInPlugin("BrianGriffon", "Brian The Dog", "1.0.0")]
public class Plugin : BaseUnityPlugin
{
public static class Assets
{
public static AssetBundle MainAssetBundle;
public static void PopulateAssets()
{
string directoryName = Path.GetDirectoryName(Assembly.GetExecutingAssembly().Location);
MainAssetBundle = AssetBundle.LoadFromFile(Path.Combine(directoryName, "briangriffondoggo"));
if ((Object)(object)MainAssetBundle == (Object)null)
{
Logger.LogError((object)"Failed to load custom assets.");
}
}
}
[Serializable]
[CompilerGenerated]
private sealed class <>c
{
public static readonly <>c <>9 = new <>c();
public static hook_Awake <>9__11_0;
internal void <Awake>b__11_0(orig_Awake orig, MenuManager self)
{
orig.Invoke(self);
bool flag = false;
Debug.Log((object)"Searching for Brian Griffon Replacement :3");
try
{
EnemyType[] array = Resources.FindObjectsOfTypeAll<EnemyType>();
EnemyType[] array2 = array;
foreach (EnemyType val in array2)
{
if (val.enemyName.ToLower().Contains("mouth") && val.enemyName.ToLower().Contains("dog"))
{
val.enemyPrefab = BrianGriffon;
BrianGriffon.GetComponent<EnemyAI>().enemyType = val;
Debug.Log((object)"Brian The Dog: Replaced Mouthdog prefab with Brian Griffon");
flag = true;
}
}
if (!flag)
{
Debug.Log((object)"Brian The Dog: Couldn't find brian griffon! Check all the enemy names here!");
EnemyType[] array3 = array;
foreach (EnemyType val2 in array3)
{
Debug.Log((object)val2.enemyName);
}
}
}
catch (Exception ex)
{
Debug.Log((object)("Brian the Dog Error: " + ex));
}
}
}
public static Harmony _harmony;
public static ManualLogSource Logger;
public static Random rnd = new Random();
public static List<ulong> storedBrians;
public static GameObject BrianGriffon;
private float currentPower = -1f;
private int pick = 1;
public static AudioClip BrianLungeAwoooo;
public static AudioClip BrianLungeBork;
public static ConfigEntry<int> rarity;
public static ConfigEntry<float> moaiGlobalSpeed;
public static ConfigEntry<string> trapOptions;
public static ConfigEntry<int> groupSize;
public static ConfigEntry<bool> spawnOutdoors;
public static ConfigEntry<bool> spawnIndoors;
public static void LogDebug(string text)
{
Logger.LogInfo((object)text);
}
public static void LogProduction(string text)
{
Logger.LogInfo((object)text);
}
private void Awake()
{
//IL_0134: Unknown result type (might be due to invalid IL or missing references)
//IL_013e: 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_0127: Expected O, but got Unknown
Logger = ((BaseUnityPlugin)this).Logger;
Assets.PopulateAssets();
bindVars();
Type[] types = Assembly.GetExecutingAssembly().GetTypes();
Type[] array = types;
foreach (Type type in array)
{
MethodInfo[] methods = type.GetMethods(BindingFlags.Instance | BindingFlags.Static | BindingFlags.NonPublic);
MethodInfo[] array2 = methods;
foreach (MethodInfo methodInfo in array2)
{
object[] customAttributes = methodInfo.GetCustomAttributes(typeof(RuntimeInitializeOnLoadMethodAttribute), inherit: false);
if (customAttributes.Length != 0)
{
methodInfo.Invoke(null, null);
}
}
}
Random.InitState((int)DateTime.Now.Ticks);
Debug.Log((object)("BrianGriffon ENEMY BUNDLE: " + ((object)Assets.MainAssetBundle).ToString()));
BrianGriffon = Assets.MainAssetBundle.LoadAsset<GameObject>("BrianGriffon");
BrianLungeAwoooo = Assets.MainAssetBundle.LoadAsset<AudioClip>("BrianLunge");
BrianLungeBork = Assets.MainAssetBundle.LoadAsset<AudioClip>("BrianBork");
NetworkPrefabs.RegisterNetworkPrefab(BrianGriffon);
object obj = <>c.<>9__11_0;
if (obj == null)
{
hook_Awake val = delegate(orig_Awake orig, MenuManager self)
{
orig.Invoke(self);
bool flag = false;
Debug.Log((object)"Searching for Brian Griffon Replacement :3");
try
{
EnemyType[] array3 = Resources.FindObjectsOfTypeAll<EnemyType>();
EnemyType[] array4 = array3;
foreach (EnemyType val2 in array4)
{
if (val2.enemyName.ToLower().Contains("mouth") && val2.enemyName.ToLower().Contains("dog"))
{
val2.enemyPrefab = BrianGriffon;
BrianGriffon.GetComponent<EnemyAI>().enemyType = val2;
Debug.Log((object)"Brian The Dog: Replaced Mouthdog prefab with Brian Griffon");
flag = true;
}
}
if (!flag)
{
Debug.Log((object)"Brian The Dog: Couldn't find brian griffon! Check all the enemy names here!");
EnemyType[] array5 = array3;
foreach (EnemyType val3 in array5)
{
Debug.Log((object)val3.enemyName);
}
}
}
catch (Exception ex2)
{
Debug.Log((object)("Brian the Dog Error: " + ex2));
}
};
<>c.<>9__11_0 = val;
obj = (object)val;
}
MenuManager.Awake += (hook_Awake)obj;
MouthDogAI.EnterLunge += (hook_EnterLunge)delegate(orig_EnterLunge orig, MouthDogAI self)
{
try
{
if (pick == 1)
{
pick = 0;
((EnemyAI)self).enemyBehaviourStates[2].SFXClip = BrianLungeAwoooo;
}
else
{
pick = 1;
((EnemyAI)self).enemyBehaviourStates[2].SFXClip = BrianLungeBork;
}
}
catch (Exception ex)
{
Debug.Log((object)("Brian The Dog Error: " + ex));
}
orig.Invoke(self);
};
Logger.LogInfo((object)"Plugin Brian The Dog is loaded!");
}
public void bindVars()
{
}
}
}
namespace EasterIsland
{
internal class ConfigModel
{
public static ConfigEntry<float> moaiGlobalSize;
public static ConfigEntry<float> moaiGlobalMusicVol;
public static ConfigEntry<float> moaiGlobalRarity;
public static ConfigEntry<float> moaiGlobalSpeed;
public static void setupConfig()
{
//IL_0006: Unknown result type (might be due to invalid IL or missing references)
//IL_000b: Unknown result type (might be due to invalid IL or missing references)
//IL_0016: Expected O, but got Unknown
//IL_0017: Unknown result type (might be due to invalid IL or missing references)
//IL_0022: Expected O, but got Unknown
//IL_0028: Expected O, but got Unknown
//IL_0023: Unknown result type (might be due to invalid IL or missing references)
//IL_0029: Expected O, but got Unknown
//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_003e: Expected O, but got Unknown
//IL_003f: Unknown result type (might be due to invalid IL or missing references)
//IL_004a: Expected O, but got Unknown
//IL_0050: Expected O, but got Unknown
//IL_004b: Unknown result type (might be due to invalid IL or missing references)
//IL_0051: 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_0066: Expected O, but got Unknown
//IL_0067: Unknown result type (might be due to invalid IL or missing references)
//IL_0072: Expected O, but got Unknown
//IL_0078: Expected O, but got Unknown
//IL_0073: Unknown result type (might be due to invalid IL or missing references)
//IL_0079: Expected O, but got Unknown
//IL_007e: Unknown result type (might be due to invalid IL or missing references)
//IL_0083: Unknown result type (might be due to invalid IL or missing references)
//IL_008e: Expected O, but got Unknown
//IL_008f: Unknown result type (might be due to invalid IL or missing references)
//IL_009a: Expected O, but got Unknown
//IL_00a0: Expected O, but got Unknown
//IL_009b: Unknown result type (might be due to invalid IL or missing references)
//IL_00a1: Expected O, but got Unknown
ConfigEntry<float> obj = moaiGlobalSize;
FloatSliderOptions val = new FloatSliderOptions();
((BaseRangeOptions<float>)val).Min = 0.05f;
((BaseRangeOptions<float>)val).Max = 5f;
FloatSliderConfigItem val2 = new FloatSliderConfigItem(obj, val);
ConfigEntry<float> obj2 = moaiGlobalMusicVol;
FloatSliderOptions val3 = new FloatSliderOptions();
((BaseRangeOptions<float>)val3).Min = 0f;
((BaseRangeOptions<float>)val3).Max = 2f;
FloatSliderConfigItem val4 = new FloatSliderConfigItem(obj2, val3);
ConfigEntry<float> obj3 = moaiGlobalRarity;
FloatSliderOptions val5 = new FloatSliderOptions();
((BaseRangeOptions<float>)val5).Min = 0f;
((BaseRangeOptions<float>)val5).Max = 10f;
FloatSliderConfigItem val6 = new FloatSliderConfigItem(obj3, val5);
ConfigEntry<float> obj4 = moaiGlobalSpeed;
FloatSliderOptions val7 = new FloatSliderOptions();
((BaseRangeOptions<float>)val7).Min = 0f;
((BaseRangeOptions<float>)val7).Max = 5f;
FloatSliderConfigItem val8 = new FloatSliderConfigItem(obj4, val7);
}
}
}
namespace BrianGriffonDog.NetcodePatcher
{
[AttributeUsage(AttributeTargets.Module)]
internal class NetcodePatchedAssemblyAttribute : Attribute
{
}
}