How to use Open.Nat/Mono.Nat with Unity?
I'm making a multiplayer game in Unity using Mirror. I want to use Open.Nat or Mono.Nat for NAT traversal. While these libraries are written in C#, I can't figure out how to use them in Unity. There are posts on Reddit, Stack Overflow, and Unity Answers/Forum, but they're outdated and don't provide much information. I tried installing the Open.Nat NuGet package, but it doesn't work.
Also, which library should I use?
Answer by firebird52 · Dec 04, 2020 at 09:38 PM
Ok. I figured out how to do this. Mono.NAT seems to be more up-to-date, so I just chose that. I downloaded it and ran the make
command to build it, then imported the DLL into Unity (see here) and then used it as normal.
Your answer
![](https://koobas.hobune.stream/wayback/20220613020654im_/https://answers.unity.com/themes/thub/images/avi.jpg)
Follow this Question
Related Questions
Mirror not working 0 Answers
Unity Mirror - cancel command if it got it to late 0 Answers
Mirror switches to localhost when I run the servers 0 Answers