RustRoguelike
RustRoguelike copied to clipboard
Key Held Together Combine Directions
Try to have held keys combine directions so up+left is the same as 7.
How does this work? I believe we said it would combine keys that were released within a small time from each other.
To do this, I think when a key is released, we would record this instead of acting on it. Then, we would have to make sure the input system is "stepped" on each frame (even if there is no input), and if enough time has passed since the last key up event it would generate an output (possibly combining multiple keys such as up+left = upleft)
That solution sounds like the best course yea. I do think that this might cause a slight delay which could be annoying. The waiting time could be very short-- presumably, the user's finger is already en-route to press the second button at the time of the pressing of the first. However. I think this is something that we would want to leave as an option rather than setting it as the default.
I believe we talked about this only applying to directional keys, correct?
What about a combination like 4+6? Is this 5, the last key pressed, or something else? It is somewhat arbitrary, but I kind of like the idea that this combines into 5 to be consistent.
We should re-visit this later as an option for players to turn on, but it is not a priority now.