Check if an ip is hosting a game?

Hey all! I’ve searched around but haven’t found any answers to my issue. It would be awesome if you could help me out.

-Players will add ip’s to their list of servers in the game menu.
-When they hit refresh, I want to be able to detect if any of the ip’s are hosting a game.

I’m using the standard built in networking for unity. Got any ideas? I tried using the Ping() function but that returns true if the ip is a valid ip, not if the ip is hosting a game.

Couldnt you just try connecting to the ip? Otherwise I can’t see any other way, data can’t be sent if the machines aren’t connected. :slight_smile: You could also register the hosted game on unitys master server and use that to see if there is a game hosted by that ip.

Well if I refresh the list and it has 3 server ip’s, then I would have to connect to all of them and I think you can only be connected to 1 at a time. Unless I connect and then disconnect but save a variable that I was able to connect and the just move down the list… We may be on to something here.