Skip to content

Commit

Permalink
fixed snake not working anymore
Browse files Browse the repository at this point in the history
Signed-off-by: J10a1n15 <45315647+j10a1n15@users.noreply.github.com>
  • Loading branch information
j10a1n15 committed Sep 23, 2024
1 parent e9e8e37 commit 7c7528c
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/main/kotlin/gay/j10a1n15/sillygames/games/Snake.kt
Original file line number Diff line number Diff line change
Expand Up @@ -60,7 +60,7 @@ class Snake : Game(), RpcProvider {
it
}.toMutableList()

if (newHead in snake) {
if (newHead in snake.drop(1)) {
gameOver = true
}
}
Expand Down

0 comments on commit 7c7528c

Please sign in to comment.