Class MonoGameIcyHost
- Namespace
- Icy.MonoGame.Configuration
- Assembly
- IcyUI.MonoGame.dll
IcyUI in a MonoGame game: a game component that pumps input, follows the display scale and draws Canvases every frame. Created by UseIcyUI(Game).
public sealed class MonoGameIcyHost : DrawableGameComponent, IGameComponent, IUpdateable, IDisposable, IDrawable, IIcyHost
- Inheritance
-
GameComponentDrawableGameComponentMonoGameIcyHost
- Implements
-
IGameComponentIUpdateableIDrawable
- Inherited Members
-
DrawableGameComponent.GraphicsDeviceDrawableGameComponent.DrawOrderDrawableGameComponent.VisibleDrawableGameComponent.DrawOrderChangedDrawableGameComponent.VisibleChangedGameComponent.Dispose()GameComponent.GameGameComponent.EnabledGameComponent.UpdateOrderGameComponent.EnabledChangedGameComponent.UpdateOrderChanged
- Extension Methods
Remarks
Components draw during base.Draw() in your game's Draw, and Microsoft.Xna.Framework.DrawableGameComponent.DrawOrder
defaults to MaxValue, so the UI covers what your game and its other components draw. Anything
you draw after base.Draw() lands on top of the UI.
Properties
Canvases
Gets the canvases drawn every frame, in order: a later canvas draws on top of an earlier one.
public IList<Canvas> Canvases { get; }
Property Value
Configuration
Gets the configuration every element in this game is created with.
public IcyConfiguration Configuration { get; }
Property Value
MainCanvas
Gets the canvas UseIcyUI() created, with input enabled; Canvases[0].
public Canvas MainCanvas { get; }
Property Value
Methods
Draw(GameTime)
Draw this component.
public override void Draw(GameTime gameTime)
Parameters
gameTimeGameTimeThe time elapsed since the last call to Microsoft.Xna.Framework.DrawableGameComponent.Draw(Microsoft.Xna.Framework.GameTime).
Initialize()
Called when the Microsoft.Xna.Framework.GameComponent needs to be initialized.
public override void Initialize()
Update(GameTime)
Update the component.
public override void Update(GameTime gameTime)
Parameters
gameTimeGameTimeMicrosoft.Xna.Framework.GameTime of the Microsoft.Xna.Framework.GameComponent.Game.