コード例 #1
0
    private void onTalentLevelChange(ref TalentLevelChangeParam inParam)
    {
        if (Singleton <GamePlayerCenter> .instance.GetHostPlayer() != null)
        {
            PoolObjHandle <ActorRoot> captain = Singleton <GamePlayerCenter> .instance.GetHostPlayer().Captain;

            if ((captain != 0) && ((inParam.src != 0) && (inParam.src == captain)))
            {
                uint[] param = new uint[] { inParam.SoulLevel, inParam.TalentLevel };
                MonoSingleton <NewbieGuideManager> .GetInstance().CheckTriggerTime(NewbieGuideTriggerTimeType.onTalentLevelChange, param);
            }
        }
    }
コード例 #2
0
    private void onTalentLevelChange(ref TalentLevelChangeParam inParam)
    {
        if (Singleton <GamePlayerCenter> .get_instance().GetHostPlayer() == null)
        {
            return;
        }
        PoolObjHandle <ActorRoot> captain = Singleton <GamePlayerCenter> .get_instance().GetHostPlayer().Captain;

        if (!captain)
        {
            return;
        }
        if (!inParam.src || inParam.src != captain)
        {
            return;
        }
        MonoSingleton <NewbieGuideManager> .GetInstance().CheckTriggerTime(NewbieGuideTriggerTimeType.onTalentLevelChange, new uint[]
        {
            (uint)inParam.SoulLevel,
            (uint)inParam.TalentLevel
        });
    }
コード例 #3
0
ファイル: TalentView.cs プロジェクト: wujiangu/wanshiwu0.1
        public void OnHeroSoulLvlChange(PoolObjHandle <ActorRoot> hero, int level)
        {
            HeroTalentViewInfo heroTalentViewInfo = this.GetHeroTalentViewInfo(hero);

            if (((heroTalentViewInfo != null) && this.SetTalentLevel(heroTalentViewInfo, level)) && (hero == this.m_heroCaption))
            {
                this.Refresh();
                if ((this.m_root != null) && this.m_root.activeSelf)
                {
                    Singleton <CBattleSystem> .GetInstance().CreateOtherFloatText(enOtherFloatTextContent.OpenTalent, (Vector3)this.m_heroCaption.handle.location, new string[0]);
                }
                Singleton <CSoundManager> .GetInstance().PlayBattleSound("UI_Prompt_tianfu", null);

                TalentLevelChangeParam prm = new TalentLevelChangeParam {
                    src         = hero,
                    SoulLevel   = level,
                    TalentLevel = heroTalentViewInfo.m_talentLevel
                };
                Singleton <GameEventSys> .instance.SendEvent <TalentLevelChangeParam>(GameEventDef.Event_TalentLevelChange, ref prm);
            }
            this.AutoLearnTalent(hero, level);
        }