Best way of doing controller support for Flashpunk


(TaylorAnderson) #1

Hello!

So I recently took a little stroll over to HaxePunk because I heard they had built-in controller support, but that place is really scary and not very welcoming to people who want to port their game. So after a while of futile attempts to port my game, I’ve decided to come back here. So now what I want to know is: what’s the easiest and most reliable way to implement controller support in Flashpunk right now? I used a solution last year by brett chalupa, but it was a little shaky and crashed my game often. Has there been a better solution since?

Thanks, Taylor Anderson


(Ultima2876) #2

Adobe’s own GameInput. Only works on desktop and mobile - not on web.


(TaylorAnderson) #3

Hmmm, thats good enough for me, cuz I think this game is gonna be another commercial one when I finally release it…I’ll look into it, thanks!


(Mike Evmm) #4

https://github.com/arkeus/as3-controller-input
I found this a couple of days ago. May suit your needs?


(TaylorAnderson) #5

Ohh this looks super useful, thanks! Will give it a shot soon!

EDIT: It works! This is a very nice framework. We really should get something like this into Flashpunk proper…


(Mike Evmm) #6

Glad I could be of help!


(TaylorAnderson) #7

The unfortunate part is that the game seems to be running slow on the debug player as a direct result of it, but I think that might be because of Adobe’s GameInput class which it builds off of, not the framework itself…