Ejemplo n.º 1
0
        public void DrawShaded(SpriteBatch sb, GameTime gt, List <EnemyChar> enemies, List <BaseProjectile> projectiles, ContentManager content, EnemySpawnManager enemySpawnManager)
        {
            sb.Begin();
            m_menuBackground.DrawMe(sb);
            m_selectionBorder.DrawMe(sb);
            sb.DrawString(Game1.gameFontNorm, "Page: " + (m_page + 1) + "\nCount: " + m_towerOptions.Count, new Vector2(72, 972), Color.White, 0, Game1.gameFontNorm.MeasureString("Page: " + (m_page + 1) + "\nCount: " + m_towerOptions.Count) / 2, 1, SpriteEffects.None, 0);
            sb.End();

            m_menu.DrawMe(sb, gt);

            sb.Begin();
            sb.Draw(m_spawnBarTex, m_spawnBarPos, m_spawnBarSrc, Color.White);
            sb.DrawString(Game1.gameFontNorm, "Wave: " + enemySpawnManager.CurrentWave, new Vector2(1380, 875), Color.Black);
            sb.End();

            for (int i = 0; i < m_towerOptions.Count; i++)
            {
                if (i >= m_minIndex && i < m_maxIndex)
                {
                    m_towerOptions[i].DrawMe(sb, gt);
                    m_towerOptions[i].IsClickable = true;
#if DEBUG
                    sb.Begin();
                    sb.DrawString(Game1.debugFont, "Button: " + m_towerOptions[i].Tower.PartProps.Count, m_towerOptions[i].Position, Color.White);
                    sb.End();
#endif
                }
                else
                {
                    m_towerOptions[i].IsClickable = false;
                }
            }
        }
Ejemplo n.º 2
0
        public void DrawMenu(SpriteBatch sb, GameTime gt, MusicManager musicManager)
        {
            sb.Begin();
            m_backing.DrawMe(sb);
            sb.DrawString(Game1.gameFontNorm, "Volume", new Vector2(960, 400), Color.White, 0, Game1.gameFontNorm.MeasureString("Volume") / 2, 1, SpriteEffects.None, 0);
            sb.DrawString(Game1.gameFontNorm, "" + (int)(musicManager.VolumeMult * 100), new Vector2(960, 420), Color.White, 0, Game1.gameFontNorm.MeasureString("" + (int)(musicManager.VolumeMult * 100)) / 2, 1, SpriteEffects.None, 0);
            sb.End();

            m_menu.DrawMe(sb, gt);
            m_volumeMenu.DrawMe(sb, gt);
        }