fix map patches + cleanup

This commit is contained in:
Mister_Nebula 2021-10-30 19:33:59 +01:00
parent 8d4cb9689e
commit 53433445e3
3 changed files with 7 additions and 22 deletions

View File

@ -1,18 +1,16 @@
using QSB.Patches;
using HarmonyLib;
using QSB.Patches;
using UnityEngine;
namespace QSB.DeathSync.Patches
{
[HarmonyPatch]
internal class MapPatches : QSBPatch
{
public override QSBPatchTypes Type => QSBPatchTypes.RespawnTime;
//public override void DoPatches()
//{
// Prefix<MapController>(nameof(MapController.LateUpdate), nameof(MapController_LateUpdate));
// Prefix<MapController>(nameof(MapController.EnterMapView), nameof(MapController_EnterMapView));
//}
[HarmonyPrefix]
[HarmonyPatch(typeof(MapController), nameof(MapController.EnterMapView))]
public static bool MapController_EnterMapView(
MapController __instance,
ref bool ____isMapMode,
@ -95,6 +93,8 @@ namespace QSB.DeathSync.Patches
return false;
}
[HarmonyPrefix]
[HarmonyPatch(typeof(MapController), nameof(MapController.LateUpdate))]
public static bool MapController_LateUpdate(
MapController __instance,
ref float ____observatoryRevealTwist,

View File

@ -9,12 +9,6 @@ namespace QSB.DeathSync.Patches
{
public override QSBPatchTypes Type => QSBPatchTypes.OnClientConnect;
//public override void DoPatches()
//{
// Prefix<PlayerRecoveryPoint>(nameof(PlayerRecoveryPoint.OnGainFocus), nameof(PlayerRecoveryPoint_OnGainFocus));
// Prefix<PlayerRecoveryPoint>(nameof(PlayerRecoveryPoint.OnPressInteract), nameof(PlayerRecoveryPoint_OnPressInteract));
//}
[HarmonyPrefix]
[HarmonyPatch(typeof(PlayerRecoveryPoint), nameof(PlayerRecoveryPoint.OnGainFocus))]
public static bool PlayerRecoveryPoint_OnGainFocus(

View File

@ -10,15 +10,6 @@ namespace QSB.RoastingSync.Patches
{
public override QSBPatchTypes Type => QSBPatchTypes.OnClientConnect;
//public override void DoPatches()
//{
// Prefix<RoastingStickController>(nameof(RoastingStickController.UpdateMarshmallowInput), nameof(RoastingStickController_UpdateMarshmallowInput));
// Prefix<Marshmallow>(nameof(Marshmallow.Burn), nameof(Marshmallow_Burn));
// Prefix<Marshmallow>(nameof(Marshmallow.Shrivel), nameof(Marshmallow_Shrivel));
// Prefix<Marshmallow>(nameof(Marshmallow.RemoveMallow), nameof(Marshmallow_RemoveMallow));
// Prefix<Marshmallow>(nameof(Marshmallow.SpawnMallow), nameof(Marshmallow_SpawnMallow));
//}
[HarmonyPrefix]
[HarmonyPatch(typeof(Marshmallow), nameof(Marshmallow.SpawnMallow))]
public static bool Marshmallow_SpawnMallow()