public void exitLevel(string sceneName) { UserLogoutEvent logOut = new UserLogoutEvent(); logOut.Send(); SceneManager.LoadScene(sceneName); }
// Run on exit of application. Logs the user out of the server and closes the websocket public void OnApplicationQuit() { UserLogoutEvent logout = new UserLogoutEvent(); logout.Send(); log("Closing!!"); if (w != null && w.connected) { w.Close(); } }
public void OnApplicationQuit() { UserLogoutEvent logout = new UserLogoutEvent(); logout.Send(); FlowEvent closeEvent = new FlowEvent(); closeEvent.command = -1; CommandProcessor.sendCommand(closeEvent); Debug.Log("Closing!!"); if (w != null && w.connected) { w.Close(); } }