Browse Source

move Debug.Enabled check into DrawToasts

GitOrigin-RevId: 8265b948f7
master
Colin McMillen 4 years ago
parent
commit
63aa190afe
  1. 3
      Shared/Debug.cs
  2. 3
      Shared/SneakGame.cs

3
Shared/Debug.cs

@ -71,6 +71,9 @@ namespace SemiColinGames {
}
public static void DrawToasts(SpriteBatch spriteBatch, SpriteFont font) {
if (!Enabled) {
return;
}
int y = 10;
foreach (var toast in toasts) {
spriteBatch.DrawString(font, toast, new Vector2(10, y), Color.Teal);

3
Shared/SneakGame.cs

@ -133,9 +133,8 @@ namespace SemiColinGames {
0, 0, GraphicsDevice.Viewport.Width, GraphicsDevice.Viewport.Height);
spriteBatch.Draw(renderTarget, drawRect, Color.White);
if (Debug.Enabled) {
// Draw debug toasts.
Debug.DrawToasts(spriteBatch, font);
}
spriteBatch.End();

Loading…
Cancel
Save