- Home /
Unity 5 new UI Button Colliders moved to the left in different resolutions
Hey everybody!
In standard resolution which is 1680x1050 everything is working fine... but if I choose a different resolution in the "Display Resolution Dialog" it seems like the colliders on all buttons in my game are moved to the left...
So you can only click the buttons on their left half side, or even beside it!
I've got the same problem with clickfields in the game I created with 2DColliders and OnMouse functions!
Could it be a problem with Unity's built-in raycasting system? Or am I just missing something?
Please help me out! ;)
I have a similar problem. In addition, I have noticed that the screen seems to be stretched. $$anonymous$$aybe this problem is specific to certain video cards. I have a lap top with a GeForce GT 525$$anonymous$$ and get the problem in full screen at a resolution of 1024x768.
Are you setting the anchors of your Ui components properly ??? Because by not setting this properly you may face this problem
I am pretty sure the anchors aren't the problem. Also it looks to me like the entire screen is stretched horizontally, not just the GUI elements, the 3d view as well. It seems like what is happening is that the display driver is for some reason stretching the screen while the GUI system is continuing on as if the display isn't stretched. All the buttons on the left side work fine but the buttons on the right only work if you are left of them.
Have you tried the same in editor with different - different resolution, that all things are working fine there..
$$anonymous$$ay we can get the screenshots of the both.
In windowed mode or the editor it works fine, no matter what the size. It only goes wrong in full screen and only at certain resolutions. To make sure its not something going on in my code, I made a simple project with just a cube and a camera looking at the cube. When you run it in standalone at 1024x768 full screen, you can clearly see the cube is stretched. You can also see the unity logo is stretched at the beginning. In the image below, the top is what I expect to get and the bottom is what I get at 1024x768.
[1]: /storage/temp/52190-stretchbug.jpg
Your answer
Follow this Question
Related Questions
Only want to detect button click event 1 Answer
How to use button multiple times 1 Answer
Detect UI Button Click Event in Update method 3 Answers
Button position scaling weird 1 Answer
Raycasting UI components 3 Answers