monkeylashes
← Homeworld: Unbound

Homeworld: Unbound 0.6 — three addresses a LAN makes equal (superseded by 0.7)

This post claimed internet play worked, and it did not. The third bug below survived into this build and was only fixed in 0.7, forty minutes later. The diagnosis is left as written because it is right and the reasoning is the point; the conclusion it drew was not.

0.5 shipped multiplayer over the internet forty minutes before this build, and it did not work. This was meant to be the one where it does.

Why testing on a LAN could never have caught it

Three separate things were broken, and all three confused the same pair of things — the address a machine calls itself, and the address someone else can reach it at. On a local network those are the same string. Everywhere else they are not, and a network you can test against in the room with you is exactly the network that hides it.

Taken in the order a game hits them:

The address advertised was the private one. Behind a router, both ends named each other by addresses that mean nothing outside the other’s house. The connection came up, reported itself healthy, and then every message on it was quietly dropped.

Replies went to port 10600 no matter where the packet came from. On mobile data that is never the right port. Thousands of subscribers share one address, so the carrier cannot keep yours, and the answer went to somewhere that did not exist. The joining player’s list simply stayed empty.

The host filed a joining player under the wrong address entirely — the one its own connection reported, rather than the one that player calls itself. This is the one that mattered. Everything looked correct right up to Start Game, at which point the joining player went looking for itself in the player list, was not there, and the game died on the spot. Every internet game, killed at the exact moment it began.

This last one is the one that survived. It was understood correctly and not actually fixed here, which is why there is a 0.7.

There is a keyboard now

This came in 0.5 and is the part of it worth keeping. Multiplayer had technically worked since 0.4, in the sense that the code ran; it was not something you could reach from inside a headset, because hosting or joining means naming yourself, naming a game, and typing an address, and there was nowhere to type anything.

It appears wherever the game has ever asked for text — player names, game names, chat, passwords, save names — and you type by pointing at a key and pulling the trigger. This build makes it shorter, lets the screen show through between the keys, and sits it directly above the field you are typing into instead of jumping to the top of the panel.

Typing into Join by address also works now. It was going into the lobby’s chat box, which claims the keyboard for as long as that screen is up and never releases it, so the address field lost focus in the same instant it got it.

What it asks of you

The host forwards two ports — TCP 10500 and UDP 10600. Whoever is joining forwards nothing at all; they type the host’s public address and the host learns them from the first packet that arrives.

Two limits worth knowing before you try. It is two players over the internet, because more than that needs the players to tell each other who they are and the protocol does not do that yet. And you cannot both be on the same home network range — most routers hand out 192.168.1.x out of the box, and if both of you are on it each machine goes looking for the other on its own network. Neither limit applies on a LAN.

No match has been played through to the end yet, so a desync late in a long game is possible. Sync checking is on, so it would report itself rather than quietly diverging.