From bf3ad0c8b0578a80dc91529af22933a7ea669242 Mon Sep 17 00:00:00 2001 From: cosmonaut Date: Thu, 29 Jun 2023 11:30:32 -0700 Subject: [PATCH] add Game.ShowRuntimeError method --- src/Game.cs | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/src/Game.cs b/src/Game.cs index 2e8261d..7193bfe 100644 --- a/src/Game.cs +++ b/src/Game.cs @@ -299,6 +299,16 @@ namespace MoonWorks Inputs.RemoveGamepad(evt.cdevice.which); } + public static void ShowRuntimeError(string title, string message) + { + SDL.SDL_ShowSimpleMessageBox( + SDL.SDL_MessageBoxFlags.SDL_MESSAGEBOX_ERROR, + title ?? "", + message ?? "", + IntPtr.Zero + ); + } + private TimeSpan AdvanceElapsedTime() { long currentTicks = gameTimer.Elapsed.Ticks;