1
\$\begingroup\$

I am a beginner in the game development world, I have just one quick problem with the UI, as you can see during the Unity Player, the UI (Raw Image w/ Texture) is normal in size but when I build my game to APK or EXE and run it, the UI is small. Why is this happening and how to fix it? enter image description here

\$\endgroup\$
2
  • \$\begingroup\$ Curious, why are you using RawImage components here instead of UI Image components with sprites? The latter will tend to have better performance due to batching. \$\endgroup\$
    – DMGregory
    Jul 10, 2018 at 11:11
  • \$\begingroup\$ DMGregory is right. Also, use the anchor to adjust with every UI size. \$\endgroup\$
    – Saad Anees
    Jul 10, 2018 at 11:17

1 Answer 1

2
\$\begingroup\$

From the information you provide it is most likely to assume that the elements that are getting wildly resized are all UI-Elements.

When placing UI-Elements, by default, Unity puts them into pixel-fixed positions rather than relative-positions. To fix that set the Ui Scale Mode on the Canvas holding all your UI-Elements to Scale With Screen Size, as detailed in this answer on Unity Answers.

enter image description here Screenshot from the linked Unity Answer in case it will ever go down.

\$\endgroup\$

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .