playMaker

Author Topic: Can you only Set and Get the position of the z-axis?  (Read 1520 times)

Adam Z

  • Full Member
  • ***
  • Posts: 207
Can you only Set and Get the position of the z-axis?
« on: October 27, 2015, 02:13:50 PM »
I'm putting together a full-body awareness camera system, so when you're in first person mode and you look down, you see your chest and feet, etc.  I'm moving the camera to a Game Object that's a child of the head bone on every frame, which works for the most part. The problem is that the camera is also moving dependent on the animation, which isn't what I want. If I only move the camera to that targets position and not update it every frame that works fine, but as soon as my character moves I get some clipping since the animation has forward leaning when moving forward.

A solution to this would be to update only the z-axis position every frame, but I'm not sure how to Get and Set only that float.  It seems that those Actions require all 3 float positions.  Any thoughts?

Thanks!


MattBradley

  • Playmaker Newbie
  • *
  • Posts: 25
Re: Can you only Set and Get the position of the z-axis?
« Reply #1 on: October 27, 2015, 02:41:06 PM »
With get and set position you can get and set each axis individually. Just leave the X and Y as 'none' and set the Z value you need.

Unless I misunderstand your problem?

Adam Z

  • Full Member
  • ***
  • Posts: 207
Re: Can you only Set and Get the position of the z-axis?
« Reply #2 on: October 27, 2015, 03:58:36 PM »
I never tried actually creating separate floats, so thanks for that tip. I'll see if I can get it working now...