Hi!
I’ve just started using the new Input System, and personally I prefer using code directly for Characters rather than events… and also use Events for simpler tasks, so I’m reading input like this currently:
bool jump = playerInput.actions["Jump"].triggered;```
which works extremely well.. however I can not ReadValue from the "Press Only" actions..
is there anyway to ReadValue from them or is this a bug?
```Vector2 pMove = playerInput.actions["PressMove"].ReadValue<Vector2>();```
the code above just yields a Vector2 with (0f, 0f), why is that?
a part of my game needs a movement to be performed only once, even if the button is being held, how would I go about doing that? is there something other than ReadValue that I can't seem to find or is this a bug or?
Thanks!
EDIT: I should add that ```playerInput.actions["PressMove"].triggered;``` actually works just fine.. but I need the value.
Without seeing your actual action / input binding setup, I’m just taking a wild guess here - is your action for pMove a button? If so, I believe you’re looking to read out a float - 0 is off 1 is on.
Hi, it’s a Vector2 I made sure of it…
I did find that I could just do this instead and it works:
However I can’t get this new Input System to work on iOS… it just keeps giving me an error about Touchscreen pressure? I’m almost sure this is 3D Touch as I’m testing it on an iPhone 6S+, but it gives me the same error on an iPhone 6+… the error only happens if I have a script that utilizes the new Input System and I use any On-Screen controls.
I’ll submit that to another thread as well maybe but posting it here in case I can get some help(file attached)
Hi! Which bug would you want me to report? the iOS one or can’t ReadValue from “Press Only” Actions?
honestly I left the new Input System cause of the iOS issue… I hope someone can help me with that.