Support loading text keys for objects without a skeleton

This means we can no longer map them to bone IDs, but they are unused anyway.

Required to load text keys from the default head models (such as Talk: Start/Stop and Blink: Start/Stop)
deque
scrawl 11 years ago
parent 8455ed6279
commit 7dfb624ee2

@ -1038,11 +1038,7 @@ class NIFObjectLoader
{
const Nif::NiTextKeyExtraData *tk = static_cast<const Nif::NiTextKeyExtraData*>(e.getPtr());
if (scene->mSkelBase)
{
int trgtid = NIFSkeletonLoader::lookupOgreBoneHandle(name, node->recIndex);
extractTextKeys(tk, scene->mTextKeys[trgtid]);
}
extractTextKeys(tk, scene->mTextKeys);
}
else if(e->recType == Nif::RC_NiStringExtraData)
{

@ -69,7 +69,7 @@ struct ObjectScene {
// The maximum length on any of the controllers. For animations with controllers, but no text keys, consider this the animation length.
float mMaxControllerLength;
std::map<int,TextKeyMap> mTextKeys;
TextKeyMap mTextKeys;
MaterialControllerManager mMaterialControllerMgr;

Loading…
Cancel
Save