define saber declaratively

This commit is contained in:
Kevin Ngo
2018-09-21 04:58:04 -07:00
parent a4b88e4502
commit ac36d57fb6
3 changed files with 53 additions and 66 deletions

View File

@@ -35,6 +35,8 @@ AFRAME.registerComponent('cursor-mesh', {
// Update cursor mesh.
intersection = cursorEl.components.raycaster.getIntersection(intersectedEl);
if (!intersection) { return; }
el.object3D.position.copy(intersection.point);
if (scenePivotEl) {