public static void ReceiveThread() { while (true) { int id = RecvInt(); for (int i = 0; i < watchedObjects.Count; i++) { if (id == watchedObjects[i].objectID) { if (!watchedObjects[i].ownedByClient) { Vector3CS position = RecvVector(); watchedObjects[i].transform.position = new Vector3(position.x, position.y, position.z); } } } } }
public static extern void SendVector(Vector3CS vec, MessageFlags flag);