public void Parse(GameClient Session, ClientPacket Packet)
        {
            if (!Session.GetHabbo().HasFuse("fuse_helptool"))
            {
                return;
            }

            GuideManager guideManager = ButterflyEnvironment.GetGame().GetGuideManager();
            bool         onDuty       = Packet.PopBoolean();

            Packet.PopBoolean();
            Packet.PopBoolean();
            Packet.PopBoolean();

            if (onDuty && !Session.GetHabbo().OnDuty)
            {
                guideManager.AddGuide(Session.GetHabbo().Id);
                Session.GetHabbo().OnDuty = true;
            }
            else
            {
                guideManager.RemoveGuide(Session.GetHabbo().Id);
                Session.GetHabbo().OnDuty = false;
            }

            ServerPacket HelpTool = new ServerPacket(ServerPacketHeader.HelperToolMessageComposer);

            HelpTool.WriteBoolean(Session.GetHabbo().OnDuty);
            HelpTool.WriteInteger(guideManager.GuidesCount);
            HelpTool.WriteInteger(0);
            HelpTool.WriteInteger(0);
            Session.SendPacket(HelpTool);
        }
Beispiel #2
0
        private void LoveCoaxSleepGuide()
        {
            var isPass4_12     = GuideManager.IsPass4_12();
            var coaxSleepGuide = GuideManager.CurFunctionGuide(GuideTypePB.LoveGuideCoaxSleep);

            if (isPass4_12 && coaxSleepGuide == FunctionGuideStage.Function_CoaxSleep_OneStage)
            {
                gameObject.Show();

                var parent = transform.Find("StartPathBtnContainer");
                var btn    = parent.Find("AppointmentBtn");
                GuideArrow.DoAnimation(btn);
                parent.gameObject.Show();
                btn.gameObject.Show();

                PointerClickListener.Get(btn.gameObject).onClick = go =>
                {
                    SendMessage(new Message(MessageConst.CMD_APPOINTMENT_JUMPCHOOSEROLE,
                                            Message.MessageReciverType.UnvarnishedTransmission));
                    parent.gameObject.Hide();
                    btn.gameObject.Hide();
                    gameObject.Hide();
                };
            }
        }
Beispiel #3
0
    private long GetLeftDrawTime(DrawPoolTypePB poolType, DrawTypePB drawTypePB)
    {
        if (GuideManager.GetRemoteGuideStep(GuideTypePB.MainGuide) < GuideConst.MainLineStep_OnClick_GemDrawCard)
        {
            //GuideManager.SetRemoteGuideStep(GuideTypePB.MainGuide, GuideConst.MainStep_PhoneSms_End);
            return(0);
        }


        long curTimeStamp = ClientTimer.Instance.GetCurrentTimeStamp();

        if (poolType == DrawPoolTypePB.DrawPoolCommon)
        {
            switch (drawTypePB)
            {
            case DrawTypePB.ByGem:

                return(_gemRefreshTime - curTimeStamp);

            case DrawTypePB.ByGold:
                return(_goldRefreshTime - curTimeStamp);

            default:
                return(long.MaxValue);
            }
        }
        else
        {
            return(long.MaxValue);
        }
    }
Beispiel #4
0
        private void Level1_1ToLevel1_3Stage()
        {
            LevelVo level1_1 = GlobalData.LevelModel.FindLevel("1-1");
            LevelVo level1_2 = GlobalData.LevelModel.FindLevel("1-2");
            LevelVo level1_3 = GlobalData.LevelModel.FindLevel("1-3");

            if (!level1_1.IsPass)
            {
                SetNpcHint(true, I18NManager.Get("Guide_MainLine1_1_Star"));
                OnClickLevel("1-1");
            }
            else if (!level1_2.IsPass)
            {
                GuideManager.SetPassLevelStep("1-1");
                SetNpcHint(true, I18NManager.Get("Guide_MainLine1_2_Star"));
                OnClickLevel("1-2");
            }
            else if (!level1_3.IsPass)
            {
                GuideManager.SetPassLevelStep("1-2");
                OnClickLevel("1-3");
            }
            else if (level1_3.IsPass)
            {
                GuideManager.SetPassLevelStep("1-3");
                Level1_3End();
            }
        }
