public void RemoveObstacle() { if (this._obstacleCount == 0) { Debug.LogErrorFormat("No obstacle to remove on this node ({0})!", new Coordinate(this.gridX, this.gridY)); } this._obstacleCount--; GridManager.NotifyGridChanged(); }
public void AddObstacle() { #if DEBUG if (this._obstacleCount == byte.MaxValue) { Debug.LogErrorFormat("Too many obstacles on this node ({0})!", new Coordinate(this.gridX, this.gridY)); } #endif this._obstacleCount++; GridManager.NotifyGridChanged(); }