A long time ago in a place not far from here, a certain triangle wrote a program to randomly select tracks from the game LEGO® Racers for the player to race. Soon thereafter, a friend asked for an equivalent version for LEGO® Racers 2. The request was acknowledged, and work so began. However, due to confusing logic and a lack of programming skills needed to carry out such a task, development was halted, and the request was never fulfilled.
One year later, the unfinished program was referenced, and after reviewing the state of the code, it was decided that the know-how required to complete it was now available. A mere two hours later, the program had been finished, and the promise made had been kept.
The next day, that same triangle decided to update the original LEGO Racers program to be consistent with the newly written LEGO Racers 2 version. In even less time than the day before, 12 minutes to be precise, that too had been fully updated.
You know what? I cannot keep this up any more. 😛
As I vaguely described, I released two applications last week (yes, they are written in Python). The first is a fully revised version of the LR Track Selector, now containing a simpler and quicker random track selection fully thanks to a brand new (and rather simple) Tkinter-based GUI. The second program, which actually came out before this re-release, is the brand new LR2 Track Selector, which is, as written in the story above, is the LR2 version of the first program. This too contains the exact same GUI as the first program, and even randomly picks the world to race on in addition to the track.
In case you are wondering why I did not complete the LR2 Track Selector sooner, it comes from the fact that I was going about it with the wrong objective. In the Racers version, it picked a track and asked for confirmation if that was a good choice for the user. If not, it would select another one. I was trying to apply this same workflow to Racers 2 version, which did not work as Racers 2 required two random selections instead of one, namely, the world then a track on that world. It was also of no help that at the time I had no knowledge of GUIs whatsoever (and I still lack a large part of that knowledge to this day). In hindsight, had I really thought about what I was doing, I could have very well make that workflow possible. However, with these releases, I abolished that idea and did what I should have done to begin with. Instead of confirming anything, I simply pick the track and/or world and present it outright. If they want a different track, simply click the button again (tip: the keyboard shortcut
<Ctrl+n> will do the same thing). Not only does this streamline the entire process in both development and usage, but it also means you can get to racing much sooner. 😀
As always, the full source code and downloads to both programs are on GitHub. 🙂