Exemplo n.º 1
0
        public static void Render(SceneGame gs, Graphics g)
        {
            //기본 판 그리기
            //homeButton.Draw(g);
            //soundToggleButton.Draw(g);
            //optionButton.Draw(g);

            if (getMenubarMode() == "towerBuild")
            {
                //구입 판 그리기
                menubarBuild.Draw(g);

                deselect.Draw(g);
            }
            else if (getMenubarMode() == "towerSelecting")
            {
                menubarBuild.Draw(g);

                drawMenubarBuildButtons(g);
            }
            else if (getMenubarMode() == "towerUpgrade")
            {
                //업그레이드 판 그리기
                menubarUpgrade.Draw(g);

                drawMenubarUpgradeButtons(g);
            }

            //라이프와 소지금
            int moneyStrHeight  = (int)(GDIController.GetStringHeight(g, new Font(new FontFamily("Segoe UI"), 15), Player.getMoney().ToString()));
            int lifeStrHeight   = (int)(GDIController.GetStringHeight(g, new Font(new FontFamily("Segoe UI"), 15), gs.currentStage.getLife().ToString()));
            int towersStrHeight = (int)(GDIController.GetStringHeight(g, new Font(new FontFamily("Segoe UI"), 15), gs.currentStage.towersNo.ToString() + " / " + BaseStage.maxTowers.ToString()));

            g.DrawString(Player.getMoney().ToString(), new Font(new FontFamily("Segoe UI"), 15), new SolidBrush(Color.Black), 480 + 64, 25 + (30 - moneyStrHeight) / 2);
            g.DrawString(gs.currentStage.getLife().ToString(), new Font(new FontFamily("Segoe UI"), 15), new SolidBrush(Color.Black), 480 + 64, 65 + (30 - lifeStrHeight) / 2);
            g.DrawString(gs.currentStage.towersNo.ToString() + " / " + BaseStage.maxTowers.ToString(), new Font(new FontFamily("Segoe UI"), 15), new SolidBrush(Color.Black), 480 + 64, 444 + (30 - towersStrHeight) / 2);

            if (!gameStarted || GameController.isPaused)
            {
                goButton.Draw(g);
            }
            else
            {
                stopButton.Draw(g);
            }
        }
Exemplo n.º 2
0
 public override bool Draw()
 {
     if (MainMenu.IsVisible && IsVisible)
     {
         try
         {
             ImageSprite.Draw(new Vector2(Nasus.Menu["Language.Select"].Position.X + 412, Nasus.Menu["Language.Select"].Position.Y + 255));
         }
         catch
         {
         }
         return(true);
     }
     return(false);
 }
Exemplo n.º 3
0
 public override bool Draw()
 {
     if (MainMenu.IsVisible && IsVisible)
     {
         try
         {
             ImageSprite.Draw(new Vector2(Kalista.Menu["Language.Select"].Position.X + 365, Kalista.Menu["Language.Select"].Position.Y + 180));
         }
         catch
         {
         }
         return(true);
     }
     return(false);
 }
Exemplo n.º 4
0
 public override bool Draw()
 {
     if (MainMenu.IsVisible && IsVisible)
     {
         try
         {
             ImageSprite.Draw(new Vector2(TwistedFate.Menu["Language.Select"].Position.X - 14, TwistedFate.Menu["Language.Select"].Position.Y + 185));
         }
         catch
         {
         }
         return(true);
     }
     return(false);
 }
Exemplo n.º 5
0
        public override bool Draw()
        {
            if (MainMenu.IsVisible && IsVisible)
            {
                try
                {
                    if (WardAtlas.WardSprite == null)
                    {
                        throw new NullReferenceException("WardAtlas is null");
                    }

                    var Preview = WardAtlas[Ward_Name[Skin.Menu["Ward.Skin"].Cast <Slider>().CurrentValue]];

                    ImageSprite.Draw(new Vector2(MainMenu.Position.X + 615, Skin.Menu["Ward.Skin"].Position.Y - 50), Preview.Rectangle);
                }
                catch
                {
                }
                return(true);
            }
            return(false);
        }