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 cartman412 · Sep 19, 2011 at 02:21 PM · c#mouse-drag

Using onmousedrag to interact with gameobjects

Hello!

I've been looking around the forum and this q&a section for a solution to my problem but i couldn't find anything helpful to my issue.

So basically right now I have a player and a sliding door. Currently the door simply slides when the player presses down a button. Instead I would like to have a small animation (player holding the door handle) and then use the mouse as if it were the players arm to open the door.

How would you recommend i'd go about doing it?

Cheers!

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

1 Reply

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

Answer by syclamoth · Sep 19, 2011 at 02:50 PM

Try making the door itself to the animation, and then use an IK controller of some kind to make the hand stick to the handle. There is a decent simple IK controller in the Unity Locomotion System, but it'll take a bit of work to get it to go nicely with your animations. All in all, there's no simple one-click solution, but if you're not afraid of a bit of coding then you can do this using IK solvers in script.

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 cartman412 · Sep 20, 2011 at 07:45 AM 0
Share

so i'm fairly new to unity in general and even more to the Locomotion System. What exactly would I need to make this work?

I would also like to have this sort of interaction with other objects in the scene that can actually be moved around like bags etc.

Any tips? It seems there isn't much help available online for this extension.

avatar image syclamoth · Sep 20, 2011 at 10:05 AM 0
Share

No I'm afraid not! I must admit that what I did with it was somewhat hacky- I used the I$$anonymous$$Simple class on my animations, and then wrote a seprate script for blending it in and out on command. This is not functionality the Locomotion System provides normally- I am simply re-purposing one of its internal mechanisms to do what I want. There are probably better solutions out there, but this is how I solved it (pun not intended)

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

3 People are following this question.

avatar image avatar image avatar image

Related Questions

Distribute terrain in zones 3 Answers

The name 'Joystick' does not denote a valid type ('not found') 2 Answers

Multiple Cars not working 1 Answer

This code only with Right Mouse Drag? 1 Answer

Where can I find tutorials for scripting in c#?? 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