void Update() { if (shouldPlayAnimation && animationIsOver) { switch (animationState) { case 0: StartCoroutine("wheelAnimation_1_dropWheel"); break; case 1: StartCoroutine("wheelAnimation_2_slowRotation"); break; case 2: StartCoroutine("wheelAnimation_3_delayBeforeStats"); break; default: victoryScreen.beginShowingStats(); break; } animationIsOver = false; animationState++; } }
void Update() { if (shouldPlayAnimation && animationIsOver) { switch (animationState) { case 0: StartCoroutine("chestAnimation_1_scrunchDown"); break; case 1: StartCoroutine("chestAnimation_delay1_pauseDuringScrunch"); break; case 2: StartCoroutine("chestAnimation_2_3_leanParentBack"); StartCoroutine("chestAnimation_2_bounceUp"); break; case 3: StartCoroutine("chestAnimation_3_lidSwingsOpen"); break; case 4: StartCoroutine("chestAnimation_4_lidBounces"); break; case 5: StartCoroutine("chestAnimation_5_lidEases"); break; case 6: StartCoroutine("chestAnimation_6_delayBeforeStats"); break; default: victoryScreen.beginShowingStats(); break; } animationIsOver = false; animationState++; } }