D
Drepple
Guest
Hello,
I am working on a project in which people can choose to host or join a server. If a client leaves he gets disconnected fine, but when the host leaves he has to restart the game if he wants to create a new server on the same port. So I assume game maker frees the port when the game is closed, just as how a client gets disconnected when closing the game. Luckily there's a function for a client to disconnect (network_destroy) so they don't have to restart the game. So I was wondering if there's a function for the host to free the port when exiting to the menu so he can create a new server on the same port without restarting. If not it would mean people had to enter ports as well as ip adresses and I want to keep it as simpel as possible.
thanks in advance, Jesse
I am working on a project in which people can choose to host or join a server. If a client leaves he gets disconnected fine, but when the host leaves he has to restart the game if he wants to create a new server on the same port. So I assume game maker frees the port when the game is closed, just as how a client gets disconnected when closing the game. Luckily there's a function for a client to disconnect (network_destroy) so they don't have to restart the game. So I was wondering if there's a function for the host to free the port when exiting to the menu so he can create a new server on the same port without restarting. If not it would mean people had to enter ports as well as ip adresses and I want to keep it as simpel as possible.
thanks in advance, Jesse