The direction is correct JPCT coordinates != OpenGL coordinates
But sth is wrong with position.
The position of the red box is 0, 0, 0.
The car (bigger red box) moved to 0, 0, -20. The light changed x and z coordinates.
But sth is wrong with position.
Code Select
car.carBody.object3d.getTransformedCenter(position);
light.setPosition(position);
The position of the red box is 0, 0, 0.
The car (bigger red box) moved to 0, 0, -20. The light changed x and z coordinates.