So I've been able to use bullet physics to bind a rigid body to a cube and have it fall while being rendering, but when I tried to "attach" a rigid body to the player it got the player stuck underneath the world, unable to move.
I was originally going use kinematic bodies but after research and trying them seems like their incomplete.
My question in the end would be am I handling the data correctly to update my camera's position and also changing the rigid bodies.
-Below is the code I use create the rigid body, and below that is the code to update both of their positions.
btTransform t;
t.setIdentity();
t.setOrigin(btVector3(0, 0, 0));
btCapsuleShape* player = new btCapsuleShape(1, 1);
btVector3 inertia(1, 0, 0);
player->calculateLocalInertia(20, inertia);
btMotionState* motion = new btDefaultMotionState(t);
btRigidBody::btRigidBodyConstructionInfo info(20, motion, player, inertia);
PlayerBody = new btRigidBody(info);
world->addRigidBody(PlayerBody);
bodies.push_back(PlayerBody);
PlayerBody->setAngularVelocity(btVector3(0,0,0));
And the code to update the position of therigid body and camera
gCamera.GetInput(window);
btVector3 t;
t = physics.PlayerBody->getLinearVelocity();
gCamera.position.x = t.getX();
gCamera.position.y = t.getY();
gCamera.position.z = t.getZ();
//Set
physics.PlayerBody->setLinearVelocity(btVector3(gCamera.position.x, gCamera.position.y, gCamera.position.z));