using System;
using System.Diagnostics;
using System.Reflection;
using System.Runtime.CompilerServices;
using System.Runtime.InteropServices;
using System.Runtime.Versioning;
using BepInEx;
using HarmonyLib;
using Microsoft.CodeAnalysis;
using UnityEngine;
[assembly: CompilationRelaxations(8)]
[assembly: RuntimeCompatibility(WrapNonExceptionThrows = true)]
[assembly: Debuggable(DebuggableAttribute.DebuggingModes.IgnoreSymbolStoreSequencePoints)]
[assembly: AssemblyTitle("SpaceShipDoor")]
[assembly: AssemblyDescription("")]
[assembly: AssemblyConfiguration("")]
[assembly: AssemblyCompany("")]
[assembly: AssemblyProduct("SpaceShipDoor")]
[assembly: AssemblyCopyright("Copyright © 2024")]
[assembly: AssemblyTrademark("")]
[assembly: ComVisible(false)]
[assembly: Guid("A83A1998-FED0-4384-AE64-C6857AFB9A47")]
[assembly: AssemblyFileVersion("1.0.0.0")]
[assembly: TargetFramework(".NETFramework,Version=v4.8", FrameworkDisplayName = ".NET Framework 4.8")]
[assembly: AssemblyVersion("1.0.0.0")]
[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 SpaceShipDoor
{
public class Main : MonoBehaviour
{
[HarmonyPatch(typeof(HangarShipDoor), "Update")]
public class HangarShipDoorPatch
{
private static void Prefix(HangarShipDoor __instance)
{
if (!__instance.buttonsEnabled)
{
__instance.SetDoorButtonsEnabled(true);
}
}
}
[HarmonyPatch(typeof(StartOfRound), "TeleportPlayerInShipIfOutOfRoomBounds")]
public class StartOfRoundPatch
{
private static bool Prefix(StartOfRound __instance)
{
return !__instance.inShipPhase;
}
}
}
[BepInPlugin("Nie_SpaceShipDoor", "SpaceShipDoor", "1.0.1")]
public class Plugin : BaseUnityPlugin
{
public const string MODNAME = "SpaceShipDoor";
public const string AUTHOR = "Nie";
public const string GUID = "Nie_SpaceShipDoor";
public const string VERSION = "1.0.1";
public Plugin()
{
Harmony.CreateAndPatchAll(Assembly.GetExecutingAssembly(), (string)null);
}
}
}