playMaker

Author Topic: Transform.localPosition  (Read 1912 times)

FritsLyn

  • Full Member
  • ***
  • Posts: 191
    • View Profile
Transform.localPosition
« on: August 12, 2015, 05:42:17 AM »
Hi, the good old

Get Collision Info
https://hutonggames.fogbugz.com/default.asp?W369

is returning world coordinates for Contact Point.

Now I'd like to know in 'Local space' if this is in front or at the rear of my spaceship.

So, in Unity scripting, I'd use
Transform.localPosition
http://docs.unity3d.com/ScriptReference/Transform-localPosition.html

- and I'd think it'd be a walk in the park to just do that in PlayMaker.. but strangely I'm stuck.. (other than I could of course set an empty at the world etc etc - but there must be a simple way?!

I'm sure this is going to be a d'oh!

Hit me :D

terri

  • Sr. Member
  • ****
  • Posts: 373
    • View Profile
    • terrivellmann.tumblr.com
Re: Transform.localPosition
« Reply #1 on: August 12, 2015, 08:33:06 AM »
Have you looked at Inverse Transform Point?

FritsLyn

  • Full Member
  • ***
  • Posts: 191
    • View Profile
Re: Transform.localPosition
« Reply #2 on: August 12, 2015, 10:34:12 AM »
Have you looked at Inverse Transform Point?

d'oh! :D

Thanks Terri!

(That has got to be the worst PlayMaker lingo ever!)

terri

  • Sr. Member
  • ****
  • Posts: 373
    • View Profile
    • terrivellmann.tumblr.com
Re: Transform.localPosition
« Reply #3 on: August 12, 2015, 11:20:27 AM »
Have you looked at Inverse Transform Point?

d'oh! :D

Thanks Terri!

(That has got to be the worst PlayMaker lingo ever!)

np, not playmaker lingo though, it's unity: http://docs.unity3d.com/ScriptReference/Transform.InverseTransformPoint.html

FritsLyn

  • Full Member
  • ***
  • Posts: 191
    • View Profile
Re: Transform.localPosition
« Reply #4 on: August 12, 2015, 11:58:37 AM »
Oh wow.. that and Transform.localPosition.. I'm getting dizzy!

But thanks a bunch :)