How to kick a player?

how can i make a owner of the room kick the player?
i just want to kick not to close the connection, like leave the room.

[code2=csharp]if(TEXTO.Contains("/kick")){
string[] Args = TEXTO.Split(' ');
if(PhotonNetwork.room.customProperties["Owner"] == PhotonNetwork.player.name){

}else{
status = "you are not the owner!";
}[/code2]

sorry for my bad english;

Comments

  • PhotonNetwork.CloseConnection( PhotonPlayer kickPlayer )
    It essentially sends an event to the target player and that client quits the game.
  • i didnt understand, how can i quet the PhotonPlayer with a string for the name?
  • PhotonNetwork.CloseConnection( PhotonPlayer kickPlayer )

    in this case I asume PhotonPlayer is a connectet peer ( PhotonPlayer : PeerBase )
    your peer class has a different name.
    However this will complettly disconnect him I think... just Connect him again to the Lobby.
  • Hi,

    How to logout the same user when he is trying to login with different devices. Is there any solution can any one please.....