## How to play a 4 Spatial Dimensions Snake

Think your art is better or your stick figures worse? Got a link to a site you want to share? Post it here!

Moderators: Jacque, Moderators General, Prelates

Pella86
Posts: 8
Joined: Mon Jul 04, 2011 8:31 am UTC

### How to play a 4 Spatial Dimensions Snake

Hi everybody,

I posted a while ago a link to a youtube video about a 4 spatial dimensions snake.
The game is simple, is like the old nokia snake, but the snake moves along 4 perpendicular axis: x, y, z and w.
I did a new video where I explain how to play the game:
Snake 4D

In 2d the snake is inside a square, in 3d inside a cube, in 4d is in an hypercube.

The game is perspectively projected, which means that the hypercube can be viewed in it's classical "cube inside a cube" conformation, but can also freely rotated.

There are 2 version of the game, and for both it's available the source code.
The first version is in python, and can be downloaded as script or as application (for mac, win, unix) and can be found here:
pyhon version

The second version can be found in the description of the above video, is written in C++ and uses qt and OpenGL for graphic.
The game works smoothly in this version, however I had difficulties to compile it, so there is only the source code available.

cheers,
Pella86

Jplus
Posts: 1680
Joined: Wed Apr 21, 2010 12:29 pm UTC
Location: Netherlands

### Re: How to play a 4 Spatial Dimensions Snake

Nice job! Also a good job in explaining how to play the game, at least for me it worked while I couldn't really imagine the thing beforehand. I think you found a good solution for controlling the snake.

I would try to compile the Qt version for you if I had more time.

Perhaps you already know it, but just for reference: there exists a computer program that lets you play with a Rubik's hybercube.
"There are only two hard problems in computer science: cache coherence, naming things, and off-by-one errors." (Phil Karlton and Leon Bambrick)

coding and xkcd combined
Feel free to call me Julian. J+ is just an abbreviation.

Pella86
Posts: 8
Joined: Mon Jul 04, 2011 8:31 am UTC

### Re: How to play a 4 Spatial Dimensions Snake

Thx for the comment I did this video to make people understand what I did.

I've seen the rubick cube, and I sucks at it in 3d, I tried the 4d and the only thing I could do was creating beautiful mosaics of colors without coming to a solution.