From 616437ff3199d6370b12ad645a0c543bc635cd1b Mon Sep 17 00:00:00 2001 From: YoshiRulz <OSSYoshiRulz+git@gmail.com> Date: Fri, 12 Jul 2024 08:09:59 +1000 Subject: [PATCH] Restore exception message in `SavestateFile.Create` partially reverts e9d6716a3 --- src/BizHawk.Client.Common/savestates/SavestateFile.cs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/BizHawk.Client.Common/savestates/SavestateFile.cs b/src/BizHawk.Client.Common/savestates/SavestateFile.cs index 104c09ca0d..a2af4d74a1 100644 --- a/src/BizHawk.Client.Common/savestates/SavestateFile.cs +++ b/src/BizHawk.Client.Common/savestates/SavestateFile.cs @@ -92,7 +92,7 @@ namespace BizHawk.Client.Common bs.PutLump(BinaryStateLump.Input, tw => { - Debug.Assert(_movieSession.Movie.FrameCount >= _emulator.Frame); + Debug.Assert(_movieSession.Movie.FrameCount >= _emulator.Frame, $"Tried to create a savestate at frame {_emulator.Frame}, but only got a log of length {_movieSession.Movie.FrameCount}!"); // this never should have been a core's responsibility tw.WriteLine("Frame {0}", _emulator.Frame); _movieSession.HandleSaveState(tw);