Your "yield return new WaitForSeconds(2)" statement must be on a line for itself, and ended with a semicolon. So must the "AvisoComprado.SetActive(true)" statement. EDIT: To clarify, in C#, a WaitForSeconds statement is correctly put "yield return new WaitForSeconds(X)" where X is the number of seconds you wish to wait for. This should do the trick: http://pastebin.com/T7qHkYpA