public void PowerUp(Powerup.PowerupType powerUp) { CancelPowerups(); faceController.SetSmugImage(2f); AchievementsController.instance.SetPowerupCollected(); switch (powerUp) { case Powerup.PowerupType.EXTRA_LIFE: Debug.Log("EXTRA LIFE!"); lives++; UpdateLives(); break; case Powerup.PowerupType.INVULNERNABILITY: Debug.Log("You are invulnerable... FOR NOW!"); invincible = true; invincibleImage.SetActive(true); currentPowerup = Powerup.PowerupType.INVULNERNABILITY; windowSpawner.GetComponent <WindowSpawner>().SetPowerUpTimer(); break; case Powerup.PowerupType.MONEYBAG: Debug.Log("Money falls from the sky."); moneybag = true; moneybagImage.SetActive(true); currentPowerup = Powerup.PowerupType.MONEYBAG; if (FistTable.instance.fistSpecial == 9) { windowSpawner.GetComponent <WindowSpawner>().SetPowerUpTimer(1 / FistTable.instance.fistPowerupsScale, BonusMoneyBag(windowSpawner.timeAlive)); } else { windowSpawner.GetComponent <WindowSpawner>().SetPowerUpTimer(1, BonusMoneyBag(windowSpawner.timeAlive)); } break; case Powerup.PowerupType.SLOW: Debug.Log("Slowing down the screen."); slowDown = true; slowDownImage.SetActive(true); currentPowerup = Powerup.PowerupType.SLOW; cameraScript.GetComponent <CameraScript>().SetSlowSpeed(true); windowSpawner.GetComponent <WindowSpawner>().SetPowerUpTimer(); break; case Powerup.PowerupType.SUPER_SOCKO: Debug.Log("SUPER SOCKO TIME!!!!!"); superSocko = true; superSockoImage.SetActive(true); currentPowerup = Powerup.PowerupType.SUPER_SOCKO; windowSpawner.GetComponent <WindowSpawner>().SetPowerUpTimer(); break; } }