To rotate a specific bone, such as the head bone, in your custom SDL2 game engine using the Spine C++ runtime, you need to follow a specific sequence of operations. First, apply any animations to the skeleton, which will set the initial pose of the bones. Then, adjust the local rotation of the specific bone you want to rotate, such as the head bone. After making this adjustment, you must call skeleton->updateWorldTransform()
to update the world transforms of all bones based on their local transforms. This sequence ensures that your manual rotation is applied on top of any animation-driven transformations. If the animation also affects the head bone's rotation, it might overwrite your changes, so ensure your manual rotation is applied after the animation.