Exemplo n.º 1
0
 // Token: 0x06000293 RID: 659 RVA: 0x00009E94 File Offset: 0x00008294
 public void Enable()
 {
     if (!this.DeskPanel)
     {
         this.tmpBagList = SuperGameMaster.GetBagList_virtual();
         if (this.tmpBagList.Count == 0)
         {
             this.tmpBagList = SuperGameMaster.GetBagList();
         }
     }
     else
     {
         this.tmpBagList = SuperGameMaster.GetDeskList_virtual();
         if (this.tmpBagList.Count == 0)
         {
             this.tmpBagList = SuperGameMaster.GetDeskList();
         }
     }
     this.SetPanelButton();
     if (!this.DeskPanel)
     {
         this.ChangeBtnEnable(SuperGameMaster.GetStandby());
     }
     else
     {
         this.ResetBtnEnableCheck();
     }
     this.ChangeButton.SetActive(SuperGameMaster.GetHome());
 }
Exemplo n.º 2
0
    // Token: 0x0600028A RID: 650 RVA: 0x00009BF0 File Offset: 0x00007FF0
    public void CheckEmpty()
    {
        List <int> bagList  = SuperGameMaster.GetBagList();
        List <int> deskList = SuperGameMaster.GetDeskList();
        bool       active   = true;

        if (bagList[0] != -1)
        {
            active = false;
        }
        if (deskList[0] != -1 || deskList[1] != -1)
        {
            active = false;
        }
        if (!SuperGameMaster.tutorial.TutorialComplete())
        {
            active = false;
        }
        this.EmptyIcon.SetActive(active);
    }
Exemplo n.º 3
0
    // Token: 0x06000333 RID: 819 RVA: 0x00010DE4 File Offset: 0x0000F1E4
    public void getState()
    {
        if (this.pathNodeSelect)
        {
            this.setResultText("経路選択中のモードです。\n終了するには再度「経由」ボタンを押してください");
            return;
        }
        List <TravelSimulator.ItemEffect> list = new List <TravelSimulator.ItemEffect>();
        List <int> list2 = new List <int>(SuperGameMaster.GetBagList());

        foreach (int num in list2)
        {
            if (num != -1)
            {
                ItemDataFormat itemDataFormat = new ItemDataFormat();
                itemDataFormat = SuperGameMaster.sDataBase.get_ItemDB_forId(num);
                for (int i = 0; i < itemDataFormat.effectType.Length; i++)
                {
                    list.Add(new TravelSimulator.ItemEffect
                    {
                        type  = itemDataFormat.effectType[i],
                        elm   = itemDataFormat.effectElm[i],
                        value = itemDataFormat.effectValue[i]
                    });
                }
            }
        }
        int        num2  = 100;
        int        num3  = 0;
        List <int> list3 = new List <int>();

        for (int j = 0; j < 5; j++)
        {
            list3.Add(0);
        }
        int        num4  = 0;
        List <int> list4 = new List <int>();

        for (int k = 0; k < 5; k++)
        {
            list4.Add(0);
        }
        List <int> list5 = new List <int>();

        for (int l = 0; l < 4; l++)
        {
            list5.Add(0);
        }
        int  num5 = 0;
        bool flag = false;

        foreach (TravelSimulator.ItemEffect itemEffect in list)
        {
            switch (itemEffect.type)
            {
            case EffectType.HP:
                if (itemEffect.elm == EffectElm.H_UP)
                {
                    num2 += itemEffect.value;
                }
                if (itemEffect.elm == EffectElm.H_UP_RND)
                {
                    num3 += itemEffect.value;
                }
                break;

            case EffectType.AREA_DECIDE:
            {
                int num6 = itemEffect.elm - EffectElm.A_EAST;
                if (itemEffect.elm == EffectElm.A_NEW_AREA)
                {
                    num6 = 4;
                }
                if (itemEffect.value == -2)
                {
                    list3[num6] = -2;
                }
                if (itemEffect.value == -1 && list3[num6] != -2)
                {
                    list3[num6] = -1;
                }
                if (list3[num6] != -1 && list3[num6] != -2)
                {
                    List <int> list6;
                    int        index;
                    (list6 = list3)[index = num6] = list6[index] + itemEffect.value;
                }
                break;
            }

            case EffectType.ITEM_PERCENT:
                if (itemEffect.elm == EffectElm.I_UP)
                {
                    num4 += itemEffect.value;
                }
                break;

            case EffectType.WAY_SPEED:
            {
                int num6 = itemEffect.elm - EffectElm.W_MOUNTAIN + 1;
                if (itemEffect.elm == EffectElm.W_NONE)
                {
                    num6 = 0;
                }
                if (itemEffect.elm == EffectElm.W_ALL)
                {
                    num6 = list4.Count - 1;
                }
                List <int> list6;
                int        index2;
                (list6 = list4)[index2 = num6] = list6[index2] + itemEffect.value;
                break;
            }

            case EffectType.EVT_WAY:
                if (itemEffect.value > list5[itemEffect.elm - EffectElm.E_MOUNTAIN])
                {
                    list5[itemEffect.elm - EffectElm.E_MOUNTAIN] = itemEffect.value;
                }
                break;

            case EffectType.FRIENDSHIP:
                if (itemEffect.value == -1)
                {
                    num5 = -1;
                }
                if (num5 != -1)
                {
                    num5 += num5;
                }
                break;

            case EffectType.TELEPORT:
                if (itemEffect.value == 1)
                {
                    flag = true;
                }
                break;
            }
        }
        string text = "【装備:";

        foreach (int num7 in list2)
        {
            if (num7 == -1)
            {
                text += "(なし),";
            }
            else
            {
                ItemDataFormat itemDataFormat2 = new ItemDataFormat();
                itemDataFormat2 = SuperGameMaster.sDataBase.get_ItemDB_forId(num7);
                text            = text + itemDataFormat2.name + ",";
            }
        }
        text  = text.Remove(text.Length - 1, 1);
        text += "】\n";
        string text2;

        if (num3 == 0)
        {
            text2 = text;
            text  = string.Concat(new object[]
            {
                text2,
                " HP:",
                (int)((double)(100 * num2) * 0.01),
                "(",
                num2 - 100,
                "%) "
            });
        }
        else
        {
            text2 = text;
            text  = string.Concat(new object[]
            {
                text2,
                " HP:",
                (int)((double)(100 * num2) * 0.01),
                " ~ ",
                (double)(100 * (num2 + num3)) * 0.01,
                "(+",
                num2 - 100,
                " ~ ",
                num2 - 100 + num3,
                "%) "
            });
        }
        text += " / エリア出現率補正(+新): ";
        for (int m = 0; m < list3.Count; m++)
        {
            if (list3[m] == -1)
            {
                text += "確定1 ";
            }
            else if (list3[m] == -2)
            {
                text += "確定2 ";
            }
            else
            {
                text = text + list3[m] + "% ";
            }
        }
        text2 = text;
        text  = string.Concat(new object[]
        {
            text2,
            " / アイテム取得:逸品 + ",
            num4,
            "% 名物",
            60 + num4,
            " ( + ",
            num4,
            "%) "
        });
        text += " / 移動コスト(+All): ";
        for (int n = 0; n < list4.Count; n++)
        {
            text = text + list4[n] + "% ";
        }
        text += " / グレード: ";
        for (int num8 = 0; num8 < list5.Count; num8++)
        {
            text = text + list5[num8] + ",";
        }
        text  = text.Remove(text.Length - 1, 1);
        text += " / 遭遇率:(共通)";
        if (num5 == -1)
        {
            text += "確定 ";
        }
        else
        {
            text2 = text;
            text  = string.Concat(new object[]
            {
                text2,
                num5,
                "%(",
                num5,
                "%)"
            });
        }
        text = text + " / 瞬間移動:" + flag.ToString().Substring(0, 1);
        this.setResultText(text);
    }
