playMaker

Author Topic: Difference between "Vector Position" and "Transform Position" in iTween?  (Read 1239 times)

indeed

  • Junior Playmaker
  • **
  • Posts: 80
    • View Profile
Hi, sorry if this is really basic, but I just don't get it. What is the difference, for example in the iTween Move To action, between Vector Position and Transform Position? When would you use one and not the other?

Lane

  • Administrator
  • Hero Member
  • *****
  • Posts: 2487
  • Yup.
    • View Profile
    • Cleverous
Re: Difference between "Vector Position" and "Transform Position" in iTween?
« Reply #1 on: February 26, 2015, 09:28:31 AM »
Vector Position needs a Vector3 variable.
Transform Position needs a GameObject/Transform variable.

They're different Object Types. If you can supply a numerical Vector3, then use the Vector Position field. If you can supply a GameObject to target, then use the Transform Position field.

indeed

  • Junior Playmaker
  • **
  • Posts: 80
    • View Profile
Re: Difference between "Vector Position" and "Transform Position" in iTween?
« Reply #2 on: February 26, 2015, 09:42:05 AM »
Ah ok, that makes sense. I was just confused about best practices. Like, if I just want a cube to raise upwards, does it makes more sense to use one or the other? Both seem to work, just want to avoid any trouble as I build things. 

Lane

  • Administrator
  • Hero Member
  • *****
  • Posts: 2487
  • Yup.
    • View Profile
    • Cleverous
Re: Difference between "Vector Position" and "Transform Position" in iTween?
« Reply #3 on: February 26, 2015, 09:43:22 AM »
Whichever one serves your purposes better is fine.