mirror of
https://github.com/OpenMW/openmw.git
synced 2025-02-06 15:15:34 +00:00
Merge branch 'xanimphysics' into 'master'
Fix animated object physics Closes #7164 See merge request OpenMW/openmw!2623
This commit is contained in:
commit
a7e37509de
1 changed files with 5 additions and 1 deletions
|
@ -496,7 +496,11 @@ namespace MWPhysics
|
||||||
{
|
{
|
||||||
if (ptr.mRef->mData.mPhysicsPostponed)
|
if (ptr.mRef->mData.mPhysicsPostponed)
|
||||||
return;
|
return;
|
||||||
osg::ref_ptr<Resource::BulletShapeInstance> shapeInstance = mShapeManager->getInstance(mesh);
|
|
||||||
|
std::string animationMesh = mesh;
|
||||||
|
if (ptr.getClass().useAnim())
|
||||||
|
animationMesh = Misc::ResourceHelpers::correctActorModelPath(mesh, mResourceSystem->getVFS());
|
||||||
|
osg::ref_ptr<Resource::BulletShapeInstance> shapeInstance = mShapeManager->getInstance(animationMesh);
|
||||||
if (!shapeInstance || !shapeInstance->mCollisionShape)
|
if (!shapeInstance || !shapeInstance->mCollisionShape)
|
||||||
return;
|
return;
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue