Why OgreNewtListener is so....

Mishra

07-01-2007 04:36:41

I don't want to blame anyone, but the OgreNewtFrameListener is really a mess. I know that walaber and the rest are simply making the wrapper, and shouldn't loose time making fixes in sample code, but for the rest of the community, it is a short and simple task...

All of those listener should call the inherited ExampleFrameListener::frameStarted method <Like Ogre examples do..>
and only proccess the OgreNewt Specific Input Keys <like space ,1,2,3(in the ragdoll demo), F3,etc.>
In the actual implementation, the code that processes the arrows and a,s,d,w is failing because of that: one moves the camera, and the other the scenenode, so in some cases, like when you fire a ball with space, the object is fired fron the position of the node, and not the camera. also the problem gets worse when you rotate after offsetting the camera.

I would fix it, but i don't have the CVS, neither the autorization to fix it, but as I see it, it's a very easy job...

PS: if I'm wrong and the code is there for something else, please let me know...

Gauntlet

10-01-2007 14:57:38

You can always sent a patch over CVS :)