Add function for detecting the lobby