Exemple #1
0
        void RenderHealth(FrameState frame, int health)
        {
            var color = _config.HealthToColor(health);

            for (var i = 0; i < health; i++)
            {
                var offset   = new Point2D(_config.Offset.X * i, _config.Offset.Y * i);
                var position = _config.StartPosition + offset;
                frame.ChangeAt(position, color);
            }
        }
Exemple #2
0
 public static void DrawScreenPoint(this FrameState frame, int x, int y, Color color)
 {
     frame.ChangeAt(new Point2D(x, y), color);
 }