• Hey Guest! Ever feel like entering a Game Jam, but the time limit is always too much pressure? We get it... You lead a hectic life and dedicating 3 whole days to make a game just doesn't work for you! So, why not enter the GMC SLOW JAM? Take your time! Kick back and make your game over 4 months! Interested? Then just click here!

Faster checking if you could connect a server

marasovec

Member
var connect = network_connect_raw(global.socket, ip, port);
if connect < 0
{
show_message("Could not connect");
game_restart();
}

This code works but when the server isnt online it stops responding for about a minute and then after the minute it says "could not connect". Is there a better way how to check it? Something like try/catch in C#?
 
Last edited:
Top