I was pleasantly surprised when a friend texted me after work to say this game was on Hacker News. I hope it brought some small joy to your day. Some comments helped identify some minor tweaks. I do not expect to have time or motivation to make bigger changes soon. Feel free to make GitHub issues.
Love the game, it just ramps up pretty slowly.
Looking at the comments and people trying to verify what the real maximum score is. I wrote a (Cartesian) snake for fun once, that was Pascal and an obscure 8-bit platform, but most fun was the pure mechanics of it; the rest was just boring, completionist details. As dopamine plateaued, I barely just worked out a formula for a curve to spread the maximum snake length across a set number of levels so that it ends at 100% of gameplay area and remains winnable. But maximum score? No idea, I couldn't be arsed to work it out. But I finished the project! https://github.com/wowczarek/dlp-misc/tree/main/spacew0rm
The game looks really good, although I think it'd be improved if the sphere was a bit smaller. It feels like it takes too long for the game to become difficult
Really cool game, but please please fix the viewport to prevent accidentaly zooming on the page on a mobile device!
94! it really doesn't get fun until around 35-40, would be fun to start there.
Obviously 666, 1337, 9223372036854775807 etc... in the leaderboard are fake, so if I had to try to figure out what the highest legit score is, I'd guess milkman with 227. Unless someone was clever enough to make an inconspicuous fake number :)
Is there a place I can read about taking unique creative approaches to original topics/games/concepts like this? "Thinking Different with Basics". I like this so much but its because it gets at an essence of creativity applied to the obvious I don't know how to learn or search for:(
Control by phone sensor (https://developer.mozilla.org/en-US/docs/Web/API/Orientation...) would be nuts.
tilting the phone as the control...
Here's a demo of the control since mdn didn't have one:
Also a more practical thing while we're doing this is a thumb drag control, that'd make this a hit.
Like flappy bird level.
Reminds me of Uncle Worm, among the better TI-83+ games. It's 2D, but the snake is curvy:
Cool. It would also be interesting to see a hyperbolic snake.
Reminds me of this video, where the dev compares spherical and hyperbolical geometries (albeit a dimension higher):
Very cool but on iOS safari, if I click one of the buttons twice too quickly it zooms in and I can’t see the full screen or the other button. Hard to zoom back out at least on my phone.
Beyond 100 it becomes a game of avoiding the The Loxodrome of Terror by spiralling into an unescapeable trap.
Easiest pattern to get some more length is to do some sort of spherical sinusoid by following the meridian and then some optional final fill loop for the poles.
Overall it feels a bit slow to get to the part where it becomes tricky
For optimal fill you might end up with something like a tennis ball/baseball pattern instead.
see fig 5 here
Very neat. Would be cool to see in 3d (cross eye option [1]!? :D)
I think an accelerated initial growth is needed. Maybe start with a growth of 5 and have it decrease so it's a 1 at around 50. It takes a bit too long to get to something non trivial, especially since it seems there is a bias to put dots on the opposite side, causing the first 5 minutes to be mostly going in a straight circumnavigations.
I wish there is a mode where the snake go toward where my mouse cursor is (similar to agar.io), as opposed to having the controls turn the snake. So in update function where we have the "direction-=.08" and "direction+=.08" bits, "direction" would be assigned a value either due to the pressed state of the 4 arrow keys, or some arctangent of mouse coordinates:
https://github.com/kevinAlbs/SphericalSnake/blob/b907738476d...
Alternatively, keep the current controls, but rotate the whole world to match the snake's direction of movement. Current mix of non-rotating world with rotating controls makes the game more difficult, most snake variants I have played opted for non-rotating world with non-rotating controls (e.g. press right to go right, independent of current snake heading, as opposed to turning clockwise).
When the game ends, the banner obscures the exact spot where the snake ran into itself, which is the thing you most want to see at the end.
Really fun! Developing my intuition for a sphere as I played was a nice experience. As other commenters have mentioned, the game ramps up a bit too slowly. Perhaps it would worth adding more than one food item.
It should start at score 50, which is when the game actually gets interesting.
it takes forever for it to get tricky. if you turn 4 directions it would have the same tension as the original. you could keep the same controls with obstacles. a maze could be fun-- kind of _irritating stick_, but _snake_, which, naturally, you'd call _stick snake_.
I noticed that the dots on the surface of the sphere are evenly spaced out close to the equator, but because there is a consistent number of dots in each ring, they are very close together when you reach the poles.
One way to get dots evenly spread out over the surface of a sphere is to use a phyllotaxis spiral pattern.
https://demonstrations.wolfram.com/PhyllotaxisSpiralPatternO...
People are having fun submitting their fake scores to the leaderboard: https://kevinalbs.com/spherical_snake/leaderboard/
I see a person or two I know in there haha
For a new kind of snake game, check out PluriSnake.
PluriSnake is a snake-based color matching daily puzzle game.
Color matching is used in two ways: (1) matching circles creates snakes, and (2) matching a snake’s color with the squares beneath it destroys them.
Snakes, but not individual circles, can be moved by snaking to squares of matching color, as long as their paths are not blocked by other snakes.
The goal is to score as highly as you can. Destroying all the squares is not required for your score to count.
Of course, there is more to it than that as you will see.
Try it out:
https://testflight.apple.com/join/mJXdJavG
Any feedback would be appreciated. Have fun!
Cute but this game does not become interesting until score 50 or more.
pretty boring start, quite fun once the snake is the size of the sphere circumference
Fun take! Would love to just drag my finger on the sphere to affect the direction instead of the two big buttons.
Good game concept and implementation. Run smoothly even on phone.
Extend the capability to include timer, boost of speed and even levels with enemies.. I would love to also try having a kind of multi level support for moves.. Like 3 layers to explore the 3d navigation with layers of ground for moves.
Awesome experiments that could easily become viral! :)
For a multiplayer spherical tron-like experience check out Astro Bears, it’s a great little party game!
Quite a good implementation, got to 62 and was playing a "space filling curve" strategy to bleed off some of the length. Looking at the leader-board I suspect some people are just sending off their own custom submissions [1].
The original was toroidal!
I thought I had the highest score, until I checked the leaderboard.
props to milkman, high score.
This is really fun! Nice job.
Small issue: I accidentally right-clicked one of the arrow buttons and it stuck in the pressed position, causing the snake to curl into itself and end my game before I could left-click out of the context menu.
this posting was a $2B+ hit to our GDP
Just need to reach MAX_SAFE_INT and I too can be on the leaderboard... And I thought 78 was pretty good
Lovely. Would love if it canvas was bigger on desktop. Zoomed in 3x is much better but pix-elated. The first 50 or so levels were very easy. Started getting difficult around 90+.
Reminds me of a old iPhone game "Snake Galaxy" with the same principle https://www.youtube.com/watch?v=8LEIC_BOhgE
Great to see someone thinking outside the box.
I love this, congratulations on the clever design and concept.
Really impressive that it's implemented in < 400 lines of Javascript code and runs so smoothly in my phone's browser (Firefox on Android)
Definitely a good concept, but the controls feel super janky. The early game is also a bit too slow.
Stuff you guys come up with are so clever
Love it! Would like to have the option to make the arrow buttons closer to play with one hand. Thank you!
Maybe add a skin around the sphere to make it look like the earth. Then the targets become places.
reminds me of some of the old Beagle Brothers one-liner games. it's easy to forget that something this simple is still fun!
Tried submitting my score, but it said the captcha score was too low?
So, Astro Bears without the bears?
This reminds me of Snake Galaxy. I'm so sad it's not available anymore, it was an adorable spherical snake game on early iPhone circa 2010 era. I really miss the little Paris planet.
https://toucharcade.com/2009/04/24/snakegalaxy-puts-a-new-sp...