Please disclose if any significant portion of your mod was created using AI tools by adding the 'AI Generated' category. Failing to do so may result in the mod being removed from Thunderstore.
Decompiled source of ElowinyCompany v1.0.21
ElowinyScrap.dll
Decompiled 2 days agousing 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 Dawn; using GameNetcodeStuff; using HarmonyLib; using LethalLib.Modules; using Microsoft.CodeAnalysis; using TMPro; using UnityEngine; using UnityEngine.UI; [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("ElowinyScrap")] [assembly: AssemblyConfiguration("Debug")] [assembly: AssemblyFileVersion("1.0.0.0")] [assembly: AssemblyInformationalVersion("1.0.0+d623f605e6bc56764110e8685f67aae2e66227e8")] [assembly: AssemblyProduct("My first plugin")] [assembly: AssemblyTitle("ElowinyScrap")] [assembly: SecurityPermission(SecurityAction.RequestMinimum, SkipVerification = true)] [assembly: AssemblyVersion("1.0.0.0")] [module: UnverifiableCode] [module: RefSafetyRules(11)] namespace Microsoft.CodeAnalysis { [CompilerGenerated] [Embedded] internal sealed class EmbeddedAttribute : Attribute { } } namespace System.Runtime.CompilerServices { [CompilerGenerated] [Embedded] [AttributeUsage(AttributeTargets.Class | AttributeTargets.Property | AttributeTargets.Field | AttributeTargets.Event | AttributeTargets.Parameter | AttributeTargets.ReturnValue | AttributeTargets.GenericParameter, AllowMultiple = false, Inherited = false)] internal sealed class NullableAttribute : Attribute { public readonly byte[] NullableFlags; public NullableAttribute(byte P_0) { NullableFlags = new byte[1] { P_0 }; } public NullableAttribute(byte[] P_0) { NullableFlags = P_0; } } [CompilerGenerated] [Embedded] [AttributeUsage(AttributeTargets.Class | AttributeTargets.Struct | AttributeTargets.Method | AttributeTargets.Interface | AttributeTargets.Delegate, AllowMultiple = false, Inherited = false)] internal sealed class NullableContextAttribute : Attribute { public readonly byte Flag; public NullableContextAttribute(byte P_0) { Flag = P_0; } } [CompilerGenerated] [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 ElowinyScrap { [BepInPlugin("com.elowiny.elowinyscrap", "ElowinyScrap", "1.0.0")] [BepInProcess("Lethal Company.exe")] public class Plugin : BaseUnityPlugin { public static readonly NamespacedKey<DawnItemInfo> MyScrapKey = NamespacedKey<DawnItemInfo>.From("elowiny", "custom_scrap"); private readonly Harmony harmony = new Harmony("com.elowiny.elowinyscrap"); private void Awake() { ((BaseUnityPlugin)this).Logger.LogInfo((object)"ElowinyScrap has started loading!"); harmony.PatchAll(); string text = Path.Combine(Path.GetDirectoryName(((BaseUnityPlugin)this).Info.Location), "elowinyscrap_bundle"); AssetBundle val = AssetBundle.LoadFromFile(text); Item val2 = val.LoadAsset<Item>("Assets/LaurentScrap/LaurentScrap.asset"); Item val3 = val.LoadAsset<Item>("Assets/GoldMacronScrap/GoldMacronScrap.asset"); Item val4 = val.LoadAsset<Item>("Assets/LorisFigurineScrap/LorisFigurineScrap.asset"); Item val5 = val.LoadAsset<Item>("Assets/MeopaSkullScrap/MeopaSkullScrap.asset"); Item val6 = val.LoadAsset<Item>("Assets/KatzenHelmetScrap/KatzenHelmetScrap.asset"); Item val7 = val.LoadAsset<Item>("Assets/MedievalShieldScrap/MedievalShieldScrap.asset"); Item val8 = val.LoadAsset<Item>("Assets/LorisKatanaScrap/LorisKatanaScrap.asset"); Item val9 = val.LoadAsset<Item>("Assets/GoldenLugerScrap/GoldenLugerScrap.asset"); Item val10 = val.LoadAsset<Item>("Assets/CromwellHeadScrap/CromwellHeadScrap.asset"); Item val11 = val.LoadAsset<Item>("Assets/KatzenRailgunScrap/KatzenRailgunScrap.asset"); Item val12 = val.LoadAsset<Item>("Assets/KatzenFlamethrowerScrap/KatzenFlamethrowerScrap.asset"); Item val13 = val.LoadAsset<Item>("Assets/KatzenLaserScrap/KatzenLaserScrap.asset"); Item val14 = val.LoadAsset<Item>("Assets/KatzenBolterScrap/KatzenBolterScrap.asset"); Item val15 = val.LoadAsset<Item>("Assets/KatzenHeavyFlamethrowerScrap/KatzenHeavyFlamethrowerScrap.asset"); Item val16 = val.LoadAsset<Item>("Assets/PimousseBustScrap/PimousseBustScrap.asset"); Item val17 = val.LoadAsset<Item>("Assets/BlueChickenScrap/BlueChickenScrap.asset"); Item val18 = val.LoadAsset<Item>("Assets/LostGourdScrap/LostGourdScrap.asset"); Item val19 = val.LoadAsset<Item>("Assets/ForestPlushieScrap/ForestPlushieScrap.asset"); Item val20 = val.LoadAsset<Item>("Assets/SonicPlushieScrap/SonicPlushieScrap.asset"); Item val21 = val.LoadAsset<Item>("Assets/PetainPlateScrap/PetainPlateScrap.asset"); val9.saveItemVariable = true; val11.saveItemVariable = true; val12.saveItemVariable = true; val13.saveItemVariable = true; val14.saveItemVariable = true; val15.saveItemVariable = true; DamageModifierComponent damageModifierComponent = val6.spawnPrefab.AddComponent<DamageModifierComponent>(); damageModifierComponent.damageReductionMultiplier = 0.3f; FlatDamageModifierComponent flatDamageModifierComponent = val7.spawnPrefab.AddComponent<FlatDamageModifierComponent>(); flatDamageModifierComponent.flatDamageReduction = 15; SimpleWeaponComponent simpleWeaponComponent = val9.spawnPrefab.AddComponent<SimpleWeaponComponent>(); simpleWeaponComponent.ammo = 6; simpleWeaponComponent.playerDamage = 30; simpleWeaponComponent.entityDamage = 2; AudioClip shootSound = val.LoadAsset<AudioClip>("Assets/GoldenLugerScrap/GoldenLugerShot.mp3"); GameObject shootParticlePrefab = val.LoadAsset<GameObject>("Assets/GoldenLugerScrap/GoldenLugerParticle.prefab"); simpleWeaponComponent.shootSound = shootSound; simpleWeaponComponent.shootParticlePrefab = shootParticlePrefab; Transform val22 = val9.spawnPrefab.transform.Find("BarrelTip"); simpleWeaponComponent.barrelLocation = (((Object)(object)val22 != (Object)null) ? val22 : val9.spawnPrefab.transform); SimpleWeaponComponent simpleWeaponComponent2 = val11.spawnPrefab.AddComponent<SimpleWeaponComponent>(); simpleWeaponComponent2.ammo = 2; simpleWeaponComponent2.playerDamage = 150; simpleWeaponComponent2.entityDamage = 20; AudioClip shootSound2 = val.LoadAsset<AudioClip>("Assets/KatzenRailgunScrap/KatzenRailgunShot.mp3"); GameObject shootParticlePrefab2 = val.LoadAsset<GameObject>("Assets/KatzenRailgunScrap/KatzenRailgunParticle.prefab"); simpleWeaponComponent2.shootSound = shootSound2; simpleWeaponComponent2.shootParticlePrefab = shootParticlePrefab2; Transform val23 = val11.spawnPrefab.transform.Find("BarrelTip"); simpleWeaponComponent2.barrelLocation = (((Object)(object)val23 != (Object)null) ? val23 : val11.spawnPrefab.transform); SimpleWeaponComponent simpleWeaponComponent3 = val14.spawnPrefab.AddComponent<SimpleWeaponComponent>(); simpleWeaponComponent3.ammo = 8; simpleWeaponComponent3.playerDamage = 50; simpleWeaponComponent3.entityDamage = 3; AudioClip shootSound3 = val.LoadAsset<AudioClip>("Assets/KatzenBolterScrap/KatzenBolterShot.mp3"); GameObject shootParticlePrefab3 = val.LoadAsset<GameObject>("Assets/KatzenBolterScrap/KatzenBolterParticle.prefab"); simpleWeaponComponent3.shootSound = shootSound3; simpleWeaponComponent3.shootParticlePrefab = shootParticlePrefab3; Transform val24 = val14.spawnPrefab.transform.Find("BarrelTip"); simpleWeaponComponent3.barrelLocation = (((Object)(object)val24 != (Object)null) ? val24 : val14.spawnPrefab.transform); ContinuousWeaponComponent continuousWeaponComponent = val12.spawnPrefab.AddComponent<ContinuousWeaponComponent>(); continuousWeaponComponent.maxAmmoSeconds = 15f; continuousWeaponComponent.currentAmmo = 15f; continuousWeaponComponent.hitboxWidth = 0.5f; continuousWeaponComponent.hitboxLength = 5f; continuousWeaponComponent.playerDamage = 5; continuousWeaponComponent.entityDamage = 1; continuousWeaponComponent.damageInterval = 0.5f; AudioClip firingSound = val.LoadAsset<AudioClip>("Assets/KatzenFlamethrowerScrap/KatzenFlamethrowerSound.mp3"); GameObject shootParticlePrefab4 = val.LoadAsset<GameObject>("Assets/KatzenFlamethrowerScrap/KatzenFlamethrowerParticle.prefab"); continuousWeaponComponent.firingSound = firingSound; continuousWeaponComponent.shootParticlePrefab = shootParticlePrefab4; Transform val25 = val12.spawnPrefab.transform.Find("BarrelTip"); continuousWeaponComponent.barrelLocation = (((Object)(object)val25 != (Object)null) ? val25 : val12.spawnPrefab.transform); ContinuousWeaponComponent continuousWeaponComponent2 = val13.spawnPrefab.AddComponent<ContinuousWeaponComponent>(); continuousWeaponComponent2.maxAmmoSeconds = 6f; continuousWeaponComponent2.currentAmmo = 6f; continuousWeaponComponent2.hitboxWidth = 0.2f; continuousWeaponComponent2.hitboxLength = 50f; continuousWeaponComponent2.playerDamage = 5; continuousWeaponComponent2.entityDamage = 1; continuousWeaponComponent2.damageInterval = 0.33f; AudioClip firingSound2 = val.LoadAsset<AudioClip>("Assets/KatzenLaserScrap/KatzenLaserSound.mp3"); GameObject shootParticlePrefab5 = val.LoadAsset<GameObject>("Assets/KatzenLaserScrap/KatzenLaserParticle.prefab"); continuousWeaponComponent2.firingSound = firingSound2; continuousWeaponComponent2.shootParticlePrefab = shootParticlePrefab5; Transform val26 = val13.spawnPrefab.transform.Find("BarrelTip"); continuousWeaponComponent2.barrelLocation = (((Object)(object)val26 != (Object)null) ? val26 : val13.spawnPrefab.transform); ContinuousWeaponComponent continuousWeaponComponent3 = val15.spawnPrefab.AddComponent<ContinuousWeaponComponent>(); continuousWeaponComponent3.maxAmmoSeconds = 12f; continuousWeaponComponent3.currentAmmo = 12f; continuousWeaponComponent3.hitboxWidth = 1f; continuousWeaponComponent3.hitboxLength = 15f; continuousWeaponComponent3.playerDamage = 5; continuousWeaponComponent3.entityDamage = 1; continuousWeaponComponent3.damageInterval = 0.5f; AudioClip firingSound3 = val.LoadAsset<AudioClip>("Assets/KatzenHeavyFlamethrowerScrap/KatzenHeavyFlamethrowerSound.mp3"); GameObject shootParticlePrefab6 = val.LoadAsset<GameObject>("Assets/KatzenHeavyFlamethrowerScrap/KatzenHeavyFlamethrowerParticle.prefab"); continuousWeaponComponent3.firingSound = firingSound3; continuousWeaponComponent3.shootParticlePrefab = shootParticlePrefab6; Transform val27 = val15.spawnPrefab.transform.Find("BarrelTip"); continuousWeaponComponent3.barrelLocation = (((Object)(object)val27 != (Object)null) ? val27 : val15.spawnPrefab.transform); NetworkPrefabs.RegisterNetworkPrefab(val2.spawnPrefab); NetworkPrefabs.RegisterNetworkPrefab(val3.spawnPrefab); NetworkPrefabs.RegisterNetworkPrefab(val4.spawnPrefab); NetworkPrefabs.RegisterNetworkPrefab(val5.spawnPrefab); NetworkPrefabs.RegisterNetworkPrefab(val6.spawnPrefab); NetworkPrefabs.RegisterNetworkPrefab(val7.spawnPrefab); NetworkPrefabs.RegisterNetworkPrefab(val8.spawnPrefab); NetworkPrefabs.RegisterNetworkPrefab(val9.spawnPrefab); NetworkPrefabs.RegisterNetworkPrefab(val10.spawnPrefab); NetworkPrefabs.RegisterNetworkPrefab(val11.spawnPrefab); NetworkPrefabs.RegisterNetworkPrefab(val12.spawnPrefab); NetworkPrefabs.RegisterNetworkPrefab(val13.spawnPrefab); NetworkPrefabs.RegisterNetworkPrefab(val14.spawnPrefab); NetworkPrefabs.RegisterNetworkPrefab(val15.spawnPrefab); NetworkPrefabs.RegisterNetworkPrefab(val16.spawnPrefab); NetworkPrefabs.RegisterNetworkPrefab(val17.spawnPrefab); NetworkPrefabs.RegisterNetworkPrefab(val18.spawnPrefab); NetworkPrefabs.RegisterNetworkPrefab(val19.spawnPrefab); NetworkPrefabs.RegisterNetworkPrefab(val20.spawnPrefab); NetworkPrefabs.RegisterNetworkPrefab(val21.spawnPrefab); DawnLib.DefineItem(NamespacedKey<DawnItemInfo>.From("elowiny", "laurentscrap"), val2, (Action<ItemInfoBuilder>)delegate(ItemInfoBuilder builder) { builder.DefineScrap((Action<ScrapBuilder>)delegate(ScrapBuilder scrapBuilder) { scrapBuilder.SetWeights((Action<WeightTableBuilder<DawnMoonInfo, SpawnWeightContext>>)delegate(WeightTableBuilder<DawnMoonInfo, SpawnWeightContext> weightBuilder) { weightBuilder.SetGlobalWeight(100); }); }); }); DawnLib.DefineItem(NamespacedKey<DawnItemInfo>.From("elowiny", "goldmacronscrap"), val3, (Action<ItemInfoBuilder>)delegate(ItemInfoBuilder builder) { builder.DefineScrap((Action<ScrapBuilder>)delegate(ScrapBuilder scrapBuilder) { scrapBuilder.SetWeights((Action<WeightTableBuilder<DawnMoonInfo, SpawnWeightContext>>)delegate(WeightTableBuilder<DawnMoonInfo, SpawnWeightContext> weightBuilder) { weightBuilder.SetGlobalWeight(100); }); }); }); DawnLib.DefineItem(NamespacedKey<DawnItemInfo>.From("elowiny", "lorisfigurinescrap"), val4, (Action<ItemInfoBuilder>)delegate(ItemInfoBuilder builder) { builder.DefineScrap((Action<ScrapBuilder>)delegate(ScrapBuilder scrapBuilder) { scrapBuilder.SetWeights((Action<WeightTableBuilder<DawnMoonInfo, SpawnWeightContext>>)delegate(WeightTableBuilder<DawnMoonInfo, SpawnWeightContext> weightBuilder) { weightBuilder.SetGlobalWeight(100); }); }); }); DawnLib.DefineItem(NamespacedKey<DawnItemInfo>.From("elowiny", "meopaskullscrap"), val5, (Action<ItemInfoBuilder>)delegate(ItemInfoBuilder builder) { builder.DefineScrap((Action<ScrapBuilder>)delegate(ScrapBuilder scrapBuilder) { scrapBuilder.SetWeights((Action<WeightTableBuilder<DawnMoonInfo, SpawnWeightContext>>)delegate(WeightTableBuilder<DawnMoonInfo, SpawnWeightContext> weightBuilder) { weightBuilder.SetGlobalWeight(100); }); }); }); DawnLib.DefineItem(NamespacedKey<DawnItemInfo>.From("elowiny", "katzenhelmetscrap"), val6, (Action<ItemInfoBuilder>)delegate(ItemInfoBuilder builder) { builder.DefineScrap((Action<ScrapBuilder>)delegate(ScrapBuilder scrapBuilder) { scrapBuilder.SetWeights((Action<WeightTableBuilder<DawnMoonInfo, SpawnWeightContext>>)delegate(WeightTableBuilder<DawnMoonInfo, SpawnWeightContext> weightBuilder) { weightBuilder.SetGlobalWeight(100); }); }); }); DawnLib.DefineItem(NamespacedKey<DawnItemInfo>.From("elowiny", "medievalshieldscrap"), val7, (Action<ItemInfoBuilder>)delegate(ItemInfoBuilder builder) { builder.DefineScrap((Action<ScrapBuilder>)delegate(ScrapBuilder scrapBuilder) { scrapBuilder.SetWeights((Action<WeightTableBuilder<DawnMoonInfo, SpawnWeightContext>>)delegate(WeightTableBuilder<DawnMoonInfo, SpawnWeightContext> weightBuilder) { weightBuilder.SetGlobalWeight(100); }); }); }); DawnLib.DefineItem(NamespacedKey<DawnItemInfo>.From("elowiny", "loriskatanascrap"), val8, (Action<ItemInfoBuilder>)delegate(ItemInfoBuilder builder) { builder.DefineScrap((Action<ScrapBuilder>)delegate(ScrapBuilder scrapBuilder) { scrapBuilder.SetWeights((Action<WeightTableBuilder<DawnMoonInfo, SpawnWeightContext>>)delegate(WeightTableBuilder<DawnMoonInfo, SpawnWeightContext> weightBuilder) { weightBuilder.SetGlobalWeight(100); }); }); }); DawnLib.DefineItem(NamespacedKey<DawnItemInfo>.From("elowiny", "goldenlugerscrap"), val9, (Action<ItemInfoBuilder>)delegate(ItemInfoBuilder builder) { builder.DefineScrap((Action<ScrapBuilder>)delegate(ScrapBuilder scrapBuilder) { scrapBuilder.SetWeights((Action<WeightTableBuilder<DawnMoonInfo, SpawnWeightContext>>)delegate(WeightTableBuilder<DawnMoonInfo, SpawnWeightContext> weightBuilder) { weightBuilder.SetGlobalWeight(100); }); }); }); DawnLib.DefineItem(NamespacedKey<DawnItemInfo>.From("elowiny", "cromwellheadscrap"), val10, (Action<ItemInfoBuilder>)delegate(ItemInfoBuilder builder) { builder.DefineScrap((Action<ScrapBuilder>)delegate(ScrapBuilder scrapBuilder) { scrapBuilder.SetWeights((Action<WeightTableBuilder<DawnMoonInfo, SpawnWeightContext>>)delegate(WeightTableBuilder<DawnMoonInfo, SpawnWeightContext> weightBuilder) { weightBuilder.SetGlobalWeight(100); }); }); }); DawnLib.DefineItem(NamespacedKey<DawnItemInfo>.From("elowiny", "katzenrailgunscrap"), val11, (Action<ItemInfoBuilder>)delegate(ItemInfoBuilder builder) { builder.DefineScrap((Action<ScrapBuilder>)delegate(ScrapBuilder scrapBuilder) { scrapBuilder.SetWeights((Action<WeightTableBuilder<DawnMoonInfo, SpawnWeightContext>>)delegate(WeightTableBuilder<DawnMoonInfo, SpawnWeightContext> weightBuilder) { weightBuilder.SetGlobalWeight(100); }); }); }); DawnLib.DefineItem(NamespacedKey<DawnItemInfo>.From("elowiny", "katzenflamethrowerscrap"), val12, (Action<ItemInfoBuilder>)delegate(ItemInfoBuilder builder) { builder.DefineScrap((Action<ScrapBuilder>)delegate(ScrapBuilder scrapBuilder) { scrapBuilder.SetWeights((Action<WeightTableBuilder<DawnMoonInfo, SpawnWeightContext>>)delegate(WeightTableBuilder<DawnMoonInfo, SpawnWeightContext> weightBuilder) { weightBuilder.SetGlobalWeight(100); }); }); }); DawnLib.DefineItem(NamespacedKey<DawnItemInfo>.From("elowiny", "katzenlaserscrap"), val13, (Action<ItemInfoBuilder>)delegate(ItemInfoBuilder builder) { builder.DefineScrap((Action<ScrapBuilder>)delegate(ScrapBuilder scrapBuilder) { scrapBuilder.SetWeights((Action<WeightTableBuilder<DawnMoonInfo, SpawnWeightContext>>)delegate(WeightTableBuilder<DawnMoonInfo, SpawnWeightContext> weightBuilder) { weightBuilder.SetGlobalWeight(100); }); }); }); DawnLib.DefineItem(NamespacedKey<DawnItemInfo>.From("elowiny", "katzenbolterscrap"), val14, (Action<ItemInfoBuilder>)delegate(ItemInfoBuilder builder) { builder.DefineScrap((Action<ScrapBuilder>)delegate(ScrapBuilder scrapBuilder) { scrapBuilder.SetWeights((Action<WeightTableBuilder<DawnMoonInfo, SpawnWeightContext>>)delegate(WeightTableBuilder<DawnMoonInfo, SpawnWeightContext> weightBuilder) { weightBuilder.SetGlobalWeight(100); }); }); }); DawnLib.DefineItem(NamespacedKey<DawnItemInfo>.From("elowiny", "katzenheavyflamethrower"), val15, (Action<ItemInfoBuilder>)delegate(ItemInfoBuilder builder) { builder.DefineScrap((Action<ScrapBuilder>)delegate(ScrapBuilder scrapBuilder) { scrapBuilder.SetWeights((Action<WeightTableBuilder<DawnMoonInfo, SpawnWeightContext>>)delegate(WeightTableBuilder<DawnMoonInfo, SpawnWeightContext> weightBuilder) { weightBuilder.SetGlobalWeight(100); }); }); }); DawnLib.DefineItem(NamespacedKey<DawnItemInfo>.From("elowiny", "pimoussebustscrap"), val16, (Action<ItemInfoBuilder>)delegate(ItemInfoBuilder builder) { builder.DefineScrap((Action<ScrapBuilder>)delegate(ScrapBuilder scrapBuilder) { scrapBuilder.SetWeights((Action<WeightTableBuilder<DawnMoonInfo, SpawnWeightContext>>)delegate(WeightTableBuilder<DawnMoonInfo, SpawnWeightContext> weightBuilder) { weightBuilder.SetGlobalWeight(100); }); }); }); DawnLib.DefineItem(NamespacedKey<DawnItemInfo>.From("elowiny", "bluechickenscrap"), val17, (Action<ItemInfoBuilder>)delegate(ItemInfoBuilder builder) { builder.DefineScrap((Action<ScrapBuilder>)delegate(ScrapBuilder scrapBuilder) { scrapBuilder.SetWeights((Action<WeightTableBuilder<DawnMoonInfo, SpawnWeightContext>>)delegate(WeightTableBuilder<DawnMoonInfo, SpawnWeightContext> weightBuilder) { weightBuilder.SetGlobalWeight(100); }); }); }); DawnLib.DefineItem(NamespacedKey<DawnItemInfo>.From("elowiny", "lostgourdscrap"), val18, (Action<ItemInfoBuilder>)delegate(ItemInfoBuilder builder) { builder.DefineScrap((Action<ScrapBuilder>)delegate(ScrapBuilder scrapBuilder) { scrapBuilder.SetWeights((Action<WeightTableBuilder<DawnMoonInfo, SpawnWeightContext>>)delegate(WeightTableBuilder<DawnMoonInfo, SpawnWeightContext> weightBuilder) { weightBuilder.SetGlobalWeight(100); }); }); }); DawnLib.DefineItem(NamespacedKey<DawnItemInfo>.From("elowiny", "forestplushiescrap"), val19, (Action<ItemInfoBuilder>)delegate(ItemInfoBuilder builder) { builder.DefineScrap((Action<ScrapBuilder>)delegate(ScrapBuilder scrapBuilder) { scrapBuilder.SetWeights((Action<WeightTableBuilder<DawnMoonInfo, SpawnWeightContext>>)delegate(WeightTableBuilder<DawnMoonInfo, SpawnWeightContext> weightBuilder) { weightBuilder.SetGlobalWeight(100); }); }); }); DawnLib.DefineItem(NamespacedKey<DawnItemInfo>.From("elowiny", "sonicplushiescrap"), val20, (Action<ItemInfoBuilder>)delegate(ItemInfoBuilder builder) { builder.DefineScrap((Action<ScrapBuilder>)delegate(ScrapBuilder scrapBuilder) { scrapBuilder.SetWeights((Action<WeightTableBuilder<DawnMoonInfo, SpawnWeightContext>>)delegate(WeightTableBuilder<DawnMoonInfo, SpawnWeightContext> weightBuilder) { weightBuilder.SetGlobalWeight(100); }); }); }); DawnLib.DefineItem(NamespacedKey<DawnItemInfo>.From("elowiny", "petainplatescrap"), val21, (Action<ItemInfoBuilder>)delegate(ItemInfoBuilder builder) { builder.DefineScrap((Action<ScrapBuilder>)delegate(ScrapBuilder scrapBuilder) { scrapBuilder.SetWeights((Action<WeightTableBuilder<DawnMoonInfo, SpawnWeightContext>>)delegate(WeightTableBuilder<DawnMoonInfo, SpawnWeightContext> weightBuilder) { weightBuilder.SetGlobalWeight(100); }); }); }); ((BaseUnityPlugin)this).Logger.LogInfo((object)"ElowinyScrap finished loading!"); } } public class DamageModifierComponent : MonoBehaviour { public float damageReductionMultiplier = 0f; } public class FlatDamageModifierComponent : MonoBehaviour { public int flatDamageReduction = 0; } public class SimpleWeaponComponent : MonoBehaviour { public int ammo = 6; public int playerDamage = 30; public int entityDamage = 2; public AudioClip shootSound; public GameObject shootParticlePrefab; public Transform barrelLocation; } public class ContinuousWeaponComponent : MonoBehaviour { public float maxAmmoSeconds = 10f; public float currentAmmo = 10f; public int playerDamage = 2; public int entityDamage = 1; public float hitboxWidth = 4f; public float hitboxLength = 8f; public float damageInterval = 0.25f; public GameObject shootParticlePrefab; public AudioClip firingSound; public Transform barrelLocation; private bool isFiring = false; private float damageTickTimer = 0f; private ParticleSystem spawnedParticles = null; private AudioSource audioSource = null; private GrabbableObject itemScript; private void Start() { itemScript = ((Component)this).GetComponent<GrabbableObject>(); audioSource = ((Component)this).gameObject.AddComponent<AudioSource>(); audioSource.playOnAwake = false; audioSource.spatialBlend = 1f; audioSource.rolloffMode = (AudioRolloffMode)1; audioSource.maxDistance = 30f; if ((Object)(object)itemScript != (Object)null && (Object)(object)itemScript.itemProperties != (Object)null) { itemScript.itemProperties.holdButtonUse = true; } } private void Update() { if ((Object)(object)itemScript != (Object)null && (!itemScript.isHeld || itemScript.isPocketed)) { if (isFiring) { SetFiringState(state: false); itemScript.isBeingUsed = false; } } else { if (!isFiring) { return; } if (currentAmmo <= 0f) { currentAmmo = 0f; SetFiringState(state: false); if ((Object)(object)itemScript != (Object)null) { itemScript.isBeingUsed = false; } return; } currentAmmo -= Time.deltaTime; if ((Object)(object)itemScript.playerHeldBy != (Object)null && (Object)(object)itemScript.playerHeldBy == (Object)(object)GameNetworkManager.Instance.localPlayerController) { damageTickTimer += Time.deltaTime; if (damageTickTimer >= damageInterval) { damageTickTimer = 0f; FireSphereCast(itemScript.playerHeldBy); } } } } private void FireSphereCast(PlayerControllerB player) { //IL_000e: 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_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_0068: 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_00c6: Unknown result type (might be due to invalid IL or missing references) //IL_0114: Unknown result type (might be due to invalid IL or missing references) Ray val = default(Ray); ((Ray)(ref val))..ctor(((Component)player.gameplayCamera).transform.position, ((Component)player.gameplayCamera).transform.forward); float num = hitboxWidth / 2f; int num2 = 2621448; RaycastHit[] array = Physics.SphereCastAll(((Ray)(ref val)).origin, num, ((Ray)(ref val)).direction, hitboxLength, num2, (QueryTriggerInteraction)2); RaycastHit[] array2 = array; for (int i = 0; i < array2.Length; i++) { RaycastHit val2 = array2[i]; GameObject gameObject = ((Component)((RaycastHit)(ref val2)).collider).gameObject; PlayerControllerB val3 = gameObject.GetComponentInParent<PlayerControllerB>(); if ((Object)(object)val3 == (Object)null) { val3 = gameObject.GetComponent<PlayerControllerB>(); } if ((Object)(object)val3 != (Object)null) { if ((Object)(object)val3 != (Object)(object)player) { val3.DamagePlayerFromOtherClientServerRpc(playerDamage, ((Ray)(ref val)).direction, (int)player.playerClientId); } continue; } EnemyAICollisionDetect component = gameObject.GetComponent<EnemyAICollisionDetect>(); if ((Object)(object)component != (Object)null && (Object)(object)component.mainScript != (Object)null) { component.mainScript.HitEnemyOnLocalClient(entityDamage, ((Ray)(ref val)).direction, player, true, -1); } } } public void SetFiringState(bool state) { //IL_004e: Unknown result type (might be due to invalid IL or missing references) //IL_0054: Unknown result type (might be due to invalid IL or missing references) isFiring = state; if ((Object)(object)spawnedParticles == (Object)null && (Object)(object)shootParticlePrefab != (Object)null) { Transform val = (((Object)(object)barrelLocation != (Object)null) ? barrelLocation : ((Component)this).transform); GameObject val2 = Object.Instantiate<GameObject>(shootParticlePrefab, val.position, val.rotation, val); spawnedParticles = val2.GetComponent<ParticleSystem>(); } if (isFiring) { if ((Object)(object)spawnedParticles != (Object)null) { spawnedParticles.Play(); } if ((Object)(object)audioSource != (Object)null && (Object)(object)firingSound != (Object)null) { audioSource.clip = firingSound; audioSource.loop = true; if (!audioSource.isPlaying) { audioSource.Play(); } } } else { if ((Object)(object)spawnedParticles != (Object)null) { spawnedParticles.Stop(); } if ((Object)(object)audioSource != (Object)null) { audioSource.Stop(); } } } } [HarmonyPatch(typeof(GrabbableObject))] public class ContinuousWeaponPatch { [HarmonyPatch("ItemActivate")] [HarmonyPrefix] public static bool ItemActivatePrefix(GrabbableObject __instance, bool used, bool buttonDown) { ContinuousWeaponComponent component = ((Component)__instance).GetComponent<ContinuousWeaponComponent>(); if ((Object)(object)component != (Object)null) { if (buttonDown && component.currentAmmo > 0f) { __instance.isBeingUsed = true; component.SetFiringState(state: true); } else if (!buttonDown) { __instance.isBeingUsed = false; component.SetFiringState(state: false); } return true; } return true; } } [HarmonyPatch(typeof(PlayerControllerB))] public class PlayerDamagePatch { [HarmonyPatch("DamagePlayer")] [HarmonyPrefix] public static void Prefix(PlayerControllerB __instance, ref int damageNumber) { if (!((Object)(object)__instance == (Object)null) && !((Object)(object)__instance.currentlyHeldObjectServer == (Object)null)) { DamageModifierComponent component = ((Component)__instance.currentlyHeldObjectServer).GetComponent<DamageModifierComponent>(); FlatDamageModifierComponent component2 = ((Component)__instance.currentlyHeldObjectServer).GetComponent<FlatDamageModifierComponent>(); float num = damageNumber; if ((Object)(object)component != (Object)null && component.damageReductionMultiplier > 0f) { num *= 1f - component.damageReductionMultiplier; } if ((Object)(object)component2 != (Object)null && component2.flatDamageReduction > 0) { num -= (float)component2.flatDamageReduction; } damageNumber = Mathf.Max(0, Mathf.RoundToInt(num)); } } } [HarmonyPatch(typeof(GrabbableObject))] [HarmonyPatch(typeof(GrabbableObject))] [HarmonyPatch(typeof(GrabbableObject))] public class WeaponUsePatch { [HarmonyPatch("ItemActivate")] [HarmonyPrefix] public static void Prefix(GrabbableObject __instance, bool used, bool buttonDown) { //IL_0088: 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_00d9: Unknown result type (might be due to invalid IL or missing references) //IL_0139: 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_015b: Unknown result type (might be due to invalid IL or missing references) //IL_01a4: Unknown result type (might be due to invalid IL or missing references) //IL_01a9: Unknown result type (might be due to invalid IL or missing references) //IL_0203: Unknown result type (might be due to invalid IL or missing references) //IL_0256: Unknown result type (might be due to invalid IL or missing references) if (!buttonDown) { return; } SimpleWeaponComponent component = ((Component)__instance).GetComponent<SimpleWeaponComponent>(); if (!((Object)(object)component != (Object)null) || component.ammo <= 0) { return; } component.ammo--; if ((Object)(object)component.shootSound != (Object)null) { AudioSource component2 = ((Component)__instance).GetComponent<AudioSource>(); if ((Object)(object)component2 != (Object)null) { component2.PlayOneShot(component.shootSound, 1f); } else { AudioSource.PlayClipAtPoint(component.shootSound, ((Component)__instance).transform.position, 1f); } } if ((Object)(object)component.shootParticlePrefab != (Object)null) { Transform val = (((Object)(object)component.barrelLocation != (Object)null) ? component.barrelLocation : ((Component)__instance).transform); GameObject val2 = Object.Instantiate<GameObject>(component.shootParticlePrefab, val.position, val.rotation); Object.Destroy((Object)(object)val2, 2f); } if (!((Object)(object)__instance.playerHeldBy != (Object)null) || !((Object)(object)__instance.playerHeldBy == (Object)(object)GameNetworkManager.Instance.localPlayerController)) { return; } PlayerControllerB playerHeldBy = __instance.playerHeldBy; Ray val3 = default(Ray); ((Ray)(ref val3))..ctor(((Component)playerHeldBy.gameplayCamera).transform.position, ((Component)playerHeldBy.gameplayCamera).transform.forward); int num = 2623753; RaycastHit[] array = Physics.RaycastAll(val3, 50f, num, (QueryTriggerInteraction)2); Array.Sort(array, (RaycastHit x, RaycastHit y) => ((RaycastHit)(ref x)).distance.CompareTo(((RaycastHit)(ref y)).distance)); RaycastHit[] array2 = array; for (int num2 = 0; num2 < array2.Length; num2++) { RaycastHit val4 = array2[num2]; GameObject gameObject = ((Component)((RaycastHit)(ref val4)).collider).gameObject; PlayerControllerB val5 = gameObject.GetComponentInParent<PlayerControllerB>(); if ((Object)(object)val5 == (Object)null) { val5 = gameObject.GetComponent<PlayerControllerB>(); } if ((Object)(object)val5 != (Object)null) { if ((Object)(object)val5 != (Object)(object)playerHeldBy) { val5.DamagePlayerFromOtherClientServerRpc(component.playerDamage, ((Ray)(ref val3)).direction, (int)playerHeldBy.playerClientId); break; } continue; } EnemyAICollisionDetect component3 = gameObject.GetComponent<EnemyAICollisionDetect>(); if ((Object)(object)component3 != (Object)null && (Object)(object)component3.mainScript != (Object)null) { component3.mainScript.HitEnemyOnLocalClient(component.entityDamage, ((Ray)(ref val3)).direction, playerHeldBy, true, -1); break; } if (gameObject.layer == 8 || gameObject.layer == 11 || gameObject.layer == 0) { break; } } } } [HarmonyPatch(typeof(HUDManager))] public class HUDManagerPatch { public static TextMeshProUGUI armorText; [HarmonyPatch("Start")] [HarmonyPostfix] public static void StartPostfix(HUDManager __instance) { //IL_0006: Unknown result type (might be due to invalid IL or missing references) //IL_000c: Expected O, but got Unknown //IL_005f: Unknown result type (might be due to invalid IL or missing references) //IL_0090: Unknown result type (might be due to invalid IL or missing references) //IL_00a6: Unknown result type (might be due to invalid IL or missing references) //IL_00bc: 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_00e8: Unknown result type (might be due to invalid IL or missing references) GameObject val = new GameObject("ElowinyArmorText"); val.transform.SetParent(((Component)((Graphic)__instance.weightCounter).canvas).transform, false); armorText = val.AddComponent<TextMeshProUGUI>(); ((TMP_Text)armorText).font = ((TMP_Text)__instance.weightCounter).font; ((TMP_Text)armorText).fontSize = 16f; ((Graphic)armorText).color = Color.green; ((TMP_Text)armorText).alignment = (TextAlignmentOptions)514; RectTransform component = ((Component)armorText).GetComponent<RectTransform>(); component.sizeDelta = new Vector2(300f, 50f); component.anchorMin = new Vector2(0.5f, 0f); component.anchorMax = new Vector2(0.5f, 0f); component.pivot = new Vector2(0.5f, 0f); component.anchoredPosition = new Vector2(0f, 100f); ((TMP_Text)armorText).text = ""; } [HarmonyPatch("Update")] [HarmonyPostfix] public static void UpdatePostfix(HUDManager __instance) { if ((Object)(object)GameNetworkManager.Instance == (Object)null || (Object)(object)GameNetworkManager.Instance.localPlayerController == (Object)null || (Object)(object)armorText == (Object)null) { return; } PlayerControllerB localPlayerController = GameNetworkManager.Instance.localPlayerController; if ((Object)(object)localPlayerController.currentlyHeldObjectServer != (Object)null) { DamageModifierComponent component = ((Component)localPlayerController.currentlyHeldObjectServer).GetComponent<DamageModifierComponent>(); FlatDamageModifierComponent component2 = ((Component)localPlayerController.currentlyHeldObjectServer).GetComponent<FlatDamageModifierComponent>(); SimpleWeaponComponent component3 = ((Component)localPlayerController.currentlyHeldObjectServer).GetComponent<SimpleWeaponComponent>(); ContinuousWeaponComponent component4 = ((Component)localPlayerController.currentlyHeldObjectServer).GetComponent<ContinuousWeaponComponent>(); string text = ""; if ((Object)(object)component3 != (Object)null) { text += $"Ammo Remaining: {component3.ammo}\n"; } ((TMP_Text)armorText).text = text.Trim(); if ((Object)(object)component != (Object)null && component.damageReductionMultiplier > 0f) { int num = Mathf.RoundToInt(component.damageReductionMultiplier * 100f); text += $"Percentage Damage Reduction: {num}%\n"; } if ((Object)(object)component2 != (Object)null && component2.flatDamageReduction > 0) { text += $"Flat DMG Reduction: {component2.flatDamageReduction} DMG"; } if ((Object)(object)component4 != (Object)null) { int num2 = Mathf.CeilToInt(component4.currentAmmo); text += $"Fuel: {num2}s\n"; } ((TMP_Text)armorText).text = text.Trim(); } else { ((TMP_Text)armorText).text = ""; } } } [HarmonyPatch(typeof(GrabbableObject))] public class WeaponSavePatch { [HarmonyPatch("GetItemDataToSave")] [HarmonyPostfix] public static void SaveAmmo(GrabbableObject __instance, ref int __result) { SimpleWeaponComponent component = ((Component)__instance).GetComponent<SimpleWeaponComponent>(); if ((Object)(object)component != (Object)null) { __result = component.ammo + 1000; return; } ContinuousWeaponComponent component2 = ((Component)__instance).GetComponent<ContinuousWeaponComponent>(); if ((Object)(object)component2 != (Object)null) { __result = Mathf.RoundToInt(component2.currentAmmo * 100f) + 10000; } } [HarmonyPatch("LoadItemSaveData")] [HarmonyPostfix] public static void LoadAmmo(GrabbableObject __instance, int saveData) { SimpleWeaponComponent component = ((Component)__instance).GetComponent<SimpleWeaponComponent>(); if ((Object)(object)component != (Object)null) { if (saveData >= 1000) { component.ammo = saveData - 1000; } return; } ContinuousWeaponComponent component2 = ((Component)__instance).GetComponent<ContinuousWeaponComponent>(); if ((Object)(object)component2 != (Object)null && saveData >= 10000) { component2.currentAmmo = (float)(saveData - 10000) / 100f; } } } public static class MyPluginInfo { public const string PLUGIN_GUID = "ElowinyScrap"; public const string PLUGIN_NAME = "My first plugin"; public const string PLUGIN_VERSION = "1.0.0"; } }
JetpackSafetyProtocol.dll
Decompiled 2 days agousing System.Diagnostics; using System.Reflection; using System.Runtime.CompilerServices; using System.Runtime.InteropServices; using System.Runtime.Versioning; using BepInEx; using BepInEx.Configuration; using GameNetcodeStuff; using HarmonyLib; 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("JetpackSafetyProtocol")] [assembly: AssemblyDescription("")] [assembly: AssemblyConfiguration("")] [assembly: AssemblyCompany("")] [assembly: AssemblyProduct("JetpackSafetyProtocol")] [assembly: AssemblyCopyright("Copyright © 2026")] [assembly: AssemblyTrademark("")] [assembly: ComVisible(false)] [assembly: Guid("e54827aa-9989-41ab-95e5-52e1eec3d12c")] [assembly: AssemblyFileVersion("1.0.0.0")] [assembly: TargetFramework(".NETFramework,Version=v4.6.2", FrameworkDisplayName = ".NET Framework 4.6.2")] [assembly: AssemblyVersion("1.0.0.0")] namespace JetpackSafetyProtocol; [BepInPlugin("com.yourname.jetpacksafety", "Jetpack Safety Protocol", "1.0.0")] public class Plugin : BaseUnityPlugin { public static ConfigEntry<string> BannedUsersConfig; private void Awake() { //IL_002a: Unknown result type (might be due to invalid IL or missing references) //IL_0030: Expected O, but got Unknown BannedUsersConfig = ((BaseUnityPlugin)this).Config.Bind<string>("Targeting", "BannedUsernames", "Elowiny,Jimmy,Coco", "A comma-separated list of usernames."); Harmony val = new Harmony("com.yourname.jetpacksafety"); val.PatchAll(typeof(JetpackPatch)); } } [HarmonyPatch(typeof(PlayerControllerB))] public class JetpackPatch { [HarmonyPatch("BeginGrabObject")] [HarmonyPostfix] public static void BeginGrabObjectPostfix(PlayerControllerB __instance, ref GrabbableObject ___currentlyGrabbingObject) { //IL_00a9: Unknown result type (might be due to invalid IL or missing references) //IL_00d4: Unknown result type (might be due to invalid IL or missing references) //IL_00da: Unknown result type (might be due to invalid IL or missing references) if ((Object)(object)___currentlyGrabbingObject == (Object)null || !(___currentlyGrabbingObject is JetpackItem) || StartOfRound.Instance.inShipPhase) { return; } string value = Plugin.BannedUsersConfig.Value; string[] array = value.Split(new char[1] { ',' }); bool flag = false; string[] array2 = array; foreach (string text in array2) { if (__instance.playerUsername == text.Trim()) { flag = true; break; } } if (flag) { Landmine.SpawnExplosion(((Component)__instance).transform.position, true, 0f, 0f, 0, 0f, (GameObject)null, false); __instance.DamagePlayer(1000, true, true, (CauseOfDeath)3, 0, false, default(Vector3)); ___currentlyGrabbingObject = null; __instance.isGrabbingObjectAnimation = false; } } }
ElowinyCharacters.dll
Decompiled 2 days agousing 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 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: IgnoresAccessChecksTo("Assembly-CSharp")] [assembly: AssemblyCompany("ElowinyCharacters")] [assembly: AssemblyConfiguration("Debug")] [assembly: AssemblyFileVersion("1.0.0.0")] [assembly: AssemblyInformationalVersion("1.0.0+d623f605e6bc56764110e8685f67aae2e66227e8")] [assembly: AssemblyProduct("ElowinyCharacters")] [assembly: AssemblyTitle("ElowinyCharacters")] [assembly: SecurityPermission(SecurityAction.RequestMinimum, SkipVerification = true)] [assembly: AssemblyVersion("1.0.0.0")] [module: UnverifiableCode] namespace Microsoft.CodeAnalysis { [CompilerGenerated] [Embedded] internal sealed class EmbeddedAttribute : Attribute { } } namespace System.Runtime.CompilerServices { [CompilerGenerated] [Embedded] [AttributeUsage(AttributeTargets.Class | AttributeTargets.Property | AttributeTargets.Field | AttributeTargets.Event | AttributeTargets.Parameter | AttributeTargets.ReturnValue | AttributeTargets.GenericParameter, AllowMultiple = false, Inherited = false)] internal sealed class NullableAttribute : Attribute { public readonly byte[] NullableFlags; public NullableAttribute(byte P_0) { NullableFlags = new byte[1] { P_0 }; } public NullableAttribute(byte[] P_0) { NullableFlags = P_0; } } [CompilerGenerated] [Embedded] [AttributeUsage(AttributeTargets.Class | AttributeTargets.Struct | AttributeTargets.Method | AttributeTargets.Interface | AttributeTargets.Delegate, AllowMultiple = false, Inherited = false)] internal sealed class NullableContextAttribute : Attribute { public readonly byte Flag; public NullableContextAttribute(byte P_0) { Flag = P_0; } } } namespace ModelReplacement { public class MRKAISERKATTAIL3D : BodyReplacementBase { protected override GameObject LoadAssetsAndReturnModel() { string text = "KaiserKattail3D"; return Assets.MainAssetBundle.LoadAsset<GameObject>(text); } } [BepInPlugin("com.elowiny.ElowinyCompany", "ElowinyCharacters", "0.1.0")] [BepInDependency(/*Could not decode attribute arguments.*/)] public class Plugin : BaseUnityPlugin { private void Awake() { //IL_0021: Unknown result type (might be due to invalid IL or missing references) //IL_0027: Expected O, but got Unknown Assets.PopulateAssets(); ModelReplacementAPI.RegisterSuitModelReplacement("Kattail3D", typeof(MRKAISERKATTAIL3D)); Harmony val = new Harmony("com.elowiny.ElowinyCompany"); val.PatchAll(); ((BaseUnityPlugin)this).Logger.LogInfo((object)"Plugin com.elowiny.ElowinyCompany is loaded!"); } } public static class Assets { public static string mainAssetBundleName = "elowinycharacters"; public static AssetBundle MainAssetBundle = null; private static string GetAssemblyName() { return Assembly.GetExecutingAssembly().GetName().Name.Replace(" ", "_"); } public static void PopulateAssets() { if ((Object)(object)MainAssetBundle == (Object)null) { Console.WriteLine(GetAssemblyName() + "." + mainAssetBundleName); using Stream stream = Assembly.GetExecutingAssembly().GetManifestResourceStream(GetAssemblyName() + "." + mainAssetBundleName); MainAssetBundle = AssetBundle.LoadFromStream(stream); } } } } namespace System.Runtime.CompilerServices { [AttributeUsage(AttributeTargets.Assembly, AllowMultiple = true)] internal sealed class IgnoresAccessChecksToAttribute : Attribute { public IgnoresAccessChecksToAttribute(string assemblyName) { } } }