• 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 Stefan 3 · Mar 16, 2011 at 01:01 PM · itweenpathmoveto

iTweens MoveTo and "path" property

Hi there,

I don't know, what I'm doing wrong here, but I can't seem to use the "path"-property wit$$anonymous$$n MoveTo. Here's the code snippet I use:

iTween.MoveTo(gameObject, iTween.Hash("path",iTweenPath.GetPath("Path1"), "time",5));

or more explicitely t$$anonymous$$s one:

iTween.MoveTo(gameObject, iTween.Hash("path",[Vector3(1,2,3),Vector3(2,1,3),Vector3(3,2,1)], "time",5));

The object to w$$anonymous$$ch the code is attached doesn't move at all. However if I add "movetopath",false it will stick right to the first node of the path - but won't move as well.

iTween was a big help so far and I checked the examples for PutOnPath and PointOnPath but the Path-Editor + MoveTo seems more like the solution for me because of the easing for the movement.

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

7 Replies

· Add your reply
  • Sort: 
avatar image
1

Answer by pixelplacement · Mar 16, 2011 at 04:04 PM

That's odd - are there any other scripts on the GO?

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 Stefan 3 · Mar 16, 2011 at 04:13 PM 0
Share
avatar image Stefan 3 · Mar 16, 2011 at 04:25 PM 0
Share
avatar image
1

Answer by pixelplacement · Mar 31, 2011 at 09:24 PM

Is t$$anonymous$$s resolved?

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 Stefan 4 · Apr 09, 2011 at 07:30 PM 0
Share
avatar image Wolfram · Jun 26, 2012 at 11:50 PM 0
Share
avatar image
0

Answer by Stefan 4 · Mar 17, 2011 at 01:46 PM

I prepared a simple and small test-project. Perhaps someone can figure it out. I might be totally wrong, with what I'm doing, so any help would be much appreciated!

Here's the file: http://www.sendspace.com/file/2se5fr

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 ben · Mar 18, 2011 at 11:34 AM

surely it ll work specify the name of the path u have created correctly

iTween.MoveTo(gameObject, iTween.Hash("path" , iTweenPath.GetPath("CamPathForward"), "time" , 10, "easeType", iTween.EaseType.easeInOutSine));

CamPathForward - path name ...v created using pathEditor script

Comment
Add comment · Show 3 · 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 Stefan 4 · Mar 19, 2011 at 07:50 PM 0
Share
avatar image ben · Mar 24, 2011 at 04:42 AM 0
Share
avatar image Stefan 4 · Apr 09, 2011 at 07:24 PM 0
Share
avatar image
0

Answer by newnixon · Apr 30, 2012 at 04:34 PM

I am having a similar issue. I have a truck with a camera inside the cab showing all the different types of radios. I have a gui that you click to take down each path depending on w$$anonymous$$ch radio you choose. The itween paths work and it flows well, the issues comes in when I attach a script to the camera to make it look to a cube that i have animating using moveto. I couldn't figure out how to rotate the camera toward an object once the path ended so I use the

void Update () { transform.LookAt(target);

 }

The target is the cube.

T$$anonymous$$s works but he camera is jittery as it travels down the path to look at the cube. If I take off the LookAt script, the camera runs smooth but the camera is not looking at the object. There is no colliders on the box. Do you have any solutions?

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
  • 1
  • 2
  • ›

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.

Welcome to Unity Answers

If you’re new to Unity Answers, please check our User Guide to help you navigate through our website and refer to our FAQ for more information.

Before posting, make sure to check out our Knowledge Base for commonly asked Unity questions.

Check our Moderator Guidelines if you’re a new moderator and want to work together in an effort to improve Unity Answers and support our users.

Follow this Question

Answers Answers and Comments

3 People are following this question.

avatar image avatar image avatar image

Related Questions

iTween MoveTo + Rotation? 2 Answers

Go back to first node (itween + moveto) 2 Answers

iTween, moving to a node on a path. 1 Answer

iTween - look for new path, move to or reverse at end? 0 Answers

iTween Camera Jitter while moving on path 2 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