/// <summary> /// 从reader创建并初始化障碍物. /// </summary> public Obstacle CreateObstacle(BinaryReader reader, IDictionary<int, HalfEdge> container) { Obstacle answer = new Obstacle(); answer.ReadBinary(reader, container); obstacleContainer.Add(answer); return answer; }
/// <summary> /// 释放障碍物. /// </summary> public void ReleaseObstacle(Obstacle obstacle) { obstacleContainer.Remove(obstacle); }
/// <summary> /// 创建由boundingEdges包围的障碍物. /// </summary> public Obstacle CreateObstacle(List<HalfEdge> boundingEdges) { Obstacle answer = new Obstacle(); answer.BoundingEdges = boundingEdges; obstacleContainer.Add(answer); return answer; }