Esempio n. 1
0
 public void Code(Goku goku, SenzuBeans senzuBean, Villain buu, Redbull redBull )
 {
     SenzuBeanzStuff(senzuBean); //senzuBeanStuff HAS to be above GokuStuff.
     GokuStuff(goku, senzuBean, redBull);
     BuuStuff(buu, goku);
     RedBullStuff(redBull, goku, buu);
 }
Esempio n. 2
0
 private void GokuStuff(Ch2Goku goku2, Goku goku, SenzuBeans senzuBean, Redbull redBull )
 {
     ScoreTimer+=2;
     if (ScoreTimer == 60)
     {
         goku.score++;
         ScoreTimer = 0;
     }
     goku2.Movement(ref redBull.XBoost);
     int OnScreen = senzuBean.SenzuBeanRect.Count;
     goku2.CaptureSenzuBean(ref senzuBean.SenzuBeanRect, out senzuBean.SenzuBeanRect, out senzuBean.RectsOnScreen);
     if (OnScreen != senzuBean.SenzuBeanRect.Count)
         goku.score += goku.level;
     bar.HealthANDExpBar(ref goku2.level, ref goku2.health, ref goku2.EXP);
     if (goku2.health <= 0)
     {
         Dead = true;
         if (goku2.level != 0)
             goku.score = goku.score * goku.level;
         string highScore = System.IO.File.ReadAllText(@"Content\Text.txt");
         goku.HighScore = int.Parse(highScore);
         if (goku.score > goku.HighScore)
         {
             System.IO.File.WriteAllText(@"Content\Text.txt", goku.score.ToString());
             goku.HighScore = goku.score;
         }
     }
 }
Esempio n. 3
0
 public void Code(Ch2Goku goku2, Ch2Goku MirrorGoku, SenzuBeans senzuBean,Goku goku,Redbull redBull, Ch2Villain Villain2, Extra extra)
 {
     SenzuBeanStuff(senzuBean);
     GokuStuff(goku2, goku, senzuBean, redBull);
     MirrorGokuStuff(MirrorGoku,goku2,senzuBean);
     score = goku.score * goku2.level;
     RedBullStuff(redBull,goku2, MirrorGoku,Villain2);
     VillainStuff(Villain2, goku2,MirrorGoku,extra);
 }
Esempio n. 4
0
 private void GokuStuff(Ch2Goku goku2, Goku goku, SenzuBeans senzuBean, Redbull redBull)
 {
     ScoreTimer += 2;
     if (ScoreTimer == 60)
     {
         goku.score++;
         ScoreTimer = 0;
     }
     goku2.Movement(ref redBull.XBoost);
     int OnScreen = senzuBean.SenzuBeanRect.Count;
     goku2.CaptureSenzuBean(ref senzuBean.SenzuBeanRect, out senzuBean.SenzuBeanRect, out senzuBean.RectsOnScreen);
     if (OnScreen != senzuBean.SenzuBeanRect.Count)
         goku.score += goku.level;
     bar.HealthANDExpBar(ref goku2.level, ref goku2.health, ref goku2.EXP);
 }
Esempio n. 5
0
        public void Code(Ch2Goku goku2, Ch2Goku MirrorGoku, SenzuBeans senzuBean, Goku goku, Redbull redBull, Ch2Villain Villain2, Extra extra, KeyboardState oldkeyboard)
        {
            SenzuBeanStuff(senzuBean);
            GokuStuff(goku2, goku,MirrorGoku, senzuBean, redBull);
            score = goku.score * goku2.level;
            RedBullStuff(redBull, goku2, MirrorGoku, Villain2);
            VillainStuff(Villain2, goku2, MirrorGoku, extra, goku);
            if (Keyboard.GetState().IsKeyDown(Keys.C) && oldkeyboard.IsKeyUp(Keys.C))
            {
                if (ToonChoice == 0)
                { ToonChoice = 1; }

                else if (ToonChoice == 1)
                    ToonChoice = 0;
            }
        }