Beispiel #5
0
    public void SetRemoteGuideStep(GuideTypePB guideType, int step)
    {
        //step = 1000;
        var currentStep = GuideManager.GetRemoteGuideStep(guideType);

        //引导步骤大于要设置的步骤的时候不做处理
        Debug.LogError("currentStep" + currentStep + "step" + step);
        if (currentStep >= step)
        {
            return;
        }
        LoadingOverlay.Instance.Show();

        var req = new GuideReq
        {
            GuideType = guideType,
            GuideId   = step
        };

        Debug.LogError("guideType:" + guideType + "  step:" + step);

        var buffer = NetWorkManager.GetByteData(req);

        NetWorkManager.Instance.Send <GuideRes>(CMD.USERC_GUIDE, buffer, OnSetGuideSuccess);
    }
Beispiel #6
0
    void Start()
    {
        var finishBtn = transform.Find("FinishBtn").GetComponent <Button>();

        if (finishBtn != null)
        {
            finishBtn.onClick.AddListener(delegate()
            {
                base.Close();
                SendMessage(new Message(MessageConst.CMD_BATTLE_FINISH));
            });
        }

        var tryAgainBtn = transform.Find("TryAgainBtn").GetComponent <Button>();

        if (tryAgainBtn != null)
        {
            tryAgainBtn.onClick.AddListener(delegate()
            {
                if (!GuideManager.IsPass1_9())
                {
                    FlowText.ShowMessage(I18NManager.Get("Guide_Battle6", "1-9"));
                    return;
                }

                SendMessage(new Message(MessageConst.CMD_BATTLE_RESTART));
            });
        }
    }
Beispiel #7
0
 public override void Init()
 {
     GuideManager.RegisterModule(this);
     _lovePanel = new LovePanel();
     _lovePanel.Init(this);
     _lovePanel.Show(0);
 }
Beispiel #8
0
    public override void OnMessage(Message message)
    {
        var name = message.Name;
        var body = message.Params;

        switch (name)
        {
        case MessageConst.MOUDLE_GUIDE_END_LOCAL:
            //本地记录的引导结束
            _currentPanel.Destroy();
            GuideManager.SetStepState(GuideStae.Close, (string)message.Body);
            GuideManager.Hide();
            break;

        case MessageConst.MOUDLE_GUIDE_STEP_REMOTE:
            SetRemoteGuideStep((GuideTypePB)body[0], (int)body[1]);
            break;

        case MessageConst.MOUDLE_GUIDE_END_SERVER:
            _currentPanel.Destroy();
            GuideManager.Hide();
            break;
        }

        UnvarnishedTransmissionMessage(message);
    }
    public override void OnInspectorGUI()
    {
        DrawDefaultInspector();

        if (GUILayout.Button("跳过所有新手引导", GUILayout.Height(30)))
        {
            CSendCommand command = new CSendCommand();
            command.cmd = "gmpassnew";
            IOControler.GetInstance().SendProtocol(command);

            for (int i = 100101; i < 300604; ++i)
            {
                GuideManager.GetInstance().guideIDList.Add(i);
            }

            try
            {
                UI_HomeControler.Inst.ReMoveUI(UI_Intitle.UI_ResPath);
                UI_HomeControler.Inst.ReMoveUI(UI_Guide.UI_ResPath);
            }
            catch
            {
            }
        }
    }
