• Products
  • Solutions
  • Made with Unity
  • Learning
  • Support & Services
  • Community
  • Asset Store
  • Get Unity

UNITY ACCOUNT

You need a Unity Account to shop in the Online and Asset Stores, participate in the Unity Community and manage your license portfolio. Login Create account
  • Blog
  • Forums
  • Answers
  • Evangelists
  • User Groups
  • Beta Program
  • Advisory Panel

Navigation

  • Home
  • Products
  • Solutions
  • Made with Unity
  • Learning
  • Support & Services
  • Community
    • Blog
    • Forums
    • Answers
    • Evangelists
    • User Groups
    • Beta Program
    • Advisory Panel

Unity account

You need a Unity Account to shop in the Online and Asset Stores, participate in the Unity Community and manage your license portfolio. Login Create account

Language

  • Chinese
  • Spanish
  • Japanese
  • Korean
  • Portuguese
  • Ask a question
  • Spaces
    • Default
    • Help Room
    • META
    • Moderators
    • Topics
    • Questions
    • Users
    • Badges
  • Home /
avatar image
1
Question by SarkanyIndustries · Aug 15, 2015 at 03:56 AM · uiraycastbuttonresolutionclick

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! ;)

Comment
Add comment · Show 12
10 |3000 characters needed characters left characters exceeded
▼
  • Viewable by all users
  • Viewable by moderators
  • Viewable by moderators and the original poster
  • Advanced visibility
Viewable by all users
avatar image paulgaze · Aug 17, 2015 at 04:09 AM 1
Share

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.

avatar image itsharshdeep · Aug 17, 2015 at 05:10 AM 1
Share

Are you setting the anchors of your Ui components properly ??? Because by not setting this properly you may face this problem

avatar image paulgaze · Aug 17, 2015 at 05:52 AM 1
Share

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.

avatar image itsharshdeep · Aug 17, 2015 at 08:49 AM 1
Share

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.

avatar image paulgaze · Aug 17, 2015 at 12:25 PM 1
Share

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

stretchbug.jpg (34.5 kB)
Show more comments

0 Replies

· Add your reply
  • Sort: 

Your answer

Hint: You can notify a user about this post by typing @username

Up to 2 attachments (including images) can be used with a maximum of 524.3 kB each and 1.0 MB total.

Follow this Question

Answers Answers and Comments

6 People are following this question.

avatar image avatar image avatar image avatar image avatar image avatar image

Related Questions

Button is not being clicked. 1 Answer

Button position scaling weird 1 Answer

Raycasting UI components 3 Answers

UI button and raycast script that I have made both aren't working to change my scene 1 Answer

How do I make a UI button to click a key? 1 Answer


Enterprise
Social Q&A

Social
Subscribe on YouTube social-youtube Follow on LinkedIn social-linkedin Follow on Twitter social-twitter Follow on Facebook social-facebook Follow on Instagram social-instagram

Footer

  • Purchase
    • Products
    • Subscription
    • Asset Store
    • Unity Gear
    • Resellers
  • Education
    • Students
    • Educators
    • Certification
    • Learn
    • Center of Excellence
  • Download
    • Unity
    • Beta Program
  • Unity Labs
    • Labs
    • Publications
  • Resources
    • Learn platform
    • Community
    • Documentation
    • Unity QA
    • FAQ
    • Services Status
    • Connect
  • About Unity
    • About Us
    • Blog
    • Events
    • Careers
    • Contact
    • Press
    • Partners
    • Affiliates
    • Security
Copyright © 2020 Unity Technologies
  • Legal
  • Privacy Policy
  • Cookies
  • Do Not Sell My Personal Information
  • Cookies Settings
"Unity", Unity logos, and other Unity trademarks are trademarks or registered trademarks of Unity Technologies or its affiliates in the U.S. and elsewhere (more info here). Other names or brands are trademarks of their respective owners.
  • Anonymous
  • Sign in
  • Create
  • Ask a question
  • Spaces
  • Default
  • Help Room
  • META
  • Moderators
  • Explore
  • Topics
  • Questions
  • Users
  • Badges