Example #1
0
    public void OnUpgradeBtn()
    {
        bool bActiveSkill = petData.activeSkillType == skillData.skillType;
        int  skillLv      = bActiveSkill ? petData.aSkillLv : petData.pSkillLv;
        int  needCoin     = 0;

        SoundManager.GetInstance().PlaySound(Define.SoundType.Click);

        if (DataManager.GetInstance().IsEnoughCoin(skillData.GetSkillCost(skillLv), ref needCoin))
        {
            if (upgradeCallback != null)
            {
                upgradeCallback();
            }

            PopupSystem.ClosePopup(Define.PopupType.SkillInfo);
        }
        else
        {
            //NeedCoinPopup popup = PopupSystem.GetPopup<NeedCoinPopup>(Define.PopupType.NeedCoin);
            //popup.SetData(needCoin, () =>
            //{
            //    PopupSystem.ClearPopupStack();
            //    UISystem.OpenDialog(Define.DialogType.ShopDialog);
            //});
            //PopupSystem.OpenPopup(Define.PopupType.NeedCoin);
            DataManager.GetInstance().SetNeedCoin(needCoin);
            UISystem.OpenDialog(Define.DialogType.ShopDialog);
        }
    }
    // Token: 0x06000B5F RID: 2911 RVA: 0x00049038 File Offset: 0x00047238
    private void DrawIncomingClanInvitation(GroupInvitationView view, int y, int width)
    {
        Rect position = new Rect(4f, (float)(y + 4), (float)(width - 1), 50f);

        GUI.BeginGroup(position);
        Rect position2 = new Rect(0f, 0f, position.width, position.height - 1f);

        if (GUI.enabled && position2.Contains(Event.current.mousePosition))
        {
            GUI.Box(position2, GUIContent.none, BlueStonez.box_grey50);
        }
        GUI.Label(new Rect(80f, 5f, position.width - 250f, 20f), string.Format("{0}: {1}", LocalizedStrings.ClanInvite, view.GroupName), BlueStonez.label_interparkbold_13pt_left);
        GUI.Label(new Rect(80f, 30f, position.width - 250f, 20f), "> " + view.Message, BlueStonez.label_interparkmed_11pt_left);
        if (GUITools.Button(new Rect(position.width - 120f - 18f, 5f, 60f, 20f), new GUIContent(LocalizedStrings.Accept), BlueStonez.buttondark_medium))
        {
            if (PlayerDataManager.IsPlayerInClan)
            {
                PopupSystem.ShowMessage(LocalizedStrings.Error, LocalizedStrings.YouAlreadyInClanMsg, PopupSystem.AlertType.OK);
            }
            else
            {
                int requestId = view.GroupInvitationId;
                PopupSystem.ShowMessage(LocalizedStrings.Accept, "Do you want to accept this clan invitation?", PopupSystem.AlertType.OKCancel, delegate()
                {
                    Singleton <InboxManager> .Instance.AcceptClanRequest(requestId);
                }, "Join", null, LocalizedStrings.Cancel, PopupSystem.ActionType.Positive);
            }
        }
        if (GUITools.Button(new Rect(position.width - 50f - 18f, 5f, 60f, 20f), new GUIContent(LocalizedStrings.Ignore), BlueStonez.buttondark_medium))
        {
            Singleton <InboxManager> .Instance.DeclineClanRequest(view.GroupInvitationId);
        }
        GUI.EndGroup();
        GUI.Label(new Rect(4f, (float)(y + 50 + 8), (float)width, 1f), GUIContent.none, BlueStonez.horizontal_line_grey95);
    }
Example #3
0
    // Token: 0x06000F5C RID: 3932 RVA: 0x00064AD4 File Offset: 0x00062CD4
    private void HandleVersionError()
    {
        ChannelType channel = ApplicationDataManager.Channel;

        switch (channel)
        {
        case ChannelType.IPhone:
        case ChannelType.IPad:
            PopupSystem.ShowError(LocalizedStrings.Error, "Your UberStrike client is out of date. Please update from the App Store.", PopupSystem.AlertType.OK, new Action(this.OpenIosAppStoreUpdatesPage));
            break;

        case ChannelType.Android:
            PopupSystem.ShowError(LocalizedStrings.Error, "Your UberStrike client is out of date. Please update from our website.", PopupSystem.AlertType.OK, new Action(this.OpenAndroidAppStoreUpdatesPage));
            break;

        default:
            if (channel != ChannelType.WebPortal && channel != ChannelType.WebFacebook)
            {
                PopupSystem.ShowError(LocalizedStrings.Error, "Your UberStrike client is not supported. Please update from our website.\n(Invalid Channel: " + ApplicationDataManager.Channel + ")", PopupSystem.AlertType.OK);
            }
            else
            {
                PopupSystem.ShowError(LocalizedStrings.Error, "Your UberStrike client is out of date. Please refresh your browser.", PopupSystem.AlertType.None);
            }
            break;
        }
    }
Example #4
0
    public static void GameOver(bool bTimeUp)
    {
        if (instance == null)
        {
            return;
        }

        instance.bPlaying = false;
        instance.tileSystem.GameOver();

        ScenesManager.SetEscapeMethod(null);

        SoundManager.GetInstance().FadeOutAndStopBGM(Define.SoundType.TickTock, 0.5f);
        SoundManager.GetInstance().FadeOutAndStopBGM(Define.SoundType.TickTockBack, 0.5f);
        SoundManager.GetInstance().FadeOutAndStopBGM(Define.SoundType.GameBGM, 0.5f);

        TimeUpPopup popup = PopupSystem.GetPopup <TimeUpPopup>(Define.PopupType.TimeUp);

        popup.SetData(bTimeUp, () =>
        {
            bool bShowContinue = DataManager.GetInstance().CanShowContinueVideo();
            if (bShowContinue && UnityAdsController.IsReady(Define.continueId))
            {
                ContinueDialog.SetData(bTimeUp);
                UISystem.OpenDialog(Define.DialogType.ContinueDialog);
            }
            else
            {
                UISystem.OpenDialog(Define.DialogType.ResultDialog);
            }
        });
        PopupSystem.OpenPopup(Define.PopupType.TimeUp);

        instance.uiSystem.GameOver();
    }
Example #5
0
        private void UserSplit(EntityUid uid, EntityUid userUid, int amount,
                               StackComponent?stack             = null,
                               TransformComponent?userTransform = null)
        {
            if (!Resolve(uid, ref stack))
            {
                return;
            }

            if (!Resolve(userUid, ref userTransform))
            {
                return;
            }

            if (amount <= 0)
            {
                PopupSystem.PopupCursor(Loc.GetString("comp-stack-split-too-small"), Filter.Entities(userUid));
                return;
            }

            if (Split(uid, amount, userTransform.Coordinates, stack) is not {
            } split)
            {
                return;
            }

            HandsSystem.PickupOrDrop(userUid, split);

            PopupSystem.PopupCursor(Loc.GetString("comp-stack-split"), Filter.Entities(userUid));
        }
 // Token: 0x0600128E RID: 4750 RVA: 0x0006E744 File Offset: 0x0006C944
 private void OnMicroTxnCallback(MicroTxnAuthorizationResponse_t param)
 {
     Debug.Log("Steam MicroTxnParams: " + param);
     if (param.m_bAuthorized > 0)
     {
         ShopWebServiceClient.FinishBuyBundleSteam(param.m_ulOrderID.ToString(), delegate(bool success)
         {
             if (success)
             {
                 PopupSystem.ClearAll();
                 PopupSystem.ShowMessage("Purchase Successful", "Thank you, your purchase was successful.", PopupSystem.AlertType.OK, delegate()
                 {
                     ApplicationDataManager.RefreshWallet();
                 });
             }
             else
             {
                 Debug.Log("Managed error from WebServices");
                 PopupSystem.ClearAll();
                 PopupSystem.ShowMessage("Purchase Failed", "Sorry, there was a problem processing your payment. Please visit support.uberstrike.com for help.", PopupSystem.AlertType.OK);
             }
         }, delegate(Exception ex)
         {
             Debug.Log(ex.Message);
             PopupSystem.ClearAll();
             PopupSystem.ShowMessage("Purchase Failed", "Sorry, there was a problem processing your payment. Please visit support.uberstrike.com for help.", PopupSystem.AlertType.OK);
         });
     }
     else
     {
         Debug.Log("Purchase canceled");
         PopupSystem.ClearAll();
     }
 }
