Search code examples
c#unity-game-enginezeromqnetmq

Unity and ZeroMQ


came across several post but doesn't seem to be able to find a definite answer as to how do one integrate ZeroMQ and Unity without the use of a wrapper/dll.

Wanting to use a Pub/Sub method, so it would be nice if someone is able to assist on this as well.

P/S using VS Code.


Solution

  • The standard way to use libraries is to import them using nuget. This ensures any other dependencies are included.

    I have not used unity3D, but there seem to be a asset to import nuget packages. See this post for more info.

    From the NetMQ homepage:

    NetMQ is a 100% native C# port of ZeroMQ

    This means you do not need clrzmq or any other native library. You still need the dll for NetMQ, but .net dlls are typically easier to include and use than wrappers around native libraries.

    Note that NetMQ uses LGPL license, that means you can use the dll for the library. But if you actually include the source code that would mean your whole game would also need to be licensed under LGPL.