Hi ledahut,
Oh, ok, I think I get it now.
I have run into another issue now though
I have defined everything inside a game class init() function.
The issue I have is that when I go to use the callbacks to these functions:
void PhysicsApplyForceAndTorque (const NewtonBody* body);
void PhysicsSetTransform (const NewtonBody* body, const dFloat* matrix);
It throws two errors:
error C3867: 'Game::PhysicsSetTransform': function call missing argument list; use '&Game::PhysicsSetTransform' to create a pointer to member
error C3867: 'Game::PhysicsApplyForceAndTorque': function call missing argument list; use '&Game::PhysicsApplyForceAndTorque' to create a pointer to member
My pointer and reference skills aren't too good.
Am I on the right track here?
Somebody mentioned on a google search that you can't callback a memeber function unless you make them static?
I got this when I made the two functions static:
1>c:\users\joe\documents\visual studio 2008\projects\irrlicht1\irrlicht1\src\game.cpp(139) : error C2664: 'NewtonBodySetTransformCallback' : cannot convert parameter 2 from 'void (__cdecl *)(const NewtonBody *,const float *)' to 'NewtonSetTransform'
1> None of the functions with this name in scope match the target type
1>c:\users\joe\documents\visual studio 2008\projects\irrlicht1\irrlicht1\src\game.cpp(140) : error C2664: 'NewtonBodySetForceAndTorqueCallback' : cannot convert parameter 2 from 'void (__cdecl *)(const NewtonBody *)' to 'NewtonApplyForceAndTorque'
1> None of the functions with this name in scope match the target type
Not sure what to do now?
Thanks for your help!