Example #7
0
    public IEnumerator StartGetLoadout()
    {
        if (!Singleton <ItemManager> .Instance.ValidateItemMall())
        {
            PopupSystem.ShowMessage("Error Getting Shop Data", "The shop is empty, perhaps there\nwas an error getting the Shop data?", PopupSystem.AlertType.OK, new Action(HandleWebServiceError));
            yield break;
        }
        yield return(UserWebServiceClient.GetLoadout(AuthToken, delegate(LoadoutView ev)
        {
            if (ev != null)
            {
                CheckLoadoutForExpiredItems(ev);
                Singleton <LoadoutManager> .Instance.UpdateLoadout(ev);
                GameState.Current.Avatar.SetLoadout(new Loadout(Singleton <LoadoutManager> .Instance.Loadout));
                _localPlayerSkinColor = ColorConverter.HexToColor(ev.SkinColor);
            }
            else
            {
                ApplicationDataManager.LockApplication("It seems that you account is corrupted. Please visit support.uberstrike.com for advice.");
            }
        }, delegate(Exception ex)
        {
            ApplicationDataManager.LockApplication("There was an error getting your loadout.");
        }));

        yield break;
    }
    public void LoginByChannel()
    {
        string @string = PlayerPrefs.GetString("CurrentSteamUser", string.Empty);

        Debug.Log(string.Format("SteamWorks SteamID:{0}, PlayerPrefs SteamID:{1}", PlayerDataManager.SteamId, @string));
        if (string.IsNullOrEmpty(@string) || @string != PlayerDataManager.SteamId)
        {
            Debug.Log(string.Format("No SteamID saved. Using SteamWorks SteamID:{0}", PlayerDataManager.SteamId));
            PopupSystem.ShowMessage(string.Empty, "Have you played UberStrike before?", PopupSystem.AlertType.OKCancel, delegate()
            {
                UnityRuntime.StartRoutine(StartLoginMemberSteam(true));
            }, "No", delegate()
            {
                PopupSystem.ShowMessage(string.Empty, "Do you want to upgrade an UberStrike.com or Facebook account?\n\nNOTE: This will permenantly link your UberStrike account to this Steam ID", PopupSystem.AlertType.OKCancel, delegate()
                {
                    UnityRuntime.StartRoutine(StartLoginMemberSteam(true));
                }, "No", delegate()
                {
                    UnityRuntime.StartRoutine(StartLoginMemberSteam(false));
                }, "Yes");
            }, "Yes");
        }
        else
        {
            Debug.Log(string.Format("Login using saved SteamID:{0}", @string));
            UnityRuntime.StartRoutine(StartLoginMemberSteam(true));
        }
    }
Example #9
0
 // Token: 0x0600192E RID: 6446 RVA: 0x00010C92 File Offset: 0x0000EE92
 protected override void OnModerationCustomMessage(string message)
 {
     PopupSystem.ShowMessage("Administrator Message", message, PopupSystem.AlertType.OK, delegate()
     {
     });
     global::EventHandler.Global.Fire(new GameEvents.PlayerPause());
 }
Example #10
0
    private void CallbackSkip()
    {
        BasicPopup popup = PopupSystem.GetPopup <BasicPopup>(Define.PopupType.Basic);

        popup.SetData(DataManager.GetText(TextTable.skipVideoKey));
        PopupSystem.OpenPopup(Define.PopupType.Basic);
    }
