You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The internet match IP/password field currently allows only entering IPv4 addresses. However, hostnames are also used and resolved. However, if a hostname gets resolved to an IPv6 address, the game crashes:
Unhandled Exception detected: SocketException: An address incompatible with the requested protocol was used
(Filename: /home/builduser/buildslave/unity/build/artifacts/generated/common/runtime/DebugBindings.gen.cpp Line: 51)
System.Net.Sockets.Socket.Connect (System.Net.EndPoint remoteEP, Boolean requireSocketPolicy)
System.Net.Sockets.Socket.Connect (System.Net.EndPoint remoteEP)
System.Net.Sockets.UdpClient.DoConnect (System.Net.IPEndPoint endPoint)
(Filename: /home/builduser/buildslave/unity/build/artifacts/generated/common/runtime/DebugBindings.gen.cpp Line: 51)
SocketException: An address incompatible with the requested protocol was used
at System.Net.Sockets.Socket.Connect (System.Net.EndPoint remoteEP, Boolean requireSocketPolicy) [0x00000] in <filename unknown>:0
at System.Net.Sockets.Socket.Connect (System.Net.EndPoint remoteEP) [0x00000] in <filename unknown>:0
at System.Net.Sockets.UdpClient.DoConnect (System.Net.IPEndPoint endPoint) [0x00000] in <filename unknown>:0
(Filename: Line: -1)
Unhandled Exception detected: NullReferenceException: Object reference not set to an instance of an object
(Filename: /home/builduser/buildslave/unity/build/artifacts/generated/common/runtime/DebugBindings.gen.cpp Line: 51)
LocalLANClient.DoTick () <0x000fa>
NetworkMatch.NetSystemDoTick () <0x004e4>
NetworkMatch.Update () <0x00033>
Overload.NetworkManager.Update () <0x0003b>
(wrapper dynamic-method) Overload.GameManager.Overload.GameManager.Update_Patch2 (Overload.GameManager) <0x0059e>
(Filename: /home/builduser/buildslave/unity/build/artifacts/generated/common/runtime/DebugBindings.gen.cpp Line: 51)
NullReferenceException: Object reference not set to an instance of an object
at LocalLANClient.DoTick () <0x000fa>
at NetworkMatch.NetSystemDoTick () <0x004e4>
at NetworkMatch.Update () <0x00033>
at Overload.NetworkManager.Update () <0x0003b>
at (wrapper dynamic-method) Overload.GameManager.Overload.GameManager.Update_Patch2 (Overload.GameManager) <0x0059e>
(Filename: Line: -1)
Unhandled Exception detected: NullReferenceException: Object reference not set to an instance of an object
(Filename: /home/builduser/buildslave/unity/build/artifacts/generated/common/runtime/DebugBindings.gen.cpp Line: 51)
LocalLANClient.DoTick () <0x000fa>
NetworkMatch.NetSystemDoTick () <0x004e4>
NetworkMatch.Update () <0x00033>
Overload.NetworkManager.Update () <0x0003b>
(wrapper dynamic-method) Overload.GameManager.Overload.GameManager.Update_Patch2 (Overload.GameManager) <0x0059e>
(Filename: /home/builduser/buildslave/unity/build/artifacts/generated/common/runtime/DebugBindings.gen.cpp Line: 51)
As a quick improvement, I added a small patch in PR #225 which will prefer an IPv4 if multiple addresses are returned by the DNS.
However, in the long run, it would be nice to see if we could make olmod internet games work with IPv6 natively. It's not clear which changes this might require, and it it is feasible at all...
The text was updated successfully, but these errors were encountered:
I looked a little bit into this. The UdpConnection class just needs to know the address family to use at construction time. For the matchmaking phase alone, the client side would be easy to adapt, as we already have the IPAddress at that time and know the address family.
For the server side, we would need an additionalUpdClient to listen for IPv6. That should be a bit more work, but could still be doable with reasonable effort.
However, the big question which remains is whether the rest of the code can deal with IPv6 addresses or not. Haven't looked into that yet....
The internet match IP/password field currently allows only entering IPv4 addresses. However, hostnames are also used and resolved. However, if a hostname gets resolved to an IPv6 address, the game crashes:
As a quick improvement, I added a small patch in PR #225 which will prefer an IPv4 if multiple addresses are returned by the DNS.
However, in the long run, it would be nice to see if we could make olmod internet games work with IPv6 natively. It's not clear which changes this might require, and it it is feasible at all...
The text was updated successfully, but these errors were encountered: