Wayback Machinekoobas.hobune.stream
May JUN Jul
Previous capture 12 Next capture
2021 2022 2023
1 capture
12 Jun 22 - 12 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
0
Question by bromley · May 11, 2016 at 04:39 PM · uitriggerpanelevent triggeringclicking

Event Trigger doesn't work!

I've created a UI Panel with a Text as Child and in the Panel I added a Event Trigger: I want that clicking on the panel, it calls a function of another object. I don't know why but it doesn't work.

Here a screen. alt text

Please help.

thtr.png (50.2 kB)
Comment
Add comment · Show 2
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 amdinis · May 11, 2016 at 04:48 PM 0
Share

Change the option "Runtime Only" to "Editor and Runtime" and check if it works.

avatar image bromley amdinis · May 11, 2016 at 06:00 PM 0
Share

unfortunately doesn't change anything

1 Reply

· Add your reply
  • Sort: 
avatar image
3
Best Answer

Answer by Flaring-Afro · May 11, 2016 at 06:43 PM

It sounds like the text child (and any other children) are blocking the click. Make sure they have "Raycast Target" unchecked. Any gameobject lower than the panel in the hierarchy also could block the click. Make sure they either aren't raycast targets or they aren't over the panel. Even if the part of the gameobject that you can view isn't blocking it, if the invisible rect transform dimensions go over the panel, they will block click events.

Comment
Add comment · Show 2 · 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 bromley · May 11, 2016 at 06:53 PM 0
Share

ok, i've unchecked raycast target, but nothing has changed here the child properties alt text

dfg.png (55.3 kB)
avatar image bromley · May 12, 2016 at 08:30 AM 0
Share

Solved! There were two problems: one of these has mentioned by Flaring Afro, in fact now i've unchecked all raycast target over this panel; the second one was a trigger problem, in fact it called an Asset object ins$$anonymous$$d a Scene object, so it was like doesn't exist. Now work good... thanks for the help ;)

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

72 People are following this question.

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

Related Questions

How would I detect a right click with an event trigger? 3 Answers

[C#] How to code within the Unity 4.6 new UI Panels? 0 Answers

How to adjust the screen resolution? 0 Answers

How to simulate GetKeyDown for a UI button 2 Answers

Canvas, Scroll Rect, Panels, Panes? 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