Live data from Hacker News

Snake Game using jQuery

webdeveloperjuice.com

1–9 of 9 posts

Re: Snake Game using jQuery

#3

There is a bug. If you are traveling right, then quickly press down, release down, then press left, and release left, you will die. This is not snake behavior.

I experienced the same bug. It makes quickly turning to get a 'food' block in an adjacent cell very difficult.

Re: Snake Game using jQuery

#6
post #5

Why is this interesting? Is there some novel technique used here? The quality of the site its hosted on certainly isn't great.

I found it interesting that it works at all given that it's using td elements as board cells, jQuery to compare dom elements for cell referencing/dereferencing, and setInterval to update the animation and gamer input.

Re: Snake Game using jQuery

#8

There is a bug. If you are traveling right, then quickly press down, release down, then press left, and release left, you will die. This is not snake behavior.

I experienced the same bug. It makes quickly turning to get a 'food' block in an adjacent cell very difficult.

Yeah I think it misses some moves based on the timing loop