[PUN] Leaving room won't delete player on LeftRoom()

So when the player clicks the “Disconnect” button it loads them into the main menu but leaves their character behind, and leaves a random player with the player’s character to control at the same time. Is there anyway to delete the disconnecting player’s character so this doesn’t happen.

When the button is pressed, call the Destroy method or SetActive to false. For example.

Destroy(GameObject.Find("[NAME OF GAMEOBJECT]"));

or

 GameObject.Find("[NAME OF GAMEOBJECT]").SetActive(false);

OK, GOOD NEWS! I have figured it out. So in one of my room scripts I had a OnPlayerLeaveRoom which had a Player parameter called otherPlayer. I used this to utilize the PhotonNetwork.DestoryPlayerObjects class and used otherPlayer as the parameter for that and it did the trick. Thanks to all that helped.