Esempio n. 1
0
        public void Yak_Skill1(OperatorController operatorController)
        {
            BackUpOperatorData(operatorController);
            EachSecondSkill eachSecondSkill = Heal;
            int             healValue       = 25;
            EndSkill        end             = ReBackUpOperatorData;

            operatorController._operatorData = tempDataClear.ModificatorPlus(Attribute.MaximumHP, operatorController._operatorData.maxHP * 0.33f);

            operatorController.StartCoroutine(ActiveSkillWithCount(operatorController, null, eachSecondSkill, end, 0, healValue));
        }
Esempio n. 2
0
        public void Sunbr_Skill1(OperatorController operatorController)
        {
            BackUpOperatorData(operatorController);
            EachSecondSkill eachSecondSkill = Heal;
            int             healValue       = 100;
            EndSkill        end             = ReBackUpOperatorData;

            operatorController._operatorData = tempDataClear.ModificatorMultiplication(Attribute.AttackPower, 1.33f);

            operatorController.StartCoroutine(ActiveSkillWithCount(operatorController, null, eachSecondSkill, end, 0, healValue));
        }
Esempio n. 3
0
        IEnumerator ActiveSkillWithCount(OperatorController operatorController, StartSkill startSkill = null, EachSecondSkill eachSecondSkill = null, EndSkill endSkill = null, int _duration = 0, int eachSecondSkillParametr = 0)
        {
            isActive    = true;
            isCanActive = false;
            operatorController.SetStartSkillPoint(duration, duration);

            startSkill?.Invoke(operatorController);

            MainController.mainInterfaceFields.selectOperatorUI.updateSelectInfo(operatorController._operatorData);

            if (duration > 0)
            {
                curDurationTime = duration;
            }
            else
            {
                if (_duration > 0)
                {
                    curDurationTime = _duration;
                }
            }

            while (curDurationTime > 0)
            {
                if (MainController.mainInterfaceFields.selectOperatorUI.operatorController != null)
                {
                    eachSecondSkill?.Invoke(operatorController, eachSecondSkillParametr);
                    operatorController.SetSkillPoint(curDurationTime - 1);

                    MainController.mainInterfaceFields.selectOperatorUI.updateSelectInfoOnlySkill();
                }
                curDurationTime--;
                yield return(new WaitForSeconds(1f));
            }

            endSkill?.Invoke(operatorController);

            MainController.mainInterfaceFields.selectOperatorUI.updateSelectInfo(operatorController._operatorData);


            isActive    = false;
            isCanActive = true;
            operatorController.StartCoroutine(SkillPointGenerate(operatorController));

            yield return(null);
        }