public override void draw(GameTime gameTime) { mSpriteBatch.Begin(); mBackground.draw(mSpriteBatch); mCurrentBackground.draw(mSpriteBatch); mGroupButtons.draw(mSpriteBatch); if (currentScreen == mList.Count() - 1) { mSpriteBatch.Draw(mNext, new Rectangle(586, 474, 80, 86), Color.White); } if (currentScreen == 0) { mSpriteBatch.Draw(mPrevious, new Rectangle(350, 474, 80, 86), Color.White); } mCursor.draw(mSpriteBatch); if (mFade != null) { mFade.draw(mSpriteBatch); } mSpriteBatch.End(); }
public override void draw(GameTime gameTime) { if (mVideoPlayer != null) { if (mVideoPlayer.State != MediaState.Stopped) { mVideoTexture = mVideoPlayer.GetTexture(); } } if (mVideoTexture != null) { mSpriteBatch.Begin(); mSpriteBatch.Draw(mVideoTexture, new Rectangle(0, 0, 800, 600), Color.White); mSpriteBatch.End(); } if (mShowTextClickToStart && !mClicked) { mSpriteBatch.Begin(); mSpriteBatch.Draw(mTextureClickToStart, new Vector2(280, 520), Color.White); mSpriteBatch.End(); } mSpriteBatch.Begin(); mCursor.draw(mSpriteBatch); if (mFade != null) { mFade.draw(mSpriteBatch); } mSpriteBatch.End(); /*mSpriteBatch.Begin( * SpriteSortMode.Immediate, * BlendState.AlphaBlend, * null, * null, * null, * null, * mCamera.get_transformation(Game1.getInstance().GraphicsDevice)); * * * if (mCurrentTexture != null) * { * mSpriteBatch.Draw(mCurrentTexture, mRectangleExhibitionTexture, Color.White); * } * //mButtonNext.draw(mSpriteBatch); * mCursor.draw(mSpriteBatch); * * if (mFade != null) * { * mFade.draw(mSpriteBatch); * } * * * mSpriteBatch.End(); */ }
public override void draw(GameTime gameTime) { mSpriteBatch.Begin(); mCurrentBackground.draw(mSpriteBatch); mFadeIn.draw(mSpriteBatch); mSpriteBatch.End(); }
public override void draw(GameTime gameTime) { mSpriteBatch.Begin(); if (mBackgroundBefore != null) { mBackgroundBefore.draw(mSpriteBatch); } if (mBackgroundImage != null && mBackgroundBefore == null) { mBackgroundImage.draw(mSpriteBatch); } if (mMacromapShip != null) { mMacromapShip.draw(mSpriteBatch); } mMacromapPlayer.draw(mSpriteBatch); mSpriteBatch.Draw(mTextureBorder, new Rectangle(0, 0, 800, 600), Color.White); mSpriteBatch.Draw(mTextureBussola, new Rectangle(800 - 168, 422, 158, 165), Color.White); mSpriteBatch.Draw(mTextureBussolaPointer, new Vector2(710, 516), null, Color.White, angleBussola - (float)Math.PI / 2, new Vector2(mTextureBussolaPointer.Width / 2, mTextureBussolaPointer.Height / 2), 1, SpriteEffects.None, 0f); mSpriteBatch.Draw(mTexturePinoBussola, new Rectangle(632, 425, 158, 165), Color.White); if (mExplosionManager != null) { mExplosionManager.draw(mSpriteBatch); } if (mStartFeatures && mShowTextureFallingPlayer) { mSpriteBatch.Draw(mTexturePlayerFalling, new Vector2(176, 235), new Rectangle(0, 0, mTexturePlayerFalling.Width, mTexturePlayerFalling.Height), Color.White, 0f, new Vector2(30, 30), reduceScale(), SpriteEffects.None, 0); } if (mShowTextClickToStart && !mClicked) { mSpriteBatch.Draw(mTextureClickToStart, new Vector2(245, 484), Color.White); } mCursor.draw(mSpriteBatch); if (mFade != null) { mFade.draw(mSpriteBatch); } mSpriteBatch.End(); }
public override void draw(GameTime gameTime) { mSpriteBatch.Begin(); mCurrentBackground.draw(mSpriteBatch); mButtonBack.draw(mSpriteBatch); mCursor.draw(mSpriteBatch); if (mFade != null) { mFade.draw(mSpriteBatch); } mSpriteBatch.End(); }
public override void draw(GameTime gameTime) { mSpriteBatch.Begin(); if (mShowBlackBackground) { // mSpriteBatch.Draw(mBlackBackground, new Rectangle(0, 0, 800, 600), Color.Black); } else { mCurrentBackground.draw(mSpriteBatch); } if (mFade != null) { mFade.draw(mSpriteBatch); } if (mIncreaseAlpha) { if (mAlpha < 1) { mAlpha += 0.05f; } else { mAlpha = 1; } } //se estiver saindo do splash pro main menu... if (mClicked) { mAlpha -= 0.25f; } mSpriteBatch.Draw(mGamelogo, new Rectangle(200, 50, 382, 349), Color.White * mAlpha); if (mShowTextClickToStart && !mClicked) { mSpriteBatch.Draw(mTextureClickToStart, new Vector2(240, 392), Color.White); } mCursor.draw(mSpriteBatch); mSpriteBatch.End(); }
public override void draw(GameTime gameTime) { mSpriteBatch.Begin(); mCurrentBackground.draw(mSpriteBatch); if (cSCREEN == MainMenuScreen.SCREENS.MAINMENU_SCREEN) { if (mShowContinueScreen) { mButtonContinue.setVisible(true); mButtonContinue.enableCollision(true); mButtonNewGame.setVisible(true); mButtonNewGame.enableCollision(true); mButtonPlay.setVisible(false); mButtonPlay.enableCollision(false); mButtonHelp.setVisible(false); mButtonHelp.enableCollision(false); mButtonCredits.setVisible(false); mButtonCredits.enableCollision(false); mButtonExit.setVisible(false); mButtonExit.enableCollision(false); } else { mButtonContinue.setVisible(false); mButtonContinue.enableCollision(false); mButtonNewGame.setVisible(false); mButtonNewGame.enableCollision(false); mButtonPlay.setVisible(true); mButtonPlay.enableCollision(true); mButtonHelp.setVisible(true); mButtonHelp.enableCollision(true); mButtonCredits.setVisible(true); mButtonCredits.enableCollision(true); mButtonExit.setVisible(true); mButtonExit.enableCollision(true); } mGroupButtons.draw(mSpriteBatch); mSoundIcon.draw(mSpriteBatch); mCursor.draw(mSpriteBatch); if (mFade != null) { mFade.draw(mSpriteBatch); } } mSpriteBatch.End(); if (cSCREEN != MainMenuScreen.SCREENS.MAINMENU_SCREEN) { currentScreen.draw(gameTime); } }
public override void draw(GameTime gameTime) { try { if (mVideoPlayer.State != MediaState.Stopped && !crash) { mVideoTexture = mVideoPlayer.GetTexture(); } } catch (Exception) { crash = true; Skip(); } if (mVideoTexture != null) { mSpriteBatch.Begin(); mSpriteBatch.Draw(mVideoTexture, new Rectangle(0, 0, 800, 600), Color.White); mSpriteBatch.End(); } if (mShowTextClickToStart && !mClicked) { mSpriteBatch.Begin(); // mSpriteBatch.Draw(mTextureClickToStart, new Vector2(280, 520), Color.White); mSpriteBatch.End(); } mSpriteBatch.Begin(); mCursor.draw(mSpriteBatch); if (mFade != null) { mFade.draw(mSpriteBatch); } mButtonSkip.draw(mSpriteBatch); mSpriteBatch.End(); }
public override void draw(GameTime gameTime) { mSpriteBatch.Begin(); //mCurrentBackground.draw(mSpriteBatch); mBackgroundImage.draw(mSpriteBatch); mSpriteBatch.Draw(mTextureChooseTitle, new Rectangle(188, 50, mTextureChooseTitle.Width, mTextureChooseTitle.Height), Color.White); /*if (mCurrentSelectableCharacter == mSelectableCharacterRed) * { * mSpriteBatch.Draw(mTextureRedNameSelected, new Rectangle(120, 430, mTextureRedNameSelected.Width, mTextureRedNameSelected.Height), Color.White * mAlpha); * mSpriteBatch.Draw(mTextureGreenNameUnselected, new Rectangle(354, 435, mTextureGreenNameUnselected.Width, mTextureGreenNameUnselected.Height), Color.White * mAlpha); * mSpriteBatch.Draw(mTextureBlueNameUnselected, new Rectangle(580, 430, mTextureBlueNameUnselected.Width, mTextureBlueNameUnselected.Height), Color.White * mAlpha); * } * else * if (mCurrentSelectableCharacter == mSelectableCharacterGreen) * { * mSpriteBatch.Draw(mTextureGreenNameSelected, new Rectangle(354, 435, mTextureGreenNameSelected.Width, mTextureGreenNameSelected.Height), Color.White * mAlpha); * mSpriteBatch.Draw(mTextureRedNameUnselected, new Rectangle(120, 430, mTextureRedNameUnselected.Width, mTextureRedNameUnselected.Height), Color.White * mAlpha); * mSpriteBatch.Draw(mTextureBlueNameUnselected, new Rectangle(580, 430, mTextureBlueNameUnselected.Width, mTextureBlueNameUnselected.Height), Color.White * mAlpha); * } * else * if (mCurrentSelectableCharacter == mSelectableCharacterBlue) * { * mSpriteBatch.Draw(mTextureBlueNameSelected, new Rectangle(580, 430, mTextureBlueNameSelected.Width, mTextureBlueNameSelected.Height), Color.White * mAlpha); * mSpriteBatch.Draw(mTextureGreenNameUnselected, new Rectangle(354, 435, mTextureGreenNameUnselected.Width, mTextureGreenNameUnselected.Height), Color.White * mAlpha); * mSpriteBatch.Draw(mTextureRedNameUnselected, new Rectangle(120, 430, mTextureRedNameUnselected.Width, mTextureRedNameUnselected.Height), Color.White * mAlpha); * } * else //ninguem selecionado * { * mSpriteBatch.Draw(mTextureBlueNameUnselected, new Rectangle(580, 430, mTextureBlueNameUnselected.Width, mTextureBlueNameUnselected.Height), Color.White); * mSpriteBatch.Draw(mTextureGreenNameUnselected, new Rectangle(354, 435, mTextureGreenNameUnselected.Width, mTextureGreenNameUnselected.Height), Color.White); * mSpriteBatch.Draw(mTextureRedNameUnselected, new Rectangle(120, 430, mTextureRedNameUnselected.Width, mTextureRedNameUnselected.Height), Color.White); * } */ if (mReduceAlpha) { if (mAlpha > 0) { mAlpha -= 0.05f; } else { mAlpha = 0; } //só pra garantir o anti-pau if (mCurrentSelectableCharacter != null) { if (mCurrentSelectableCharacter == mSelectableCharacterRed) { mSelectableCharacterRed.draw(mSpriteBatch); mSelectableCharacterGreen.draw(mSpriteBatch, Color.White * mAlpha);//new Color(255 * mAlpha, 255 * mAlpha, 255 * mAlpha, mAlpha) * mAlpha); mSelectableCharacterBlue.draw(mSpriteBatch, Color.White * mAlpha); } if (mCurrentSelectableCharacter == mSelectableCharacterGreen) { mSelectableCharacterRed.draw(mSpriteBatch, Color.White * mAlpha); mSelectableCharacterGreen.draw(mSpriteBatch); mSelectableCharacterBlue.draw(mSpriteBatch, Color.White * mAlpha); } if (mCurrentSelectableCharacter == mSelectableCharacterBlue) { mSelectableCharacterRed.draw(mSpriteBatch, Color.White * mAlpha); mSelectableCharacterGreen.draw(mSpriteBatch, Color.White * mAlpha); mSelectableCharacterBlue.draw(mSpriteBatch); } } } else { mSelectableCharacterRed.draw(mSpriteBatch); mSelectableCharacterGreen.draw(mSpriteBatch); mSelectableCharacterBlue.draw(mSpriteBatch); } mCursor.draw(mSpriteBatch); /*if (mFade != null) * { * mFade.draw(mSpriteBatch); * }*/ if (mFade != null) { mFade.draw(mSpriteBatch); } mSpriteBatch.End(); }