Explorar o código

Fix orientation of raycast hit

Garrett Johnson %!s(int64=5) %!d(string=hai) anos
pai
achega
8655e35541
Modificáronse 1 ficheiros con 1 adicións e 0 borrados
  1. 1 0
      example/index.js

+ 1 - 0
example/index.js

@@ -270,6 +270,7 @@ function animate() {
 		if ( closestHit.face ) {
 
 			const normal = closestHit.face.normal;
+			normal.transformDirection( closestHit.object.matrixWorld );
 			rayIntersect.lookAt(
 				point.x + normal.x,
 				point.y + normal.y,