When this code is run, pressing the ‘w’ key does not produce any response. But when q, w, e are pressed quickly in succession, it enters the KeyUp callback for w. However, at this time, the keycode for e is 16 (and this number represents the event corresponding to q)."
There is still a problem, KeyUp cannot be triggered, and it may be triggered incorrectly.
When this code is run, pressing the ‘w’ key does not produce any response. But when q, w, e are pressed quickly in succession, it enters the KeyUp callback for w. However, at this time, the keycode for e is 16 (and this number represents the event corresponding to q)."