Browse Source

Updating JS to the TS file

Raanan Weber 10 years ago
parent
commit
079d4c4373
1 changed files with 1 additions and 0 deletions
  1. 1 0
      Babylon/Mesh/babylon.subMesh.js

+ 1 - 0
Babylon/Mesh/babylon.subMesh.js

@@ -114,6 +114,7 @@
                 var currentIntersectInfo = ray.intersectsTriangle(p0, p1, p2);
 
                 if (currentIntersectInfo) {
+                    if(currentIntersectInfo.distance < 0 ) continue;
                     if (fastCheck || !intersectInfo || currentIntersectInfo.distance < intersectInfo.distance) {
                         intersectInfo = currentIntersectInfo;
                         intersectInfo.faceId = index / 3;