aframe-super-hands-component
aframe-super-hands-component copied to clipboard
Unable to get grabbed component
Hi -
I'd like to simply get the component that is being grabbed. In the readme, it says that that component will have a 'grabbed' attribute set.
When I run the following code (registering xbuttondown), I don't see the txt component changing, and in fact this code never runs.
const txt = document.getElementById("txt");
for (let item of items) {
if (item.hasAttribute('grabbed')) {
txt.setAttribute("value", item.id);
}
}
I may be wrong but why dont you use the grab-start grab-end events?
hi! not sure if you've figured out your issue but you might want to try item.is('grabbed')'