diff --git a/KeplerEngine/Globals.cs b/KeplerEngine/Globals.cs
index 9baecf4..28186e1 100644
--- a/KeplerEngine/Globals.cs
+++ b/KeplerEngine/Globals.cs
@@ -4,13 +4,16 @@
using Microsoft.Xna.Framework.Content;
using Microsoft.Xna.Framework.Graphics;
using Microsoft.Xna.Framework.Input.Touch;
+using MonoGameGum;
+using Gum.Forms;
+using Gum.Forms.Controls;
+
namespace KeplerEngine;
public class Globals
{
public static SpriteBatch SpriteBatch { get; set; }
-
public static RenderTarget2D RenderTarget { get; set; }
///
@@ -21,7 +24,7 @@ public class Globals
///
/// VisibleRenderTargetBounds: the rectangle (in native render-target coordinates)
/// that is currently visible on screen after scaling (useful for anchoring)
- ///
+//
public static Rectangle VisibleRenderTargetBounds { get; set; } = Rectangle.Empty;
///
@@ -30,13 +33,20 @@ public class Globals
public static Rectangle RenderTargetDisplayRect { get; set; } = Rectangle.Empty;
///
- /// Returns the visible render target bounds if they're not empty.
- /// Otherwise, returns the bounds of the original render target.
+ /// The default Kepler Engine's Gum service
///
- public static Rectangle GetVisibleRenderTargetBounds() {
+ public GumService GumUI { get; } = GumService.Default;
+
+
+ ///
+ /// Returns the visible render target bounds if they're not empty.
+ /// Otherwise, returns the bounds of the original rend
+ {
var visible = Globals.VisibleRenderTargetBounds;
if (visible == Rectangle.Empty)
visible = Globals.RenderTarget.Bounds;
+f (visible == Rectangle.Empty)
+ visible = Globals.RenderTarget.Bounds;
return VisibleRenderTargetBounds == Rectangle.Empty
? RenderTarget.Bounds
@@ -54,8 +64,8 @@ public enum ScalingMode
Contain,
///
- /// Fill window, may crop.
- ///
+ /// Fi
+//
Cover,
///
@@ -70,8 +80,7 @@ public enum ScalingMode
public static MouseInputHandler Mouse { get; set; } = new MouseInputHandler();
- public static TouchInputHandler Touch { get; set; } = new TouchInputHandler();
-
+ public static TouchInputHandler Touch { get; set; } = new TouchInputHandler
public static SceneManager SceneManager { get; set; } = new SceneManager();
public static GameTime UpdateTime { get; set; }
@@ -93,7 +102,6 @@ public static void Update(GameTime gameTime)
Keyboard.Update();
Mouse.Update();
Touch.Update();
-
SceneManager.GetCurrentScene().Update();
OnUpdate(gameTime);
@@ -102,12 +110,12 @@ public static void Update(GameTime gameTime)
public static void Draw(GameTime gameTime)
{
DrawTime = gameTime;
- DeltaTime = (float)DrawTime.ElapsedGameTime.TotalSeconds;
+eltaTime = (float)DrawTime.ElapsedGameTime.TotalSeconds;
SceneManager.GetCurrentScene().Draw();
OnRender(gameTime);
- }
-
+ }
+
public static Action OnUpdate = (gt) => {};
public static Action OnRender = (gt) => {};
-}
\ No newline at end of file
+}
diff --git a/KeplerEngine/KeplerEngine.csproj b/KeplerEngine/KeplerEngine.csproj
index cbb91f8..1c9f06b 100644
--- a/KeplerEngine/KeplerEngine.csproj
+++ b/KeplerEngine/KeplerEngine.csproj
@@ -3,6 +3,7 @@
net8.0
+
All