Exemplo n.º 4
0
    // Token: 0x06000754 RID: 1876 RVA: 0x00031A3C File Offset: 0x0002FE3C
    public void UpdateTutorial()
    {
        if (this.TutorialComplete())
        {
            return;
        }
        if (this.SetScene == Scenes.NONE)
        {
            return;
        }
        Scenes setScene = this.SetScene;

        if (setScene != Scenes.MainOut)
        {
            if (setScene != Scenes.MainIn)
            {
                if (setScene == Scenes.Shop)
                {
                    UIMaster_Shop UI_Cmp = this.UI.GetComponent <UIMaster_Shop>();
                    switch (this.tutorialStep)
                    {
                    case Step.d1_SH_BuyItem:
                    {
                        int selectShopIndex = UI_Cmp.DisplayPanel.GetComponent <DisplayPanel>().GetSelectShopIndex();
                        if (selectShopIndex != -1 && !UI_Cmp.HelpUI.activeSelf && selectShopIndex != 0)
                        {
                            UI_Cmp.DisplayPanel.GetComponent <DisplayPanel>().unsetCursor();
                            UI_Cmp.DisplayPanel.GetComponent <DisplayPanel>().ResetSelectShopIndex();
                            UI_Cmp.DisplayPanel.GetComponent <DisplayPanel>().SetInfoPanelData(-1, Vector3.zero);
                            UI_Cmp.DisplayPanel.GetComponent <FlickCheaker>().stopFlick(true);
                            UI_Cmp.blockUI(true, new Color(0f, 0f, 0f, 0f));
                            HelpPanel help = UI_Cmp.HelpUI.GetComponent <HelpPanel>();
                            help.OpenPanel("はじめにお手頃な\n「えびづるのスコーン」を\n買ってみましょう");
                            help.ResetOnClick_Screen();
                            help.SetOnClick_Screen(delegate
                                {
                                    help.ClosePanel();
                                });
                            help.SetOnClick_Screen(delegate
                                {
                                    UI_Cmp.blockUI(false);
                                });
                            help.SetOnClick_Screen(delegate
                                {
                                    UI_Cmp.DisplayPanel.GetComponent <FlickCheaker>().stopFlick(false);
                                });
                        }
                        if (!UI_Cmp.BackFunc_GetStopFlag())
                        {
                            UI_Cmp.BackFunc_Stop(true);
                        }
                        if (SuperGameMaster.FindItemStock(0) >= 1)
                        {
                            this.StepTutorial(true);
                        }
                        break;
                    }

                    case Step.d2_SH_GoHome:
                    {
                        int selectShopIndex2 = UI_Cmp.DisplayPanel.GetComponent <DisplayPanel>().GetSelectShopIndex();
                        if (selectShopIndex2 != -1 && !UI_Cmp.HelpUI.activeSelf)
                        {
                            UI_Cmp.DisplayPanel.GetComponent <DisplayPanel>().unsetCursor();
                            UI_Cmp.DisplayPanel.GetComponent <DisplayPanel>().ResetSelectShopIndex();
                            UI_Cmp.DisplayPanel.GetComponent <DisplayPanel>().SetInfoPanelData(-1, Vector3.zero);
                        }
                        break;
                    }
                    }
                }
            }
            else
            {
                UIMaster_MainIn     component  = this.UI.GetComponent <UIMaster_MainIn>();
                ObjectMaster_MainIn component2 = this.Obj.GetComponent <ObjectMaster_MainIn>();
                if (component2.Frog.activeSelf)
                {
                    component2.Frog.SetActive(false);
                }
                if (component.BagDeskUI.GetComponent <BagDeskPanels>().EmptyIcon.activeSelf)
                {
                    component.BagDeskUI.GetComponent <BagDeskPanels>().EmptyIcon.SetActive(false);
                }
                Step step = this.tutorialStep;
                if (step != Step.e0_MI_OpenBag)
                {
                    if (step != Step.e1_MI_ReStart)
                    {
                        if (step == Step.b0_MI_GoOut)
                        {
                            this.seTime += Time.deltaTime;
                            if (this.seTime > 2f && this.seTime - Time.deltaTime < 2f)
                            {
                                HelpPanel component3 = component.HelpUI.GetComponent <HelpPanel>();
                                if (!component3.HelpWindow.activeSelf)
                                {
                                    component3.ClosePanel();
                                    component3.ActionStock_Next();
                                }
                            }
                        }
                    }
                }
                else
                {
                    if (component2.Frog.activeSelf)
                    {
                        component2.Frog.SetActive(false);
                    }
                    if (component.BagDeskUI.activeSelf)
                    {
                        component.BagDeskUI.GetComponent <FlickCheaker>().stopFlick(true);
                        if (!component.BagDeskUI.GetComponent <BagDeskPanels>().BagPanelUI.GetComponent <BagPanel>().ItemView.activeSelf)
                        {
                            if (!SuperGameMaster.GetStandby())
                            {
                                List <int> tmpListAll = component.BagDeskUI.GetComponent <BagDeskPanels>().Get_tmpListAll();
                                if (tmpListAll[0] == 0 && tmpListAll[1] == 1000)
                                {
                                    component.BagCompleteCursor.GetComponentInChildren <Image>().enabled = true;
                                }
                                else
                                {
                                    component.BagCompleteCursor.GetComponentInChildren <Image>().enabled = false;
                                }
                            }
                            else
                            {
                                component.BagCompleteCursor.GetComponentInChildren <Image>().enabled = false;
                            }
                        }
                        else
                        {
                            component.BagCompleteCursor.GetComponentInChildren <Image>().enabled = false;
                        }
                    }
                    else if (!component.BagMarkUI.activeSelf && !component.HelpUI.activeSelf)
                    {
                        component.BagCompleteCursor.GetComponentInChildren <Image>().enabled = false;
                        List <int> bagList = SuperGameMaster.GetBagList();
                        if (bagList[0] == 0 && bagList[1] == 1000 && SuperGameMaster.GetStandby())
                        {
                            SuperGameMaster.evtMgr.delete_Act_Timer_EvtList_forType(TimerEvent.Type.GoTravel);
                            SuperGameMaster.evtMgr.delete_Act_Timer_EvtList_forType(TimerEvent.Type.BackHome);
                            SuperGameMaster.evtMgr.delete_Act_Timer_EvtList_forType(TimerEvent.Type.Picture);
                            SuperGameMaster.evtMgr.delete_Act_Timer_EvtList_forType(TimerEvent.Type.Drift);
                            SuperGameMaster.evtMgr.delete_Act_Timer_EvtList_forType(TimerEvent.Type.Return);
                            SuperGameMaster.travel.GoTravel(536870911, 1);
                            int index = SuperGameMaster.evtMgr.search_TimerEvtIndex_forType(TimerEvent.Type.BackHome);
                            EventTimerFormat eventTimerFormat = SuperGameMaster.evtMgr.get_TimerEvt(index);
                            List <int>       list             = new List <int>(eventTimerFormat.evtValue);
                            if (list.Count >= 6 && list[4] >= 10000)
                            {
                                list[4] = 3009;
                            }
                            SuperGameMaster.evtMgr.set_TimerEvt_forId(eventTimerFormat.id, list);
                            SuperGameMaster.evtMgr.SetTime_TimerEvt(TimerEvent.Type.GoTravel, 0, 536870911);
                            SuperGameMaster.SetStandby(true);
                            SuperGameMaster.SetLastTravelTime(536870911);
                            SuperGameMaster.SetStandbyWait(0);
                            component.BagCompleteCursor.SetActive(false);
                            this.StepTutorial(true);
                        }
                        else
                        {
                            SuperGameMaster.saveData.lastTravelTime = SuperGameMaster.saveData.restTime;
                            SuperGameMaster.evtMgr.delete_Act_Timer_EvtList_forType(TimerEvent.Type.GoTravel);
                            SuperGameMaster.evtMgr.delete_Act_Timer_EvtList_forType(TimerEvent.Type.BackHome);
                            SuperGameMaster.evtMgr.delete_Act_Timer_EvtList_forType(TimerEvent.Type.Picture);
                            SuperGameMaster.evtMgr.delete_Act_Timer_EvtList_forType(TimerEvent.Type.Drift);
                            SuperGameMaster.evtMgr.delete_Act_Timer_EvtList_forType(TimerEvent.Type.Return);
                            component.blockUI(false);
                            component.TutorialUBlock();
                            component.BagMarkUI.SetActive(true);
                        }
                    }
                }
            }
        }
        else
        {
            UIMaster_MainOut     UI_Cmp     = this.UI.GetComponent <UIMaster_MainOut>();
            ObjectMaster_MainOut component4 = this.Obj.GetComponent <ObjectMaster_MainOut>();
            Step step2 = this.tutorialStep;
            switch (step2 + 1)
            {
            case Step.a0_MO_FrogTap:
                this.seTime += Time.deltaTime;
                if (this.seTime % 5f < (this.seTime - Time.deltaTime) % 5f || this.seTime - Time.deltaTime == 0f)
                {
                    SuperGameMaster.audioMgr.PlaySE(Define.SEDict["SE_Sparrow"]);
                }
                if (Input.GetKeyDown(KeyCode.Escape) && !UI_Cmp.ConfilmUI.activeSelf)
                {
                    if (!UI_Cmp.Title_StartUI.activeSelf)
                    {
                        if (UI_Cmp.WebViewUI.activeSelf)
                        {
                            UI_Cmp.WebViewUI.GetComponent <WebViewPanel>().ClosePanel();
                        }
                        else
                        {
                            UI_Cmp.Title_StartUI.SetActive(true);
                            UI_Cmp.Title_PolicyUI.SetActive(false);
                        }
                        SuperGameMaster.audioMgr.PlaySE(Define.SEDict["SE_Cancel"]);
                    }
                    else
                    {
                        ConfilmPanel confilm = UI_Cmp.ConfilmUI.GetComponent <ConfilmPanel>();
                        confilm.OpenPanel_YesNo("アプリケーションを終了しますか?");
                        confilm.ResetOnClick_Yes();
                        confilm.SetOnClick_Yes(delegate
                        {
                            confilm.ClosePanel();
                        });
                        confilm.SetOnClick_Yes(delegate
                        {
                            SuperGameMaster.SaveData();
                        });
                        confilm.SetOnClick_Yes(delegate
                        {
                            Application.Quit();
                        });
                        confilm.ResetOnClick_No();
                        confilm.SetOnClick_No(delegate
                        {
                            confilm.ClosePanel();
                        });
                    }
                }
                break;

            case Step.a1_MO_FrogName:
                this.seTime += Time.deltaTime;
                if (this.seTime > 0f && this.seTime - Time.deltaTime < 0f)
                {
                    this.seTime = 0f;
                }
                this.seTime2 += Time.deltaTime;
                if (this.seTime2 > 4f)
                {
                    component4.Call_FlickMove(new Vector2(Mathf.Clamp((1.92f - Camera.main.transform.localPosition.x) / 60f, 1E-05f, 0.1f), 0f));
                }
                if (this.seTime2 > 7f)
                {
                    if (Input.GetMouseButtonDown(0))
                    {
                        Vector2 point = Camera.main.ScreenToWorldPoint(Input.mousePosition);
                        if (component4.Frog.GetComponent <Collider2D>().OverlapPoint(point))
                        {
                            this.StepTutorial(false);
                            UI_Cmp.FrogCursorUI.SetActive(false);
                        }
                    }
                    else if (this.seTime2 > 9f)
                    {
                        this.StepTutorial(false);
                        UI_Cmp.FrogCursorUI.SetActive(false);
                    }
                }
                if (this.seTime2 >= 2f && this.seTime2 - Time.deltaTime < 2f)
                {
                    SuperGameMaster.audioMgr.PlaySE(Define.SEDict["SE_Grassy"]);
                }
                if (this.seTime2 % 3f < (this.seTime2 - Time.deltaTime) % 3f && this.seTime2 > 7f)
                {
                    SuperGameMaster.audioMgr.PlaySE(Define.SEDict["SE_Frog"]);
                }
                if (this.seTime % 5f < (this.seTime - Time.deltaTime) % 5f || this.seTime - Time.deltaTime == 0f)
                {
                    SuperGameMaster.audioMgr.PlaySE(Define.SEDict["SE_Sparrow"]);
                }
                break;

            case Step.a2_MO_GoHome:
                if (this.seTime != 0f)
                {
                    this.seTime += Time.deltaTime;
                    UI_Cmp.blockUI(true, new Color(0f, 0f, 0f, this.seTime));
                    if (this.seTime > 1f)
                    {
                        UI_Cmp.blockUI(true, new Color(0f, 0f, 0f, 1f));
                        this.seTime = 0f;
                        UI_Cmp.FrogNameUI.GetComponent <FrogNamePanel>().OpenNamePanel();
                        component4.Frog.SetActive(false);
                    }
                }
                break;

            case Step.b0_MI_GoOut:
                this.seTime += Time.deltaTime;
                if (this.seTime >= 0.5f && this.seTime - Time.deltaTime < 0.5f)
                {
                    SuperGameMaster.audioMgr.PlaySE(Define.SEDict["SE_Frog"]);
                }
                if (this.seTime <= 1f)
                {
                    UI_Cmp.blockUI(true, new Color(0f, 0f, 0f, 1f - this.seTime));
                }
                if (this.seTime > 1f && this.seTime - Time.deltaTime < 1f)
                {
                    UI_Cmp.blockUI(true, new Color(0f, 0f, 0f, 0f));
                    HelpPanel help = UI_Cmp.HelpUI.GetComponent <HelpPanel>();
                    help.OpenPanel(string.Empty);
                    help.ResetOnClick_Screen();
                    help.SetOnClick_Screen(delegate
                    {
                        help.ClosePanel();
                    });
                    help.SetOnClick_Screen(delegate
                    {
                        help.ActionStock_Next();
                    });
                    help.ActionStock_New("おうちのなかに入っていきました\nなかをのぞいてみましょう");
                    help.ActionStock_Add(delegate
                    {
                        help.ClosePanel();
                    });
                    help.ActionStock_Add(delegate
                    {
                        UI_Cmp.blockUI(false);
                    });
                    help.ActionStock_Add(delegate
                    {
                        UI_Cmp.TutorialUBlock();
                    });
                    help.ActionStock_Add(delegate
                    {
                        UI_Cmp.MoveCursorUI.SetActive(true);
                    });
                    help.ActionStock_Add(delegate
                    {
                        UI_Cmp.MoveUI.GetComponent <MovePanel>().InBtn.GetComponent <Button>().onClick.AddListener(delegate
                        {
                            this.StepTutorial(true);
                        });
                    });
                    help.ActionStock_Add(delegate
                    {
                        UI_Cmp.MoveUI.GetComponent <MovePanel>().InBtn.GetComponent <Button>().onClick.AddListener(delegate
                        {
                            UI_Cmp.MoveUI.GetComponent <MovePanel>().InBtn.GetComponent <Button>().enabled = true;
                        });
                    });
                    help.ActionStock_Add(delegate
                    {
                        UI_Cmp.MoveUI.GetComponent <MovePanel>().InBtn.GetComponent <Button>().onClick.AddListener(delegate
                        {
                            SuperGameMaster.audioMgr.StopSE();
                        });
                    });
                    help.ActionStock_Add(delegate
                    {
                        UI_Cmp.MoveUI.GetComponent <MovePanel>().InBtn.GetComponent <Button>().onClick.AddListener(delegate
                        {
                            SuperGameMaster.audioMgr.PlaySE(Define.SEDict["SE_Knock"]);
                        });
                    });
                    help.ActionStock_Add(delegate
                    {
                        UI_Cmp.MoveUI.GetComponent <MovePanel>().InBtn.GetComponent <Button>().onClick.AddListener(delegate
                        {
                            this.seTime = 0f;
                        });
                    });
                }
                if (this.seTime > 3f && this.seTime - Time.deltaTime < 3f)
                {
                    HelpPanel component5 = UI_Cmp.HelpUI.GetComponent <HelpPanel>();
                    if (!component5.HelpWindow.activeSelf)
                    {
                        component5.ClosePanel();
                        component5.ActionStock_Next();
                    }
                }
                break;

            case Step.c0_MO_GetStandby:
                if (this.seTime == 0f)
                {
                    UI_Cmp.setFadeOut(99999f);
                    UI_Cmp.FadeUI.GetComponent <Image>().color = new Color(0f, 0f, 0f, 0f);
                }
                this.seTime += Time.deltaTime;
                if (this.seTime >= 1f && this.seTime - Time.deltaTime < 1f)
                {
                    UI_Cmp.setFadeOut(0.25f);
                    SuperGameMaster.audioMgr.PlaySE(Define.SEDict["SE_Move"]);
                }
                break;

            case Step.c1_MO_GetClover:
                if (!UI_Cmp.HelpUI.activeSelf)
                {
                    if (Input.GetMouseButtonUp(0))
                    {
                        component4.Call_FlickInit();
                    }
                    this.Obj.GetComponent <FlickCheaker>().FlickUpdate();
                    component4.Call_FlickMove();
                }
                if (Camera.main.transform.position.x <= -1.9f && UI_Cmp.CloverCursorUI.activeSelf)
                {
                    UI_Cmp.CloverCursorUI.SetActive(false);
                    HelpPanel help = UI_Cmp.HelpUI.GetComponent <HelpPanel>();
                    help.OpenPanel("スライド操作でみつ葉のクローバーを\n収穫しましょう");
                    help.ResetOnClick_Screen();
                    help.SetOnClick_Screen(delegate
                    {
                        help.ClosePanel();
                    });
                    help.SetOnClick_Screen(delegate
                    {
                        this.StepTutorial(false);
                    });
                }
                break;

            case Step.c2_MO_GoShop:
                if (Input.GetMouseButton(0))
                {
                    if (Camera.main.transform.position.x > 0f)
                    {
                        UI_Cmp.CloverCursorUI.GetComponentInChildren <Image>().enabled = true;
                    }
                    else
                    {
                        UI_Cmp.CloverCursorUI.GetComponentInChildren <Image>().enabled = false;
                    }
                }
                if (!UI_Cmp.HelpUI.activeSelf && !UI_Cmp.ConfilmUI.activeSelf)
                {
                    component4.ScrollAndCloverCheck();
                    component4.CloverFarm.GetComponent <CloverFarm>().CloverProc();
                    if (SuperGameMaster.GetFirstFlag(Flag.TUTORIAL_CLOVER) && SuperGameMaster.GetFirstFlag(Flag.TUTORIAL_FOURLEAF) && SuperGameMaster.FindItemStock(1000) + SuperGameMaster.CloverPointStock() >= SuperGameMaster.GetCloverList().Count)
                    {
                        if (SuperGameMaster.FindItemStock(1000) > 10)
                        {
                            SuperGameMaster.getCloverPoint(10);
                        }
                        this.StepTutorial(true);
                    }
                }
                if (!UI_Cmp.HelpUI.activeSelf && !UI_Cmp.ConfilmUI.activeSelf && !SuperGameMaster.GetFirstFlag(Flag.TUTORIAL_CLOVER) && SuperGameMaster.CloverPointStock() >= 1)
                {
                    UI_Cmp.CloverMarkUI.SetActive(true);
                    HelpPanel help = UI_Cmp.HelpUI.GetComponent <HelpPanel>();
                    help.OpenPanel("収穫したみつ葉のクローバーは\nこちらで確認することができます");
                    help.ResetOnClick_Screen();
                    help.SetOnClick_Screen(delegate
                    {
                        help.ClosePanel();
                    });
                    help.SetOnClick_Screen(delegate
                    {
                        UI_Cmp.CloverMarkUI.SetActive(false);
                    });
                    help.SetOnClick_Screen(delegate
                    {
                        help.ActionStock_Next();
                    });
                    help.ActionStock_New("畑のクローバーを全て収穫しましょう");
                    help.ActionStock_Add(delegate
                    {
                        help.ClosePanel();
                    });
                    SuperGameMaster.SetFirstFlag(Flag.TUTORIAL_CLOVER);
                }
                if (!UI_Cmp.HelpUI.activeSelf && !UI_Cmp.ConfilmUI.activeSelf && !SuperGameMaster.GetFirstFlag(Flag.TUTORIAL_FOURLEAF) && SuperGameMaster.FindItemStock(1000) >= 1)
                {
                    ConfilmPanel confilm = UI_Cmp.ConfilmUI.GetComponent <ConfilmPanel>();
                    confilm.OpenPanel(string.Empty);
                    confilm.AddContents(UnityEngine.Object.Instantiate <GameObject>(component4.CloverFarm.GetComponent <CloverFarm>().AddConfirm_pref));
                    confilm.ResetOnClick_Screen();
                    confilm.SetOnClick_Screen(delegate
                    {
                        confilm.ClosePanel();
                    });
                    confilm.SetOnClick_Screen(delegate
                    {
                        UI_Cmp.BackFunc_Stop(true);
                    });
                    SuperGameMaster.SetFirstFlag(Flag.TUTORIAL_FOURLEAF);
                }
                break;

            case Step._StepMax:
                if (!UI_Cmp.ResultUI.activeSelf && !UI_Cmp.HelpUI.activeSelf && !UI_Cmp.ConfilmUI.activeSelf && !SuperGameMaster.tutorial.TutorialComplete())
                {
                    HelpPanel    help    = UI_Cmp.HelpUI.GetComponent <HelpPanel>();
                    ConfilmPanel confilm = UI_Cmp.ConfilmUI.GetComponent <ConfilmPanel>();
                    help.OpenPanel(string.Concat(new string[]
                    {
                        string.Empty,
                        SuperGameMaster.GetFrogName(),
                        "は旅立ちました\n",
                        SuperGameMaster.GetFrogName(),
                        "が帰ってくるには\nしばらく時間がかかります\n今回のしたくなら数時間ほどで\n帰ってきそうです"
                    }));
                    help.ResetOnClick_Screen();
                    help.SetOnClick_Screen(delegate
                    {
                        help.ClosePanel();
                    });
                    help.SetOnClick_Screen(delegate
                    {
                        help.ActionStock_Next();
                    });
                    help.ActionStock_New("※ヘルプで通知をONに設定しておくと\n" + SuperGameMaster.GetFrogName() + "が帰ってきたときに\n通知が入ります");
                    help.ActionStock_Add(delegate
                    {
                        help.ClosePanel();
                    });
                    help.ActionStock_Add(delegate
                    {
                        help.ActionStock_Next();
                    });
                    help.ActionStock_New(SuperGameMaster.GetFrogName() + "は旅のしたくがなくても\n自由にでかけていきますが\n今回のように旅のしたくを\n手伝ってあげていると\n旅の様子をうつした<color=#61a8c7><b>写真</b></color>や\n手に入れた各地の<color=#61a8c7><b>おみやげ</b></color>を\nプレゼントしてくれます");
                    help.ActionStock_Add(delegate
                    {
                        help.ClosePanel();
                    });
                    help.ActionStock_Add(delegate
                    {
                        help.ActionStock_Next();
                    });
                    help.ActionStock_New(SuperGameMaster.GetFrogName() + "が出かけている間に\n次の旅に備えて\nみつ葉のクローバーを収穫して\nもちものを用意しておきましょう");
                    help.ActionStock_Add(delegate
                    {
                        help.ClosePanel();
                    });
                    help.ActionStock_Add(delegate
                    {
                        help.ActionStock_Next();
                    });
                    help.ActionStock_New("チュートリアルはここまでです\n" + SuperGameMaster.GetFrogName() + "との\n旅をお楽しみください");
                    help.ActionStock_Add(delegate
                    {
                        help.ClosePanel();
                    });
                    help.ActionStock_Add(delegate
                    {
                        confilm.OpenPanel(string.Empty);
                    });
                    help.ActionStock_Add(delegate
                    {
                        confilm.AddContents(UnityEngine.Object.Instantiate <GameObject>(UI_Cmp.AddConfirm_pref));
                    });
                    help.ActionStock_Add(delegate
                    {
                        confilm.ResetOnClick_Screen();
                    });
                    help.ActionStock_Add(delegate
                    {
                        confilm.SetOnClick_Screen(delegate
                        {
                            confilm.ClosePanel();
                        });
                    });
                    help.ActionStock_Add(delegate
                    {
                        confilm.SetOnClick_Screen(delegate
                        {
                            UI_Cmp.blockUI(false);
                        });
                    });
                    help.ActionStock_Add(delegate
                    {
                        confilm.SetOnClick_Screen(delegate
                        {
                            UI_Cmp.freezeObject(false);
                        });
                    });
                    help.ActionStock_Add(delegate
                    {
                        confilm.SetOnClick_Screen(delegate
                        {
                            UI_Cmp.BackFunc_Stop(false);
                        });
                    });
                    help.ActionStock_Add(delegate
                    {
                        confilm.SetOnClick_Screen(delegate
                        {
                            this.FinishTutorial();
                        });
                    });
                    SuperGameMaster.evtMgr.delete_Act_Timer_EvtList_forType(TimerEvent.Type.Drift);
                }
                break;
            }
        }
    }
