Thanks guys!
I wrote a
blog post on the site about the game's smooth grid-based movement. I'll copy it here as well:
Out of the many grid-based Snake and Tron style games I have played, almost all have noticeably jerky player movement. The usual reason for this is that the game uses tile-based graphics and wants to constrain player location to coordinates on the grid, however I consider smooth visualizations essential to the aesthetic of Snayke.
Here is a recording of Snayke with its smooth movement disabled:
And here is the same gameplay with smooth movement enabled:
It's easy to see how much smooth movement adds to a grid-based game, especially when things move at slower speeds. There are a few different ways to accomplish this depending on the visual style of the game.
In Snayke's case, each snake is represented by an individual tile image for each position the snake occupies on the grid. Smooth movement is achieved by doing a scissor cut-out of the front and back tiles of the snake, where the size of the visible area of the scissored tiles are determined by the time left until the snake's head reaches its next grid position.
While Snayke's visual movement appears smooth, snakes still move in discrete ticks under the hood. Collision detection and direction changes are calculated every time a snake advances to a new position on the grid, rather than continuously. This entails a slight amount of lag between the player pressing buttons and the game reacting, but no more than what would be there if smooth movement were disabled.
Here is the gameplay recording with collision visualizations enabled, showing collision detection acting in descrete ticks compared to the snake's smooth visual movement:
YouTube video