using System.Diagnostics;
using System.Reflection;
using System.Runtime.CompilerServices;
using System.Runtime.InteropServices;
using System.Runtime.Versioning;
using BepInEx;
using BepInEx.Logging;
using HarmonyLib;
using SanyaModLC.Patches;
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("SanyaModLC")]
[assembly: AssemblyDescription("")]
[assembly: AssemblyConfiguration("")]
[assembly: AssemblyCompany("")]
[assembly: AssemblyProduct("SanyaModLC")]
[assembly: AssemblyCopyright("Copyright © 2025")]
[assembly: AssemblyTrademark("")]
[assembly: ComVisible(false)]
[assembly: Guid("d75e89c1-e9b0-457b-b72f-92505a82bad3")]
[assembly: AssemblyFileVersion("1.0.0.0")]
[assembly: TargetFramework(".NETFramework,Version=v4.7.2", FrameworkDisplayName = ".NET Framework 4.7.2")]
[assembly: AssemblyVersion("1.0.0.0")]
namespace SanyaModLC
{
[BepInPlugin("Savchenko.LCSanyaMod", "LC Sanya Mod", "1.0.0.0")]
public class SanyaModBase : BaseUnityPlugin
{
private const string modGUID = "Savchenko.LCSanyaMod";
private const string modName = "LC Sanya Mod";
private const string modVersion = "1.0.0.0";
private readonly Harmony harmony = new Harmony("Savchenko.LCSanyaMod");
private static SanyaModBase Instance;
internal ManualLogSource mls;
internal static AudioClip[] SoundFX;
internal static AssetBundle Bundle;
private void Awake()
{
if ((Object)(object)Instance == (Object)null)
{
Instance = this;
}
mls = Logger.CreateLogSource("Savchenko.LCSanyaMod");
mls.LogInfo((object)"The test mod has awaken");
mls = ((BaseUnityPlugin)this).Logger;
string location = ((BaseUnityPlugin)Instance).Info.Location;
location = location.TrimEnd("SanyaModLC.dll".ToCharArray());
Bundle = AssetBundle.LoadFromFile(location + "sanya");
if ((Object)(object)Bundle != (Object)null)
{
mls.LogError((object)"Successfully loaded asset bundle");
SoundFX = Bundle.LoadAllAssets<AudioClip>();
}
else
{
mls.LogError((object)"Failed to load asset bundle");
}
harmony.PatchAll(typeof(StartOfRoundPatch));
}
}
}
namespace SanyaModLC.Patches
{
[HarmonyPatch(typeof(HoarderBugAI))]
internal class StartOfRoundPatch
{
[HarmonyPatch("Start")]
[HarmonyPostfix]
private static void OverrideAudio(ref AudioClip[] ___chitterSFX)
{
AudioClip[] soundFX = SanyaModBase.SoundFX;
___chitterSFX = soundFX;
}
}
}