1
\$\begingroup\$

I am new to Unity. As a learning project, I started to make a very basic car racing game. In order to add an on-screen speedometer for my car, I imported an image UI.

The problem is that I can't set a source image for my speedometer UI. I tried using .jpg .png or .psd image files as well. In any case, I'm not able to drag and drop the image.

Under the list Source Image, I already have selected UISprite from the drop-down list, but still, I'm not able to set source image.

Can anyone provide me any solution? I also have attached a screenshot of what I have.

enter image description here

\$\endgroup\$
  • 1
    \$\begingroup\$ Make sure that your image imported as a sprite not a texture. Select your image and in the inspector into import setting chose (sprite and ui.) \$\endgroup\$ – klaymen Oct 29 '16 at 22:15
3
\$\begingroup\$

Click on the imported image. You should see a dropdown in the inspector that says "texture". Change it to "sprite and UI" if not already. Now you should be able to change the source image of the blank image to your desired image.

|improve this answer|||||
\$\endgroup\$

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.