now if i remove the animation its has no problem picking the object with getSceneNodeFromScreenCoordinatesBB its only when there is animation data in the .X file.
ive done a quick fix in my build of irrlicht in
CXAnimationPlayer::updateBoundingBoxFromAnimation() by pretty much commenting out the entire method except for 1 line. like so:
Code: Select all
void CXAnimationPlayer::updateBoundingBoxFromAnimation()
{
// if (!Joints.size())
// return;
// bool first = true;
// for (u32 i=0; i<Joints.size(); ++i)
// I think there should be two vectors from aabbox of each joint should
// be used instead of just (0,0,0)
// if (!Joints[i].Weights.empty())
/* {
core::vector3df p(0,0,0);
Joints[i].AnimatedMatrix.transformVect(p);
if (first)
Box.reset(p);
else
Box.addInternalPoint(p);
first = false;
}
*/
AnimatedMesh->BoundingBox = Box;
}