Exemplo n.º 1
0
 protected Booster(int id, BoostTypes typeOfBoost, BoosterTypes boosterType, int damageBoost, int shieldBoost, int healthBoost,
                   int boxRewardBoost)
 {
     Id             = id;
     BoostType      = typeOfBoost;
     Type           = boosterType;
     DamageBoost    = damageBoost;
     ShieldBoost    = shieldBoost;
     HealthBoost    = healthBoost;
     BoxRewardBoost = boxRewardBoost;
 }
Exemplo n.º 2
0
    public static void GetBooster(BoosterTypes boosterType)
    {
        var index = (int)boosterType;

        openAndCloseCore.Open(boosters[index].transform);
        boostersImage[index]            = (boosters[index].GetComponent <Image>());
        boostersImage[index].fillAmount = 1f;

        if (boosterType == BoosterTypes.speed)
        {
            animatorController.IncreaseAnimationSpeed(1.5f);
        }
    }
Exemplo n.º 3
0
    static BoosterTypes bt = BoosterTypes.Speed;        //Booster type


    public static void OnPickup()
    {
        bt = (BoosterTypes)Random.Range(0, 2);

        switch (bt)
        {
        case BoosterTypes.Speed:
            SpeedBooster();
            break;

        case BoosterTypes.SuperBreak:
            SuperBreakerBooster();
            break;

        case BoosterTypes.Shield:
            ShieldBooster();
            break;

        default:
            Debug.LogError(bt);
            break;
        }
    }