Пример #1
0
    public ReviewDialog()
        : base(DialogMode.YES_OR_NO)
    {
        Material dialogUIMaterial = UIResourceMgr.GetInstance().GetMaterial("Dialog");
        Material buttonsMaterial  = UIResourceMgr.GetInstance().GetMaterial("Buttons");

        SetBackgroundTexture(dialogUIMaterial, DialogTexturePosition.Dialog, AutoRect.AutoPos(new Rect((960 - 574) / 2f, (640 - 306) / 2f, 574f, 306f)));
        SetTextAreaOffset(AutoRect.AutoValuePos(new Rect(80, 70, -100, -90)));

        SetText(ConstData.FONT_NAME2, "\n                REVIEW US \nLIKE THIS GAME? WANT MORE UPDATES? PLEASE REVIEW US.", ColorName.fontColor_darkorange);
        SetButtonTexture(buttonsMaterial, ButtonsTexturePosition.ButtonNormal, ButtonsTexturePosition.ButtonPressed, AutoRect.AutoSize(ButtonsTexturePosition.TinySizeButton));

        SetYesButtonOffset(AutoRect.AutoValuePos(new Vector2(70, 0)), AutoRect.AutoSize(ButtonsTexturePosition.TinySizeButton));
        SetNoButtonOffset(AutoRect.AutoValuePos(new Vector2(300, 0)), AutoRect.AutoSize(ButtonsTexturePosition.TinySizeButton));
        SetYesButtonText(ConstData.FONT_NAME2, "YES", ColorName.fontColor_orange);
        SetNoButtonText(ConstData.FONT_NAME2, "NO,THANKS", ColorName.fontColor_orange);
    }
Пример #2
0
    public IAPDialog(DialogMode mode)
        : base(mode)
    {
        SetTextAreaOffset(AutoRect.AutoValuePos(new Rect(80, 80, -20, -106)));
        SetText(ConstData.FONT_NAME1, "", ColorName.fontColor_darkorange);
        Material material = UIResourceMgr.GetInstance().GetMaterial("ArenaMenu");

        this.SetText(NOT_ENOUGH_CASH);
        SetButtonTexture(material, ArenaMenuTexturePosition.GetMoneyButtonNormal, ArenaMenuTexturePosition.GetMoneyButtonPressed, AutoRect.AutoSize(ArenaMenuTexturePosition.GetMoneyButtonPressed));

        SetYesButtonOffset(AutoRect.AutoValuePos(new Vector2(26, -42)), AutoRect.AutoSize(ArenaMenuTexturePosition.GetMoneyButtonPressed));
        this.DisableNoButton();
        this.SetYesButtonText("");
        this.SetNoButtonText("");

        this.SetCloseButtonTexture(material, ArenaMenuTexturePosition.CloseButtonNormal, ArenaMenuTexturePosition.CloseButtonPressed);
        this.SetCloseButtonOffset(AutoRect.AutoValuePos(new Vector2(-16, 224)), AutoRect.AutoSize(ArenaMenuTexturePosition.CloseButtonNormal));
    }
