August 2018
Intermediate to advanced
794 pages
28h 4m
English
In the script class PlayerInventoryDisplay the Image variable imageStarGO is a reference to the UI Image object Image-star-icon. The sprite variables iconStar and iconNoStar are references to the Sprite files in the Project panel - the sprites to tell the player whether or not a star is being carried.
Each time method OnChangeCarryingStar(carryingStar) is invoked by the PlayerInventory object, this method uses an if statement to set the UI Image to the sprite that corresponds to the value of the bool argument received.
Read now
Unlock full access