Here we are at the last section of this chapter. As we know from the last step, we need a way to show the number of rockets left on the screen. In this step, we will create the rocket UI, which will show the number of rockets left and the rocket graphics. We will use both GUITexture and
OnGUI() to create the UI.
This is the last section, which will create the
RocketUI script to display the remaining rocket bullets on the screen:
RocketUI. Then, double-click on it to open MonoDevelop and replace the script as follows:
public var rocketLauncher : RocketLauncher; public var customSkin : GUISkin; public var width : float = 80; public var height : float = 25; ...