using System;
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.Logging;
using LethalLib.Modules;
using Microsoft.CodeAnalysis;
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("FoodScrapsAndWalkie")]
[assembly: AssemblyConfiguration("Debug")]
[assembly: AssemblyFileVersion("0.0.3.0")]
[assembly: AssemblyInformationalVersion("0.0.3")]
[assembly: AssemblyProduct("Food Scraps and Walkie")]
[assembly: AssemblyTitle("FoodScrapsAndWalkie")]
[assembly: SecurityPermission(SecurityAction.RequestMinimum, SkipVerification = true)]
[assembly: AssemblyVersion("0.0.3.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 FoodScrapsAndWalkie
{
[BepInPlugin("FoodScrapsAndWalkie", "Food Scraps and Walkie", "0.0.3")]
[BepInDependency(/*Could not decode attribute arguments.*/)]
public class Plugin : BaseUnityPlugin
{
internal static ManualLogSource Logger;
public static AssetBundle MyCustomAssets;
private void Awake()
{
Logger = ((BaseUnityPlugin)this).Logger;
Logger.LogInfo((object)"Plugin FoodScrapsAndWalkie is loaded!");
string directoryName = Path.GetDirectoryName(Assembly.GetExecutingAssembly().Location);
MyCustomAssets = AssetBundle.LoadFromFile(Path.Combine(directoryName, "food_scraps_and_walkie_bundle"));
if ((Object)(object)MyCustomAssets == (Object)null)
{
Logger.LogError((object)"Failed to load custom assets.");
return;
}
Logger.LogInfo((object)"Custom assets are loaded!");
Logger.LogInfo((object)"Registering scrap");
int num = 55;
string[] array = new string[6] { "Coffee", "Burger", "Cake", "Cookie", "Bread", "CursedWalkie" };
Item[] array2 = (Item[])(object)new Item[array.Length];
for (int i = 0; i < array.Length; i++)
{
array2[i] = MyCustomAssets.LoadAsset<Item>("Assets/ScrapMod/Items/" + array[i] + ".asset");
Utilities.FixMixerGroups(array2[i].spawnPrefab);
NetworkPrefabs.RegisterNetworkPrefab(array2[i].spawnPrefab);
Items.RegisterScrap(array2[i], num, (LevelTypes)(-1));
}
}
}
public static class MyPluginInfo
{
public const string PLUGIN_GUID = "FoodScrapsAndWalkie";
public const string PLUGIN_NAME = "Food Scraps and Walkie";
public const string PLUGIN_VERSION = "0.0.3";
}
}