From df8e0bbff2533a5d9b9c1ef11ca2f4589663b1ed Mon Sep 17 00:00:00 2001 From: scrawl Date: Sun, 1 Apr 2012 14:53:41 +0200 Subject: [PATCH] player check --- apps/openmw/mwworld/world.cpp | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/apps/openmw/mwworld/world.cpp b/apps/openmw/mwworld/world.cpp index 47e608624..9ca31b5d3 100644 --- a/apps/openmw/mwworld/world.cpp +++ b/apps/openmw/mwworld/world.cpp @@ -754,7 +754,7 @@ namespace MWWorld std::vector < std::pair < float, std::string > >::iterator it = results.begin(); while (it != results.end()) { - if ( (*it).second == mPlayer->getPlayer().getRefData().getHandle()) + if ( getPtrViaHandle((*it).second) == mPlayer->getPlayer() ) { it = results.erase(it); } @@ -776,6 +776,9 @@ namespace MWWorld Ogre::Vector3 pos(p.x(), p.z(), -p.y()); Ogre::SceneNode* node = mFaced1.getRefData().getBaseNode(); + //std::cout << "Num facing 1 : " << mFaced1Name << std::endl; + //std::cout << "Type 1 " << mFaced1.getTypeName() << std::endl; + query->occlusionTest(pos, node); } else @@ -786,8 +789,8 @@ namespace MWWorld mFaced2 = getPtrViaHandle(results[1].second); mNumFacing = 2; - //std::cout << "Num facing 2 : " << mFaced1Name << " " << mFaced2Name << std::endl; - //std::cout << "Type 1 " << mFaced1.getTypeName() << " " << mFaced2.getTypeName() << std::endl; + std::cout << "Num facing 2 : " << mFaced1Name << " " << mFaced2Name << std::endl; + std::cout << "Type 1 " << mFaced1.getTypeName() << " " << mFaced2.getTypeName() << std::endl; btVector3 p = mPhysics->getRayPoint(results[1].first); Ogre::Vector3 pos(p.x(), p.z(), -p.y());