Gamepad HTML5

gurigraphics

  • Posts: 690
Gamepad HTML5
Gamepad for HTML5 Games


Platforms
Works only in HTML5.


About this extension

Gamepad HTML5 use Gamepad API for to access joystick in HTML5 games.


How this work

It's simple. This use bool game attributes: BUTTON_0, BUTTON_1, BUTTON_DOWN, etc.

If bool is true, then button = press.

----------------------------------------------

Get it

DOWNLOAD   

----------------------------------------------

How to Install

http://community.stencyl.com/index.php/topic,30432.0.html

----------------------------------------------

Version History

Version 1.0 - 25/12/2015 (deprecated)
Version 2.0 - 08/02/2017
----------------------------------------------

Notes

- It works only on HTML5.
- For test use a local server: http://www.uniformserver.com

License: The MIT License (MIT)
Copyright (c) 2017 Gurigraphics

« Last Edit: February 08, 2017, 08:56:29 am by gurigraphics »

Wow! Awesome job man! Cant wait to try this out!

gurigraphics

  • Posts: 690
Merry Christmas. ^ ^

Strange that does not work in dropbox. Must be HTTPS security problem.

So this works for Xbox controllers also, correct?



henkass

  • *
  • Posts: 16
Hey I'm having some issues with this extension. It doesn't seem to work in the flash web player. How does it actually work? Do I use regular controller input after I've enabled it through the extension block? Do I have to run it with the html5? There's so much that's unclear. Otherwise it's great that you made this extension. And what do you mean when you say I have to use html template? And jQuery?
Also your stencyl projec uses an extension with a diffrent name, which completely ruins the point of having a stencyl project because all of the blocks are removed that's supposed to help you.
Sorry if I sound negative about this. Thanks in advance for an answer!

« Last Edit: February 01, 2016, 05:46:58 am by henkass »

gurigraphics

  • Posts: 690
Quote
Hey I'm having some issues with this extension. It doesn't seem to work in the flash web player.

The Online Demo worked with his control?

Quote
How does it actually work? Do I use regular controller input after I've enabled it through the extension block?

It's simple. This use bool game attributes: BUTTON_0, BUTTON_1, BUTTON_DOWN, etc. If bool is true, then button = press.

The extension has a single block to activate it.

Quote
Do I have to run it with the html5? And what do you mean when you say I have to use html template? And jQuery?

In html template, insert your game.swf. Only this.

Quote
Also your stencyl projec uses an extension with a diffrent name, which completely ruins the point of having a stencyl project because all of the blocks are removed that's supposed to help you.

Ok. I updated the new file of project. Anyway, after enabling the extension you need to restart Stencyl.

Quote
Sorry if I sound negative about this. Thanks in advance for an answer!

I wonder if it were not free how that would be.

« Last Edit: February 08, 2017, 08:44:00 am by gurigraphics »

henkass

  • *
  • Posts: 16
Ok I used your stencyl project, and the extension was enabled, and I put the Game.swf in the html template, and then I created a test project on newgrounds, the program loads, it seems, but the controller does not work for some reason. Your test program works though, with the same controller. And I checked, the extension was loaded into the program and it had the create block just where it's supposed to be.

gurigraphics

  • Posts: 690
If it works on the local server the code is ok. I tested it on dropbox and not worked.
So I put this site.

Anyway, the technology Gamepad API is still beta. I do not know what can be.

You can try using https Jquery:
Code: [Select]
<script src="https://ajax.googleapis.com/ajax/libs/jquery/2.2.0/jquery.min.js"></script>

Nikkita31

  • Posts: 131
Hi Gurigraphics.

I think I am missing something here. I've been playing around with this extension for hours but I can't make this thing work.
I was able to install the extension and able to export the sample game you provided in flash.  I think there will be an animation when you pressed a button. Anyway, if it's possible can you provide any flash game link that has this extension enabled? Thanks.

-renegadequarters

redadouzet

  • Posts: 1
Does this work if i compile the game as html5 ?

gurigraphics

  • Posts: 690
Updated to Gamepad HTML5

Work only in HTML5

   <°)}}}}})<(