News for hackers. Stuff that matters.
Re:My 2.5 year old laptop can write Space Invaders in JavaSc... by simonw on Tuesday July 29, 2025 @03:09PM (#44727149)
It sounds like you care deeply about learning as much as you can. I care about that too.

I would encourage you to consider that even LLM-generated code can teach you a ton of useful new things.

Go read the source code for my dumb, zero-effort space invaders clone: https://github.com/simonw/tools/blob/main/space-invaders-GLM...

There's a bunch of useful lessons to be picked up even from that!

- Examples of CSS gradients, box shadows and flexbox layout

- CSS keyframe animation

- How to implement keyboard events in JavaScript

- A simple but effective pattern for game loops against a Canvas element, using requestAnimationFrame

- How to implement basic collision detection

If you've written games like this before these may not be new to you, but I found them pretty interesting.

There are no comments on this comment yet.