Playmaker Forum
PlayMaker Help & Tips => PlayMaker Help => Topic started by: PET on September 08, 2015, 10:30:35 AM
-
Hello guys,
I'm working on a 3D Shmup. Just so you have an idea it looks something like this:
http://puu.sh/k4dkH/f9c5efab79.jpg
I'm working on the movement controller and I'm not sure how to do it. This is what I have right now.
http://puu.sh/k4di7/9e6fd8ee72.png
I just listen for an AXIS EVENT and whenever that happens I send the ship to that state.
I also have a "Translate" that basically moves the player at the current camera speed.
What do I set up on the move states? I tried some Translate... it works but I'm not sure how to get back to the main state to check for other movements. I also want to be able to move diagonally so I need 2 states at the same time.
Any suggestion how to do this better?
Thank You for your help.
-
Couldn't you use a character controller + FSM with get axis vector, simple move? Set the controller on an empty object on the ground plane and parent your 3d ship object above the ground to the controller.
-
You mean something like this?
http://puu.sh/k58YM/3adddecf46.jpg
However I'm still not sure how to do the FSM since I'm a bit more confused now :D
Thanks
-
Put the fsm on the controller not the ship, one state, two actions: Get axis vector save as variable, simple move by that variable. You won't be directly moving the ship, it will just look like you are.
-
http://puu.sh/k5cmP/22ad7a0b90.png
Thanks. This works surprisingly well.
Now I have to tilt the ship when moving right/left ...
and get rid of the inertia. The ship is not 100% precise. When I lift the button the ship still drags into that direction a bit.
-
You can increase the "Drag" on the rigidbody component and the ship will stop faster. If that is what you mean it keeps moving after you stop controlling.