Exemplo n.º 5
0
    // Token: 0x060003DB RID: 987 RVA: 0x000184F4 File Offset: 0x000168F4
    public void CreateButton(Item.Type itemType)
    {
        RectTransform component = this.contentsList.GetComponent <RectTransform>();

        this.DeleteButtonAll();
        List <int> list = new List <int>();

        if (this.listMode == ItemScrollView.Mode.Equip)
        {
            list = this.CallObj.GetComponent <BagPanel>().Get_tmpItemListAll();
        }
        else
        {
            list.AddRange(SuperGameMaster.GetBagList());
            list.AddRange(SuperGameMaster.GetDeskList());
        }
        using (List <ItemListFormat> .Enumerator enumerator = SuperGameMaster.saveData.ItemList.GetEnumerator())
        {
            while (enumerator.MoveNext())
            {
                ItemListFormat item           = enumerator.Current;
                ItemDataFormat itemDataFormat = SuperGameMaster.sDataBase.get_ItemDB_forId(item.id);
                if (itemDataFormat != null)
                {
                    if (itemType == Item.Type.NONE || itemDataFormat.type == itemType)
                    {
                        GameObject gameObject;
                        if (itemDataFormat.type != Item.Type.Specialty)
                        {
                            gameObject = UnityEngine.Object.Instantiate <GameObject>(this.btnPref);
                            gameObject.transform.SetParent(component, false);
                            gameObject.GetComponent <ItemButton>().CngItemName(itemDataFormat.name);
                            gameObject.GetComponent <ItemButton>().CngItemInfo(itemDataFormat.info);
                        }
                        else
                        {
                            gameObject = UnityEngine.Object.Instantiate <GameObject>(this.spe_btnPref);
                            gameObject.transform.SetParent(this.spe_contentsList.GetComponent <RectTransform>(), false);
                        }
                        gameObject.GetComponent <ItemButton>().setItemId(itemDataFormat.id, itemDataFormat.type);
                        gameObject.GetComponent <ItemButton>().CngImage(itemDataFormat.img);
                        gameObject.GetComponent <ItemButton>().ItemScrollView = base.gameObject;
                        ItemScrollView.Mode mode = this.listMode;
                        if (mode != ItemScrollView.Mode.View)
                        {
                            if (mode != ItemScrollView.Mode.Present)
                            {
                                if (mode == ItemScrollView.Mode.Equip)
                                {
                                    if (itemDataFormat.spend)
                                    {
                                        int num = item.stock;
                                        if (list.FindIndex((int itemId) => itemId.Equals(item.id)) != -1)
                                        {
                                            foreach (int num2 in list)
                                            {
                                                if (num2 == item.id)
                                                {
                                                    num--;
                                                }
                                            }
                                        }
                                        gameObject.GetComponent <ItemButton>().CngStockNum(num);
                                        if (this.CallObj.GetComponent <BagPanel>().tmpBagList[this.setId] == itemDataFormat.id)
                                        {
                                            gameObject.GetComponent <ItemButton>().Fade(new Color(0.7f, 0.7f, 0.7f));
                                            gameObject.GetComponent <ItemButton>().SetCheckImage(true);
                                            gameObject.GetComponent <ItemButton>().setItemId(-2, Item.Type._ElmMax);
                                        }
                                        else if (num <= 0)
                                        {
                                            UnityEngine.Object.Destroy(gameObject);
                                        }
                                    }
                                    else
                                    {
                                        if (list.FindIndex((int itemId) => itemId.Equals(item.id)) != -1)
                                        {
                                            gameObject.GetComponent <Button>().interactable = false;
                                            if (this.CallObj.GetComponent <BagPanel>().tmpBagList[this.setId] == itemDataFormat.id)
                                            {
                                                gameObject.GetComponent <ItemButton>().SetCheckImage(true);
                                                gameObject.GetComponent <ItemButton>().Fade(new Color(0.7f, 0.7f, 0.7f));
                                                gameObject.GetComponent <ItemButton>().setItemId(-2, Item.Type._ElmMax);
                                                gameObject.GetComponent <Button>().interactable = true;
                                            }
                                            else
                                            {
                                                gameObject.GetComponent <ItemButton>().Fade(new Color(0.7f, 0.7f, 0.7f));
                                            }
                                        }
                                        gameObject.GetComponent <ItemButton>().CngStockNum(-2);
                                    }
                                }
                            }
                            else if (itemDataFormat.spend)
                            {
                                int num3 = item.stock;
                                if (list.FindIndex((int itemId) => itemId.Equals(item.id)) != -1)
                                {
                                    foreach (int num4 in list)
                                    {
                                        if (num4 == item.id)
                                        {
                                            num3--;
                                        }
                                    }
                                }
                                if (num3 > 0)
                                {
                                    gameObject.GetComponent <ItemButton>().CngStockNum(num3);
                                }
                                else
                                {
                                    UnityEngine.Object.Destroy(gameObject);
                                }
                            }
                            else
                            {
                                gameObject.GetComponent <ItemButton>().CngStockNum(-2);
                            }
                        }
                        else
                        {
                            gameObject.GetComponent <Button>().enabled = false;
                            if (itemDataFormat.spend)
                            {
                                int num5 = item.stock;
                                if (list.FindIndex((int itemId) => itemId.Equals(item.id)) != -1)
                                {
                                    foreach (int num6 in list)
                                    {
                                        if (num6 == item.id)
                                        {
                                            num5--;
                                        }
                                    }
                                }
                                if (num5 > 0)
                                {
                                    gameObject.GetComponent <ItemButton>().CngStockNum(num5);
                                }
                                else
                                {
                                    UnityEngine.Object.Destroy(gameObject);
                                }
                            }
                            else
                            {
                                gameObject.GetComponent <ItemButton>().CngStockNum(-2);
                            }
                        }
                    }
                }
            }
        }
    }
