| Unity |
This topic contains the following sections:
About Unity Unity
is a game development system which supports Mono (with limitations).
Special builds of the DigitalRune assemblies for use with Unity are available.
Limitations
The DigitalRune Engine for Unity has the following limitations:
-
The XNA-dependent libraries are not available for Unity. These are:
-
DigitalRune Game UI (DigitalRune.Game.Input.dll
and DigitalRune.Game.UI.dll) and
-
DigitalRune Graphics (DigitalRune.Graphics.dll).
-
The assembly DigitalRune.ServiceLocation.dll is not available.
If you need a Unity build of this DLL, let us know.
-
Multithreading is disabled.
Unity and Mono
The Mono implementation in Unity (v4.x) has some limitations and odd behaviors. Here are a few
things which we have observed:
-
.NET assemblies must be built for .NET 3.5, not .NET 4.0.
-
Mono in the Unity player for the desktop is more powerful than in the Unity web player. This means, everything can work fine in the Unity editor, but crash in the browser.
-
The web player may crash with an access violation exception if a .NET library uses a standard
.NET construct which is not supported. For example, if a .NET class has a
SerializableAttribute, the web player crashes.
-
Some standard .NET classes are not implemented properly. For example, the classes
Collection and KeyedCollection are
not properly implemented, and we had to re-implement
them ourselves (or rather get the correct implementation from the Mono project).
-
Some exceptions which occurred in a MonoBehavior.Update() method can be silently
caught. This left the code in an invalid state or caused misleading exceptions in other
parts of the code. We had to move the same code to MonoBehavior.Start() to get a helpful exception message.
Apart from the above mentioned limitations, the Unity build of the DigitalRune Engine is a
normal .NET 3.5 build which can be used in .NET/Mono applications. For example, you can
use the same assembly in your Unity game client and in a .NET/Mono game server.