We've all been there - you try to move a mesh from one place to another and once the little fellar is on his way via the vector, the little fellar is moving backwards (facing the opposite way it is moving) but is moving in the right direction:
Mathmatically, can the above be written to move the mesh but not reverse the way it is facing?
I played around with it a bit and managed to send the mesh on a negative vector (ie moving the right way and facing the right way), but the steering went wonky.
I'm just wondering if mathmatically this can be done? Perhaps, I am even doing the math wrong?
Some might suggest to 'RotateMesh' the mesh beforehand or load it into a modelling package and face it the opposite way. However, my problem is the characters are all rigged up with skeletons and stuff. If I try to flip them then they go all wonky like something out of 'The Thing'.
I feel that a solution to this problem benefits the community
bx#=EntityX(targetmesh)-EntityX(yourmesh) bz#=EntityZ(targetmesh)-EntityZ(yourmesh) bn#=Sqr(bx^2+by^2+bz^2) bx#=bx/bn bz#=bz/bn AlignToVector yourmesh,bx,0,bz,0,.1 MoveEntity yourmesh,0,0,.05
Mathmatically, can the above be written to move the mesh but not reverse the way it is facing?
I played around with it a bit and managed to send the mesh on a negative vector (ie moving the right way and facing the right way), but the steering went wonky.
I'm just wondering if mathmatically this can be done? Perhaps, I am even doing the math wrong?
Some might suggest to 'RotateMesh' the mesh beforehand or load it into a modelling package and face it the opposite way. However, my problem is the characters are all rigged up with skeletons and stuff. If I try to flip them then they go all wonky like something out of 'The Thing'.
I feel that a solution to this problem benefits the community