Advertisement

Scanning for local LAN games

Started by February 10, 2005 12:06 AM
0 comments, last by Kibble 20 years ago
If I were to add a feature to my game to scan for local LAN servers of my game, should I have it looking though 192.168.0.0 and upwards, testing for the server listen port? Is there an easier way to do this?
Yes, use the UDP broadcasting feature. When you want to find games, broadcast a packet to the port your server listens on. When you recieve this message as a server, send a response back with the info you want to include like player slots available, game type, things of that nature.

Taking your original route would also require you to test 10.x.x.x, quite a few combinations!

This topic is closed to new replies.

Advertisement