How to properly disconnect players who lose their network connection?

Posted by TexDreemurr
I want to properly and safely remove the player from play if they suddenly lose their network connection. Maybe move them to a room that says they lost connection. I know there's "gms_info_isconnected ( )", but how do I use this? or is there another, simpler way to do it?

On top of this, is there a way to display (or I suppose draw) everyone's ping so that I know who's lagging?

Thank you in advance!

Replies (1)

Last message on 8 Sep 2019

Size43 (Administrator) on 8 Sep 2019, 14:05:38
You can simply check if gms_info_isconnected() returns true, and if so move the player to another room like you normally would.

It's only possible to get and display your own ping. There's no built-in function to see the ping of other players.