right now when it disconnects, it doesn't try to reconnect. try a "socket.connect();" with an exponential decay: try after 1 second, then 2 seconds, then 4 seconds, then 8 seconds, then 16 seconds, etc. stop after 10 tries=2048 seconds of trying=34 minutes of trying with constantly increasing interval. yeah i'm a nerd.
right now when it disconnects, it doesn't try to reconnect. try a "socket.connect();" with an exponential decay: try after 1 second, then 2 seconds, then 4 seconds, then 8 seconds, then 16 seconds, etc. stop after 10 tries=2048 seconds of trying=34 minutes of trying with constantly increasing interval. yeah i'm a nerd.