Agent skill Web motion
Three.js Interaction
Use spatial graphics, scenes or materials to support a web experience.
Install the skill
Run the command from your project root with Node.js and npm.
npx skills@latest add CloudAI-X/threejs-skills --skill threejs-interaction --agent claude-code --yesCheck this file in your project.claude/skills/threejs-interaction/SKILL.md
Other ways to install
Choose an assistant interactively
npx skills@latest add CloudAI-X/threejs-skills --skill threejs-interactionSelect your assistant and choose the project installation scope.
Official instructions
The tested Skills CLI 1.10.0 requires Node.js 22.20 or later. Bring an existing Three.js project and a local preview. Check the installed version and renderer first.
View operation manualWhat this skill helps with
- Use spatial graphics, scenes or materials to support a web experience.
Good for
- 3D on the web
- Inputs
- Canvas element, camera and selectable objects
- Exercise
- Pick an object in a canvas with Raycaster
- Acceptance
- Verify selection at canvas edges, after resize and on an empty hit. If canvas controls also handle dragging, check that a drag does not activate click selection.
- Skill name
threejs-interaction- Repository
CloudAI-X/threejs-skills
Keep the change to a scene you can compare
Open-ended request
Make the whole 3D scene better.
Without a baseline and scoped inputs, you cannot tell which adjustment solved the problem.
A reproducible outcome
- Pick an object in a canvas with Raycaster
- Canvas element, camera and selectable objects
threejs-interaction operation manual
Pick an object in a canvas with Raycaster
Canvas element, camera and selectable objects
Check the current scene
Check the current scene
Prompt · Step 1Use CloudAI-X’s threejs-interaction and read the installed SKILL.md. The scope is [Project and preview route]. Locate [Canvas] and the intended selectable scene objects. Reproduce a click at the center and edge when the canvas is offset inside the document.Apply the documented technique
Pick an object in a canvas with Raycaster
Prompt · Step 2Use CloudAI-X’s threejs-interaction and read the installed SKILL.md. The scope is [Project and preview route]. Convert pointer coordinates relative to the canvas bounds into normalized device coordinates. Use Raycaster.setFromCamera with the active camera and raycast only the selected object set. Resolve child hits to their selectable parent where required.Verify the rendered behavior
Verify the rendered behavior
- Verify selection at canvas edges, after resize and on an empty hit. If canvas controls also handle dragging, check that a drag does not activate click selection.
Prompt · Step 3Use CloudAI-X’s threejs-interaction and read the installed SKILL.md. The scope is [Project and preview route]. Verify selection at canvas edges, after resize and on an empty hit. If canvas controls also handle dragging, check that a drag does not activate click selection.
Look up a specific implementation problem
Ask the assistant to use the current preview and installed dependency as evidence.
What inputs are required?threejs-interaction
- Command or reference
SKILL.md- Examples
- Canvas element, camera and selectable objects
How do I verify the real effect?Browser
- Command or reference
Pick an object in a canvas with Raycaster- Examples
- Verify selection at canvas edges, after resize and on an empty hit. If canvas controls also handle dragging, check that a drag does not activate click selection.
Troubleshooting and FAQ
Why may an example fail in my project?
Confirm Three.js and its addons use matching versions and check the renderer required by that example.
How do I judge the result?
Verify selection at canvas edges, after resize and on an empty hit. If canvas controls also handle dragging, check that a drag does not activate click selection.