Ejemplo n.º 1
0
    // ON DRAW GIZMOS
    private void OnDrawGizmos()
    {
        if (!Application.isPlaying)
        {
            return;
        }
        Gizmos.color = Color.green;

        if (drawSpriteBounds)
        {
            doDrawSpriteBounds(bounds.getTopLeftWorldPoint(), bounds.getTopRightWorldPoint(), bounds.getBottomLeftWorldPoint(), bounds.getBottomRightWorldPoint());
        }

        if (drawCollisionRaycasts)
        {
            doDrawCollisionRaycasts(bounds.getTopLeftWorldPoint(), bounds.getTopRightWorldPoint(), bounds.getBottomLeftWorldPoint(), bounds.getBottomRightWorldPoint());
        }
    }