Decompiled source of OmegaProject05 v1.0.0

MoreCompany.dll

Decompiled 7 months ago
using System;
using System.Collections.Generic;
using System.Collections.ObjectModel;
using System.Diagnostics;
using System.Reflection;
using System.Runtime.CompilerServices;
using System.Runtime.Versioning;
using System.Security;
using System.Security.Permissions;
using BepInEx;
using HarmonyLib;
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("MoreCompany")]
[assembly: AssemblyConfiguration("Debug")]
[assembly: AssemblyFileVersion("100.0.0")]
[assembly: AssemblyInformationalVersion("100.0.0")]
[assembly: AssemblyProduct("MoreCompany")]
[assembly: AssemblyTitle("MoreCompany")]
[assembly: SecurityPermission(SecurityAction.RequestMinimum, SkipVerification = true)]
[assembly: AssemblyVersion("100.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 MoreCompany
{
	[BepInPlugin("me.swipez.melonloader.morecompany", "MoreCompany", "100.0.0")]
	public class MainClass : BaseUnityPlugin
	{
		private void Awake()
		{
			((BaseUnityPlugin)this).Logger.LogInfo((object)"I am just a MoreCompany replacement! :)");
		}
	}
}
namespace MoreCompany.Cosmetics
{
	public enum CosmeticType
	{
		HAT,
		WRIST,
		CHEST,
		R_LOWER_ARM,
		HIP,
		L_SHIN,
		R_SHIN
	}
	public class CosmeticInstance : MonoBehaviour
	{
		public CosmeticType cosmeticType;

		public string cosmeticId;

		public Texture2D icon;
	}
	public class CosmeticGeneric
	{
		public static ObservableCollection<GameObject> ToLoad = new ObservableCollection<GameObject>();

		public virtual string gameObjectPath { get; }

		public virtual string cosmeticId { get; }

		public virtual string textureIconPath { get; }

		public CosmeticType cosmeticType { get; }

		public void LoadFromBundle(AssetBundle bundle)
		{
			GameObject val = bundle.LoadAsset<GameObject>(gameObjectPath);
			((Object)val).hideFlags = (HideFlags)32;
			Texture2D val2 = bundle.LoadAsset<Texture2D>(textureIconPath);
			((Object)val2).hideFlags = (HideFlags)32;
			CosmeticInstance cosmeticInstance = val.AddComponent<CosmeticInstance>();
			cosmeticInstance.cosmeticId = cosmeticId;
			cosmeticInstance.icon = val2;
			cosmeticInstance.cosmeticType = cosmeticType;
			CollectionExtensions.AddItem<GameObject>((IEnumerable<GameObject>)ToLoad, val);
		}
	}
	public class CosmeticApplication : MonoBehaviour
	{
		public Transform head;

		public Transform hip;

		public Transform lowerArmRight;

		public Transform shinLeft;

		public Transform shinRight;

		public Transform chest;

		public List<CosmeticInstance> spawnedCosmetics = new List<CosmeticInstance>();

		public void Awake()
		{
		}

		public void ClearCosmetics()
		{
		}

		public void ApplyCosmetic(string cosmeticId, bool startEnabled)
		{
		}

		public void RefreshAllCosmeticPositions()
		{
		}
	}
	public class CosmeticRegistry
	{
		public static GameObject cosmeticGUI;

		private static GameObject displayGuy;

		private static CosmeticApplication cosmeticApplication;

		public static List<string> locallySelectedCosmetics = new List<string>();

		public const float COSMETIC_PLAYER_SCALE_MULT = 0.38f;

		public static ObservableCollection<AssetBundle> ToLoad = new ObservableCollection<AssetBundle>();

		public static Dictionary<string, CosmeticInstance> cosmeticInstances = new Dictionary<string, CosmeticInstance>();

		public static void LoadCosmeticsFromBundle(AssetBundle bundle)
		{
			ToLoad.Add(bundle);
		}

		public static void LoadCosmeticsFromAssembly(Assembly assembly, AssetBundle bundle)
		{
			Type[] types = assembly.GetTypes();
			Type[] array = types;
			foreach (Type type in array)
			{
				if (type.IsSubclassOf(typeof(CosmeticGeneric)))
				{
					CosmeticGeneric cosmeticGeneric = (CosmeticGeneric)type.GetConstructor(new Type[0]).Invoke(new object[0]);
					cosmeticGeneric.LoadFromBundle(bundle);
				}
			}
		}

		public static void SpawnCosmeticGUI()
		{
		}

		public static void PopulateCosmetics()
		{
		}

		public static void UpdateCosmeticsOnDisplayGuy(bool startEnabled)
		{
		}

		public static bool IsEquipped(string cosmeticId)
		{
			return false;
		}

		public static void ToggleCosmetic(string cosmeticId)
		{
		}
	}
}
namespace MoreCompany.Utils
{
	public static class AssetBundleExtension
	{
		public static T LoadPersistentAsset<T>(this AssetBundle bundle, string name) where T : Object
		{
			T val = bundle.LoadAsset<T>(name);
			if ((Object)(object)val != (Object)null)
			{
				((Object)val).hideFlags = (HideFlags)32;
				return val;
			}
			return default(T);
		}
	}
}