fernandojsg / aframe-input-mapping-component

https://fernandojsg.github.io/aframe-input-mapping-component
MIT License
24 stars 7 forks source link

Multiple input states actived at the same time? #22

Open fernandojsg opened 6 years ago

fernandojsg commented 6 years ago

As discussed at https://github.com/fernandojsg/aframe-input-mapping-component/issues/11

Could it be interesting to have things like:

AFRAME.setCurrentInputState(['teleport', 'paint']); 

We could have a more advanced API to handle modifications of the states:

AFRAME.setCurrentInputState(['teleport', 'grab']);

or

AFRAME.activateCurrentInputState('grab');
AFRAME.deactivateCurrentInputState('paint');

or

AFRAME.switchCurrentInputState(['grab'], ['paint']); // To add some and remove others
...