Пример #3
0
    public GameDialog(DialogMode mode)
        : base(mode)
    {
        Material dialogUIMaterial = UIResourceMgr.GetInstance().GetMaterial("Dialog");
        Material buttonsMaterial  = UIResourceMgr.GetInstance().GetMaterial("Buttons");

        SetBackgroundTexture(dialogUIMaterial, DialogTexturePosition.Dialog, AutoRect.AutoPos(new Rect((960 - 574) / 2f, (640 - 306) / 2f, 574f, 306f)));
        SetTextAreaOffset(AutoRect.AutoValuePos(new Rect(80, 70, -100, -90)));
        if (mode == DialogMode.YES_OR_NO)
        {
            SetText(ConstData.FONT_NAME2, "", ColorName.fontColor_darkorange);
            SetButtonTexture(buttonsMaterial, ButtonsTexturePosition.ButtonNormal, ButtonsTexturePosition.ButtonPressed, AutoRect.AutoSize(ButtonsTexturePosition.TinySizeButton));

            SetYesButtonOffset(AutoRect.AutoValuePos(new Vector2(70, 0)), AutoRect.AutoSize(ButtonsTexturePosition.TinySizeButton));
            SetNoButtonOffset(AutoRect.AutoValuePos(new Vector2(300, 0)), AutoRect.AutoSize(ButtonsTexturePosition.TinySizeButton));
            SetYesButtonText(ConstData.FONT_NAME2, "YES", ColorName.fontColor_orange);
            SetNoButtonText(ConstData.FONT_NAME2, "NO", ColorName.fontColor_orange);
        }
        else if (mode == DialogMode.TAP_TO_DISMISS)
        {
            SetTipTextOffset(AutoRect.AutoValuePos(new Rect(180, -260, 0, 0)));
            SetTipText(ConstData.FONT_NAME2, "TAP TO DISMISS", ColorName.fontColor_darkorange);
        }
    }
Пример #4
0
    // Use this for initialization
    public GameOverUI()
    {
        uiPos  = new GameOverUIPosition();
        texPos = new GameOverTexturePosition();

        gameState      = GameApp.GetInstance().GetGameState();
        selectedWeapon = gameState.GetWeapons()[0];

        gameuiMaterial = UIResourceMgr.GetInstance().GetMaterial("GameUI");
        Material buttonsMaterial = UIResourceMgr.GetInstance().GetMaterial("Buttons");

        retryButton = new UITextButton();

        retryButton.Rect = AutoRect.AutoPos(uiPos.RetryButton);
        retryButton.SetTexture(UIButtonBase.State.Normal, buttonsMaterial, ButtonsTexturePosition.ButtonNormal, AutoRect.AutoSize(ButtonsTexturePosition.ButtonNormal));
        retryButton.SetTexture(UIButtonBase.State.Pressed, buttonsMaterial, ButtonsTexturePosition.ButtonPressed, AutoRect.AutoSize(ButtonsTexturePosition.ButtonPressed));
        retryButton.SetText(ConstData.FONT_NAME1, "RETRY", ColorName.fontColor_orange);

        quitButton = new UITextButton();

        quitButton.Rect = AutoRect.AutoPos(uiPos.QuitButton);
        quitButton.SetTexture(UIButtonBase.State.Normal, buttonsMaterial, ButtonsTexturePosition.ButtonNormal, AutoRect.AutoSize(ButtonsTexturePosition.ButtonNormal));
        quitButton.SetTexture(UIButtonBase.State.Pressed, buttonsMaterial, ButtonsTexturePosition.ButtonPressed, AutoRect.AutoSize(ButtonsTexturePosition.ButtonPressed));
        quitButton.SetText(ConstData.FONT_NAME1, "QUIT", ColorName.fontColor_orange);


        dialogImage = new UIImage();
        dialogImage.SetTexture(gameuiMaterial,

                               GameUITexturePosition.Dialog, AutoRect.AutoSize(GameUITexturePosition.Dialog));

        dialogImage.Rect = AutoRect.AutoPos(uiPos.DialogImage);

        mask = new UIImage();
        mask.SetTexture(gameuiMaterial, GameUITexturePosition.Mask, AutoRect.AutoSize(uiPos.Mask));
        mask.Rect = AutoRect.AutoValuePos(uiPos.Mask);

        gameoverLabel = new UITextImage();
        gameoverLabel.SetTexture(buttonsMaterial,

                                 ButtonsTexturePosition.Label, ButtonsTexturePosition.LargeLabelSize * 0.1f);


        gameoverLabel.Rect = AutoRect.AutoPos(uiPos.GameOverLabel);
        //gameoverLabel.SetText(ConstData.FONT_NAME1, " GAME OVER", ColorName.fontColor_orange);



        cashText = new UIText();
        cashText.Set(ConstData.FONT_NAME1, "Cash", ColorName.fontColor_orange);
        cashText.Rect = AutoRect.AutoPos(uiPos.CashText);


        /*
         * surviveTimeText = new UIText();
         * surviveTimeText.Set(ConstData.FONT_NAME2, "TIME ", ColorName.fontColor_darkorange);
         * surviveTimeText.Rect = uiPos.SurviveTimeText;
         */

        firstLineText = new UIText();
        firstLineText.Set(ConstData.FONT_NAME1, "GAME OVER", ColorName.fontColor_darkorange);
        firstLineText.AlignStyle = UIText.enAlignStyle.center;
        firstLineText.Rect       = AutoRect.AutoPos(uiPos.FirstLineText);

        /*
         * scoreText = new UIText();
         * scoreText.Set(ConstData.FONT_NAME2, "KILLS   "+GameApp.GetInstance().GetGameScene().Killed, ColorName.fontColor_darkorange);
         * scoreText.Rect = uiPos.ScoreText;
         */


        gameover = new UIImage();
        gameover.SetTexture(gameuiMaterial, GameUITexturePosition.GameOver, AutoRect.AutoSize(GameUITexturePosition.GameOver) * 0.1f);
        gameover.Rect       = AutoRect.AutoPos(uiPos.GameOver);
        gameover.Visible    = false;
        gameover.Enable     = false;
        retryButton.Visible = false;
        quitButton.Visible  = false;
        //this.Add(dialogImage);
        //this.Add(gameoverLabel);
        this.Add(mask);
        //this.Add(firstLineText);
        //this.Add(scoreText);
        this.Add(retryButton);
        this.Add(quitButton);
        this.Add(gameover);

        this.SetUIHandler(this);

        uiInited = true;
        GameScene gameScene = GameApp.GetInstance().GetGameScene();

        if (gameScene.GetQuest() != null)
        {
            surviveTimeText.SetText("SurviveTime " + gameScene.GetQuest().GetQuestInfo());
            firstLineText.SetText("Kills " + gameScene.Killed);
        }
    }
