From ce6916635f738e3e61cd271dd89d76341ff42e47 Mon Sep 17 00:00:00 2001 From: JohnCorby Date: Tue, 29 Mar 2022 14:09:18 -0700 Subject: [PATCH] Revert "TEST ME: remove PlayerCrushedController_CrushPlayer patch" This reverts commit e9251498cc0690e1b55f13b4b602fae763ed915c. --- QSB/Player/Patches/PlayerPatches.cs | 15 +++++++++++++++ 1 file changed, 15 insertions(+) diff --git a/QSB/Player/Patches/PlayerPatches.cs b/QSB/Player/Patches/PlayerPatches.cs index 283efc13..deff4700 100644 --- a/QSB/Player/Patches/PlayerPatches.cs +++ b/QSB/Player/Patches/PlayerPatches.cs @@ -10,6 +10,21 @@ internal class PlayerPatches : QSBPatch { public override QSBPatchTypes Type => QSBPatchTypes.OnClientConnect; + /// + /// this usually does a bunch of extra stuff before crushing the player. + /// it's too much effort to revert all that when respawning. + /// so we just don't do the extra stuff. + /// + [HarmonyPrefix] + [HarmonyPatch(typeof(PlayerCrushedController), nameof(PlayerCrushedController.CrushPlayer))] + public static bool PlayerCrushedController_CrushPlayer() + { + // #CrushIt https://www.twitch.tv/videos/846916781?t=00h03m51s + // this is what you get from me when you mix tiredness and a headache - jokes and references only i will get + Locator.GetDeathManager().KillPlayer(DeathType.Crushed); + return false; + } + [HarmonyPrefix] [HarmonyPatch(typeof(PlayerData), nameof(PlayerData.LearnLaunchCodes))] public static bool LearnLaunchCodes()