示例#1
0
    public void Succ(int skillID, ENSkillConnectionType type)
    {
        if (m_qteState == EnQteState.enStateStop)
        {
            return;
        }
        if (CurrentIndex >= m_qteList.Count)
        {
            Stop();
            return;
        }
        if (type == m_qteList[CurrentIndex].m_type)
        {//succ
            m_qteList[CurrentIndex].m_state = QTEInfo.EnQteInfoState.enQteSucc;
            //通知qte序列
            BattleArena.Singleton.NotifyChanged((int)BattleArena.ENPropertyChanged.enQteSequence, UIQTESequence.EnEventType.enChange);
            //通知技能隐藏qte
            ActorManager.Singleton.MainActor.NotifyChanged((int)Actor.ENPropertyChanged.enBattleBtn_D, MainPlayer.ENBattleBtnNotifyType.enQteHide);

            m_qteList[CurrentIndex].m_state = QTEInfo.EnQteInfoState.enQteEnd;
            ++CurrentIndex;

            if (CurrentIndex == m_qteList.Count)
            {//所有成功
                //通知qte序列all succ
                BattleArena.Singleton.NotifyChanged((int)BattleArena.ENPropertyChanged.enQteSequence, UIQTESequence.EnEventType.enAllSucc);
                if (m_qteExtraReward == 0)
                {
                    m_qteExtraReward = GameTable.WorldParamTableAsset.Lookup((int)ENWorldParamIndex.enQteExtraReward).IntTypeValue;
                }
                //add soulcharge
                if (BattleArena.Singleton.SkillCombo.SkillComboNumber != 0)
                {
                    //BattleArena.Singleton.SoulCharge.AddSoul(EnSoulType.enSkillCombo, BattleArena.Singleton.SkillCombo.SkillComboNumber);
                    //clear
                    BattleArena.Singleton.SkillCombo.ClearSkillCombo();
                    //connecteffect
                    if (BattleArena.Singleton.Combo.ConnectEffectNumber != 0)
                    {
                        //BattleArena.Singleton.SoulCharge.AddSoul(EnSoulType.enConnectEffect, BattleArena.Singleton.Combo.ConnectEffectNumber);
                        //clear connecteffectnumber
                        BattleArena.Singleton.Combo.ClearConnectEffect();
                    }
                }
                //BattleArena.Singleton.SoulCharge.AddSoul(EnSoulType.enQte, CurrentIndex);
                //BattleArena.Singleton.SoulCharge.AddSoul(EnSoulType.enExtra, m_qteExtraReward);

                //BattleArena.Singleton.SoulCharge.StopResult();
                Stop();
            }
            else
            {//通知下一个
                m_qteState         = EnQteState.enStateNext;
                m_nextQteStartTime = Time.time;
                m_qteList[CurrentIndex].m_state = QTEInfo.EnQteInfoState.enQteIng;
                //通知qte序列
                BattleArena.Singleton.NotifyChanged((int)BattleArena.ENPropertyChanged.enQteSequence, UIQTESequence.EnEventType.enChange);
            }
        }
    }
示例#2
0
    //停止
    void Stop(ENSkillConnectionType type)
    {
        //add soulcharge
        if (SkillComboNumber != 0)
        {
            //BattleArena.Singleton.SoulCharge.AddSoul(EnSoulType.enSkillCombo, SkillComboNumber + 1);
            //clear
            ClearSkillCombo();
            if (BattleArena.Singleton.Combo.ConnectEffectNumber != 0)
            {
                //BattleArena.Singleton.SoulCharge.AddSoul(EnSoulType.enConnectEffect, BattleArena.Singleton.Combo.ConnectEffectNumber);
                //clear connecteffectnumber
                BattleArena.Singleton.Combo.ClearConnectEffect();
            }
        }
        //BattleArena.Singleton.SoulCharge.StopResult();

        m_startTime   = float.MaxValue;
        m_currentType = ENSkillConnectionType.enNone;
        if (type == ENSkillConnectionType.enConnect ||
            type == ENSkillConnectionType.enSpecial)
        {
            Start(type);
        }
        //隐藏uiskillcombo
        BattleArena.Singleton.NotifyChanged((int)BattleArena.ENPropertyChanged.enSkillCombo, false);
    }
示例#3
0
 //成功
 void Succ(ENSkillConnectionType type)
 {
     ++SkillComboNumber;
     //显示uiskillcombo
     BattleArena.Singleton.NotifyChanged((int)BattleArena.ENPropertyChanged.enSkillCombo, true);
     Start(type);
     m_duration += ModifyTime;
 }
示例#4
0
 //清除数据
 public void ClearSkillCombo()
 {
     SkillComboNumber = 0;
     m_startTime      = float.MaxValue;
     m_currentType    = ENSkillConnectionType.enNone;
     //隐藏uiskillcombo
     BattleArena.Singleton.NotifyChanged((int)BattleArena.ENPropertyChanged.enSkillCombo, false);
 }
示例#5
0
 //开始
 void Start(ENSkillConnectionType type)
 {
     if (type == ENSkillConnectionType.enConnect ||
         type == ENSkillConnectionType.enSpecial)
     {
         m_currentType = type;
         m_startTime   = Time.time;
         if (type == ENSkillConnectionType.enConnect)
         {
             m_duration = ConnectionTime;
         }
         else if (type == ENSkillConnectionType.enSpecial)
         {
             m_duration = SpecialTime;
         }
     }
 }
示例#6
0
    //设置技能连接类型,并判断成功失败
    public void SetConnectionInfo(ENSkillConnectionType type)
    {
        if (m_currentType == ENSkillConnectionType.enNone)
        {
            Start(type);
            return;
        }
        switch (m_currentType)
        {
        case ENSkillConnectionType.enConnect:
            if (type == ENSkillConnectionType.enConnect ||
                type == ENSkillConnectionType.enSpecial ||
                type == ENSkillConnectionType.enFinal)
            {    //succ
                Succ(type);
            }
            else if (type == ENSkillConnectionType.enNormal)
            {
            }
            else
            {
                Stop(type);
            }
            break;

        case ENSkillConnectionType.enSpecial:
            if (type == ENSkillConnectionType.enSpecial ||
                type == ENSkillConnectionType.enFinal)
            {    //succ
                Succ(type);
            }
            else if (type == ENSkillConnectionType.enNormal)
            {
            }
            else
            {
                Stop(type);
            }
            break;

        default:
            break;
        }
    }