Example #1
0
        private void DrawLevelState(GameTime gameTime)
        {
            mainGame.GraphicsDevice.Clear(Color.White);

            spriteBatch.Begin();
            board.Draw(spriteBatch);

            stairs.Draw(spriteBatch);

            darwin.Draw(spriteBatch);
            firstZombie.Draw(spriteBatch);
            secondZombie.Draw(spriteBatch);
            thirdZombie.Draw(spriteBatch);
            fourthZombie.Draw(spriteBatch);
            cannibalZombie.Draw(spriteBatch);

            potion.Draw(spriteBatch);
            zTime.Draw(spriteBatch);

            if (!isAllZombiesDead())
            {
                foreach (BasicObject bo in removableWalls)
                {
                    // Draw the walls visible
                    Rectangle source = new Rectangle(0, 0, board.getSquareLength(), board.getSquareLength());
                    spriteBatch.Draw(removableWallTex, board.getPosition(bo), source, Color.White);
                }
            }


            foreach (BasicObject a in walls)
            {
                spriteBatch.Draw(wallTex, board.getPosition(a.X, a.Y), Color.White);
            }

            if (messageMode)
            {
                zombieMessage.Draw(spriteBatch, messageFont);
                darwinMessage.Draw(spriteBatch, messageFont);
                cannibalMessage.Draw(spriteBatch, messageFont);
            }

            spriteBatch.DrawString(messageFont, "HUMANITY: ",
                                   new Vector2(board.getPosition(zTime.X, zTime.Y).X + board.getSquareWidth() * 3 / 2, board.getPosition(zTime.X, 24).Y),
                                   Color.Black);

            spriteBatch.DrawString(messageFont, "DEATH COUNT: " + mainGame.DEATH_COUNTER.ToString(),
                                   new Vector2(board.getPosition(23, 24).X, board.getPosition(23, 24).Y),
                                   Color.Black);

            spriteBatch.End();
        }
Example #2
0
        private void DrawLevelState(GameTime gameTime)
        {
            mainGame.GraphicsDevice.Clear(Color.White);

            spriteBatch.Begin();
            board.Draw(spriteBatch);

            secondStair.Draw(spriteBatch);

            foreach (Leaf leaf in this.leaves)
            {
                leaf.Draw(spriteBatch);
            }

            darwin.Draw(spriteBatch);
            firstZombie.Draw(spriteBatch);

            fastZombie1.Draw(spriteBatch);


            //secondZombie.Draw(spriteBatch);
            //thirdZombie.Draw(spriteBatch);
            firstSwitch.Draw(spriteBatch);
            secondSwitch.Draw(spriteBatch);
            brain.Draw(spriteBatch);
            zTime.Draw(spriteBatch);

            if (messageMode)
            {
                //zombieMessage.Draw(spriteBatch, messageFont);
                darwinMessage.Draw(spriteBatch, messageFont);
                //brainMessage.Draw(spriteBatch, messageFont);
                fastMessage.Draw(spriteBatch, messageFont);
                //switchMessage.Draw(spriteBatch, messageFont);
            }

            spriteBatch.DrawString(messageFont, "HUMANITY: ",
                                   new Vector2(board.getPosition(zTime.X, zTime.Y).X + board.getSquareWidth() * 3 / 2, board.getPosition(zTime.X, 24).Y),
                                   Color.Black);

            spriteBatch.DrawString(messageFont, "DEATH COUNT: " + mainGame.DEATH_COUNTER.ToString(),
                                   new Vector2(board.getPosition(23, 24).X, board.getPosition(23, 24).Y),
                                   Color.Black);

            spriteBatch.End();
        }
Example #3
0
        private void DrawLevelState(GameTime gameTime)
        {
            mainGame.GraphicsDevice.Clear(Color.White);

            spriteBatch.Begin();
            board.Draw(spriteBatch);
            stairs.Draw(spriteBatch);

            vortex.Draw(spriteBatch);
            darwin.Draw(spriteBatch);
            firstZombie.Draw(spriteBatch);
            secondZombie.Draw(spriteBatch);
            thirdZombie.Draw(spriteBatch);
            fourthZombie.Draw(spriteBatch);
            fifthZombie.Draw(spriteBatch);
            sixthZombie.Draw(spriteBatch);
            firstSwitch.Draw(spriteBatch);
            brain.Draw(spriteBatch);
            zTime.Draw(spriteBatch);
            potion.Draw(spriteBatch);

            if (messageMode)
            {
                zombieMessage.Draw(spriteBatch, messageFont);
                darwinMessage.Draw(spriteBatch, messageFont);
                brainMessage.Draw(spriteBatch, messageFont);
                //switchMessage.Draw(spriteBatch, messageFont);
            }

            foreach (BasicObject a in walls)
            {
                spriteBatch.Draw(wallTex, board.getPosition(a.X, a.Y), Color.White);
            }

            spriteBatch.DrawString(messageFont, "HUMANITY: ",
                                   new Vector2(board.getPosition(zTime.X, zTime.Y).X + board.getSquareWidth() * 3 / 2, board.getPosition(zTime.X, 24).Y),
                                   Color.Black);

            spriteBatch.DrawString(messageFont, "DEATH COUNT: " + mainGame.DEATH_COUNTER.ToString(),
                                   new Vector2(board.getPosition(23, 24).X, board.getPosition(23, 24).Y),
                                   Color.Black);

            spriteBatch.End();
        }