Esempio n. 6
0
 public void Draw(SpriteBatch spriteBatch, font Font, Extra extra, Goku goku,SenzuBeans senzuBean, Villain buu, Redbull redBull)
 {
     spriteBatch.Draw(extra.GameplayBackgroundPic, BGRect, Color.White);
     spriteBatch.Draw(goku.Sprite, goku.Position, Color.White);
     foreach (Rectangle rect in senzuBean.SenzuBeanRect)
         spriteBatch.Draw(senzuBean.Pic, rect, Color.White);
     spriteBatch.Draw(extra.pixel, bar.HealthRect, Color.Red);
     spriteBatch.Draw(extra.pixel, bar.EXPRect, Color.WhiteSmoke);
     LevelUpDraw(spriteBatch, goku, Font);
     spriteBatch.DrawString(Font.SelectionFont, "Health: " + goku.health, new Vector2(5, -7), Color.Black);
     spriteBatch.DrawString(Font.SelectionFont, "Level: " + goku.level, new Vector2(5, 690), Color.Black);
     spriteBatch.DrawString(Font.SelectionFont, "You're Score: " + goku.score * goku.level, new Vector2(570, 0), Color.Black);
     spriteBatch.Draw(buu.Sprite, buu.Position, Color.White);
     foreach (Rectangle rect in redBull.redBullRect)
         spriteBatch.Draw(redBull.redBullPic, rect, Color.White);
     redBull.RedbullIconDraw(spriteBatch, Font);
 }
Esempio n. 7
0
 public void Draw(SpriteBatch spriteBatch, Extra extra, Ch2Goku goku2, Ch2Goku MirrorGoku, SenzuBeans senzuBean, font Font, Redbull redBull, Ch2Villain Villain2)
 {
     spriteBatch.Draw(extra.GameplayBackgroundPic, new Rectangle(0, 0, 545, 720), Color.White);
     spriteBatch.Draw(extra.Namek, new Rectangle(540, 0, 545, 720), Color.White);
     spriteBatch.Draw(goku2.Sprite, goku2.Position, Color.White);
     spriteBatch.Draw(MirrorGoku.Sprite, MirrorGoku.Position, Color.White);
     foreach (Rectangle rect in senzuBean.SenzuBeanRect)
         spriteBatch.Draw(senzuBean.Pic, rect, Color.White);
     spriteBatch.Draw(extra.pixel, bar.HealthRect, Color.Red);
     spriteBatch.Draw(extra.pixel, bar.EXPRect, Color.WhiteSmoke);
     spriteBatch.DrawString(Font.SelectionFont, "Health: " + goku2.health, new Vector2(5, -7), Color.Black);
     spriteBatch.DrawString(Font.SelectionFont, "Level: " + goku2.level, new Vector2(5, 690), Color.Black);
     spriteBatch.DrawString(Font.SelectionFont, "You're Score: " + score, new Vector2(570, 0), Color.Green);
        foreach (Rectangle rect in redBull.redBullRect)
         spriteBatch.Draw(redBull.redBullPic, rect, Color.White);
        redBull.RedbullIconDraw(spriteBatch, Font);
        spriteBatch.Draw(Villain2.Sprite, Villain2.Position, Color.White);
 }
Esempio n. 8
0
        public void Initialize(Goku goku, Death death, SenzuBeans senzuBean, Villain buu)
        {
            goku.health = 100;
            goku.EXP = 0;
            for (int i = 0; i < senzuBean.SenzuBeanRect.Count; i++)
            {
                senzuBean.SenzuBeanRect.RemoveAt(i);
            }

            senzuBean.RectsOnScreen = false;
            buu.X = 0;
            buu.Y = 30;
            goku.Lvled = false;
            goku.X = 500;
            goku.Y = 350;
            goku.level = 0;
            goku.score = 0;
            death.ReStart = false;
            Dead = false;
        }