Beispiel #10
0
    /// <summary>
    /// 显示选男主界面引导
    /// </summary>
    public void ShowMainViewGuide()
    {
        GuideManager.SetRemoteGuideStep(GuideTypePB.LoveGuideCoaxSleep, GuideConst.FunctionGuide_CoaxSleep_OneStage);

        Transform mainView = transform.Find("MainView");

        mainView.gameObject.Show();

        var bottom    = mainView.Find("Bottom");
        var chi       = bottom.GetButton("Chi");
        var yan       = bottom.GetButton("Yan");
        var tang      = bottom.GetButton("Tang");
        var qin       = bottom.GetButton("Qin");
        var returnBtn = mainView.Find("ReturnBtn").gameObject;

        PointerClickListener.Get(returnBtn).onClick = go =>
        {
            FlowText.ShowMessage(I18NManager.Get("Guide_CoaxSleep_ReturnBtnHint"));
        };


        chi.onClick.AddListener(() => { OnClickPlayer(PlayerPB.ChiYu, mainView); });
        yan.onClick.AddListener(() => { OnClickPlayer(PlayerPB.YanJi, mainView); });
        tang.onClick.AddListener(() => { OnClickPlayer(PlayerPB.TangYiChen, mainView); });
        qin.onClick.AddListener(() => { OnClickPlayer(PlayerPB.QinYuZhe, mainView); });
    }
Beispiel #11
0
        private IEnumerator Action4()
        {
            SystemManager.GetInstance().sceneTouchEnabled = false;

            UserManager.GetInstance().OpenFunction(FunctionType.Weapon);
            UserManager.GetInstance().OpenFunction(FunctionType.Dungeon);

            FunctionData functionData = UserManager.GetInstance().GetFunction(FunctionType.Dungeon);

            EventBox.Send(CustomEvent.HOME_SHOW_FUNCTION, functionData);

            EventBox.EventBoxHandler OnWindowOpen = null;
            OnWindowOpen = delegate(object data)
            {
                if (data == typeof(DungeonSelectWindow))
                {
                    EventBox.Remove(CustomEvent.WINDOW_OPEN, OnWindowOpen);

                    SystemManager.GetInstance().sceneTouchEnabled = true;
                    GuideManager.GetInstance().FinishGuide(GuideScriptID.G01);

                    task.Stop();
                }
            };

            EventBox.Add(CustomEvent.WINDOW_OPEN, OnWindowOpen);

            yield return(new WaitForSeconds(1.0f));

            GirlEntity2D girl = GameObject.FindGameObjectWithTag(TagDefines.TAG_GIRL).GetComponent <GirlEntity2D>();

            girl.weaponLauncher.Unload();

            girl.componentsHolder.GetComponent(ComponentDefs.Body).Play(AnimationDefs.Amaze.ToString().ToLower());
        }
Beispiel #12
0
        /// <summary>
        /// 新手引导跳转
        /// </summary>
        private void JudegIsShowNewGuide()
        {
            if (ObjectSelf.GetInstance().m_NewGuidePath != string.Empty)
            {
                UI_HomeControler.Inst.AddUI(ObjectSelf.GetInstance().m_NewGuidePath);
                ObjectSelf.GetInstance().m_NewGuidePath = string.Empty;
            }

            if (ObjectSelf.GetInstance().isGotoRuneUI)//通关1-2  跳转到符文装配界面
            {
                FailButtonClick(1);
                ObjectSelf.GetInstance().isGotoRuneUI = false;
            }
            if (ObjectSelf.GetInstance().m_isOpenZhiXian)//通关1-4  跳转到支线界面
            {
                GuideManager.GetInstance().ShowGuideWithIndex(200202);
            }
            if (ObjectSelf.GetInstance().m_isOpenPerfectReward)//通关1-6  跳转到选择关卡界面 小手指向礼品箱
            {
                GuideManager.GetInstance().ShowGuideWithIndex(200402);
            }

            if (ObjectSelf.GetInstance().isGotoRelicCowry)//通关1-5 跳转到遗迹宝藏
            {
                UI_HomeControler.Inst.AddUI(UI_Recruit.UI_ResPath);
                UI_Recruit.inst.OpenRelicBtn();
                ObjectSelf.GetInstance().isGotoRelicCowry = false;
            }
        }