Example #11
0
    // Token: 0x06000DBA RID: 3514 RVA: 0x0005F820 File Offset: 0x0005DA20
    public void OnGUI()
    {
        Rect position = this.GetPosition();

        GUI.Box(position, GUIContent.none, BlueStonez.window);
        GUITools.PushGUIState();
        GUI.enabled = !this.IsUIDisabled;
        GUI.BeginGroup(position);
        if (this._showExitButton && GUI.Button(new Rect(position.width - 20f, 0f, 20f, 20f), "X", BlueStonez.friends_hidden_button))
        {
            PopupSystem.HideMessage(this);
        }
        this.DrawPlayGUI(position);
        GUI.EndGroup();
        GUITools.PopGUIState();
        if (this.IsWaiting)
        {
            WaitingTexture.Draw(position.center, 0);
        }
        if (this.ClickAnywhereToExit && Event.current.type == EventType.MouseDown && !position.Contains(Event.current.mousePosition))
        {
            this.ClosePopup();
            Event.current.Use();
        }
        this.OnAfterGUI();
    }
Example #12
0
    public void SetData(string msg, int coin, int petIdx, System.Action buyCallback)
    {
        this.coin        = coin;
        this.buyCallback = buyCallback;

        mainLabel.text = msg;
        coinLabel.text = coin.ToString();
        Vector3 pos     = coinLabelBody.localPosition;
        float   halfDis = coinLabel.width * 0.5f + 5;

        pos.x = halfDis;
        coinLabelBody.localPosition = pos;

        pos   = coinIconBody.localPosition;
        pos.x = -halfDis - (coinIcon.width * 0.5f);
        coinIconBody.localPosition = pos;

        string characterImageStr     = "";
        string characterImageOutline = "";

        if (PopupSystem.TryGetCharacterImageOnPopup(ref characterImageStr, ref characterImageOutline, petIdx))
        {
            characterImage.spriteName   = characterImageStr;
            characterOutline.spriteName = characterImageOutline;

            characterImage.MakePixelPerfect();
            characterOutline.MakePixelPerfect();
        }
    }
    // Token: 0x06000946 RID: 2374 RVA: 0x0003AC2C File Offset: 0x00038E2C
    private IEnumerator ShowPopup(IPopupDialog popup, int delay)
    {
        yield return(new WaitForSeconds((float)delay));

        PopupSystem.Show(popup);
        yield break;
    }
Example #14
0
    // Token: 0x060013E3 RID: 5091 RVA: 0x00072D48 File Offset: 0x00070F48
    public IEnumerator StartUpdateInventoryAndEquipNewItem(IUnityItem item, bool equipNow = false)
    {
        if (item != null)
        {
            IPopupDialog popupDialog = PopupSystem.ShowMessage(LocalizedStrings.UpdatingInventory, LocalizedStrings.WereUpdatingYourInventoryPleaseWait, PopupSystem.AlertType.None);
            yield return(UnityRuntime.StartRoutine(Singleton <ItemManager> .Instance.StartGetInventory(false)));

            PopupSystem.HideMessage(popupDialog);
            if (equipNow)
            {
                this.EquipItem(item);
            }
            else if (GameState.Current.HasJoinedGame && GameState.Current.IsInGame)
            {
                this.EquipItem(item);
            }
            else if (item.View.ItemProperties.ContainsKey(ItemPropertyType.PointsBoost) || item.View.ItemProperties.ContainsKey(ItemPropertyType.XpBoost))
            {
                InventoryItem invItem = this.GetItem(item.View.ID);
                PopupSystem.ShowItem(item, "\nYou just bought the boost item!\nThis item is activated and expires in " + invItem.DaysRemaining + " days");
            }
            else
            {
                PopupSystem.ShowItem(item, string.Empty);
            }
            yield return(UnityRuntime.StartRoutine(Singleton <PlayerDataManager> .Instance.StartGetMember()));
        }
        yield break;
    }
