Exemplo n.º 1
0
    //
    public IEnumerator ShowEffectStart()
    {
        showEffect = true;

        for (int i = 0; i < 3; i++)
        {
            GameObject Effect = EffectStart.GetChild(i).gameObject;
            Effect.SetActive(true);
            TweenAlpha twA = TweenAlpha.Begin(Effect, 2f, Effect.GetComponent <SpriteRenderer>().color.a);
            twA.from = 0;

            yield return(new WaitForSeconds(0.33f));
        }
    }
Exemplo n.º 2
0
    public IEnumerator HideEffectStart()
    {
        showEffect = false;
        GameObject Effect = EffectStart.gameObject;

        for (int i = 0; i < 3; i++)
        {
            TweenAlpha.Begin(EffectStart.GetChild(i).gameObject, 2f, 0);
        }
        yield return(new WaitForSeconds(2f));

        isProtected = false;
        Destroy(Effect);
    }
Exemplo n.º 3
0
        /// <summary>
        /// Starts the effect duration and raises the <see cref="EffectStart"/> event.
        /// </summary>
        public void StartEffect()
        {
            bool wasEffectActive = IsEffectActive;

            IsEffectActive = true;

            CooldownTime = EffectDuration;

            KillButtonManager.TimerText.Color = new Color(0F, 0.8F, 0F);

            if (!wasEffectActive)
            {
                EffectStart?.SafeInvoke(this, EventArgs.Empty, nameof(EffectStart));
            }
        }
Exemplo n.º 4
0
 public MoveArchetype(string name, MoveType moveType, ElementType elementType,
     int maxPp, int power, int accuracy, DurationType durationType, int turnDuration, BattleEffectStageEffect battleEffectStageEffect, 
     EffectType effectType, EffectStart effectStart, MoveTarget moveTarget, 
     BattleEffectType battleEffectType, string battleEffectText)
 {
     Name = name;
     MoveType = moveType;
     ElementType = elementType;
     MaxPP = maxPp;
     Power = power;
     Accuracy = accuracy;
     TurnDuration = turnDuration;
     BattleEffectStageEffect = battleEffectStageEffect;
     EffectType = effectType;
     EffectStart = effectStart;
     MoveTarget = moveTarget;
     DurationType = durationType;
     BattleEffectType = battleEffectType;
     BattleEffectText = battleEffectText;
 }