O'Reilly logo

NGUI for Unity by Charles Bernardoff

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Error notification

We want the user to enter a nickname in the input field and select a power before he or she can launch the game.

Right now, the user can launch the game regardless of the input and selected power value. Let's correct this by preventing the game's launch and notifying the user, as shown in the following screenshot:

Error notification

We will use a TweenScale through code that will gradually scale up the notification from {0, 0, 0} to {1, 1, 1} by following these steps:

  1. Select our Tooltip GameObject in the Hierarchy window.
  2. Duplicate it with Ctrl + D.
  3. Rename this new duplicate as Notification and perform the following steps:
    1. Set its Depth parameter in ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required