public void SendAnchorName(String anchorName, String anchorOwnerIP) { // Use a different NetworkData instance so we do not overwrite our pose data. NetworkData networkData = new NetworkData(); networkData.SerializeAnchorName(anchorName, anchorOwnerIP); SendMessage(networkData); }
private void SendMessage(NetworkData networkData) { byte error; NetworkTransport.Send(socketId, connectionId, channelId, networkData.buffer, NetworkData.bufSize, out error); if (error != (byte)NetworkError.Ok) { Debug.Log("Error sending network message."); } }
public void SendAirTap(Vector3 position, Vector3 rotation, Vector3 hitLocation) { // Use a different NetworkData instance so we do not overwrite our pose data. NetworkData networkData = new NetworkData(); networkData.SerializeAirTap( GetVectorInAnchorSpace(position), GetVectorInAnchorSpace(rotation), GetVectorInAnchorSpace(hitLocation)); SendMessage(networkData); }