Hi guys, to make my game fit all mobile screen sizes, I apply an offset to all the UIs which is calculated from the ratio between the viewport size and the default game screen size. When I playtest my solution on my Window device with different test screen sizes, it works perfectly fine.
However when I export the game to the Android device, most of the UIs are out of the screen. After printing the values, I realise that the get_viewport().size.x return 2400 px wide, but when I print a notifier position on exiting the screen, it shows the screen is actually 1700 px wide.
Does anyone face this issue before? My phone is Galaxy S20 if that helps.