Now that we have a volume slider, let's add an enable/disable sound checkbox, which will turn down the volume to 0 and hide our volume slider.
First, create a toggle widget as follows:
- Select the Panel GameObject and create a new child with Alt + Shift + N.
- Rename that new child as
Sound. It will be our sound toggle container.
- Navigate to NGUI | Open | Widget Wizard and perform the following steps:
- Select Toggle as Template.
- Select the Dark Sprite as Background.
- Select the X Sprite as Checkmark.
- With the Sound container selected, click on the Add To button.
A checkbox with a label has just been created as shown in the following screenshot: