コード例 #1
0
    void OnDrawGizmos()
    {
        Gizmos.color = Color.yellow;
        Gizmos.DrawSphere(transform.position, 0.5f);

        if (_cellGrid != null)
        {
            _cellGrid.DebugDraw();
            if (_isGenerationCompleted)
            {
                if (_startTile != null && _startTile.Cell != null)
                {
                    _startTile.Cell.DebugDraw(Color.green);
                }
                if (_endTile != null && _endTile.Cell != null)
                {
                    _endTile.Cell.DebugDraw(Color.red);
                }
            }
        }
    }