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 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("GenshinHonkaiProtags")]
[assembly: AssemblyConfiguration("Debug")]
[assembly: AssemblyFileVersion("1.0.0.0")]
[assembly: AssemblyInformationalVersion("1.0.0")]
[assembly: AssemblyProduct("GenshinHonkaiProtags")]
[assembly: AssemblyTitle("GenshinHonkaiProtags")]
[assembly: SecurityPermission(SecurityAction.RequestMinimum, SkipVerification = true)]
[assembly: AssemblyVersion("1.0.0.0")]
[module: UnverifiableCode]
namespace Microsoft.CodeAnalysis
{
[CompilerGenerated]
[Microsoft.CodeAnalysis.Embedded]
internal sealed class EmbeddedAttribute : Attribute
{
}
}
namespace System.Runtime.CompilerServices
{
[CompilerGenerated]
[Microsoft.CodeAnalysis.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]
[Microsoft.CodeAnalysis.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 ADAMHI3 : BodyReplacementBase
{
protected override GameObject LoadAssetsAndReturnModel()
{
string text = "AdamHI3";
return Assets.MainAssetBundle.LoadAsset<GameObject>(text);
}
}
public class LUMINEGI : BodyReplacementBase
{
protected override GameObject LoadAssetsAndReturnModel()
{
string text = "LumineGI";
return Assets.MainAssetBundle.LoadAsset<GameObject>(text);
}
}
public class RAIDENMEIAPHO : BodyReplacementBase
{
protected override GameObject LoadAssetsAndReturnModel()
{
string text = "RaidenMeiAPHO";
return Assets.MainAssetBundle.LoadAsset<GameObject>(text);
}
}
public class ENTROPYHI3 : BodyReplacementBase
{
protected override GameObject LoadAssetsAndReturnModel()
{
string text = "EntropyHI3";
return Assets.MainAssetBundle.LoadAsset<GameObject>(text);
}
}
public class RAIDENMEIHOOHI3 : BodyReplacementBase
{
protected override GameObject LoadAssetsAndReturnModel()
{
string text = "RaidenMeiHoOHI3";
return Assets.MainAssetBundle.LoadAsset<GameObject>(text);
}
}
public class ENTROPYMAHI3 : BodyReplacementBase
{
protected override GameObject LoadAssetsAndReturnModel()
{
string text = "EntropyMaHI3";
return Assets.MainAssetBundle.LoadAsset<GameObject>(text);
}
}
public class AETHERGI : BodyReplacementBase
{
protected override GameObject LoadAssetsAndReturnModel()
{
string text = "AetherGI";
return Assets.MainAssetBundle.LoadAsset<GameObject>(text);
}
}
public class KIANAHOFIHI3 : BodyReplacementBase
{
protected override GameObject LoadAssetsAndReturnModel()
{
string text = "KianaHoFiHI3";
return Assets.MainAssetBundle.LoadAsset<GameObject>(text);
}
}
public class KIANAHI3 : BodyReplacementBase
{
protected override GameObject LoadAssetsAndReturnModel()
{
string text = "KianaHI3";
return Assets.MainAssetBundle.LoadAsset<GameObject>(text);
}
}
public class ELYSIAHI3 : BodyReplacementBase
{
protected override GameObject LoadAssetsAndReturnModel()
{
string text = "ElysiaHI3";
return Assets.MainAssetBundle.LoadAsset<GameObject>(text);
}
}
public class ELYSIAMAIDHI3 : BodyReplacementBase
{
protected override GameObject LoadAssetsAndReturnModel()
{
string text = "ElysiaMaidHI3";
return Assets.MainAssetBundle.LoadAsset<GameObject>(text);
}
}
public class FUHUATAIXUAN : BodyReplacementBase
{
protected override GameObject LoadAssetsAndReturnModel()
{
string text = "FuHuaTaixuan";
return Assets.MainAssetBundle.LoadAsset<GameObject>(text);
}
}
public class FUHUAHOSHI3 : BodyReplacementBase
{
protected override GameObject LoadAssetsAndReturnModel()
{
string text = "FuHuaHoSHI3";
return Assets.MainAssetBundle.LoadAsset<GameObject>(text);
}
}
public class HIMEKOMURATAHSR : BodyReplacementBase
{
protected override GameObject LoadAssetsAndReturnModel()
{
string text = "HimekoMurataHSR";
return Assets.MainAssetBundle.LoadAsset<GameObject>(text);
}
}
public class HIMEKOROUGEDMAYUMIHI3 : BodyReplacementBase
{
protected override GameObject LoadAssetsAndReturnModel()
{
string text = "HimekoRougedMayumiHI3";
return Assets.MainAssetBundle.LoadAsset<GameObject>(text);
}
}
public class THERESAVERDANTSKYHI3 : BodyReplacementBase
{
protected override GameObject LoadAssetsAndReturnModel()
{
string text = "TheresaVerdantSkyHI3";
return Assets.MainAssetBundle.LoadAsset<GameObject>(text);
}
}
public class THERESAHEATOFTRIFOLIUM : BodyReplacementBase
{
protected override GameObject LoadAssetsAndReturnModel()
{
string text = "TheresaHeatOfTrifolium";
return Assets.MainAssetBundle.LoadAsset<GameObject>(text);
}
}
public class SENADINAHI3 : BodyReplacementBase
{
protected override GameObject LoadAssetsAndReturnModel()
{
string text = "SenadinaHI3";
return Assets.MainAssetBundle.LoadAsset<GameObject>(text);
}
}
public class SONGQUEHI3 : BodyReplacementBase
{
protected override GameObject LoadAssetsAndReturnModel()
{
string text = "SongqueHI3";
return Assets.MainAssetBundle.LoadAsset<GameObject>(text);
}
}
public class CORALIE6626PLANCKHI3 : BodyReplacementBase
{
protected override GameObject LoadAssetsAndReturnModel()
{
string text = "Coralie6626PLANCKHI3";
return Assets.MainAssetBundle.LoadAsset<GameObject>(text);
}
}
public class ERDOSHELIAHI3 : BodyReplacementBase
{
protected override GameObject LoadAssetsAndReturnModel()
{
string text = "ErdosHeliaHI3";
return Assets.MainAssetBundle.LoadAsset<GameObject>(text);
}
}
public class BUFFPAIMON : BodyReplacementBase
{
protected override GameObject LoadAssetsAndReturnModel()
{
string text = "BuffPaimon";
return Assets.MainAssetBundle.LoadAsset<GameObject>(text);
}
}
[BepInPlugin("com.mariokartwii.GenshinHonkaiProtag", "GenshinHonkaiProtagonistsLC", "0.1.0")]
[BepInDependency(/*Could not decode attribute arguments.*/)]
public class Plugin : BaseUnityPlugin
{
private void Awake()
{
//IL_01da: Unknown result type (might be due to invalid IL or missing references)
//IL_01e0: Expected O, but got Unknown
Assets.PopulateAssets();
ModelReplacementAPI.RegisterSuitModelReplacement("Lumine GI", typeof(LUMINEGI));
ModelReplacementAPI.RegisterSuitModelReplacement("Aether GI", typeof(AETHERGI));
ModelReplacementAPI.RegisterSuitModelReplacement("Theresa (Heat of Trifolium) HI3", typeof(THERESAHEATOFTRIFOLIUM));
ModelReplacementAPI.RegisterSuitModelReplacement("Kiana Kaslana HI3", typeof(KIANAHI3));
ModelReplacementAPI.RegisterSuitModelReplacement("Kiana Kaslana (Finality) HI3", typeof(KIANAHOFIHI3));
ModelReplacementAPI.RegisterSuitModelReplacement("Raiden Mei (APHO) HI3", typeof(RAIDENMEIAPHO));
ModelReplacementAPI.RegisterSuitModelReplacement("Raiden Mei (Origin) HI3", typeof(RAIDENMEIHOOHI3));
ModelReplacementAPI.RegisterSuitModelReplacement("Theresa (Verdant Sky) HI3", typeof(THERESAVERDANTSKYHI3));
ModelReplacementAPI.RegisterSuitModelReplacement("Fu Hua (Taixuan) HI3", typeof(FUHUATAIXUAN));
ModelReplacementAPI.RegisterSuitModelReplacement("Fu Hua (Sentience) HI3", typeof(FUHUAHOSHI3));
ModelReplacementAPI.RegisterSuitModelReplacement("Himeko Murata (Rouged) HI3", typeof(HIMEKOROUGEDMAYUMIHI3));
ModelReplacementAPI.RegisterSuitModelReplacement("Himeko (Star Rail)", typeof(HIMEKOMURATAHSR));
ModelReplacementAPI.RegisterSuitModelReplacement("Elysia HI3", typeof(ELYSIAHI3));
ModelReplacementAPI.RegisterSuitModelReplacement("Elysia (Miss Pink) HI3", typeof(ELYSIAMAIDHI3));
ModelReplacementAPI.RegisterSuitModelReplacement("Adam HI3", typeof(ADAMHI3));
ModelReplacementAPI.RegisterSuitModelReplacement("Entropy (Female) HI3", typeof(ENTROPYHI3));
ModelReplacementAPI.RegisterSuitModelReplacement("Entropy (Male) HI3", typeof(ENTROPYMAHI3));
ModelReplacementAPI.RegisterSuitModelReplacement("Senadina HI3", typeof(SENADINAHI3));
ModelReplacementAPI.RegisterSuitModelReplacement("Coralie 6626 HI3", typeof(CORALIE6626PLANCKHI3));
ModelReplacementAPI.RegisterSuitModelReplacement("Erdos Helia HI3", typeof(ERDOSHELIAHI3));
ModelReplacementAPI.RegisterSuitModelReplacement("Songque HI3", typeof(SONGQUEHI3));
ModelReplacementAPI.RegisterSuitModelReplacement("The Herrscher of Gains", typeof(BUFFPAIMON));
Harmony val = new Harmony("com.mariokartwii.GenshinHonkaiProtag");
val.PatchAll();
((BaseUnityPlugin)this).Logger.LogInfo((object)"Plugin com.mariokartwii.GenshinHonkaiProtag is loaded!");
}
}
public static class Assets
{
public static string mainAssetBundleName = "GenshinHonkaiProtagonists";
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)
{
}
}
}