MasterServer.UnregisterHost Manual     Reference     Scripting  
Scripting > Runtime Classes > MasterServer
MasterServer.UnregisterHost

static function UnregisterHost () : void

Description

Unregister this server from the master server.

Does nothing if the server is not registered or has already unregistered.

function OnGUI() {
if (GUILayout.Button ("Disconnect")) {
Network.Disconnect();
MasterServer.UnregisterHost();
}
}