Skip to content

Commit

Permalink
Correct example 4 code
Browse files Browse the repository at this point in the history
  • Loading branch information
nickw1 committed Nov 14, 2024
1 parent 808a4bb commit f6b4e26
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion docs/04-api-communication/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
<html>
<head>
<title>three.js</title>
<script type="module" crossorigin src="/locar.js/assets/04-api-communication-B3laukjY.js"></script>
<script type="module" crossorigin src="/locar.js/assets/04-api-communication-WpYkYZAO.js"></script>
<link rel="modulepreload" crossorigin href="/locar.js/assets/locar.es-D2pHxP8J.js">
</head>
<body>
Expand Down

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion examples/04-api-communication/src/main.js
Original file line number Diff line number Diff line change
Expand Up @@ -60,7 +60,7 @@ renderer.setAnimationLoop(animate);
function animate() {
cam.update();
deviceControls.update();
const objects = clickHandler.raycast(scene, camera);
const objects = clickHandler.raycast(camera, scene);
if(objects.length) {
alert(`This is ${objects[0].object.properties.name}`);
}
Expand Down

0 comments on commit f6b4e26

Please sign in to comment.