getkey

Joined 10 years ago

Karma
143
Submissions
7
Member since
Nov 12
getkey (at] getkey.eu
View on Hacker News

Recent submissions

Comment · 10 years ago
When a game server connects to the master to be registered, what the master gets is the the IP address relatively to it. If this address happens to be accessible from a client, everything's fine. However in some cases, it is not. For example in the case described where 127.0.0.1 is the game server's address (relatively to the master), if the master sent the address 127.0.0.1 to a client, it wouldn't connect. So we need to find out the public IP address in some cases, but sometimes it is better to use the local IP address (for example if the master, the game server and a client are on the same network and the client is not allowed to access the internet).

So basically finding out which IP address the master must send to the client is a huge pain. WebRTC does it automatically (to traverse NATs).

Comment · 10 years ago
Okay. And do you send positions of all players or only those that are visible?
Comment · 10 years ago
Do you adapt the amount of data sent based on the bandwidth? If so, how?

To me the best way to do this involve knowing how often the TCP socket is doing retransmissions, which is an information typically not available at the WebSocket level.

Comment · 10 years ago
Comment · 10 years ago

Live from the official Hacker News API

A modern reader for Hacker News · SvelteKit + Skeleton