Jump to content

Capturing motion with the Gamepad API for Playstation/XBox Controllers


wwwonka
 Share

Recommended Posts

Hi! First post here.

I'm currently experimenting with the gamepad API and I'm trying to capture the motion/orientation of my dualshock 3 to build controls for a new game project. I was wondering if anyone had manage such a thing and managed to make it work in the browser? It seems that WebVR makes use of the motion data using the gamepad.pose object and so far  I've been unlucky to reach it on a regular controller. Has anyone managed such a thing and could help?

 

Thank you!

 

Link to comment
Share on other sites

Your game is going to be WebVR? Try checking out A-Frame Registry for components, should be something for the gamepad too.

I did a fair amount of experimenting with the Gamepad API some time ago (using wireless XBox 360) with 2D games - you can check that out in this article, or this one, or in this repo, or try playing this demo from the Content Kit.

What issues are you having exactly?

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...
 Share

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...