Beispiel #13
0
 /// <summary>
 /// 新手引导招募相关
 /// </summary>
 /// <param name="type"></param>
 public void ShowGuideRecruit()
 {
     if (GuideManager.GetInstance().IsContentGuideID(100201) == false)
     {
         GuideManager.GetInstance().ShowGuideWithIndex(100201);
     }
 }
Beispiel #14
0
 // 引导战斗按钮
 public void InitGuideFight()
 {
     if (GuideManager.GetInstance().isGuideUser&& GuideManager.GetInstance().IsContentGuideID(100301) == false)
     {
         GuideManager.GetInstance().ShowGuideWithIndex(100301);
     }
 }
Beispiel #15
0
 private void ShowCoaxSleepMainView()
 {
     GuideManager.RegisterModule(this);
     _mainPanel = new CoaxSleepMainPanel();
     _mainPanel.Init(this);
     _mainPanel.Show(0f);
 }
Beispiel #16
0
 private void OKBtnSpacialStageHandler()
 {
     //新手引导相关 点击【立即前往】
     if (GuideManager.GetInstance().isGuideUser)
     {
         //GuideManager.GetInstance().ShowGuideWithIndex(200602);
     }
     if (CallByFightScene)
     {
         UI_FightControler.Inst.ReMoveUI(gameObject);
         var objSelf = DreamFaction.GameNetWork.ObjectSelf.GetInstance();
         if (objSelf.GetIsPrompt())
         {
             if (objSelf.Week != objSelf.GetWeek())
             {
                 objSelf.SetPromptTime(true);
                 objSelf.SetPromptBttleend(true);
             }
         }
         UI_HomeControler.NeedShowMysteriousShop         = false;
         DreamFaction.UI.UI_MainHome.NeedShowBattlePanel = true;
         //DreamFaction.UI.UI_SelectFightArea.NeedSetToSpecialStage = true;
         //UI_SelectLevelMgr.NeedSpecialStage = true;
         DreamFaction.GameCore.SceneManager.Inst.StartChangeScene(SceneEntry.Home.ToString());
     }
     else
     {
         UI_HomeControler.Inst.ReMoveUI(gameObject);
     }
 }
Beispiel #17
0
//	void RenderComponents(int index, GObject obj){
//		GComponent item = obj.asCom;
//		item.visible = true;
//		GLoader icon = item.GetChild ("icon").asLoader;
//
//		TowerComponent tc = PlayerData.getInstance ().bagComponents [index];
//		if (tc == null) {
//			icon.url = "Equips/empty";
//		} else {
//			icon.url = "Equips/" + tc.cid;
//		}
//		item.onTouchEnd.Add (delegate() {
//			GameManager.getInstance().showDetailAmplifier(tc.cdesp);
//		});
//		item.draggable = true;
//
//		item.onDragStart.Set(delegate(EventContext context) {
//			context.PreventDefault();
//			DragDropManager.inst.StartDrag(item, "Equips/"+tc.cid, (object)(index), (int)context.data);
//			startDragBagItem(index);
//		});
//
//		//string name = PlayerData.getInstance ().bagComponents [index].cname;
//	}

