Examples
I mentioned earlier in this chapter that a common usage of masks and scroll views is a menu with multiple items in it. So, for this chapter, we’ll only create one example, a scroll view from a pre-existing menu, by mimicking the layout of the Scroll View UI object.
Making a scroll view from a pre-existing menu
To help organize the project, duplicate the Chapter11-Examples
scene that you created in the last chapter; rename it Chapter12-Examples
. Open Chapter12-Examples
and complete the following example within that scene.
I want to be able to add more items to my Inventory Panel
and allow the player to scroll through the items. I could create a new UI Scroll View item and update it to look like my current Inventory Panel
, but that would be more hassle than it’s worth. So, instead, I will convert the current Inventory Panel
to a scrollable view. After it is complete, it will look like the following figure:
Figure 12.17: The scrollable...