How to move Character on Top of moving Vehicle?

I’m trying to make a game where 1 player will control a vehicle and the other one will control a character on the top of it.
For my character I’m using 3D Buzz’s Custom 3rd Person Character(http://www.3dbuzz.com/vbforum/content.php?212), I followed the tutorials and for my vehicle I’m using “Edy’s Vehicle Physics” package…

I tried parenting the player to the vehicle, it doesnt work at all. When the car moves the player just stands still, but somehow the character does rotate like the vehicle does.

The character uses the default CharacterController component from unity and I call it’s Move() method to move around. For the car I’m not really sure how it moves, the scripts looks very complex.

I can provide some code if that helps. Any sugestion is greatly appreciated (like diferent ways to achieve what I want).

@EDIT - Copy of my answer post

"Bump!..

So, it did not work, even after alot of effort. I tried parenting the player to the vehible by code but it didn’t solve the problem, when i accelerate the car, the player just stays in its original position and fall off the vehicle once it isn’t bellow the player anymore. Again, to move the character I use the CharacterController.Move() method, and my vehicle uses a custom vehicle physics package.

How can I get my player to move with the vehicle? on top of it.

Thanks in advance"

Did you just drop the child in the parent’s game object in the inspector or did you actually write code to apply the transform of the child to the transform of the parent? That is all you really need to do to get this working.

for instance… if you wrote something like this and applied it to the player who is the child of the vehicle:

Transform.parent = transform;

For more information look up the docs here. Should get you going:

Try Physics Fixed Joint, as i guess your vehicle is using physics and is not kinematic. (That’s what I did for my player riding a horse, and I too started off from 3dbuzz’s char controller, but has changed beyond recognition now)

Bump!..

So, it did not work, even after alot of effort. I tried parenting the player to the vehible by code but it didn’t solve the problem, when i accelerate the car, the player just stays in its original position and fall off the vehicle once it isn’t bellow the player anymore. Again, to move the character I use the CharacterController.Move() method, and my vehicle uses a custom vehicle physics package.

How can I get my player to move with the vehicle? on top of it.

Thanks in advance