private void KillObjectRPC(NetworkViewID objectOwner, int objectID) { //Debug.Log("KillObjectRPC received."); GameObject obj = base.GetObject(objectOwner, objectID); //if (Network.peerType == NetworkPeerType.Server) //{ // ObjectSync objSync = obj.GetComponent<ObjectSync>(); // if (objSync != null) // objSync.Dispose(); //} HealthControl healthControl = obj.GetComponent <HealthControl>(); healthControl.Die(); }