Conversation
5246083 to
a36343e
Compare
|
I'm still on the fence whether the additional correctness & complexity is needed for Multiway or not (at least for its current uses). |
Limit diagonal movement to same magnitude as horizontal or vertical movement. Allow arbitrary direction movement with correct speed when pressing down multiple keys.
a36343e to
8f37853
Compare
There was a problem hiding this comment.
What's the point of all the e6 stuff?
There was a problem hiding this comment.
Each direction vector is added to the net movement vector when key is pressed.
Each direction vector is substracted from the net movement vector when key is released.
Pressing and then releasing 5 different direction keys should net into 0 movement.
However, due to rounding errors, you don't get 0.
That's why this net movement vector is represented as a number * 10e6.
|
I have put some more thought to it, it's just overly complicated. |
|
Closing, since mucaho ended up feeling it was too complicated, and it's also superseded by #1051 |
Benefits:
Caveat:
Notes:
Math.sqrtcalculations, not worth it