Example #15
0
    // Token: 0x0600192F RID: 6447 RVA: 0x00010CCC File Offset: 0x0000EECC
    protected override void OnModerationKickGame()
    {
        Singleton <GameStateController> .Instance.LeaveGame(false);

        PopupSystem.ShowMessage("ADMIN MESSAGE", "You were kicked out of the game!", PopupSystem.AlertType.OK, delegate()
        {
        });
    }
Example #16
0
 // Token: 0x06000D76 RID: 3446 RVA: 0x00009F9D File Offset: 0x0000819D
 private void Close()
 {
     PopupSystem.HideMessage(this);
     if (this._onCloseButtonClicked != null)
     {
         this._onCloseButtonClicked();
     }
 }
    public override void Init(PopupSystem popupSystem)
    {
        base.Init(popupSystem);

        PopulateMonths();
        PopulateYears();
        PrepareEvents(popupSystem);
    }
Example #18
0
    // Token: 0x060019E6 RID: 6630 RVA: 0x000114B7 File Offset: 0x0000F6B7
    protected override void OnKickPlayer(string message)
    {
        Singleton <GameStateController> .Instance.LeaveGame(false);

        PopupSystem.ShowMessage("Cheat Detection", message, PopupSystem.AlertType.OK, delegate()
        {
        });
    }
 // Token: 0x060019A4 RID: 6564 RVA: 0x0001126C File Offset: 0x0000F46C
 protected override void OnRoomEnterFailed(string server, int roomId, string message)
 {
     PopupSystem.ClearAll();
     PopupSystem.ShowMessage("Failed to join game", message, PopupSystem.AlertType.OK, delegate()
     {
         Singleton <GameStateController> .Instance.LeaveGame(false);
     });
 }
    // Token: 0x06000D82 RID: 3458 RVA: 0x0005E4C4 File Offset: 0x0005C6C4
    private void DoOKCancelButtons()
    {
        Rect       rect    = new Rect(this._size.x * 0.5f + 5f, this._size.y - 40f, 120f, 32f);
        GUIContent content = new GUIContent((!string.IsNullOrEmpty(this._cancelCaption)) ? this._cancelCaption : LocalizedStrings.CancelCaps);

        GUI.color = Color.white;
        bool flag;

        if (this._allowAudio)
        {
            flag = GUITools.Button(rect, content, PopupSkin.button);
        }
        else
        {
            flag = GUI.Button(rect, content, PopupSkin.button);
        }
        if (flag)
        {
            PopupSystem.HideMessage(this);
            if (this._callbackCancel != null)
            {
                this._callbackCancel();
            }
        }
        GUIStyle style = PopupSkin.button;

        PopupSystem.ActionType actionType = this._actionType;
        if (actionType != PopupSystem.ActionType.Negative)
        {
            if (actionType == PopupSystem.ActionType.Positive)
            {
                style = PopupSkin.button_green;
            }
        }
        else
        {
            style = PopupSkin.button_red;
        }
        rect        = new Rect(this._size.x * 0.5f - 125f, this._size.y - 40f, 120f, 32f);
        content     = new GUIContent((!string.IsNullOrEmpty(this._okCaption)) ? this._okCaption : LocalizedStrings.OkCaps);
        GUI.enabled = this.IsOkButtonEnabled;
        if (this._allowAudio)
        {
            flag = GUITools.Button(rect, content, style);
        }
        else
        {
            flag = GUI.Button(rect, content, style);
        }
        if (flag)
        {
            PopupSystem.HideMessage(this);
            if (this._callbackOk != null)
            {
                this._callbackOk();
            }
        }
    }
 // Token: 0x0600095F RID: 2399 RVA: 0x0003AE40 File Offset: 0x00039040
 private void InitOptionsDropdown()
 {
     this._optionsDropdown         = new GuiDropDown();
     this._optionsDropdown.Caption = new GUIContent(GlobalUiIcons.QuadpanelButtonOptions);
     this._optionsDropdown.Add(new GUIContent(" " + LocalizedStrings.Help, GlobalUiIcons.QuadpanelButtonHelp), delegate()
     {
         PanelManager.Instance.OpenPanel(PanelType.Help);
     });
     this._optionsDropdown.Add(new GUIContent(" " + LocalizedStrings.Options, GlobalUiIcons.QuadpanelButtonOptions), delegate()
     {
         PanelManager.Instance.OpenPanel(PanelType.Options);
     });
     this._optionsDropdown.Add(new GUIContent(" " + LocalizedStrings.Audio, GlobalUiIcons.QuadpanelButtonSoundoff), new GUIContent(" " + LocalizedStrings.Audio, GlobalUiIcons.QuadpanelButtonSoundon), () => ApplicationDataManager.ApplicationOptions.AudioEnabled, delegate()
     {
         ApplicationDataManager.ApplicationOptions.AudioEnabled = !ApplicationDataManager.ApplicationOptions.AudioEnabled;
         AutoMonoBehaviour <SfxManager> .Instance.EnableAudio(ApplicationDataManager.ApplicationOptions.AudioEnabled);
         ApplicationDataManager.ApplicationOptions.SaveApplicationOptions();
         AutoMonoBehaviour <SfxManager> .Instance.UpdateEffectsVolume();
     });
     if (Application.isWebPlayer)
     {
         this._optionsDropdown.Add(new GUIContent(" " + LocalizedStrings.Windowed, GlobalUiIcons.QuadpanelButtonNormalize), new GUIContent(" " + LocalizedStrings.Fullscreen, GlobalUiIcons.QuadpanelButtonFullscreen), () => Screen.fullScreen, delegate()
         {
             ScreenResolutionManager.IsFullScreen = !Screen.fullScreen;
         });
     }
     else
     {
         if (PlayerDataManager.AccessLevel == MemberAccessLevel.Admin)
         {
             this._optionsDropdown.Add(new GUIContent(" CONSOLE"), delegate()
             {
                 DebugConsoleManager.Instance.IsDebugConsoleEnabled = true;
             });
         }
         this._optionsDropdown.Add(new GUIContent(" " + LocalizedStrings.Logout, GlobalUiIcons.QuadpanelButtonLogout), delegate()
         {
             PopupSystem.ShowMessage("Logout", "This will log out your Steam account and allow you to link another account.", PopupSystem.AlertType.OKCancel, delegate()
             {
                 PlayerPrefs.DeleteKey("CurrentSteamUser");
                 Application.Quit();
             });
         });
     }
     global::EventHandler.Global.AddListener <GlobalEvents.Login>(delegate(GlobalEvents.Login ev)
     {
         if (ev.AccessLevel >= MemberAccessLevel.Moderator)
         {
             this._optionsDropdown.Add(new GUIContent(" " + LocalizedStrings.Moderate, GlobalUiIcons.QuadpanelButtonModerate), delegate()
             {
                 if (PlayerDataManager.AccessLevel >= MemberAccessLevel.Moderator)
                 {
                     PanelManager.Instance.OpenPanel(PanelType.Moderation);
                 }
             });
         }
     });
 }
 // Token: 0x06000D67 RID: 3431 RVA: 0x00009EBA File Offset: 0x000080BA
 private void ShowSignUpErrorPopup(string title, string message)
 {
     this.Hide();
     PopupSystem.ShowMessage(title, message, PopupSystem.AlertType.OK, delegate()
     {
         LoginPanelGUI.ErrorMessage = string.Empty;
         this.Show();
     });
 }
 // Token: 0x06001963 RID: 6499 RVA: 0x00087DD8 File Offset: 0x00085FD8
 protected override void OnJoinGameFailed(string message)
 {
     Debug.LogError("OnJoinGameFailed " + message);
     PopupSystem.ClearAll();
     PopupSystem.ShowMessage("Join Game failed", message, PopupSystem.AlertType.OK, delegate()
     {
         GameState.Current.MatchState.SetState(GameStateId.PregameLoadout);
     });
 }
Example #24
0
 void Start()
 {
     GenerateOffset();
     popupSystem          = gameObject.GetComponent <PopupSystem>();
     agent                = gameObject.GetComponent <NavMeshAgent>();
     agent.updateRotation = false;
     InitializeCustomer(customerId);
     AudioManager.Instance.Play("PortalOut");
 }
Example #25
0
    public void UseSkill(int idx)
    {
        PetData    data  = DataManager.GetInstance().GetSelectedPetData(idx);
        SkillTable skill = DataManager.GetInstance().GetSkillTable(data.activeSkillType);

        bActingSkill = true;

        UseSkillPopup popup = PopupSystem.GetPopup <UseSkillPopup>(Define.PopupType.UseSkill);

        popup.SetData(data, () =>
        {
            skillData[idx].nowCooltime = 0;
            skillData[idx].useSkillCount++;
            scoreAssistance.SetSkillPointMode();

            nowUseSkill = skill.skillType;

            switch (skill.skillType)
            {
            case Define.SkillType.StopTime:
                gameTimeAssistance.FreezeTime(skill.GetSkillValue(data.aSkillLv));
                AfterUseSkill();
                break;

            case Define.SkillType.BrokenTiles:
                mapAssistance.AllBlocksDown(AfterUseSkill);
                break;

            case Define.SkillType.ClearAllTiles:
                mapAssistance.ClearAllBlocks(AfterUseSkill);
                break;

            case Define.SkillType.DoubleScore:
                scoreAssistance.SetMultiBonus(
                    DataManager.GetDesignValue(Define.GameDesign.DoubleSkillScoreBonus),
                    skill.GetSkillValue(data.aSkillLv)
                    );
                AfterUseSkill();
                break;

            case Define.SkillType.FillLines:
                mapAssistance.ChangeTileTypeToFillLines(idx, AfterUseSkill);
                break;

            case Define.SkillType.ChangePuzzles:
                mapAssistance.ChangeAllPuzzles(AfterUseSkill);
                break;

            default:
                Debug.Log("something is wrong");
                AfterUseSkill();
                break;
            }
        });
        PopupSystem.OpenPopup(Define.PopupType.UseSkill);
    }
