aframe-keyboard | A virtual reality keyboard and text editor in Aframe | Augmented Reality library
kandi X-RAY | aframe-keyboard Summary
kandi X-RAY | aframe-keyboard Summary
A virtual reality keyboard and text editor in Aframe
Support
Quality
Security
License
Reuse
Top functions reviewed by kandi - BETA
Currently covering the most popular Java, JavaScript and Python libraries. See a Sample of aframe-keyboard
aframe-keyboard Key Features
aframe-keyboard Examples and Code Snippets
Community Discussions
Trending Discussions on aframe-keyboard
QUESTION
I am using the keyboard-controls
component in a-frame and I notice that I am unable to hold down multiple keys at the same time.
Please see below a stripped down example using the I
and J
keys.
Using the following scripts
...ANSWER
Answered 2018-Jul-13 at 18:53This is not a bug, but a slight misunderstanding of the keydown event on your part... The keydown event behavior can best be described as what you would expect to see when typing in a word processor, or notepad. if you hold down the I key you would see an I typed and then after a small delay, rapid repetition of I. Then additionally holding down J during that would stop the Is from being typed altogether, type a J, then after another small delay, rapid repetition of J.
What you should do instead, is once a single keydown event is being fired, set an internal variable to true, maybe call it something like throttle, steeringLeft, etc... then when a keyup event is fired for that key, set it back to false. have the car maneuver based on the true/false states of those variables.
Community Discussions, Code Snippets contain sources that include Stack Exchange Network
Vulnerabilities
No vulnerabilities reported
Install aframe-keyboard
Support
Reuse Trending Solutions
Find, review, and download reusable Libraries, Code Snippets, Cloud APIs from over 650 million Knowledge Items
Find more librariesStay Updated
Subscribe to our newsletter for trending solutions and developer bootcamps
Share this Page