Skip to content

C6DFFFF2

Marcel Härtel edited this page Aug 19, 2023 · 1 revision

MonoGameControl Methods

Methods

Dispose Disposes the contents of the attached Editor.
(Overrides GraphicsDeviceControl.Dispose(Boolean))
Draw Override to implement Drawing logic in your custom MonoGame.Forms.Control.
Initialize Override to implement Initialization logic in your custom MonoGame.Forms.Control.
IsMouseInsideControlArea Returns true when the mouse cursor is inside the specific area.
(Inherited from GraphicsDeviceControl)
OnClientSizeChanged Updates related Editor services when the ClientSize changes.
(Overrides GraphicsDeviceControl.OnClientSizeChanged(EventArgs))
OnCreateControl
(Inherited from GraphicsDeviceControl)
OnMouseEnter
(Inherited from GraphicsDeviceControl)
OnMouseLeave
(Inherited from GraphicsDeviceControl)
OnMouseWheel
(Inherited from GraphicsDeviceControl)
OnPaint
(Inherited from GraphicsDeviceControl)
OnPaintBackground
(Inherited from GraphicsDeviceControl)
OnVisibleChanged In case the ClientSize was changed before activating the window, the cam position gets updated according to this changes.
(Overrides Control.OnVisibleChanged(EventArgs))
PaintUsingSystemDrawing
(Inherited from GraphicsDeviceControl)
RunFrames Run a specific amount of frames before the game loop falls to sleep again. The bool MouseHoverUpdatesOnly must be set to 'true' before.

Remarks

This could be helpful if some update mechanics are needing longer to update but doesn't need to run continuously afterwards.
(Inherited from GameControl)

RunOneFrame Runs exactly one frame by internally calling 'Invalidate();' one single time. This will run the game loop only once and immediately shows the result.
(Inherited from GameControl)
SetMultiSampleCount Set the "MultiSampleCount" for Multi Sampled AntiAlising (MSAA). The input value will be automatically clamped to the nearest power of two in relation of what the users GraphicsDevice can handle.
(Inherited from GraphicsDeviceControl)
Update Override to implement Update (Game Loop) logic in your custom MonoGame.Forms.Control.

See Also

Reference

MonoGameControl Class
MonoGame.Forms.NET.Controls Namespace

Clone this wiki locally