To preface, I am coming from using Xamarin (free) with OpenTK. Referencing the OpenTK.dll and getting a window to render to up and running is very simple for me at this point. OpenTK provides properties for determining what OS it’s currently running on (Linux/Windows/Android/Mac/etc)…
However, MonoGame is looking like a better alternative for me (more supported platforms). So, I downloaded the 3.3 installer and went ahead and installed it. I do have Visual Studio 2010 Professional installed as well, and started a new project (for Windows without OpenGL). Everything was nicely laid out.
I then went to Xamarin and started a blank project. I browsed to the installed location of MonoGame and inside of there (the Assemblies folder) were folders for each “OS” with dll’s.
So, is there no way to create 1 project with MonoGame dll’s? Do I have to create separate projects for each OS I want to support for window creation, with a shared library for all game logic?
The way I “thought” it would work is to reference the MonoGame dll’s and the library would take care of creating whatever Window context that is supported.
As a quick test, in Xamarin, I referenced MonoGame.Framework and added this code:
Microsoft.Xna.Framework.Game g = new Microsoft.Xna.Framework.Game (); Microsoft.Xna.Framework.GameWindow.Create (g, 1000, 600); g.Run ();
but it complains that Xna does not exist in that namespace, when it fact it shows up in intellisense. I know that this isn’t the proper way to use it, but it’s just a test.