Wayback Machinekoobas.hobune.stream
May JUN Jul
Previous capture 13 Next capture
2021 2022 2023
1 capture
13 Jun 22 - 13 Jun 22
sparklines
Close Help
  • 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
3
Question by Bill 2 · Mar 15, 2011 at 02:49 PM · guifullscreen

button doesn't work when in full screen mode

hi all,

hopefully a simple problem here. I have a simple gui button that works fine when in windowed mode but not in full screen mode.

if (GUI.Button (Rect (Screen.width - 128,0,128,27), "", "optionBtn")) { //do stuff }

when in full screen mode, the hover over the button triggers the change in the graphics but the click just doesn't do anything. Am I missing something simple?

Thanks in advance

Comment
Add comment · Show 7
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 Statement · Mar 15, 2011 at 03:01 PM 0
Share

It's because all your if-test execution code is a comment! :) Joke aside, I've been seeing this problem happen frequently (in other questions). Try this with $$anonymous$$imal code in the gui to rule out other possibilities. if (button) { print it works } sort of style.

avatar image FLASHDENMARK · Mar 15, 2011 at 03:19 PM 0
Share

For some reason people from Sweden always have a "thing" with humor and jokes, though that is a good thing :)

avatar image Statement · Mar 15, 2011 at 03:25 PM 1
Share

It's because our women leave us for new men all the time, and our liquor is dead expensive due to heavy taxes and monopoly. To top this off you were smart enough to take on an education that puts you in debt for 30 years and still you're not finding any jobs. The only way to stay happy is pull a bad joke once in a while. :)

avatar image Uzquiano · Mar 15, 2011 at 03:53 PM 0
Share

Hi, I think it is because of Rect() staff. Right now I am fighting with the appearance of a GUILayout.Window(Rect(),...) that in windowed mode it shows ok but in full stays in the same point as in the windowed mode.

Try to change your Screen.width by a absolute point, e.g., 400 ins$$anonymous$$d of Screen.width

hope you can fix it, and please let me know if you managed, and if so how?

Cheers

avatar image Bill 2 · Mar 16, 2011 at 08:49 AM 0
Share

other buttons in my gui, created in the same way, work fine in fullscreen mode. It is just this one that sits in the top right corner of the screen. Another strange thing is that if you click around the button a lot, the click will usually register eventually.

Uzquiano - I'll give that a go.

Thanks for the replies and the jokes ;-)

Show more comments

3 Replies

· Add your reply
  • Sort: 
avatar image
0

Answer by Konsul · May 02, 2011 at 06:14 AM

I think that I have the same problem. My topic is here: http://forum.unity3d.com/threads/87496-Focus-is-shifted-in-GUI In my case it concerns only some aspect ratios.

Comment
Add comment · Share
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
0

Answer by spatton · Aug 27, 2011 at 11:51 PM

It could have to do with Windows being in classic mode of XP style. In Classic mode the shift occurs in fullscreen mode, in XP style it works fine.

Comment
Add comment · Share
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
0

Answer by unity_sgstarade · Jan 25, 2019 at 09:11 AM

Whenever you opt to play in fullscreen, first click somewhere in the scene and then go ahead with your gameplay keys. It worked for me.

Comment
Add comment · Share
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

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

2 People are following this question.

avatar image avatar image

Related Questions

Full Screen Get smaller when i actived it 1 Answer

full screen and resolution 1 Answer

In-Game Fullscreen Button 1 Answer

The texture fits the screen size but not the display of the score. 0 Answers

GUI.TextField problem, won't update var. 0 Answers


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