PC Screen resolution problem

Hi! I am finishing a little game that I would like to export as a PC standalone. Right now I have a problem with different screen resolutions. I have developed everything with 1366x768 in mind and I would like the game to be scaled for smaller resolutions or different aspect ratios.

Any ideas on how I could do this?
Thank you for your time.

Specify everything in relative sizes and positions. Schell Games did a good presentation on this at Unite 11, but the video isn’t online any more. Their presentation notes still are: http://unite.schellgames.com/

For example, say you have a chat window in the lower left corner that’s 683x192 pixels, or half the screen wide by one quarter screen tall. Its resolution-dependent rectangle would be specified as (0,576) - (683,767).

Instead, specify it like this:

  • Upper left: (0, 0.75*Screen.height)
  • Size: (0.5Screen.width, 0.25Screen.height)

If you want to make sure that it doesn’t get too small on low-resolution screens, add a minimum pixel size constraint:

  • Minimum pixel size: (512, 256) (example)

You can get fancier by adding an anchor specifier so that the rectangle can be computed from a corner other than the top left, such as the middle left, bottom left, bottom right, etc.

At runtime, your game can compute the actual screen rect based on the current values of Screen.width and Screen.height.

I guess my case is different. I am finishing a snake game and I use a bunch of sprites to limit the playing area. I want to have that playing area delimited so that it matches the screen edges…

I am using an orthographic camera. Is there a way to change the orthographic size so that the whole thing scales up?

You can’t just change the orthographic size if the aspect ratio is different. But you could use anchor specifiers to align sprites to various edges of the screen, and maybe some filler sprites to fill in any gaps in different aspect ratios.