only check palms if active

This commit is contained in:
Philip Rosedale 2013-12-16 17:01:46 -08:00
parent 893a3900d9
commit 0d76b370df

View file

@ -299,6 +299,9 @@ void Hand::updateCollisions() {
palm.setIsCollidingWithPalm(false);
for (int j = 0; j < getNumPalms(); j++) {
PalmData& otherPalm = otherAvatar->getHand().getPalms()[j];
if (!otherPalm.isActive()) {
continue;
}
glm::vec3 otherPalmPosition = otherPalm.getPosition();
if (glm::length(otherPalmPosition - myPalmPosition) < palmCollisionDistance) {
palm.setIsCollidingWithPalm(true);