Skip to content

Instantly share code, notes, and snippets.

@jquave
Created May 20, 2016 23:27
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save jquave/058fa32cbd02c6f94a9598c017702882 to your computer and use it in GitHub Desktop.
Save jquave/058fa32cbd02c6f94a9598c017702882 to your computer and use it in GitHub Desktop.
float newTimer = 0;
SoundManager.PlaySound( "RisingSound", CameraControl.instance.transform.position);
fader.gameObject.SetActive( true );
fader.color = Color.clear;
while (fader.color != Color.white)
{
newTimer += Time.deltaTime;
fader.color = Color.Lerp( Color.clear, Color.white, newTimer * 0.33f );
FaraDay.transform.localScale = Vector2.MoveTowards(FaraDay.transform.localScale, 3.0f * FaraDay.transform.localScale, 3 * Time.deltaTime);
yield return new WaitForEndOfFrame();
}
FaraDay.transform.localScale = FaraDay.transform.localScale / 3.0f;
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment