How to create a MonoGame-based class library for use with UWP, iOS, and Android

I installed VisualStudio 2015, Xamarin and MonoGame 3.5. I am going to create an XNA application for Windows UWP, iOS and Android.

I have several XNA-based libraries ... and I need to create them for three target systems (Windows UWP, iOS and Android), but not create a library for Windows UWP. I tried to create MonoGame Windows 10 Universal Project, but such a project cannot be converted to create a DLL.

I also tried to create a project Class Library (Universal Windows), but then I was unable to add MonoGame.Frameworkto the links.

I have the same problem when creating MonoGame Android Project... there is no way to switch to the library project. The only MonoGame project that can be modified as a library project is MonoGame iOS Project.

However, how can I create an XNA-based class library (MonoGame) that will be used from UWP, iOS, and Android?

+4
source share
2 answers

As far as I know, you have only 2 options.

Shared Projects. , , - , , , . .

- . MonoGame.Extended , . , . DLL, , , .

PCL:

  • . , .
  • PCL , PCL.

, MonoGame . , MonoGame PCL, PCL NuGet, .

, NuGet , , PCL, , DLL, . , - 3.5, PCL 3.2, .

3.6.

+2

, MonoGame .Net 4.5 . .Net, 4.5.2. , 4.5. , .

0