Countdown Fade in - how?

Hello guys!

Currently I am working on a racing game with a sphere (like ‘I’ve got some balls’, awesome game btw :wink: )
Now i want to make a starting countdown before each level (3…,2…,1…, GO!).

I made it so far, but i want to fade it in. Like the ‘3’ is in the middle of the screen and becoming bigger and bigger, then ‘2’ same thing, and so on.

Hope you know what i mean, i dont know how to do it. I am just finding things like ‘fading in scene’.

In the near future, i want to use transparency textures for each digit and i want to fade them in AND increasing size in an amount of time (like i mentioned before).

Would be awesome if you could give me some tips, how i could do this.

Okay i made it, pretty simple.

function OnGUI(){
    // Texture 3...
    if(countdown == 3){
        countdown_material = countdown_material_3;
    }

    // Texture 2...
    if(countdown == 2){
        countdown_material = countdown_material_2;
    }

    // Texture 1...
    if(countdown == 1){
        countdown_material = countdown_material_1;
    }

    if(countdown > 0){
        scaleX = (Time.time % 1) * 400;
        scaleY = (Time.time % 1) * 400;
        GUI.Label(Rect(Screen.width / 2 - scaleX/2, Screen.height /2 - scaleY/2, scaleX, scaleY), countdown_material.mainTexture);
    }

....
}

Works great, ‘countdown_material_x’ are the textures with the digits (3,2,1). ‘Time.time % 1’ resets each second the size and location. So each second, each digit getting bigger and bigger from the middle of the screen till the next second isn’t reached.

countdown gets increased with InvokeRepeating(“startCountdown”, 1, 1.0); at Start()

Hope i can help some guys, who has the same question :wink:

//Edit

If you build a ‘Restart Lvl’ on Backspace, ‘Time.time’ won’t work in this way with the countdown timer, you have to check / reset / save milliseconds of Time.time or using your own Timer.