Example #26
0
    private void CallbackSuccess()
    {
        AddCoinPopup popup = PopupSystem.GetPopup <AddCoinPopup>(Define.PopupType.AddCoin);

        popup.SetData(DataManager.GetDesignValue(Define.GameDesign.FreeCoin), () =>
        {
            DataManager.GetInstance().AfterShowFreeCoinVideo();
        });
        PopupSystem.OpenPopup(Define.PopupType.AddCoin, OnCloseButton);
    }
Example #27
0
        private void Start()
        {
            popupSystem = GetComponent <PopupSystem>();

            popupMaterials = new List <PopupSystemMaterial>()
            {
                new PopupSystemMaterial(OnPushNextButton, toNextButton.gameObject.name, false),
                new PopupSystemMaterial(OnPushClose, closeButton.gameObject.name, false),
            };
        }
 private void ShowLoginErrorPopup(string title, string message)
 {
     Debug.Log("Login Error!");
     PopupSystem.HideMessage(_progress);
     PopupSystem.ShowMessage(title, message, PopupSystem.AlertType.OK, delegate()
     {
         LoginPanelGUI.ErrorMessage = string.Empty;
         LoginByChannel();
     });
 }
Example #29
0
 public static void ExitGame()
 {
     PopupSystem.GetPopup <QuitPopup>(Define.PopupType.Quit).SetCallback(() =>
     {
         Debug.Log("Exit Game");
         Application.Quit();
     }, null);
     PopupSystem.OpenPopup(Define.PopupType.Quit);
     SoundManager.GetInstance().PlaySound(Define.SoundType.Click);
 }
Example #30
0
    public void GameStartOpening()
    {
        tileSystem.GameStartOpening();
        uiSystem.GameStartOpening();

        ReadyPopup popup = PopupSystem.GetPopup <ReadyPopup>(Define.PopupType.Ready);

        popup.SetCallback(GameStart);
        PopupSystem.OpenPopup(Define.PopupType.Ready);
    }