Decompiled source of HolaSoyGoku v1.0.0

HolaSoyGoku.dll

Decompiled 5 months ago
using System.Collections.Generic;
using System.Diagnostics;
using System.Linq;
using System.Reflection;
using System.Runtime.CompilerServices;
using System.Runtime.InteropServices;
using System.Runtime.Versioning;
using BepInEx;
using BepInEx.Logging;
using HarmonyLib;
using HolaSoyGoku.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("HolaSoyGoku")]
[assembly: AssemblyDescription("")]
[assembly: AssemblyConfiguration("")]
[assembly: AssemblyCompany("")]
[assembly: AssemblyProduct("HolaSoyGoku")]
[assembly: AssemblyCopyright("Copyright ©  2024")]
[assembly: AssemblyTrademark("")]
[assembly: ComVisible(false)]
[assembly: Guid("defc309f-567a-4eea-bdc4-cf82d12fec96")]
[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 HolaSoyGoku
{
	[BepInPlugin("Poseidon.LCTutorialMod", "LC Tutorial", "1.0.0.0")]
	public class HolaSoyGoku : BaseUnityPlugin
	{
		private const string modGUID = "Poseidon.LCTutorialMod";

		private const string modName = "LC Tutorial";

		private const string modVersion = "1.0.0.0";

		private readonly Harmony harmony = new Harmony("Poseidon.LCTutorialMod");

		private static HolaSoyGoku Instance;

		internal ManualLogSource nls;

		internal static List<AudioClip> SoundFX;

		internal static AssetBundle Bundle;

		private void Awake()
		{
			if ((Object)(object)Instance == (Object)null)
			{
				Instance = this;
			}
			nls = Logger.CreateLogSource("Poseidon.LCTutorialMod");
			nls.LogInfo((object)"The mod is AWAKE, i hate this shit fr");
			harmony.PatchAll(typeof(SonidoGoku));
			nls = ((BaseUnityPlugin)this).Logger;
			SoundFX = new List<AudioClip>();
			string location = ((BaseUnityPlugin)Instance).Info.Location;
			location = location.TrimEnd("HolaSoyGoku.dll".ToCharArray());
			Bundle = AssetBundle.LoadFromFile(location + "holasoygoku");
			if ((Object)(object)Bundle != (Object)null)
			{
				SoundFX = Bundle.LoadAllAssets<AudioClip>().ToList();
			}
			else
			{
				nls.LogError((object)"No cargo mijo");
			}
		}
	}
}
namespace HolaSoyGoku.Patches
{
	[HarmonyPatch(typeof(FlowermanAI))]
	internal class SonidoGoku
	{
		[HarmonyPatch("Update")]
		[HarmonyPostfix]
		private static void OverrideAudio(FlowermanAI __instance)
		{
			__instance.crackNeckSFX = HolaSoyGoku.SoundFX[0];
		}
	}
}