因为没法修改,请需要的朋友自己将键盘监听那段替换为以下内容:
document.body.addEventListener(keydown
function(e) {
if ((e.keyCode == 87 || e.keyCode == 38) && that.dir != D) {
that.dir = U
} else if ((e.keyCode == 83 || e.keyCode == 40) && that.dir != U) {
that.dir = D
} else if ((e.keyCode == 65 || e.keyCode == 37) && that.dir != R) {
that.dir = L
} else if ((e.keyCode == 68 || e.keyCode == 39) && that.dir != L) {
that.dir = R
}
}
false)
回复
吃两个后,然后按反方向 会卡 住