Browse Source

add resolution to FPS display

GitOrigin-RevId: c414668d05
master
Colin McMillen 4 years ago
parent
commit
523d1b519d
  1. 3
      Jumpy.Shared/JumpyGame.cs

3
Jumpy.Shared/JumpyGame.cs

@ -93,7 +93,8 @@ namespace Jumpy {
Rectangle drawRect = new Rectangle(
0, 0, GraphicsDevice.Viewport.Width, GraphicsDevice.Viewport.Height);
spriteBatch.Draw(renderTarget, drawRect, Color.White);
string fpsText = $"FPS: {fpsCounter.Fps:F1}";
string fpsText = $"{GraphicsDevice.Viewport.Width}x{GraphicsDevice.Viewport.Height}, " +
$"{fpsCounter.Fps:F1} FPS";
spriteBatch.DrawString(font, fpsText, new Vector2(10, 10), Color.White);
spriteBatch.End();

Loading…
Cancel
Save