I'm relatively new to DirectX. I'm playing around with a simple game with cannons shooting at each other (think Scorched Earth).
I started out loading .X models into Mesh objects and just rendered them. When rotating/elevating the cannon I would simply rotate the entire model, which looks junky.
So I figured the best way to do this is with skeletal animation. Though I don't want to 'play' an animation. I just want to rotate the bones to cause the corresponding parts of the mesh to move (rotate). I used 3DCanvas to create a model that works and by rotating the correct frames I get the desired result.
When you press the Enter key I create a projectile and send it flying in the direction the cannon is facing. The problem I have now is the projectile is created at the origin of the model, not the end of the barrel. How can I figure out how to position the projectile at the end of the barrel?
FYI, I converted the SkinnedMesh sample for the C++ SDK to VB.NET.
Thanks
I started out loading .X models into Mesh objects and just rendered them. When rotating/elevating the cannon I would simply rotate the entire model, which looks junky.
So I figured the best way to do this is with skeletal animation. Though I don't want to 'play' an animation. I just want to rotate the bones to cause the corresponding parts of the mesh to move (rotate). I used 3DCanvas to create a model that works and by rotating the correct frames I get the desired result.
When you press the Enter key I create a projectile and send it flying in the direction the cannon is facing. The problem I have now is the projectile is created at the origin of the model, not the end of the barrel. How can I figure out how to position the projectile at the end of the barrel?
FYI, I converted the SkinnedMesh sample for the C++ SDK to VB.NET.
Thanks