aframe-physics-extras | Cannon API interface | Augmented Reality library
kandi X-RAY | aframe-physics-extras Summary
kandi X-RAY | aframe-physics-extras Summary
Cannon API interface components the A-Frame Physics System
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-physics-extras
aframe-physics-extras Key Features
aframe-physics-extras Examples and Code Snippets
Community Discussions
Trending Discussions on aframe-physics-extras
QUESTION
The problem:
I want to make a ball the user can throw. With my current implementation, physics work but I cannot lift the ball. However, if I delete the "dynamic-body" I can grab the ball exactly as I am supposed to, and move it around. Heck, I tried changing it to "static-body" and it still works. The problem seems to be whenever I mix grabbable and dynamic-body. I know it should be possible in an older version, as I was using this tutorial: https://www.youtube.com/watch?v=SKYfYd3pk4I
However, he is using progressive-controls which are not available in the newest super-hands package, I don't know if that changes anything. Is there anything I am doing wrong here?
Here are my snippits of code that could affect the result:
My A-Frame packages:
...ANSWER
Answered 2020-Nov-19 at 03:10Thanks to this: https://github.com/bryik/aframe-ball-throw/blob/master/index.html
I found the culprit. I needed to add the static-body to my hand-entities, so that collision could be detected. No idea why collision was detected without them before though.
Modified code:
QUESTION
I am using aframe physics extra component and trying to detect collision between two static bodies.
Here is my codepen - https://codepen.io/nirajupadhyay11/pen/gQraNq
However, I am not sure, why it is not working.
Here is the code -
...ANSWER
Answered 2018-Nov-11 at 11:25It seems to be working. The physics-collider
provides an event collisions
which is emitted when both static bodies collide with each other.
If you add an event listener
QUESTION
I'm making an A-Frame project which will allow users to interact with math models. I'm using the aframe-super-hands-component
with aframe-physics-extras
for its nice "sleep" effect. To add a layer of control, I'm trying to make it so that the user can use a controller's joysticks to bring a model closer/farther away from the controller, similar to the Oculus Dash controls (https://youtu.be/sMjlM5vFSA0?t=1m55s).
However, when I try to update a model's position, as my model entities are defined as dynamic bodies, they don't move. I know that I can remove the dynamic-body
component, move the body, and then reattach dynamic-body
, but I want to avoid that as I'm planning to move models in tick
. Is there a way I can move a dynamic body without breaking dynamic-body
behavior?
Here's a link to an example which tries to update a box's position: https://codepen.io/kchen1250/pen/MBmRYo
...ANSWER
Answered 2018-Jul-24 at 15:29You can sync the position of the entity and the dynamic-body
using the dynamic-body
s method syncToPhysics()
Community Discussions, Code Snippets contain sources that include Stack Exchange Network
Vulnerabilities
No vulnerabilities reported
Install aframe-physics-extras
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