Forum rules - please read before posting.
Tech questions during the weekend? Drop in on the community Discord channel!

Inventory resizing when change resolution

Hi everyone,
AC 1.69.0 + Unity 2018.4.8f1 on a 2d game.

Hi, in these days I made the new Unity UI menus to link to AC menus and I follow the Resolution tutorial. All is ok but I have a little issue with the resize of the inventory menu when I change resolution at particular resolutions.
Here the results at different resolution (the correct one is 1920x1080):
1920x1080: https://drive.google.com/open?id=13x8pMRQunmda4Wt-2E95dg8eDXHGeMMC
1280x768: https://drive.google.com/open?id=1nasXByeM3_qgnj1QZRExBva1xCUyoKQX
720x576: https://drive.google.com/open?id=1C4ZPuPDmxmeZzuB1KH_PR9FX9Th9MJdx
640x480: https://drive.google.com/open?id=1fS4pYgx9yZ6cQheZ2RdHXvYNLaCE0DKh
All other menus are ok.

The actual inventory menu has 20 slot and the shift and right button are invisible (I want a "Fix" inventory). I tried Scale With Screen size (in canvas property) with Match Width Or Height to 0-0.5-1, but I can't reach the correct result for all the resolutions. In another thread someone suggests to force aspect ratio (in settings menu) to 1.7778 but seems not to work.
Is there some possible trick to solve it?

Thank you very much.

Comments

  • Each of the resolutions also change the aspect ratio. Are you locking your aspect ratio in the Settings Manager?

    AC won't affect your UI's display, so this seems to be more of a Unity UI issue. The upcoming v1.70 update, however, will introduce a new component called "Auto Correct UI Dimensions".

    When attached to a UI-based Menu's "RectTransform boundary", it can be used to re-position and re-size that RectTransform based on minimum and maximum anchor values. This allows, for example, the default Inventory menu to correctly span the width of the playable screen regardless of resolution or fixed aspect ratio. Hopefully it should be useful in this case as well.

  • Hi Chris: do you mean this Aspect ratio? https://drive.google.com/open?id=1qMKtaciZD-NgARGuTXLZmg6xqn8fzOkO or in some other place?

    In the project settings of unity (inside Player) I tried to uncheck the various Aspect Ratios, and it works correctly only with 16:9.

  • Yes, that's what I meant.

    Unity UI won't respond to the AC-enforced aspect ratio. The Canvas Scaler component will only react to the game window size. This is what the component I mention above should address.

  • Ok thank you, do you have a possible date for the upcoming v1.70?

  • I was planning for this week, but some last-minute showstoppers mean it'll likely have to be delayed a little longer, I'm afraid.

  • Don't worry, meanwhile I'm using AC version. Thank you.

Sign In or Register to comment.

Howdy, Stranger!

It looks like you're new here. If you want to get involved, click one of these buttons!

Welcome to the official forum for Adventure Creator.
Do NOT follow this link or you will be banned from the site!