//	void startDragBagItem(int idx){
//		beforeDragPos = tComponents.LocalToGlobal(tComponents.GetChildAt(idx).position);
//		isDropOnSlot = false;
//		//tComponents.GetChildAt(index).visible = false;
//		for (int i = idx+1; i < tComponents.numItems; i++) {
//			Vector2 startPos = tComponents.GetChildAt (i).position;
//			Vector2 endPos = tComponents.GetChildAt (i-1).position;
//			tComponents.GetChildAt (i).TweenMove (endPos,0.3f);
//		}
//		tComponents.RemoveChildAt(idx);
//		nowDragIdx = idx;
//		tComponents.EnsureBoundsCorrect ();
//	}


    void clickTower(EventContext context)
    {
        GComponent item = (GComponent)context.data;
        int        idx  = towers.GetChildIndex(item);

        towerIdx = idx;
        TowerTemplate tt = PlayerData.getInstance().ownedTowers[idx];

        for (int i = 0; i < 4; i++)
        {
            components [i].visible = true;
            if (tt.components [i] == null)
            {
                components[i].setInfo(null);
            }
            else
            {
                components[i].setInfo(tt.components[i]);
            }
        }
        _property.visible = true;
        updateCalcedProperty(tt);

        if (PlayerData.getInstance().guideStage == 14)
        {
            GuideManager.getInstance().showGuideCloseMenu();
            PlayerData.getInstance().guideStage = 15;
        }
    }
Beispiel #18
0
    /// <summary>
    ///     设置新手引导统计点
    /// </summary>
    /// <param name="step"></param>
    /// <param name="guideType"></param>
    public void SetStatisticsRemoteGuideStep(int step)
    {
        var type     = GuideTypePB.MainGuideRecord;
        var lastStep = GuideManager.GetRemoteGuideStep(type); //获取上次的点

        Debug.LogError("获取统计上次的点===>" + lastStep);
        if (step <= lastStep)
        {
            Debug.LogError("拦截掉重复发的点===>" + step);
            return;
        }

        ClientTimer.Instance.DelayCall(() =>
        {
            Debug.LogError("发送统计的点p===>" + step);
            var req = new GuideReq
            {
                GuideType = type,
                GuideId   = step
            };
            var buffer = NetWorkManager.GetByteData(req);
            NetWorkManager.Instance.Send <GuideRes>(CMD.USERC_GUIDE, buffer, res =>
            {
                Debug.LogError("更新统计点===>" + res.UserGuide.GuideId + "更新的统计类型===>" + res.UserGuide.GuideType);
                GuideManager.UpdateRemoteGuide(res.UserGuide);
            });
        }, 0.3f);
    }
Beispiel #19
0
    void chooseItem()
    {
        int idx = _new_item_list.selectedIndex;

        //Debug.Log (idx);
        if (items [idx].StartsWith("c"))
        {
            PlayerData.getInstance().gainComponent(items [idx]);
        }
        else if (items [idx].StartsWith("t"))
        {
            PlayerData.getInstance().gainTowerBase(items [idx]);
        }

        Vector3 posLocal = _new_item_list.GetChildAt(idx).position;

        GameManager.getInstance().initGetItemEffect(_new_item_list.LocalToGlobal(posLocal), items[idx]);
        GameManager.getInstance().finishItemGet();
        this.Hide();

        if (PlayerData.getInstance().guideStage == 11)
        {
            GuideManager.getInstance().showGuideDetail();
            PlayerData.getInstance().guideStage = 12;
        }
    }
Beispiel #20
0
        private void Step2()
        {
            var upgradeStarContainer = transform.Find("UpgradeLevelContainer");

            upgradeStarContainer.gameObject.Show();

            var btn = transform.Find("UpgradeLevelContainer/UpgradeOneLevel");

            GuideArrow.DoAnimation(btn);

            PointerClickListener.Get(btn.gameObject).onClick = go =>
            {
                GuideManager.SetStatisticsRemoteGuideStep(GuideConst.MainLineStep_OnClick_CardLevelUp);
                var vo = GlobalData.CardModel.UserCardList[0];
                SendMessage(new Message(MessageConst.CMD_CARD_UPGRADE_ONELEVEL,
                                        Message.MessageReciverType.UnvarnishedTransmission,
                                        vo));
                upgradeStarContainer.gameObject.Hide();

                if (GuideManager.TempState == TempState.AchievementOver)
                {
                    GuideManager.SetStatisticsRemoteGuideStep(GuideConst.MainLineStep_CardView_levelUp);
                }
            };
        }