Exemplo n.º 6
0
    // Token: 0x060003D1 RID: 977 RVA: 0x00017DE4 File Offset: 0x000161E4
    public void GetBagList()
    {
        string text = "\n";

        text += "\n\n【支度リスト】 (bagList/DeskList) ~~~~~~~~~~~ \n";
        text += "\u3000かばん:\n";
        foreach (int num in SuperGameMaster.GetBagList())
        {
            if (num == -1)
            {
                text += "\u3000\u3000\u3000\u3000\u3000- ,\n";
            }
            else
            {
                ItemDataFormat itemDataFormat = new ItemDataFormat();
                itemDataFormat = SuperGameMaster.sDataBase.get_ItemDB_forId(num);
                text           = text + "\u3000\u3000\u3000\u3000\u3000" + itemDataFormat.name + ",\n";
            }
        }
        text += "\u3000つくえ:\n";
        foreach (int num2 in SuperGameMaster.GetDeskList())
        {
            if (num2 == -1)
            {
                text += "\u3000\u3000\u3000\u3000\u3000\u3000- ,\n";
            }
            else
            {
                ItemDataFormat itemDataFormat2 = new ItemDataFormat();
                itemDataFormat2 = SuperGameMaster.sDataBase.get_ItemDB_forId(num2);
                text            = text + "\u3000\u3000\u3000\u3000\u3000" + itemDataFormat2.name + ",\n";
            }
        }
        text += "\n~~~~~~~~~(仮想リスト)~~~~~~~~~\n";
        text += "\u3000かばん:\n";
        foreach (int num3 in SuperGameMaster.GetBagList_virtual())
        {
            if (num3 == -1)
            {
                text += "\u3000\u3000\u3000\u3000\u3000\u3000- ,\n";
            }
            else
            {
                ItemDataFormat itemDataFormat3 = new ItemDataFormat();
                itemDataFormat3 = SuperGameMaster.sDataBase.get_ItemDB_forId(num3);
                text            = text + "\u3000\u3000\u3000\u3000\u3000" + itemDataFormat3.name + ",\n";
            }
        }
        text += "\u3000つくえ:\n";
        foreach (int num4 in SuperGameMaster.GetDeskList_virtual())
        {
            if (num4 == -1)
            {
                text += "\u3000\u3000\u3000\u3000\u3000\u3000- ,\n";
            }
            else
            {
                ItemDataFormat itemDataFormat4 = new ItemDataFormat();
                itemDataFormat4 = SuperGameMaster.sDataBase.get_ItemDB_forId(num4);
                text            = text + "\u3000\u3000\u3000\u3000\u3000" + itemDataFormat4.name + ",\n";
            }
        }
        this.Result_text.GetComponent <Text>().text = text;
    }