Esempio n. 1
0
        public void Draw()
        {
            if (drawableCmpts != null && isDrawEnabled)
            {
                foreach (var cmpt in drawableCmpts)
                {
                    cmpt.Draw();
                }
            }

            if (children != null)
            {
                foreach (var child in children)
                {
                    child.Draw();
                }
            }

            if (DrawPositionsGlobal || DrawPosition)
            {
                DebugHelper.DrawDot(WorldPosition, new Color(.1f, 1f, .1f, 1f));
            }

            if (DrawHitboxesGlobal || DrawHitbox)
            {
                var hitbox = GetComponent <ColliderComponent>();

                if (hitbox?.Enabled == true)
                {
                    hitbox.Draw();
                }
            }
        }
Esempio n. 2
0
 public void Draw()
 {
     if (DrawEnabled)
     {
         var worldPosition = Object.WorldPosition;
         DebugHelper.DrawDot(new Point(worldPosition.X, adjustedY), DebugHelper.Blue);
     }
 }