Beispiel #21
0
 public override void UpdateUIView()
 {
     if (!ObjectSelf.GetInstance().isSkillShow)
     {
         if (cdIcon.fillAmount > 0 && cdTime > 0 && !isHeroDead)
         {
             cdTime           -= Time.deltaTime;
             cdIcon.fillAmount = cdTime / mMaxCoolDownTime;
             ShowCdNumber();
             SetHeroShowState(SkillState.CdCool);
         }
     }
     if (cdTime <= 0 && !isHeroDead && FightControler.Inst.GetFightState() == FightState.Fighting)
     {
         isCdFinish++;
         SetHeroShowState(SkillState.CanUse);
     }
     if (isTrigger)
     {
         curTime += Time.deltaTime;
         if (curTime > allTime)
         {
             GuideManager.GetInstance().ShowGuideWithIndex(100312);
             isTrigger = false;
         }
     }
 }
Beispiel #22
0
        private void Awake()
        {
            GuideManager.SetStatisticsRemoteGuideStep(GuideConst.MainLineStep_OnClick_Mission);

            GuideManager.TempState = TempState.NONE;

            _btn = transform.Find("ListContent/DailyTask/DailyTaskList/Content/DailyTaskItem/GetBtn").gameObject;
            GuideArrow.DoAnimation(_btn.transform);

            PointerClickListener.Get(_btn).onClick = go =>
            {
                List <UserMissionVo> arr = GlobalData.MissionModel.GetMissionListByType(MissionTypePB.Daily);
                EventDispatcher.TriggerEvent(EventConst.RecieveTaskReward, arr[0]);
                _btn.Hide();
                transform.Find("ListContent").gameObject.Hide();

                GuideManager.SetStatisticsRemoteGuideStep(GuideConst.MainLineStep_Finish_Mission1);
                BackToMainUI();
            };

            PointerClickListener.Get(gameObject).onClick = go =>
            {
                PopupManager.CloseAllWindow();
            };
        }
Beispiel #23
0
    public override void Init()
    {
        _activityPanel = new ActivityPanel();
        _activityPanel.Init(this);

        GuideManager.RegisterModule(this);
    }
Beispiel #24
0
    /// <summary>
    /// 处理View消息
    /// </summary>
    /// <param name="message"></param>
    public override void OnMessage(Message message)
    {
        string name = message.Name;

        object[] body = message.Params;
        switch (name)
        {
        case MessageConst.CMD_APPOINTMENT_ENSUREOPENGATE:
            _usergate        = (AppointmentGateRuleVo)body[0];
            _appointmentrule = (AppointmentRuleVo)body[1];

            //这里要判断卡牌和星级啊。从appointment中获取到。
            var cardvo = GlobalData.CardModel.GetUserCardById(_appointmentrule.ActiveCards[0]);
            if (cardvo.Star < _usergate.Star)
            {
                //Debug.LogError("cstar"+cardvo.Star+"  userstar"+_usergate.Star);
                FlowText.ShowMessage(I18NManager.Get("LoveAppointment_Hint3"));    //("星缘心级不足");
                return;
            }

            if ((int)cardvo.Evolution < _usergate.Evo)
            {
//					Debug.LogError("(int)cardvo.Evolution"+(int)cardvo.Evolution+" _usergate.Evo"+_usergate.Evo);
                FlowText.ShowMessage(I18NManager.Get("LoveAppointment_Hint4"));                        //("星缘未进化");
                return;
            }



            if (_ensureOpenGateWindow == null)
            {
                _ensureOpenGateWindow = PopupManager.ShowWindow <EnsureOpenGateWindow>("LoveAppointment/Prefabs/EnsureOpenGateWindow");
            }
            _ensureOpenGateWindow.SetData(_usergate, _appointmentrule.Id);

            //bug 这个事件监听在Start的时候无法执行。
            EventDispatcher.AddEventListener(EventConst.OpenGate, OpenGate);

            break;

//			case MessageConst.CMD_APPOINTMENT_UPDATE_LOVESTORY:
//
//				UpdateAppointmentData();
//				break;
        case MessageConst.CMD_APPOINTMENT_ACTIVE_PHOTOCLEARUP:
            PhotoNickUpReq((int)body[0], (int)body[1]);
            break;

        case MessageConst.CMD_APPOINTMENT_JUMPTODAILY:

            if (!GuideManager.IsOpen(ModulePB.Love, FunctionIDPB.LoveDiary))
            {
                string desc = GuideManager.GetOpenConditionDesc(ModulePB.Love, FunctionIDPB.LoveDiary);
                FlowText.ShowMessage(desc);
                return;
            }
            ModuleManager.Instance.EnterModule(ModuleConfig.MODULE_LOVEDIARY, false);
            break;
        }
    }
