From d560d06c1eab8e2a0f822c4d9b9d36eab2a907f4 Mon Sep 17 00:00:00 2001 From: MSWS Date: Sun, 24 Mar 2024 16:01:25 -0700 Subject: [PATCH] Fix coinflip x2 printouts --- mod/Jailbreak.LastRequest/LastRequestManager.cs | 2 +- mod/Jailbreak.LastRequest/LastRequests/Coinflip.cs | 1 + 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/mod/Jailbreak.LastRequest/LastRequestManager.cs b/mod/Jailbreak.LastRequest/LastRequestManager.cs index 07f477f6..6a2cf035 100644 --- a/mod/Jailbreak.LastRequest/LastRequestManager.cs +++ b/mod/Jailbreak.LastRequest/LastRequestManager.cs @@ -129,7 +129,7 @@ public HookResult OnPlayerDeath(EventPlayerDeath @event, GameEventInfo info) { // Handle active LRs var activeLr = ((ILastRequestManager)this).GetActiveLR(player); - if (activeLr != null) + if (activeLr != null && activeLr.state != LRState.Completed) { var isPrisoner = activeLr.prisoner.Slot == player.Slot; EndLastRequest(activeLr, isPrisoner ? LRResult.GuardWin : LRResult.PrisonerWin); diff --git a/mod/Jailbreak.LastRequest/LastRequests/Coinflip.cs b/mod/Jailbreak.LastRequest/LastRequests/Coinflip.cs index 65b9bb2f..de87ab2f 100644 --- a/mod/Jailbreak.LastRequest/LastRequests/Coinflip.cs +++ b/mod/Jailbreak.LastRequest/LastRequests/Coinflip.cs @@ -33,6 +33,7 @@ public override void Setup() public override void Execute() { + state = LRState.Active; MenuManager.OpenChatMenu(guard, menu); timeout = plugin.AddTimer(10, () =>