Beispiel #1
0
/// <summary>
/// Currently draws the topmost screen, needs to be improved to support things such as pop ups
/// It'll be a simple fix to check to see which screens are requesting to be drawn
/// and draw them in the order of the stack.
/// </summary>
/// <param name="spriteBatch"></param>
        public void Draw(SpriteBatch spriteBatch)
        {
            BaseScreen DrawScreen = screenStack.Peek();

            DrawScreen.Draw(spriteBatch);
        }
Beispiel #2
0
        /// <summary>
        /// This is probably the worst way of going about it but this method checks the top screen and updates it
        /// Although this will not be relevant soon since screen updates will be decided through ENUMS.
        /// </summary>
        /// <param name="gameTime"></param>

        public void UpdateTopScreen(GameTime gameTime)
        {
            BaseScreen updateScreen = screenStack.Peek();

            updateScreen.Update(gameTime);
        }