Beispiel #25
0
    public override void Init()
    {
        DelayUnloadAtlas = 0.2f;

        GuideManager.RegisterModule(this);

        new AssetLoader().LoadAudio(AssetLoader.GetBackgrounMusicById("battleBgm"),
                                    (clip, loader) => { AudioManager.Instance.PlayBackgroundMusic(clip); });

        AutoUnloadAtlas = false;

        _battlePanel = new BattlePanel();
        _battlePanel.Init(this);
        _battlePanel.Show(0);

        _battleCommon = InstantiateView("Battle/Prefabs/Panels/BattleCommon");
        _battleCommon.transform.SetParent(Parent.transform, false);

        _battleFinalBg = InstantiateView("Battle/FinalEstimate/FinalEstimateViewBg");
        _battleFinalBg.transform.SetParent(Parent.transform, false);
        _battleFinalBg.transform.SetSiblingIndex(0);
        _battleFinalBg.Hide();

        SetProgress(0, MaxPower);
    }
Beispiel #26
0
        private void Level1_3EndGetAwardWindowAni()
        {
            var      list = GuideManager.GetGuideAwardsToRule(GuideTypePB.MainGuide);
            RewardVo vo   = null;

            foreach (var t in list)
            {
                if (t.Resource == ResourcePB.Card)
                {
                    vo = new RewardVo(t);
                    break;
                }
            }

            _award.transform.GetRawImage("GetAward/Awards/1/PropImage").texture = ResourceManager.Load <Texture>(vo.IconPath);
            _award.transform.GetText("GetAward/Awards/1/Name").text             = CardName(vo.Id);
            _award.gameObject.Show();
            transform.Find("Mask").gameObject.Show();
            _award.DOScale(Vector3.one, 0.2F).SetEase(Ease.OutExpo).OnComplete(() =>
            {
                PointerClickListener.Get(_award.gameObject).onClick = go =>
                {
                    _award.DOScale(new Vector3(_samllScale, _samllScale, 1), 0.2F).SetEase(Ease.OutExpo)
                    .OnComplete(() =>
                    {
                        transform.Find("Mask").gameObject.Hide();
                        GoToNextGuideStage(I18NManager.Get("Guide_MainLineGetFirstAward"));
                    });
                };
            });
        }
Beispiel #27
0
        // 新手引导添加
        protected override void UpdateView()
        {
            base.UpdateView();
            if (m_IsTriger)
            {
                m_CurTime += Time.deltaTime;
                if (m_CurTime > 1.0f)
                {
                    m_CurTime  = 0.0f;
                    m_IsTriger = false;

                    if (m_GuideCount == 1)
                    {
                        m_GuideCount += 1;
                        // 点击【切换模式】 100308
                        if (GuideManager.GetInstance().IsContentGuideID(100308) == false)
                        {
                            GameEventDispatcher.Inst.dispatchEvent(GameEventID.G_Guide_Fighting, 100308);
                        }
                    }
                    else
                    {
                        // 点击【众神之主技能】 100311
                        if (GuideManager.GetInstance().IsContentGuideID(100311) == false)
                        {
                            GameEventDispatcher.Inst.dispatchEvent(GameEventID.G_Guide_Fighting, 100311);
                        }
                    }
                }
            }
        }
