コード例 #1
0
        /// <summary>
        /// исцртување на главната панела (позадина, карактер, по потреба куршуми, непријатели, скорови ... итн)
        /// </summary>
        /// <param name="sender"></param>
        /// <param name="e"></param>
        private void MainForm_Paint(object sender, PaintEventArgs e)
        {
            e.Graphics.DrawImage(BckgrBitmap, Bckgr.startingX, 0, BckgrBitmap.Width, BckgrBitmap.Height);
            e.Graphics.DrawImage(Character.CurrentCharacterImage, Character.X, Character.Y);
            if (VisibleBullet)
            {
                BulletInjection.DrawInjection(e.Graphics);
            }
            MyEnemies.DrawEvilMinions(e.Graphics);
            Coins.Draw(e.Graphics);
            Bananas.Draw(e.Graphics);
            e.Graphics.DrawString("COINS: " + CollectedCoins.ToString(), font, brush, point);
            //e.Graphics.DrawString("FOOD: " + CollectedBananas.ToString(), font, brush, point2);
            this.DrawLifeAndKilledEM(e.Graphics);

            if (!VectorVillian.IsKilled && gamemode == GameMode.Hard)
            {
                VectorVillian.DrawVector(e.Graphics);
            }
        }
コード例 #2
0
ファイル: Mario2D.cs プロジェクト: lindenbergresearch/ReNoir
 /// <summary>
 ///     Resets all player properties to initial values
 /// </summary>
 public override void Reset()
 {
     debug("Reset player...");
     LivesLeft.Update(3);
     CollectedCoins.Update(0);
 }