Playmaker Forum
PlayMaker Help & Tips => PlayMaker Help => Topic started by: coxy17 on December 17, 2013, 05:07:08 PM
-
Hi
I need to get a camera to follow a input Axis based on a rotation. I have the following setup (screenshot attached) and have included a transform direction (top of screenshot) for testing but not sure where to go from here.
Setup.
I get the Axis and store it. (I specify the Multiplier to 1.)
I use Float Multiply to get the desired X number.
I rotate based upon the SideWay Input.
I can see the object rotates but doesnt take the camera with it.
thanks
Nick
-
This FSM is not on the camera?
You only need Get Axis and Rotate, but Rotate is pointing at the Owner object. What is the Transform Direction action for? Is the Camera a child of this FSM Owner?
-
Hi Lane,
Sorry should of explained further. I have this setup on the player and the camera separately (not child). The setup ive attached now is what 'Jean Fabre' provided me with a demo from another topic. I want to separate out the Horizontal and Vertical input Axis movements. But got to the point of the first screenshot to get a left turn.
What im after
3 seperate FSM for each axis. (left, right and forward) and to control them with keyboard key other than the standard input keys.
Thanks
Nick
-
Get Axis returns positive and negative values, just assign a Positive and Negative key in the Input Manager, call that pref in Get Axis, store it and Add Force/Translate every frame with the Get Axis result for Left and Right.
So you only need a Horizontal Get Axis+Add Force and a Vertical Get Axis+Add Force.
Forward can be handled by Get Axis+Add Force as well, just use it on Z(self) with a another Input.
From what you're explaining it just looks like your stack is overcomplicated to accomplish what you want, unless I'm just misunderstanding.
-
Hi,
You are not far away, I can rotate now just that i need the camera to follow with a slight delay to the players movement (last screenshot).
It works with the combination in the screenshot i added. So need to essentially separate it out into vertical and horizontal BUT keep the camera following. No worries if you are struggling to understand me.
Was hoping Jean would comment as i was recently talking to him about it in another topic before moving it here.
Nick
-
Do you have any examples of what you're trying to make? Like a YouTube video?
-
Its ok now, i have just Transformed Rotate and used what you advised its working ok now thanks. :) Must of been over complicating it.