I’m a beginner in Unity. I have read and practiced some tutorial articles about creating 2D game in Unity.
For mobile devices, I know that I need to build my games to iOS and Android mobile devices. However, how we can setup the screen solution (is it Camera ?) in Unity so my games can fit mobile devices ?
Could you please share some useful advice or links about this with me ?
Your actual problem is a bit unclear, but i’ll see if i understood what you want.
First of all, you must switch your project platform to the one you want to build to. For this, you go to File->Build settings, then choose the platform you want to build to and click the switch platform button (i’ve attached a pic of how the screen should look for android after you switch).
This should be the first step, now, secondly, you have to choose a screen size. For that, in your Game view, from the free aspect dropdown, select whatever screen size fits your project (i’ve attached another pic for you to see where to pick it).
Now lastly, designing a perfectly scalable UI for mobile is quite the challenge for a lot of people with Unity, but here are some links. You need to learn about the Canvas and how anchors work
Are you making a pixel art game?
Because that article only talks about how to make pixel art sprites look better on Unity’s ortographic camera.
You don’t need anything to scale sprites to multiple screen resolutions, Unity does that automatically for you.
Just drag a new sprite onto the scene, and then make the game view bigger. You’ll see that it scales.
The problem with different screen sizes is the User Interface (UI) → buttons, menu items and so on. Those don’t really scale, and you must use a Canvas to anchor and scale them properly. Don’t worry about the actual in-game art, if you’re using Sprites, then they will scale by themselves. As for the UI, the links i provided should provide you at least with some insight on what to look for.