I am creating a health bar for a 2D game, and would like to use the Image API. I have a sprite to use for the game player’s health status, and want to make use of the Image API’s Filled property.
I’m having a problem with the image showing up, though. If I create a gameobject, and attach a sprite to it with a sprite renderer, then I have no problems and it shows up fine. However, if I attach an image to a gameobject, and the sprite to that image, the image doesn’t show up in the scene or in the game, and Z-layering does not appear to be an issue.
What am I doing wrong that is making my image not render?