Sign In Start Free Trial
Account

Add to playlist

Create a Playlist

Modal Close icon
You need to login to use this feature.
  • Book Overview & Buying Learning NGUI for Unity
  • Table Of Contents Toc
Learning NGUI for Unity

Learning NGUI for Unity

By : Charles Bernardoff (EURO)
4.7 (6)
close
close
Learning NGUI for Unity

Learning NGUI for Unity

4.7 (6)
By: Charles Bernardoff (EURO)

Overview of this book

Project teams rarely forget to work on the technology, but they often forget to work with the people, and no matter how amazing your new technology is, it’s useless unless people use it efficiently.
Table of Contents (12 chapters)
close
close
11
Index

Creating tooltips

Let's use the OnTooltip() event to show a tooltip for our buttons and different options, as shown in the following screenshot:

Creating tooltips

The tooltip object shown in the preceding screenshot, which we are going to create, is composed of four elements:

  • Tooltip: The tooltip container, with the Tooltip component attached.
  • Background: The background sprite that wraps around Label.
  • Border: A yellow border that wraps around Background.
  • Label: The label that displays the tooltip's text.

We will also make sure the tooltip is localized using NGUI methods.

The tooltip object

In order to create the tooltip object, we'll first create its visual elements (widgets), and then we'll attach the Tooltip component to it in order to define it as NGUI's tooltip.

Widgets

First, we need to create the tooltip object's visual elements:

  1. Select our UI Root GameObject in the Hierarchy view.
  2. Hit Alt + Shift + N to create a new empty child GameObject.
  3. Rename this new child from GameObject to...
CONTINUE READING
83
Tech Concepts
36
Programming languages
73
Tech Tools
Icon Unlimited access to the largest independent learning library in tech of over 8,000 expert-authored tech books and videos.
Icon Innovative learning tools, including AI book assistants, code context explainers, and text-to-speech.
Icon 50+ new titles added per month and exclusive early access to books as they are being written.
Learning NGUI for Unity
notes
bookmark Notes and Bookmarks search Search in title playlist Add to playlist font-size Font size

Change the font size

margin-width Margin width

Change margin width

day-mode Day/Sepia/Night Modes

Change background colour

Close icon Search
Country selected

Close icon Your notes and bookmarks

Confirmation

Modal Close icon
claim successful

Buy this book with your credits?

Modal Close icon
Are you sure you want to buy this book with one of your credits?
Close
YES, BUY

Submit Your Feedback

Modal Close icon
Modal Close icon
Modal Close icon