void ResetDetailAggregates(ResetEnum resetType)
 {
     foreach (Band band in GetDetailBands())
     {
         foreach (ValueWidget widget in band.Items.FindAll(typeof(ValueWidget)))
         {
             if (widget.CalcType != CalcEnum.None && widget.ResetType == resetType)
             {
                 widget.Reset();
             }
         }
     }
 }
 void ResetAggregates(List <Band> bands, ResetEnum resetType)
 {
     foreach (Band band in bands)
     {
         foreach (BaseWidget widget in band.Items)
         {
             ValueWidget vw = widget as ValueWidget;
             if (vw != null && vw.CalcType != CalcEnum.None && vw.ResetType == resetType)
             {
                 vw.Reset();
             }
         }
     }
 }
예제 #3
0
    public void playReset(ResetEnum AnimType = ResetEnum.ANIME_EXPLODE, ScientistHand hand = null)
    {
        if (gameoverState)
        {
            return;
        }
        if (triggered == false)
        {
            triggered = true;
            switch (AnimType)
            {
            case ResetEnum.NO_ANIM:
                //Nothing
                break;

            case ResetEnum.ANIME_EXPLODE:
                deathAnim();
                break;

            case ResetEnum.HAND_KILL:
                hand.Trigger();
                byhand = true;
                timer  = 1.5f;
                break;

            default:
                break;
            }
            if (!byhand)
            {
                timer = timerDuration;
            }
        }
        else if (byhand && AnimType == ResetEnum.ANIME_EXPLODE)
        {
            byhand = false;
            deathAnim();
            timer = timerDuration;
        }
    }
예제 #4
0
 void ResetDetailAggregates(ResetEnum resetType)
 {
     foreach (Band band in GetDetailBands())
     {
         foreach (ValueWidget widget in band.Items.FindAll(typeof(ValueWidget)))
         {
             if (widget.CalcType != CalcEnum.None && widget.ResetType == resetType)
             {
                 widget.Reset();
             }
         }
     }
 }
예제 #5
0
 void ResetAggregates(List<Band> bands, ResetEnum resetType)
 {
     foreach (Band band in bands)
     {
         foreach (BaseWidget widget in band.Items)
         {
             ValueWidget vw = widget as ValueWidget;
             if (vw != null && vw.CalcType != CalcEnum.None && vw.ResetType == resetType)
                 vw.Reset();
         }
     }
 }