dries.page /DIY /art /dev

Space Snake: Unleashed

Dec 11, 2020

Scroll down for a Javascript game I made for a coding class exercise. Our first chance to get creative with a real programming language. I got my inspiration from some games older than myself: 'Snake' and sidescrolling shooters like 'R-type'.

Teaser image for Space Snake: Unleashed.

We only had a few days so I started without learning theory. After finishing, the coach sent me an article on how JS games are usually made - using a main loop instead of several parallel ones, and using the canvas element instead of a shifting HTML table to imitate 'pixels'. You could compare it to having painted with a sponge and then learning brushes exist. Painting with sponges works if you don't mind the strange looks, but to make smart decisions you need to know what tools are out there.

Later we learned about Object-Oriented Programming and SOLID and while these are very useful principles, I couldn't help but feel that programming is a lot slower when you try to do everything the right way. For small and solo projects, it can be better to just do things in whichever way feels productive and fun. If I had been a perfectionist, this game might not even exist!

Anyway, enjoy SPACE SNAKE: UNLEASHED.

It goes well with Synthwave music like this:


Health:
Paused
Use the arrow keys to move.