4 ms·
Ha! Sorry about that. I wanted to avoid hard-coding keycodes for the sake of legibility so I used 'W'.getCharcodeAt(0) — which unfortunately doesn't work for th
by kreldjarn 12y ago
Ha! Sorry about that. I wanted to avoid hard-coding keycodes for the sake of legibility so I used 'W'.getCharcodeAt(0) — which unfortunately doesn't work for the arrow keys.
- Recoil42 12y agoWhy not just use constants?
- deleted 12y ago[deleted]
- kreldjarn 12y agoPoint taken. I honestly did not perceive it as a necessary feature, but I'll fix this when I open up the code again.
- deleted 12y ago[deleted]
- ImJasonH 12y agoRather than berate him for this "unforgivable" practice, why not send him a pull request fixing it? https://github.com/kreldjarn/TRON/blob/gh-pages/scripts/Player.js#L39-L44 https://github.com/kreldjarn/TRON/blob/gh-pages/scripts/Play...