Beispiel #28
0
    IEnumerator moveMark(int index)
    {
        GameManager.getInstance().hideDetailPanel();

        isMoving = true;
        markGO.SetActive(true);
        Vector3 target = new Vector3((index % GRID_WIDTH) * GRID_INTERVAL_WIDTH, -(index / GRID_WIDTH) * GRID_INTERVAL_HEIGHT, 0);

        //Vector3 target = encounterGo [bg[totalPattern[index][0]][totalPattern[index][1]]].transform.localPosition;
        while (true)
        {
            Vector3 diff = (target - markGO.transform.localPosition);
            if (diff.magnitude < Time.deltaTime * 8f)
            {
                markGO.transform.localPosition = target;
                break;
            }
            else
            {
                markGO.transform.localPosition = Vector3.Lerp(markGO.transform.localPosition, target, 0.15f);
                //markGO.transform.localPosition += dir.normalized * Time.deltaTime * 8f;
            }
            yield return(null);
        }
        isMoving = false;

        if (PlayerData.getInstance().guideStage == 0)
        {
            PlayerData.getInstance().guideStage = 1;
            GuideManager.getInstance().showGuideMovePlayer(getToturialGridPos());
        }

        markedIndex = index;
        changeEncounterDetail(markedIndex);
    }
Beispiel #29
0
        /// <summary>
        ///     Opens the guide tool.
        /// </summary>
        internal void OpenGuideTool()
        {
            GuideManager guideManager = Yupi.GetGame().GetGuideManager();
            bool         onDuty       = Request.GetBool();

            Request.GetBool();
            Request.GetBool();
            Request.GetBool();

            if (onDuty)
            {
                guideManager.AddGuide(Session);
            }
            else
            {
                guideManager.RemoveGuide(Session);
            }

            Session.GetHabbo().OnDuty = onDuty;
            Response.Init(LibraryParser.OutgoingRequest("HelperToolConfigurationMessageComposer"));
            Response.AppendBool(onDuty);
            Response.AppendInteger(guideManager.GuidesCount);
            Response.AppendInteger(guideManager.HelpersCount);
            Response.AppendInteger(guideManager.GuardiansCount);
            SendResponse();
        }
Beispiel #30
0
        private void LoveAppointmentBtnGuide(bool loveAppointment = false)
        {
            var btn = transform.Find("StartPathBtnContainer");

            btn.gameObject.Show();

            transform.Find("StartPathBtnContainer/AppointmentBtn").gameObject.Show();

            var guideView = transform.Find("GuideView_LoveBtn");

            if (loveAppointment)
            {
                guideView.gameObject.Show();
                GuideManager.SetStatisticsRemoteGuideStep(GuideConst.MainLineStep_OnClick_LoveBtn);
            }
            else
            {
                guideView.gameObject.Hide();
            }

            var guidetext = transform.GetText("GuideView_LoveBtn/DialogFrame/Text");

            guidetext.text = loveAppointment
                ? I18NManager.Get("Guide_MainLineLoveStory")
                : I18NManager.Get("Guide_LoveDiaryGuide");
            GuideArrow.DoAnimation(transform.Find("StartPathBtnContainer/AppointmentBtn"));


            PointerClickListener.Get(transform.Find("StartPathBtnContainer/AppointmentBtn").gameObject).onClick = go =>
            {
                SendMessage(new Message(MessageConst.CMD_APPOINTMENT_JUMPCHOOSEROLE,
                                        Message.MessageReciverType.UnvarnishedTransmission));
            };
        }
Beispiel #31
0
 public void Show(GuideManager.GuideInfo guideInfo )
 {
     if ( blurRender )
         blurRender.gameObject.SetActive(true);
     foreach(tk2dSprite sprite in spriteList )
         HOTween.To( sprite , changeColorTime , "color" , Global.changeAlpha( sprite.color , 1.0f));
 }