half of them is to "search weapons and camera"
another half is to set the weapon as a child of camera
it works for x,y,z translation of the camera
but not for the pitch,yaw and the pointer where the camera is looking at
here is a piece of the code:
Code: Select all
camera = smgr->addCameraSceneNodeFPS(0,100,100,-1,keyMap,9,true,2);
IAnimatedMesh *soldierMesh = smgr->getMesh("Models/Weapons/Pistol/pistol.3ds");
soldierNode = smgr->addAnimatedMeshSceneNode(soldierMesh);
soldierNode->setParent(camera);
tks