public void clearRecord(FsConnect _fsConnect, uint ID) { for (int i = ghostPlanes.Count - 1; i >= 0; i--) { if (ID == ghostPlanes[i].ID) { _fsConnect.RemoveObject(ghostPlanes[i].ID, Requests.TowPlane); ghostPlanes.RemoveAt(i); } } }
public void clearRecords(FsConnect _fsConnect) { foreach (GhostPlane ghostPlane in ghostPlanes) { if (ghostPlane.ID != TARGETMAX) { _fsConnect.RemoveObject(ghostPlane.ID, Requests.TowPlane); } } ghostPlanes = new List <GhostPlane>(); }