top | item 8910118

Lightbot: A simple programming game

127 points| abraham_s | 11 years ago |lightbot.com | reply

28 comments

order
[+] Orangeair|11 years ago|reply
I find this interesting for how it demonstrates recursion as a means of looping. Most simple code tutorials like this just follow the procedural style, and make you throw a set of instructions inside of a loop block.
[+] kolev|11 years ago|reply
It's not that simple. My 6-year-old son is having hard time - even with the Junior version on Android. Sometimes I do have issue with the regular version as well - it's much easier to write code than use the constructs.
[+] mjmahone17|11 years ago|reply
This game has a similar code mechanic to CargoBot: https://itunes.apple.com/us/app/cargo-bot/id519690804?mt=8

CargoBot has given me hours of having to really think about how to structure my "code" to get the recursive calls just right. I haven't gotten deep into Lightbot yet, but it should be a fun puzzle if later levels have similar types of recursive challenges.

[+] anomie|11 years ago|reply
http://pleasingfungus.com/Manufactoria/ is another great game along the same lines
[+] ygra|11 years ago|reply
I love Manufactoria, precisely because it's a game about programming but manages to avoid the Lightbot style where you just put commands in a fixed sequence. Lightbot abstracts procedural programming into a game, but so did graph3.tpu back in the day for me. Manufactoria makes a game about programming by forcing even programmers to think different.
[+] slowmovintarget|11 years ago|reply
Haven't seen it mentioned in the comments yet, but here's another that's a bit more hardcore: http://robocode.sourceforge.net/

You code the AI for your tank then let it loose in an arena with other tanks. You have to handle path-finding, scanning, range-finding, target identification, hit/miss analysis.

Some of the winning bots are amazingly competent with their scan-and-move algorithms. You code in Java or some flavor of .Net.

[+] gasping|11 years ago|reply
This was really good but there were a few levels that left a bit to be desired. Some of them were basically "find a way to mash this code into these functions without exceeding the instruction cap" while others encouraged quite elegant programming. The last one of the final stage was probably the best example, I thought it was quite elegant.
[+] Tideflat|11 years ago|reply
As a hint: When you run out of space in a function, then just tack the still needed blocks to the end of every call of that function. It is a bad real-life programming pattern but works in this language.

(This language seems non-turning complete without conditionals.)

[+] abraham_s|11 years ago|reply
I have been looking for a game to suggest to my 8 year old nephew. This looks simple enough for him to start on. But I am guessing he might need some help when recursion comes into picture. Thanks to others who have posted other suggestions.
[+] artgon|11 years ago|reply
This is a really clever way to help people get an idea of what programming is all about.

Great work!

[+] akkartik|11 years ago|reply
Right after the first level the question in my mind was, "hmm, I wonder what the tile for conditionals looks like." That question was never answered. Anybody have any ideas on how to answer it?
[+] dyarosla|11 years ago|reply
Creator here. Conditionals are introduced in some of the premium versions. You can see how they work in the video at the top of lightbot.com- once the paintbrush is introduced to color the robot conditionals allow for running commands based on lightbot's color.
[+] glesica|11 years ago|reply
Was anyone able to actually play the game? It took me to an introduction, the last slide of which was "I'm finished with my hour of code" and I couldn't go any further.
[+] borkabrak|11 years ago|reply
That got me at first, too. If you'll notice, the slides are 'chapters' that you can click on to try the challenges therein contained.
[+] mkesper|11 years ago|reply
Sadly it requires Flash/Shumway.
[+] tensorproduct|11 years ago|reply
I played this game some years ago before I learned anything about programming. Coming back to it with some understanding of recursion makes it a lot easier (though still tough in places).
[+] madlag|11 years ago|reply
My daughter has been playing it since she was 7, it's really cool to teach the basics of programming, and more generally to improve accuracy of spatial and time reasoning.
[+] otikik|11 years ago|reply
Auto playing music on load -> instant tab close.