Esempio n. 9
0
        public void Initialize(Ch2Goku goku2, SenzuBeans senzuBean, Ch2Villain Villain2, Death death)
        {
            goku2.health = 100;
               goku2.EXP = 0;
               for (int i = 0; i < senzuBean.SenzuBeanRect.Count; i++)
               {
               senzuBean.SenzuBeanRect.RemoveAt(i);
               }

               senzuBean.RectsOnScreen = false;
               Villain2.X = 0;
               Villain2.Y = 30;
               goku2.Lvled = false;
               goku2.X = 500;
               goku2.Y = 350;
               goku2.level = 0;

               death.ReStart = false;
               Dead = false;
        }
Esempio n. 10
0
        public void Initialize(Ch2Goku goku2,Ch2Goku goku3, SenzuBeans senzuBean, Ch2Villain Villain2, Death death)
        {
            goku2.health = 100;
            goku2.EXP = 0;
            for (int i = 0; i < senzuBean.SenzuBeanRect.Count; i++)
            {
                senzuBean.SenzuBeanRect.RemoveAt(i);
            }

            senzuBean.RectsOnScreen = false;
            Villain2.X = 0;
            Villain2.Y = 30;
            goku2.Lvled = false;
            goku2.X = 600;
            goku2.Y = 350;
            goku3.X = 10;
            goku3.Y = 200;
            goku2.level = 0;

            death.ReStart = false;
            Dead = false;
            goku2.Position = new Rectangle(600, 350, 50, 75);
            goku3.Position = new Rectangle(10, 200, 50, 75);
        }
Esempio n. 11
0
 private void SenzuBeanStuff(SenzuBeans senzuBean)
 {
     senzuBean.AddSenzuBeans();
 }
Esempio n. 12
0
 private void MirrorGokuStuff(Ch2Goku MirrorGoku, Ch2Goku goku2, SenzuBeans senzuBean)
 {
     MirrorGoku.MirrorMovement(goku2);
     MirrorGoku.CaptureSenzuBeans2(ref senzuBean.SenzuBeanRect, out senzuBean.SenzuBeanRect, out senzuBean.RectsOnScreen, goku2);
 }
Esempio n. 13
0
 private void GokuStuff(Ch2Goku goku2, Goku goku, Ch2Goku goku3, SenzuBeans senzuBean, Redbull redBull)
 {
     ScoreTimer +=2;
     if (ScoreTimer == 60)
     {
         goku.score+=4;
         ScoreTimer = 0;
     }
     if (ToonChoice == 0)
     {
         goku2.Movement(ref redBull.XBoost);
     }
     if (ToonChoice == 1)
     {
         goku3.Ch4Movement(ref redBull.XBoost, ref goku2.level);
     }
     int OnScreen = senzuBean.SenzuBeanRect.Count;
     goku2.CaptureSenzuBean(ref senzuBean.SenzuBeanRect, out senzuBean.SenzuBeanRect, out senzuBean.RectsOnScreen);
     if (OnScreen != senzuBean.SenzuBeanRect.Count)
     {
         goku.score += goku.level;
         SenzuBeanCollectionCountdown = 360;
     }
     SenzuBeanCollectionCountdown--;
     if (SenzuBeanCollectionCountdown == 0)
     {
         SenzuBeanCollectionCountdown = 360;
         goku2.health -= 100;
     }
     bar.HealthANDExpBar(ref goku2.level, ref goku2.health, ref goku2.EXP);
     int Onscreen = senzuBean.SenzuBeanRect.Count;
     goku3.CaptureSenzuBeans2(ref senzuBean.SenzuBeanRect, out senzuBean.SenzuBeanRect, out senzuBean.RectsOnScreen, goku2);
     if (Onscreen != senzuBean.SenzuBeanRect.Count)
     {
         goku.score += goku.level;
         SenzuBeanCollectionCountdown = 360;
     }
 }