stirante / lol-client-java-api

Simple library which provides access to internal League of Legends Client API.
GNU General Public License v3.0
67 stars 14 forks source link

Reconnect logic? #25

Closed sabihismail closed 2 years ago

sabihismail commented 2 years ago

Hi,

Is there some way to auto-detect the league client being restarted/logging into another user? Or some alternative solution to enable this?

Thanks!

stirante commented 2 years ago

Hi,

The connection is listener based, so you can notice, that first you get onClientDisconnected and then onClientConnected. If you don't, you can always print all events from the websocket and check if there is some characteristic event sent on restart/relogin.