void OnTriggerStay(Collider other) { if (other.gameObject.tag.Equals("Button/Normal")) { other.gameObject.GetComponent <LoadLevels>().Load(); } else { int tmp = ObjectSystem.IsObjectHittable(other.gameObject.tag); if (tmp != -1) { if (!isEndless) { if (other.tag.Equals("Object/Popcorn")) { targetScale += new Vector3(0.01f, 0f, 0.01f); } else { if (PowerupSystem.IsCurrentPowerup(PowerupSystem.Powerups.DoubleSize)) { targetScale += new Vector3(scale * 2, 0f, scale * 2); } else { targetScale += new Vector3(scale, 0f, scale); } cylinder.transform.localScale += new Vector3(0, 0.5f, 0); cam.newTargetVector(); } } Destroy(other.gameObject); PowerupSystem.ChoosePowerup(tmp); } } }