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
0
Question by dmcdonough · Jan 18, 2012 at 10:45 PM · collidermeshmouseonmouseuponmousedrag

OnMouseUp not always firing on mesh that is changing

Got a situation where a runtime-built mesh is changing based on user input: the user drags the mouse over the mesh, and based on where they move it we move the verts around and rebuilding the mesh frame-by-frame. The mesh change occurs only when during a mouse drag. What we're seeing is that the mesh will detect and fire an OnMouseDown and OnMouseDrag callback when the user begins their motion, but won't always register an OnMouseUp when they release.

I've debugged some and found that if you drag the mouse into a fresh, unchanged area of the mesh, the OnMouseUp callback will not happen. But, if you drag around in a previously modified area of the mesh, it will occur. It seems to be that if the mouse is released over a part of the mesh that was changed during that drag sequence, OnMouseUp simply does not occur.

Any ideas?

Comment
Add comment · Show 1
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 BalsamicVinegar · Jan 18, 2012 at 10:59 PM 0
Share

What type of collider are you using? Primitive or mesh? If it works on un-changed sections of the mesh but not on modified sections, I dare say it has nothing to do with the mouse up function. Go through the game frame by frame and see if your collider is being updated with the changes. $$anonymous$$y guess is that it is not updating. Try calling recalculateBounds on the new mesh.

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

5 People are following this question.

avatar image avatar image avatar image avatar image avatar image

Related Questions

Can I enable/disable a collider so it will/won't detect mouse clicks? 5 Answers

Pushing a mesh with mesh collider 1 Answer

Having trouble getting a smooth collision with dynamic mesh collider 0 Answers

How to remove internal triangle/faces when combining mesh 0 Answers

How do I use a mesh collider With .blend? 3 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