playMaker

Author Topic: Resetting Axis/Axis Event on Dpad Controllers  (Read 1492 times)

rondmc

  • Playmaker Newbie
  • *
  • Posts: 24
Resetting Axis/Axis Event on Dpad Controllers
« on: June 10, 2017, 07:03:00 PM »
Hi all,

I'm having a bit of trouble involving my controller (Xinput on Windows) and the Axis Event and Reset Input Axes actions in Playmaker.

I'm using the Axis Event to switch between events when a direction is pressed, then in the next event the Reset Input Axis action is called in order to prevent the direction being held down and causing the events to call too fast. In my menu, for example, the options will scroll too fast making it look like certain options are being skipped over. In another part of my game, I have the player input a series of directions in a certain order, like a skill check, but it will mess up if they, for example, press down and the next direction calls for them to press left. The game still registers the down direction because the axis did not reset.

It works fine using the keyboard. I suspect the controller's dpad axis isn't affected by Reset Input Axis or it is but the dpad calls the axis too fast. According to Unity's documentation, the gravity option only works on keyboard/mouse so that won't work, unless I'm missing something?
« Last Edit: June 10, 2017, 07:10:56 PM by rondmc »

rondmc

  • Playmaker Newbie
  • *
  • Posts: 24
Re: Resetting Axis/Axis Event on Dpad Controllers
« Reply #1 on: June 12, 2017, 03:30:14 PM »
I think I added a temp fic for now that seems to work. I just add a .1 sec wait action after the Axis Event and things are much more manageable. If anyone has a better solution, I'd love to hear.

djaydino

  • Administrator
  • Hero Member
  • *****
  • Posts: 7615
    • jinxtergames
Re: Resetting Axis/Axis Event on Dpad Controllers
« Reply #2 on: June 12, 2017, 11:30:50 PM »
Hi,
Maybe a 'next frame event' can be used there.
But it depends on how you have set this up.