Hello. I’m using a standard Unity GUI. I am trying to scale it to make my game playable on devices with different resolution. The problem is I can not figure out how to scale GUI properly according to the DPI of device’s screen.
I tried this method Unity3D: script to automatically scale gui elements on high dpi devices (like iPhone 4 or iPad 3rd Generation). · GitHub but for some reason it doesn’t work for me on my mobile phone but on PC it does work (but if I change the resolution at runtime it stops working).
I am attaching two screenshots. The first one is from my mobile phone and the second is from my PC!