Immediate applyRotation()

Is there a way to apply rotation immediately in a script? A way that doesn’t involve directly manipulating the transform matrix, or if that’s unavoidable an easy way to do it.

I’ve made a skybox by using a background scene, I’m matching the camera position (which is multiplied down to simulate parallax) and rotation (unmodified) of the skybox scene. No matter what I do the rotation of the skybox scene camera’s rotation is one frame behind, which is ver noticable. I’m using the blendertutorials fps mouselook script to get my camera rotating, which relies on motion actuators.

I tried replacing the actuators with applyRotation, which works, but still results in a delayed rotation.

Thanks for any help.

I think the problem lies in how you’re getting the camera position and orientation, rather than how it’s applied; if you do it by storing them in a global variable which is read by the skybox camera, then the skybox camera’s script is probably running before the main camera, so it has to wait a frame to get the proper values. Also, if the rotation is unmodified, why not just use own.worldOrientation=camOrientation (where camOrientation is the orientation of the main camera, from wherever you got it)? After all, you don’t have to modify it in any way, so it should just work.