Exemplo n.º 1
0
        public override void Update(Draw d)
        {
            if (curimgfn == Files.brick_invisible && World.PlayMode == PlayMode.Editor)
                d.DrawRectangle(dPen.Black, Left, Top, Width, Height);

            d.DrawImage(curimg, Left, Top, Width, Height);
        }
Exemplo n.º 2
0
        public override void Update(Draw d)
        {
            int width = image.Width;
            for (int i = 0; i < blocks; i++)
                d.DrawImage(image, Left + i * (imgWidth + 1), Top, width, Height);

            if (color == BrickColor.Invisible && World.PlayMode == PlayMode.Editor)
                d.DrawRectangle(dPen.Black, Left, Top, Width, Height);
        }
Exemplo n.º 3
0
        public void Update(Draw d)
        {
            if (Settings.BackgroundImg != null)
                d.DrawImage(Settings.BackgroundImg, 0, 0, Settings.GameWindowWidth, Settings.LevelHeight);

            d.MoveCoords(viewport.X, viewport.Y);
            foreach (GameObject go in AllElements)
            {
                go.Update(d);
            }
            d.MoveCoords(-viewport.X, -viewport.Y);
        }
Exemplo n.º 4
0
 public override void Update(Draw d)
 {
     d.DrawImage(curimg, Left, Top, Width, Height);
 }
Exemplo n.º 5
0
        public override void Update(Draw d)
        {
            d.DrawImage(imgU, Left, Top, Width, imgU.Height);

            for (int i = 0; i < blocks; i++)
            {
                d.DrawImage(imgM, Left, Top + imgU.Height + i * imgM.Height, Width, imgM.Height);
            }
        }
Exemplo n.º 6
0
 public void Update(Draw d, GameDirection direction, float left, float top, int width, int height)
 {
     d.DrawImage(images[(int)direction, cur], left, top, width, height);
     if ((DateTime.Now - last).TotalMilliseconds >= milliSecPerFrame && Refresh)
     {
         cur++;
         last = DateTime.Now;
     }
     if (cur >= images.GetLength(1))
         cur = 0;
 }
Exemplo n.º 7
0
 public override void Update(Draw d)
 {
     for (int i = 0; i < blocks + 2; i++)
     {
         dImage paint = i == 0 ? imgL : (i + 1 == blocks + 2 ? imgR : imgM);
         d.DrawImage(paint, Left + i * (paint.Width - 1), Top, paint.Width, Height);
     }
 }