using System;
using System.Diagnostics;
using System.Reflection;
using System.Runtime.CompilerServices;
using System.Runtime.Versioning;
using System.Security;
using System.Security.Permissions;
using BepInEx;
using BepInEx.Configuration;
using BepInEx.Logging;
using Microsoft.CodeAnalysis;
using PersonalBoombox;
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("alexandre v1")]
[assembly: AssemblyConfiguration("Debug")]
[assembly: AssemblyDescription("A yakuza boombox mod for lethal company ")]
[assembly: AssemblyFileVersion("1.0.2.0")]
[assembly: AssemblyInformationalVersion("1.0.2+33bf76edbee386e89c8f826a3cd2227dd7dbba71")]
[assembly: AssemblyProduct("Yakuza Boombox")]
[assembly: AssemblyTitle("YakuzaBoombox")]
[assembly: SecurityPermission(SecurityAction.RequestMinimum, SkipVerification = true)]
[assembly: AssemblyVersion("1.0.2.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 YakuzaBoombox
{
public static class PluginInfo
{
public const string PluginGuid = "alexandre_v1.YakuzaBoombox";
public const string PluginName = "YakuzaBoombox";
public const string PluginVersion = "1.0.2";
}
[BepInPlugin("alexandre_v1.YakuzaBoombox", "YakuzaBoombox", "1.0.2")]
[BepInProcess("Lethal Company.exe")]
[BepInDependency("ImoutoSama.PersonalBoombox", "1.3.0")]
public class YakuzaBoomboxPlugin : BaseUnityPlugin
{
private ManualLogSource _logger;
private ConfigEntry<bool> _overridePriceFlagConfig;
private ConfigEntry<int> _overridePriceValueConfig;
private void Awake()
{
_logger = Logger.CreateLogSource("alexandre_v1.YakuzaBoombox");
_logger.LogInfo((object)"Plugin YakuzaBoombox has been added!");
_overridePriceFlagConfig = ((BaseUnityPlugin)this).Config.Bind<bool>("General", "Override Price Flag", false, "If you want to override price of the boomboxes, you MUST set this to true.");
_overridePriceValueConfig = ConfigBindClamp("General", "Override Price Value", 30, "Overrides the price of the boomboxes by this value. Clamped from 0 to 1000.", 0, 1000);
RequestData val = PersonalBoomboxPlugin.AddFromAssemblyDll(Assembly.GetExecutingAssembly().Location);
val.overridePriceFlag = _overridePriceFlagConfig.Value;
val.overridePriceValue = _overridePriceValueConfig.Value;
}
private ConfigEntry<int> ConfigBindClamp(string section, string key, int defaultValue, string description, int min, int max)
{
ConfigEntry<int> val = ((BaseUnityPlugin)this).Config.Bind<int>(section, key, defaultValue, description);
val.Value = Mathf.Clamp(val.Value, min, max);
return val;
}
}
}