summaryrefslogtreecommitdiff
path: root/StardewModdingAPI/Events
diff options
context:
space:
mode:
Diffstat (limited to 'StardewModdingAPI/Events')
-rw-r--r--StardewModdingAPI/Events/Graphics.cs13
1 files changed, 13 insertions, 0 deletions
diff --git a/StardewModdingAPI/Events/Graphics.cs b/StardewModdingAPI/Events/Graphics.cs
index a2e7fc40..2b91144a 100644
--- a/StardewModdingAPI/Events/Graphics.cs
+++ b/StardewModdingAPI/Events/Graphics.cs
@@ -8,6 +8,14 @@ namespace StardewModdingAPI.Events
public static event EventHandler DrawTick = delegate { };
public static event EventHandler DrawInRenderTargetTick = delegate { };
+ /// <summary>
+ /// Draws when SGame.Debug is true. F3 toggles this.
+ /// Game1.spriteBatch.Begin() is pre-called.
+ /// Do not make end or begin calls to the spritebatch.
+ /// If you are only trying to add debug information, use SGame.DebugMessageQueue in your Update loop.
+ /// </summary>
+ public static event EventHandler DrawDebug = delegate { };
+
public static void InvokeDrawTick()
{
try
@@ -29,5 +37,10 @@ namespace StardewModdingAPI.Events
{
Resize.Invoke(sender, e);
}
+
+ public static void InvokeDrawDebug(object sender, EventArgs e)
+ {
+ DrawDebug.Invoke(sender, e);
+ }
}
} \ No newline at end of file