JavaScript-Snake icon indicating copy to clipboard operation
JavaScript-Snake copied to clipboard

Highscore check doesn't seem to work anymore

Open Coteh opened this issue 6 years ago • 1 comments

Noticed that the alert notifying the player that they beat their high score does not run anymore, and seems like it's due to jsSnakeHighScore being set whenever the snake eats food (and foodEaten gets called) and snake has a length greater than high score.

Also, should alert be used for this sort of thing, or would it be better to move this into a new dialog box?

Coteh avatar Oct 18 '19 23:10 Coteh

For some odd reason, it works on Safari... but the highscore also starts with undefined (if it's first time playing)... 🤔

Coteh avatar Oct 18 '19 23:10 Coteh