playMaker

Author Topic: Any Button Store String Action?  (Read 1456 times)

oishiiniku

  • Playmaker Newbie
  • *
  • Posts: 6
Any Button Store String Action?
« on: July 13, 2017, 04:47:08 AM »
Hi there,

I'm trying to store the string values from Xbox 360 controller buttons when they are pressed. I tried using the 'Any Key Store String' action, but this only seems to store keyboard input. I guess I need an action that returns a string based on button mappings in my project's InputManager. Is there an action like this already? Or is there another way to store the string for any button pressed? Maybe a custom version of 'Get Button Down' that has the option of storing the button's string?

Thanks,

Nick.

djaydino

  • Administrator
  • Hero Member
  • *****
  • Posts: 7616
    • jinxtergames
Re: Any Button Store String Action?
« Reply #1 on: July 13, 2017, 06:59:07 AM »
Hi,
Its a unity limitation so i can't make an any button to string, but i did make a custom 'get key down' for you
You still need to have 1 action for each button but the key (keycode) name  (including mouse and joystick buttons) you can store in a string now.

oishiiniku

  • Playmaker Newbie
  • *
  • Posts: 6
Re: Any Button Store String Action?
« Reply #2 on: July 15, 2017, 02:07:15 AM »
That's awesome! I should have a fairly finite amount of buttons  I'm listening out for, so this is a good solution.

Thanks so much!

djaydino

  • Administrator
  • Hero Member
  • *****
  • Posts: 7616
    • jinxtergames
Re: Any Button Store String Action?
« Reply #3 on: July 15, 2017, 05:14:25 AM »
Hi,
Happy to help :)

Please let me know if it works fine and if there are no bugs in it, so i can add this to the Ecosystem