Exemple #1
0
 void Update()
 {
     if (m_morphBag)
     {
         MorphBag();
     }
     if (CS.GetDonePaning() && GM.GetEndGameMenuState() == false && m_inputDelay <= 0)
     {
         InputManager();
     }
     if (BS == BagState.idle && throwPower == 0 && GM.GetEndGameMenuState() == false)
     {
         BagMovementIdleMovement();
     }
     else if (BS == BagState.flying)
     {
         BagFlyingState();
     }
     if (m_inputDelay > 0)
     {
         m_inputDelay = m_inputDelay - Time.deltaTime;
     }
 }
    void Update()
    {
        if (!GM.GetEndGameMenuState())
        {
            switch (GetPotionType())
            {
            //  bouncePower, scaleMultiplier, goldMultiplier, extraThrow,  gravity, scoreEndMultiplier, drag,  timeScale)

            case PotionType.SuperBounce:
                SetVariables(1.25f, 0.5f, 1, false, 1, 1, 0, 1.0f, 0.05f);
                break;

            case PotionType.none:
                SetVariables(1.0f, 0.5f, 1, false, 1, 1, 0, 1.0f, 0.05f);
                break;

            case PotionType.Gigantic:
                SetVariables(1.0f, 1.0f, 1, false, 1, 1, 0, 1.0f, 0.1f);
                break;

            case PotionType.Success:
                SetVariables(1.0f, 0.5f, 1.5f, false, 1, 1, 0, 1.0f, 0.05f);
                break;

            case PotionType.Minature:
                SetVariables(1.0f, 0.3f, 1.0f, false, 1, 1, 0, 1.0f, 0.05f);
                break;

            case PotionType.Slow_Motion:
                SetVariables(1.0f, 0.5f, 1.0f, false, 1, 1, 0, 0.5f, 0.05f);
                break;

            case PotionType.Score:
                SetVariables(1.0f, 0.5f, 1.0f, false, 1, 1.05f, 0, 1.0f, 0.05f);
                break;

            case PotionType.Presence:
                SetVariables(1.0f, 0.5f, 1.0f, true, 1, 1.0f, 0, 1.0f, 0.05f);
                break;

            case PotionType.Iron:
                SetVariables(0.1f, 0.5f, 1.0f, false, 2.0f, 1.0f, 0, 1.0f, 0.05f);
                break;
            }
        }
    }