TE
TechEcho
Home24h TopNewestBestAskShowJobs
GitHubTwitter
Home

TechEcho

A tech news platform built with Next.js, providing global tech news and discussions.

GitHubTwitter

Home

HomeNewestBestAskShowJobs

Resources

HackerNews APIOriginal HackerNewsNext.js

© 2025 TechEcho. All rights reserved.

Show HN: Zero latency networked snake game

2 pointsby slicedbrandyover 5 years ago

1 comment

slicedbrandyover 5 years ago
G&#x27;day folks!<p>I built a zero client-perceived latency snake game that runs remotely, supporting concurrent players.<p>Specifically this is implemented using the &quot;validator&quot; adapter. The idea is that the server delivers a signed token to the client including the positions of the fruits, and the starting position of the snake. The client must then record its tick movements (x, y) until it reaches one of the fruit. These are then sent back to the server, which instantaneously runs the given simulation to check that all moves are legal. This process then repeats with a newly generated fruit and token.<p>You can see a demo of this functionality on my site: <a href="https:&#x2F;&#x2F;tomarell.com" rel="nofollow">https:&#x2F;&#x2F;tomarell.com</a>