Пример #5
0
    public PauseMenuUI()
    {
        uiPos = new PauseMenuUIPosition();

        gameState = GameApp.GetInstance().GetGameState();


        buttonsMaterial = UIResourceMgr.GetInstance().GetMaterial("Buttons");
        gameuiMaterial  = UIResourceMgr.GetInstance().GetMaterial("GameUI");
        background      = new UIImage();
        background.SetTexture(gameuiMaterial,

                              GameUITexturePosition.Dialog, AutoRect.AutoSize(GameUITexturePosition.DialogSize));
        background.Rect = AutoRect.AutoPos(uiPos.Background);


        pauseLabel = new UITextImage();
        pauseLabel.SetTexture(buttonsMaterial,

                              ButtonsTexturePosition.Label, AutoRect.AutoSize(ButtonsTexturePosition.Label));
        pauseLabel.Rect = AutoRect.AutoPos(uiPos.PauseLabel);
        pauseLabel.SetText(ConstData.FONT_NAME1, " PAUSE", ColorName.fontColor_orange);


        soundLabel = new UITextImage();
        soundLabel.SetTexture(buttonsMaterial,

                              ButtonsTexturePosition.Label, AutoRect.AutoSize(ButtonsTexturePosition.Label));
        soundLabel.Rect = AutoRect.AutoPos(uiPos.SoundLabel);
        soundLabel.SetText(ConstData.FONT_NAME1, " SOUND", ColorName.fontColor_orange);



        resumeButton = new UITextButton();
        resumeButton.SetTexture(UIButtonBase.State.Normal, buttonsMaterial,

                                ButtonsTexturePosition.ButtonNormal, AutoRect.AutoSize(ButtonsTexturePosition.SmallSizeButton));
        resumeButton.SetTexture(UIButtonBase.State.Pressed, buttonsMaterial,

                                ButtonsTexturePosition.ButtonPressed, AutoRect.AutoSize(ButtonsTexturePosition.SmallSizeButton));
        resumeButton.Rect = AutoRect.AutoPos(uiPos.ResumeButton);
        resumeButton.SetText(ConstData.FONT_NAME1, " RESUME", ColorName.fontColor_orange);


        musicButtonOff = new UITextSelectButton();
        musicButtonOff.SetTexture(UIButtonBase.State.Normal, buttonsMaterial,

                                  ButtonsTexturePosition.SoundButtonNormal, AutoRect.AutoSize(ButtonsTexturePosition.SoundButtonNormal));
        musicButtonOff.SetTexture(UIButtonBase.State.Pressed, buttonsMaterial,

                                  ButtonsTexturePosition.SoundButtonPressed, AutoRect.AutoSize(ButtonsTexturePosition.SoundButtonPressed));
        musicButtonOff.Rect = AutoRect.AutoPos(uiPos.MusicButtonOff);
        musicButtonOff.SetText(ConstData.FONT_NAME1, " OFF", ColorName.fontColor_orange);



        musicButtonOn = new UITextSelectButton();
        musicButtonOn.SetTexture(UIButtonBase.State.Normal, buttonsMaterial,

                                 ButtonsTexturePosition.SoundButtonNormal, AutoRect.AutoSize(ButtonsTexturePosition.SoundButtonNormal));
        musicButtonOn.SetTexture(UIButtonBase.State.Pressed, buttonsMaterial,

                                 ButtonsTexturePosition.SoundButtonPressed, AutoRect.AutoSize(ButtonsTexturePosition.SoundButtonPressed));
        musicButtonOn.Rect = AutoRect.AutoPos(uiPos.MusicButtonOn);
        musicButtonOn.SetText(ConstData.FONT_NAME1, " ON", ColorName.fontColor_orange);

        if (gameState.MusicOn)
        {
            musicButtonOn.Set(true);
            musicButtonOff.Set(false);
        }
        else
        {
            musicButtonOn.Set(false);
            musicButtonOff.Set(true);
        }



        returnButton = new UITextButton();
        returnButton.SetTexture(UIButtonBase.State.Normal, buttonsMaterial,

                                ButtonsTexturePosition.ButtonNormal, AutoRect.AutoSize(ButtonsTexturePosition.SmallSizeButton));
        returnButton.SetTexture(UIButtonBase.State.Pressed, buttonsMaterial,

                                ButtonsTexturePosition.ButtonPressed, AutoRect.AutoSize(ButtonsTexturePosition.SmallSizeButton));
        returnButton.Rect = AutoRect.AutoPos(uiPos.ReturnButton);
        returnButton.SetText(ConstData.FONT_NAME1, " QUIT", ColorName.fontColor_orange);


        mask = new UIImage();
        mask.SetTexture(gameuiMaterial, GameUITexturePosition.Mask, AutoRect.AutoSize(uiPos.Mask));
        mask.Rect = AutoRect.AutoValuePos(uiPos.Mask);



        this.Add(mask);
        this.Add(background);

        //this.Add(pauseLabel);

        this.Add(soundLabel);



        this.Add(musicButtonOff);
        this.Add(musicButtonOn);

        this.Add(resumeButton);
        this.Add(returnButton);



        this.SetUIHandler(this);

        Hide();
    }
