Esempio n. 1
0
        void Update()
        {
            if (isTransformingNow == true)
            {
                if (timer < _TransformingTime)
                {
                    timer += Time.deltaTime;
                }
                else
                {
                    Shapeshift();
                }
            }
            else
            {
                timer = 0.0f;
            }

            if (PardusMode == true && isTransformingNow == false)
            {
                float amount = _Mana.spendMana(ManaCostPerSec);
                if (amount == 0)
                {
                    StartShapeshift();
                }
            }
        }
Esempio n. 2
0
        /// <summary>
        /// Every frame we perform a number of checks related to jump
        /// </summary>
        public override void ProcessAbility()
        {
            if (!AbilityPermitted || !Mana.Charging)
            {
                return;
            }

            base.ProcessAbility();

            if (ChargedAmount < MaxChargeAmount)
            {
                Charge(Mana.spendMana(DeltaCharge));
            }
            //Spawn particles at each loop, scaled with the ChargedAmount
            UpdateGuiValues();
        }