Playmaker Forum
Bug Reporting => PlayMaker Bug Reporting => Topic started by: Sjones on September 17, 2012, 06:59:26 AM
-
the self space doesn't work in get position it still works in world space, could be the same for rotation.
there may be an issue with set position and rotation too.
how to:
fsm with get position.
specify game object
play level
set unity move to local from global
move object in local space
observe get position store vector in world space with space set to either self or world.
-
can anyone confirm this? or is it something I am doing wrong, I am using this for a camera control, after rotating the camera and scrolling around it moves in the direction it was before it rotated, thus moving in the world axis and not local.
thanks
-
Hi,
Can you provide a sample? I can't really get my head around what you are explaning :)
bye,
Jean
-
hi, sorry for any confusion, please find attached a quick level, in it the camera moves on the camera fsm
the position is posted to the screen in its world X,Y,Z position and also its self (I call local) X,Y,Z position
the camera move fsm has a start and stop, just make it go to the next state to activate
the camera move is set to get and set its position in self space
note that the position posted to the screen for the self and world are the same
expected result the camera to move in its self Z and not the world Z axis
also moving it in editor while the scene is running in local mode all co-ordinates update in world position
-
Hi,
your file doesn't want to open at all. I double click on it and it doesn't fire anything in Unity...
what Unity version are you using?
bye,
Jean
-
I am using 3.5.5f3 I re-opend the file on my computer and was fine, I tested it on my laptop and I had the exact same problem, to fix it I had to put it into the asset folder of a project and then open it in the project tab within untiy, it then opened up fine, if this fails to work for you I will get some screen shots or video
-
HI,
ok, the camera is not attached to anything, hence its local position IS world position. but here that would not help anyway:
Make sure you fully read the unity doc on transform, because it does behave slightly different from what you could be used in 3d soft like mx or maya.
when you query the position of gameObject, you will always get the world position, not the local position, you need to explicitly query for the local position to get it.
bye,
Jean
-
Thank you very much for the info, I understand the difference and think I have found a solution for what I was expecting, putting this as solved