Ejemplo n.º 1
0
        private void Form1_Paint(object sender, PaintEventArgs e)
        {
            kiro.Draw(e.Graphics);
            kiro.DrawBullets(e.Graphics);
            foreach (Zombie z in zombies)
            {
                z.Draw(e.Graphics);
            }

            foreach (AmmoGift gift in gifts)
            {
                gift.Draw(e.Graphics);
            }
            if (Shoots == true)
            {
                kiro.Shoot();
                Shoots = false;
            }

            if (hasBoss)
            {
                boss.Draw(e.Graphics);
                hasBoss = true;
            }
        }
Ejemplo n.º 2
0
 private void Form1_Paint(object sender, PaintEventArgs e)
 {
     try
     {
         hero.Draw(e.Graphics);
         if (level1doc != null)
         {
             level1doc.Paint(e.Graphics);
         }
         else if (level2doc != null)
         {
             level2doc.Paint(e.Graphics);
         }
     }
     catch (Exception ex)
     {
     }
 }