Пример #6
0
    // Use this for initialization
    IEnumerator Start()
    {
        yield return(0);

        uiPos = new UIPosition();
        //texPos = new GameUITexturePosition();

        float screenRatioX = ((float)Screen.width) / 960.00f;

        buttonRect = new Rect[4];
        buttonRect[ButtonNames.WEAPON_SWITCH] = new Rect(650, 540, 205, 89);
        buttonRect[ButtonNames.BOMB]          = new Rect(0.4f * Screen.width, 0.25f * Screen.height, 0.24f * Screen.width, 0.08f * Screen.height);
        buttonRect[ButtonNames.CONTINUE]      = new Rect(0.4f * Screen.width, 0.25f * Screen.height, 0.14f * Screen.width, 0.14f * Screen.height);
        buttonRect[ButtonNames.START_OVER]    = new Rect(0.4f * Screen.width, 0.25f * Screen.height, 0.14f * Screen.width, 0.14f * Screen.height);


        if (AutoRect.GetPlatform() == Platform.IPad)
        {
            uiPos.PlayerLogo           = new Rect(-16 - 32, 566 + 64, 116, 81);
            uiPos.PlayerLogoBackground = new Rect(0 - 32, 556 + 64, 134, 88);
            uiPos.HPBackground         = new Rect(94 - 32, 590 - 12 + 64, 288, 50);
            uiPos.HPImage = new Rect(94 - 32, 590 - 12 + 64, 288, 50);
            uiPos.WeaponLogoBackground = new Rect(960 - 148 + 32, 640 - 74 + 54, 148, 88);
            uiPos.WeaponLogo           = new Rect(960 - 180 + 32, 640 - 84 + 64, 194, 112);
            uiPos.BulletsLogo          = new Rect(960 - 420 + 32, 640 - 94 + 64, 194, 112);
            uiPos.WeaponInfo           = new Rect(656 + 32, 558 + 64, 100, 64);
            uiPos.PauseButton          = new Rect(408, 588, 160, 166);
            uiPos.CashText             = new Rect(0, 576 + 64, 1024, 64);
            uiPos.Mask   = new Rect(0, 0, 1024, 768);
            uiPos.Switch = new Rect(960 - 268 + 32, 640 - 90 + 12 + 64, 148, 88);
        }



        gameScene = GameApp.GetInstance().GetGameScene();
        player    = gameScene.GetPlayer();

        m_UIManager = gameObject.AddComponent <UIManager>() as UIManager;
        m_UIManager.SetParameter(8, 1, false);
        m_UIManager.SetUIHandler(this);



        int  avatarLogoIndex = (int)player.GetAvatarType();
        Rect logoRect        = GameUITexturePosition.GetAvatarLogoRect(avatarLogoIndex);

        //Player Logo
        playerLogoImage      = new UIImage();
        playerLogoImage.Rect = AutoRect.AutoPos(uiPos.PlayerLogo);

        playerLogoImage.SetTexture(gameuiMaterial, logoRect, AutoRect.AutoSize(logoRect));
        //playerLogoImage.SetTextureSize(new Vector2(texPos.PlayerLogo.width, texPos.PlayerLogo.height));

        //HP
        hpBackground = new UIImage();
        hpBackground.SetTexture(gameuiMaterial, GameUITexturePosition.HPBackground, AutoRect.AutoSize(GameUITexturePosition.HPBackground));
        hpBackground.Rect = AutoRect.AutoPos(uiPos.HPBackground);


        dayclear = new UIImage();
        dayclear.SetTexture(gameuiMaterial, GameUITexturePosition.DayClear, AutoRect.AutoSize(GameUITexturePosition.DayClear));
        dayclear.Rect    = AutoRect.AutoPos(uiPos.DayClear);
        dayclear.Visible = false;
        dayclear.Enable  = false;
        hpImage          = new UIImage();
        hpImage.SetTexture(gameuiMaterial, GameUITexturePosition.HPImage, AutoRect.AutoSize(GameUITexturePosition.HPImage));


        playerLogoBackgroundImage = new UIImage();
        playerLogoBackgroundImage.SetTexture(gameuiMaterial, GameUITexturePosition.PlayerLogoBackground, AutoRect.AutoSize(GameUITexturePosition.PlayerLogoBackground));
        playerLogoBackgroundImage.Rect = AutoRect.AutoPos(uiPos.PlayerLogoBackground);

        //Weapon Switch
        weaponBackground      = new UIImage();
        weaponBackground.Rect = AutoRect.AutoPos(uiPos.WeaponLogoBackground);
        weaponBackground.SetTexture(gameuiMaterial, GameUITexturePosition.WeaponLogoBackground, AutoRect.AutoSize(GameUITexturePosition.WeaponLogoBackground));


        int  weaponLogoIndex = GameApp.GetInstance().GetGameState().GetWeaponIndex(player.GetWeapon());
        Rect weaponlogoRect  = GameUITexturePosition.GetWeaponLogoRect(weaponLogoIndex);

        weaponLogo      = new UIClickButton();
        weaponLogo.Rect = AutoRect.AutoPos(uiPos.WeaponLogo);
        weaponLogo.SetTexture(UIButtonBase.State.Normal, gameuiMaterial, weaponlogoRect, AutoRect.AutoSize(weaponlogoRect));
        weaponLogo.SetTexture(UIButtonBase.State.Pressed, gameuiMaterial, weaponlogoRect, AutoRect.AutoSize(weaponlogoRect));


        switchImg      = new UIImage();
        switchImg.Rect = AutoRect.AutoPos(uiPos.Switch);
        switchImg.SetTexture(gameuiMaterial, GameUITexturePosition.Switch, AutoRect.AutoSize(GameUITexturePosition.Switch));
        switchImg.Enable = true;

        Material buttonsMaterial = UIResourceMgr.GetInstance().GetMaterial("Buttons");

        bulletsLogo      = new UIImage();
        bulletsLogo.Rect = AutoRect.AutoPos(uiPos.BulletsLogo);
        Rect bulletlogoRect = ButtonsTexturePosition.GetBulletsLogoRect((int)player.GetWeapon().GetWeaponType());

        bulletsLogo.SetTexture(buttonsMaterial, bulletlogoRect, AutoRect.AutoSize(bulletlogoRect));
        bulletsLogo.Enable = false;



        InputController inputController = player.InputController;
        //Move Joystick
        Vector2 thumbCenter = inputController.ThumbCenter;

        joystickImage      = new UIImage();
        joystickImage.Rect = new Rect((thumbCenter.x - inputController.ThumbRadius), ((Screen.height - thumbCenter.y) - inputController.ThumbRadius), AutoRect.AutoValue(169), AutoRect.AutoValue(168));
        joystickImage.SetTexture(gameuiMaterial, GameUITexturePosition.MoveJoystick, AutoRect.AutoSize(GameUITexturePosition.MoveJoystick));

        joystickThumb = new UIImage();
        joystickThumb.SetTexture(gameuiMaterial, GameUITexturePosition.MoveJoystickThumb, AutoRect.AutoSize(GameUITexturePosition.MoveJoystickThumb));

        thumbCenter             = inputController.ShootThumbCenter;
        shootjoystickImage      = new UIImage();
        shootjoystickImage.Rect = new Rect((thumbCenter.x - inputController.ThumbRadius), ((Screen.height - thumbCenter.y) - inputController.ThumbRadius), AutoRect.AutoValue(169), AutoRect.AutoValue(168));
        shootjoystickImage.SetTexture(gameuiMaterial, GameUITexturePosition.ShootJoystick, AutoRect.AutoSize(GameUITexturePosition.ShootJoystick));
        shootjoystickImage.SetRotation(Mathf.Deg2Rad * 180);

        shootjoystickThumb = new UIImage();
        shootjoystickThumb.SetTexture(gameuiMaterial, GameUITexturePosition.ShootJoystickThumb, AutoRect.AutoSize(GameUITexturePosition.ShootJoystickThumb));


        pauseButton      = new UIClickButton();
        pauseButton.Rect = AutoRect.AutoPos(uiPos.PauseButton);
        pauseButton.SetTexture(UIButtonBase.State.Normal, gameuiMaterial, GameUITexturePosition.PauseButtonNormal, AutoRect.AutoSize(GameUITexturePosition.PauseButtonNormal));
        pauseButton.SetTexture(UIButtonBase.State.Pressed, gameuiMaterial, GameUITexturePosition.PauseButtonPressed, AutoRect.AutoSize(GameUITexturePosition.PauseButtonPressed));


        //Cash
        cashText = new UIText();
        //cashText.Rect = new Rect(0.05f * Screen.width, 0.75f * Screen.height, 400, 50);
        cashText.AlignStyle = UIText.enAlignStyle.center;
        cashText.Rect       = AutoRect.AutoPos(uiPos.CashText);
        cashText.Set(ConstData.FONT_NAME1, "$" + GameApp.GetInstance().GetGameState().GetCash().ToString("N0"), ColorName.fontColor_orange);



        //Weapon Info
        weaponInfoText            = new UIText();
        weaponInfoText.AlignStyle = UIText.enAlignStyle.left;

        weaponInfoText.Rect = AutoRect.AutoPos(uiPos.WeaponInfo);
        weaponInfoText.Set(ConstData.FONT_NAME2, fpsStr, ColorName.fontColor_darkorange);



        fpsText            = new UIText();
        fpsText.AlignStyle = UIText.enAlignStyle.left;
        fpsText.Rect       = AutoRect.AutoPos(uiPos.LevelInfo);
        fpsText.Set(ConstData.FONT_NAME3, "", Color.white);

        dayInfoPanel = new DayInfoPanel();
        dayInfoPanel.SetDay(GameApp.GetInstance().GetGameState().LevelNum);

        mask = new UIImage();
        mask.SetTexture(gameuiMaterial, GameUITexturePosition.Mask, AutoRect.AutoSize(uiPos.Mask));
        mask.Rect = AutoRect.AutoValuePos(uiPos.Mask);

        Vector2 size = AutoRect.AutoSize(GameUITexturePosition.SemiMaskSize);
        Rect    pos  = AutoRect.AutoPos(uiPos.RightSemiMask);

        if (AutoRect.GetPlatform() == Platform.IPad)
        {
            size = new Vector2(512, 768);
            pos  = new Rect(512, 0, 512, 768);
        }
        semiMask = new UIImage();
        semiMask.SetTexture(gameuiMaterial, GameUITexturePosition.Mask, size);
        semiMask.Rect = pos;



        unlockPanel = new UnlockPanel();


        m_UIManager.Add(dayInfoPanel);
        m_UIManager.Add(hpBackground);
        m_UIManager.Add(hpImage);
        m_UIManager.Add(playerLogoBackgroundImage);
        m_UIManager.Add(playerLogoImage);
        m_UIManager.Add(joystickImage);
        m_UIManager.Add(joystickThumb);
        m_UIManager.Add(shootjoystickImage);
        m_UIManager.Add(shootjoystickThumb);
        m_UIManager.Add(weaponBackground);
        m_UIManager.Add(weaponLogo);
        m_UIManager.Add(switchImg);
        m_UIManager.Add(pauseButton);
        m_UIManager.Add(semiMask);
        if (Application.loadedLevelName == SceneName.SCENE_TUTORIAL)
        {
            m_UIManager.Add(dialog);
        }
        m_UIManager.Add(bulletsLogo);
        m_UIManager.Add(weaponInfoText);
        //m_UIManager.Add(cashText);
        m_UIManager.Add(mask);

        m_UIManager.Add(dayclear);
        //m_UIManager.Add(fpsText);

        m_UIManager.Add(unlockPanel);


        semiMask.Enable  = false;
        semiMask.Visible = false;
        dayInfoPanel.Show();
        uiInited = true;

        EnableTutorialOKButton(false);
        mask.Enable  = false;
        mask.Visible = false;

        SetWeaponLogo(player.GetWeapon().GetWeaponType());

        panels[GameUIName.PAUSE] = new PauseMenuUI();
        ((PauseMenuUI)panels[GameUIName.PAUSE]).SetGameUIScript(this);

        panels[GameUIName.GAME_OVER] = new GameOverUI();
        panels[GameUIName.NEW_ITEM]  = new NewItemUI();

        //unlockPanel.Show();
        for (int i = 0; i < GameUIName.UI_COUNT; i++)
        {
            m_UIManager.Add(panels[i]);
        }
        startTime = Time.time;
    }