04-14-2023, 06:37 AM
Hi
I have a Bezier spline, all normals pointin out (y direction) and it is not moving in z direction.
I then wish to create a specified GameObject on the cube, but when doing this it rotates the GameObject around y so the orientation no longer is correct.
i can se the same happens if i use "Quaternion.LookRotation(splineCurve.GetTangentByDistance(distanceAndOffset,Space.World))" then it turns the GameObject also on the y axis.
so the problem seems to be the spline but i cannot se the problem or what settings i should tweek.
do someone have an idea how to fix this
best regards
Nicolaj
I have a Bezier spline, all normals pointin out (y direction) and it is not moving in z direction.
I then wish to create a specified GameObject on the cube, but when doing this it rotates the GameObject around y so the orientation no longer is correct.
i can se the same happens if i use "Quaternion.LookRotation(splineCurve.GetTangentByDistance(distanceAndOffset,Space.World))" then it turns the GameObject also on the y axis.
so the problem seems to be the spline but i cannot se the problem or what settings i should tweek.
do someone have an idea how to fix this
best regards
Nicolaj