A controller haptics (vibrations) component for A-Frame.
npm install aframe-haptics-componenttriggerdown, triggerup) | [] |
events if other than the controller entity. | this.el |
force and duration as arguments, defaults data-defined duration and force). |
js
this.el.components.haptics.pulse();
// function pulse (force, duration)
this.el.components.haptics.pulse(0.5, 200);
`
$3
#### Browser
Install and use by directly including the browser files:
`html
My A-Frame Scene
`
#### npm
Install via npm:
`bash
npm install aframe-haptics-component
`
Then require and use.
`js
require('aframe');
require('aframe-haptics-component');
``