Download

Mobile game scaling issue for level objects

Hi! I have just developed the main functionality for my puzzle mobile game, and am ready for adding the good looking graphics. The main play area is based on functionality on level objects (world space), while the UI elements are based on UMG Widgets, which works good with dpi scaling using anchors.

Before going to the work here, I have a few things that I need to sort out.

  1. How do I ensure that my world space interacting play area aligns to the center of the screen independently of mobile device, also keeping 1:1 ratio on the geometry? Now I have just placed an ortho camera actor above the puzzle area.

  2. I have a gfx background, which also has eg. a nice border for the puzzle area. I need it to be aligned correctly as well. Should I place gfx like that in the level world space or should I place it in the UMG Widget? If UMG Widget, should I create a new UMG Widget just for the background, or would it be wiser to have it in the same widget as the HUD elements (sounds the easiest and simplest)? I tried to place it in the widget, but couldn’t get it behind the world space puzzle objects in z order on the Add to viewport node, even set with -200.

I have read through some scaling documentation, but eighter I missed just these points, or these specific subjects didn’t get mentioned in the material I read. I am surprised I can’t find more hits on this topic, as I presume that most mobile games has solved this somehow. Hopefully I have just overlooked something obvious.

Can anyone please direct me into the bliss here? Thank you.

Bump, anyone with any insight?