robohack: The only legitimate use of a computer

Imitation is the sincerest form of flattery, supposedly. If that’s the case with robohack, the flattery is well earned.

The name might be a hint, but if you don’t know about Robotron: 2084, it might not work to know what game robohack hopes to imitate. If you remember the golden age of arcade games, then you won’t need to click on this link as a reminder. ;)

From personal experience, I can tell you two things about Robotron that stick out in my memory, and after that I’ll tell you the most amazing thing I know about it.

First, Robotron was an out-and-out action slugfest, and it worked because of the dual joystick model. It took a little while (or a few dollars, I guess I should say) to get used to the idea of moving and shooting in different directions, but once you got the hang of it, everything else seemed primitive.

Second, Robotron’s sound effects were fantastic, not just in technical terms, but because they fit the mood of the game as well. You can find fault in the cutoffs or splits between effects (only one audio channel to work with in 1982), but from an atmospheric perspective, those noises and zings were perfect.

And the amazing thing? The whole business ran on a 1Mhz Motorola CPU. :???: And what have you accomplished today, with your quad-core system with 12Gb of RAM and 4Tb of storage? I didn’t think so.

robohack pays homage to the original in a text-only environment, and does a pretty good job, if I may say so.

2014-11-10-jsgqk71-robohack-01 2014-11-10-jsgqk71-robohack-02

A lot of the action is lost in those static shots, but I’m sure whatever computer you’re viewing this page on is plenty powerful to put together a live version. You’re operating with thousands of times more power than the original game had, and it’s working only on an 80×24 screen. ;)

Movement is with the E-S-F-D keys in four directions, and firing is with I-J-K-L-Y-U-B-N in eight. That more or less mimics the original Robotron layout, but I would prefer a tighter set of keys for the eight-direction set.

You could conceivably adjust the source code to accept different keystrokes, then recompile, but I’m not going to count that as any degree of “customization.” :roll:

Your goal is to collect as many members of the last Human family, designated by capital M characters. Your pursuers are Grunt robots marked by the letter G, and Hulks as letter H, the latter of which cannot be destroyed. Collect a family member and win points, but you’ll be destroyed if robots collide with you, or if you touch glowing Electrodes.

And that is the formula for a pretty darned good action console game.

High points: Awesome title screen. Excellent explosion animations and firing effects. Great use of color, speedy action and a tough challenge. Grunts will throng after you quite quickly, and sidestepping them and the Electrodes can be tough.

The playing field is a good size even if it doesn’t draw out to the ends of your screen. And the Humans are sufficiently stupid to make you tapdance to collect them, which only further frustrates your quest. And yes, that’s a good thing.

Low points: You might do well to focus on either moving or shooting while you learn the controls. Unless you’re a pianist, it might take a while to get the hang of the needing both hands. But again, that’s part of the game.

Occasionally robohack stutters while it collects movement or firing instructions, meaning you can’t just hold down one key to move while firing in another direction. It doesn’t seem to read the keys that way, and until you get used to that, it’s going to be frustrating.

The original game had a Hulk “stagger effect,” where firing into a Hulk caused them to stagger back a half step before continuing their pursuit. That is somewhat mimicked here, where firing at a Hulk causes it to pause for a moment before continuing. I suppose that’s the best that could be expected under the circumstances.

The necessity of the animation and collision effects means there’s a possibility you’ll get killed by a Grunt seemingly out of nowhere. The original game drew a straight line to your character, and each Grunt moved one step in that line. With only a 72×20 (or so) map to work with, their “lines” of travel might catch you off-step when they get very close. Don’t say you weren’t warned.

And I’m at a loss as to why I can fire in eight directions but only move in four … ?

No sound. :(

But I’m quite pleased with robohack as a game that has reached its first decade and still shows potential. It’s fast, it’s tough to learn, and it’s got great visual effects for a console adaptation.

So this is an easy decision … one super-valuable and highly rare K.Mandla gold star for robohack: :star: ;) Enjoy … because as one of the creators of the original game once said, “The only legitimate use of a computer is to play games.” 8-)

ctris and seatris: A homophonic puzzle pair

You might find this hard to believe, but I have another week’s worth — at least — of games prepped for discussion. I know we just finished a huge 10-day block of games last month, but it seems that if you mention a console game, people are quite eager to suggest another.

And so my last round of 20 or so games netted another 20, at least a dozen of which work fine and will grace these pages in coming days. My only fear is that this might become a self-perpetuating reaction, and I’ll never see the end of this blog. … :’(

I’m going to pluck out the easy ones today, just because two of the crop are both Tetris remakes. I hold no ill will toward Tetris clones, but it’s a common programming exercise and (without being rude) neither of these rises to the level of the best Tetrises I’ve seen.

Over the past two years I’ve probably tried a dozen more of these in varying quality, and there are probably still dozens more out there. :shock: So let’s crank through this homophonic puzzle pair, in the manner of some other grouped games. …



Pros: Good clean colors, easy shapes, straightforward controls. Clean display arrangement, tucks into 80×24. Pause key. Keeps a high score list. Cons: Moves quickly from the start. Does not resize to terminal. No on-screen cues aside from score, level and next piece. Only one-way rotation. No drop indicator. Overall: ctris manages to nail the core elements of Tetris without missing any critical component, but also doesn’t add any embellishments whatsoever. Your flag options are scant and don’t add much to gameplay, but the pure Tetris experience is here. That much puts ctris dead square in the middle of the pack for Tetris clones, with plenty worse than ctris, and plenty better.



Pros: Strict ASCII characters, but with bolded colors. Cumulative block stats and plenty of other on-screen info, but somewhat jumbled. Optional key arrangements. Very basic display that nestles into 80×24. Keeps high score chart. Good pacing, and level advance controls. Cons: Game trough is somewhat narrow, and pieces are slim, making the play field hard to read as blocks are broken apart. Does not resize to terminal. Optional, but not customizable, key arrangements. Everything is bold, as opposed to using accents for visibility. One rotational direction. Overall: seatris has shortcomings that could be easily corrected, but until then it rides much the same rail as ctris. seatris may offer a few more options for controls and a few more on-screen cues and stats, but certainly doesn’t leapfrog ctris on those grounds. I give it more slack since its source code dates back to 1999 though. :|

Neither ctris nor seatris strikes me as much innovation, but that doesn’t discount the fact that they both work fine. There are better tetris options available to you that will only cost a sliver more in system resources though, so I can’t see picking one of these over yetris or vitetris, unless you’re just fond of one.

For what it’s worth, I have considered closing the doors on Tetris clones, much like I have for revision control systems or one-codec playback tools or firewall tools. Writing a Tetris clone is probably a hush-hush rite of passage for CS degrees somewhere, and I’m probably lucky I don’t have more to sift through.

For the time being though, I don’t mind including them. It will have to be a game of immense technical prowess to impress me though. Stay tuned. … :|

Bonus: A dozen more remainders

It’s that time again: It’s time for another dozen titles that — either through age, or my thick-headedness, or just gremlins — couldn’t, didn’t or wouldn’t perform as expected. As always, this may not be the case if you try them out.

  • bashttpd: I found bashttpd after my discovery of ngincat; a vanilla search for “tiny http server” turned up this bash server script, and of course, the one-line built-in python server command. bashttpd will work with netcat too, or socat, but in my case performed only sporadically, and only with socat. I say that, but in truth it only gave me one page, then quit out of the server and the “site” was dead. I used the commands listed on the home page, so I’m not sure what I did wrong. …
  • burncdda: I had links for three CD-oriented tools, and all three sputtered for one reason or another. burncdda is not in any recent version of Debian, and my attempts to build it in Arch were stymied by very out-of-date dependencies, a lot of which were unknown to me. mp3_check was one of those, which dates back to 2000 and just didn’t build. That was the final nail in the coffin.
  • burncenter: The second CD-related utility to collapse on me. The home page is available, but the source link is dead. There was a Debian package on that page, but that link is dead too. There is a link to a Freecode page, but that page is gone. And the svn repo linked there is gone too. So … that’s that.
  • lastbash: A player for the console. I could swear I have heard of people using this, but the version I had wouldn’t connect to anything, and just gave its help message over and over … even when I was using example stations off the man page.
  • nwm: Another ncurses window manager selector, along the lines of cdm or ncdm. This also entered a gray area for me, since it’s rather dated and I don’t know what would be the proper way to insert it into systemd. Not that it matters, since every attempt to run it left me with “tokenizer errors,” and never made a jump to X. The menu and selection bar worked fine, if that’s any consolation. :roll:
  • ratox: Theodore mentioned this a couple of months ago, but the AUR version crumples when trying to build tox-git, and just sits there for hours and hours without moving. I’m going to come back and visit this one again though, because the description on the home page sells it well.
  • slice: This was a recommendation from a regular anonymous contributor, as a tool that wrangles with text files and sifts out selected strings. I spent a lot of time with it but there isn’t much documentation and I couldn’t grasp how to work it to get the results I wanted. The man page was little help, since it mostly described the search features in mathematical terms. Perhaps it is just a little too abstract for someone of my experience level. In Debian, not in Arch.
  • subdb-cli: This was a wild swing on my part, as a possible downloader for movie subtitles. Every movie title or file name I gave it was unfindable though. Perhaps I was feeding it the wrong information. …
  • tcdr: My third CD-type utility to fail in this dozen, and a ripper this time. It’s in AUR, but exploded all over my screen when I tried to use it. It also was still pining after /dev/dsp, and wanted root access to build a nest of directories at /mnt. I … don’t know if I’m comfortable with that. …
  • terminal-screensaver: This is a very old PKGBUILD in AUR that was submitted in 2008 and hasn’t been updated in a year. The link to the homepage is a 404-style message, and I saw no signs that the source or the description had been relocated so … I assume it’s gone. The link to the source from the AUR page yields a 550 error. This is not the same terminal-screensaver as we saw a few months ago, either. And yes, there needs to be a little weeding done in AUR again; I find broken, outdated or zero-byte PKGBUILDs all the time. :|
  • I got quite a few notes about this a month or so ago, and it seems like a useful service. If I understand it correctly though, there’s nothing to install or run here, it’s just accessible through curl, and therefore usable from the command line.
  • xtermcontrol: If you’re an xterm user, this might be your will-to-power moment. xtermcontrol isn’t a control panel for xterm; instead, it’s a tool for changing xterm settings on the fly. This is great stuff if you prefer that particular emulator, but sort of ho-hum if you use something else. Either way, it’s not really a console application per se.

That’s it. The standard disclaimer applies: Just because I was too dense to figure them out, or just because they crashed when I tried to compile them doesn’t mean they won’t work for you either. If you meet with success, please tell me about it. ;)

pup: Playing fetch with HTML

Every month I export the posts from this site, grind away at the XML file, pluck out titles and links, and rearrange them to form an index page. Don’t say thank you; I do it for me as much as anyone else. I can’t remember everything I’ve covered in the past two years, and that index has saved me more than once. :\

Point being, it takes a small measure of grep, plus some rather tedious vim footwork to get everything arranged in the proper order and working.

You know what would be nice? If some tool could skim through that XML file, extract just the link and title fields, and prettify them to make my task a bit easier.

pup can do that.


Oh, that is so wonderful. … :roll:

In that very rudimentary example, pup took the file, the field I wanted, and sifted through for all the matching tags before dumping it into the index file.

pup will also colorize and format HTML for the sake of easy viewing, and the effect is again, oh-so wonderful.


That might remind you of tidyhtml, the savior of sloppy HTML coders everywhere, and you could conceivably use it that way. pup can do a lot more than that, though.

You can parse for multiple tags with pup, filter out specific IDs nestled in <span> tags, print from selected nodes and pluck out selectors. And a lot more that I don’t quite understand fully. :oops:

It is possible that you could do some of what pup does with a crafty combination of things like sed or grep. Then again, pup seems confident in its HTML expertise, and the way it is designed is easy to figure out.

And for those of you who won’t deal with software more than a few months old, I can see that at the time of this writing, pup had been updated within the week. So it’s quite fresh. Try pup without fear of poisoning your system with year-old programs. ;)

realpath: It’s the real thing

I am apparently still suffering the unintentional side effects of my long-ago decision to dump everything from coreutils, bsd-games and util-linux back into my list. Because yesterday I realized I still had a zero-byte file for realpath hiding in my vimwiki folder. >:(

These things are like rabbits. Turn your back and they’ve multiplied. O_o

realpath belongs to the coreutils family, and I am not being kind by suggesting it has no real function or can’t solve an issue. Remember when I prattled endlessly about basename and dirname? realpath solves some of the issues that I mentioned with those programs.

Here’s what it looks like in action:

kmandla@6m47421: ~/temp$ realpath test.txt 

kmandla@6m47421: ~/temp$ realpath .

Oh, K.Mandla. Thank you sooo much for showing that. Thank you sooo much for solving my existential crisis with realpath. K.Mandla, your grimy little blog is a fount of wisdom.

Hey, my little blog may be grimy, but at least it’s legit, original content. Can’t say that about a lot of Linux “news” sites. :evil:

Back to business: realpath, as you can see above, returns the path of the target you specify, or as the man page so verbosely explains, “prints the resolved path.” :\

Before you close this tab, here’s one more example:

kmandla@6m47421: ~$ realpath sdb1

O-ho. What’s this? Well, I keep a symlink in my home directory that targets a mount point — with that, I can abbreviate mount /media/sdb1 to just mount sdb1, no difference.

realpath returns the real path :roll: of the symlink, rather than just its location in my home folder. Now we’re cooking.

realpath will accept a few flags, but they strike me as particularly discrete cases for links, and tune realpath‘s output more than I would ever need. Double-check them if you feel you may want them.

So there it is. And unless I’m mistaken — again — this really is the last title from coreutils.

I think. :/

mdp: A new challenger appears

You’ve probably known about tpp, a text-based presentation tool, for a long time. I know I’ve mentioned it here, and did a long time ago on another dumb site.

tpp never really has much competition, probably because text-based presentation tools represent an extremely narrow niche market. Extremely narrow — like, hair’s-breadth narrow. :shock:

mdp is a challenger for the throne though, and judging by its flair, it may be enough to drive a wedge into that extremely narrow niche market.

From the console, mdp has a very straitlaced look about it.


Everything centered, clean arrangement, page counter in the lower right and authorship tag on the lower left. Arrow keys for control, space to advance and q to quit.

But, as might be anticipated, in a terminal emulator things get a little more intense.


Wow. Underlining? UTF-8 characters? Wide character support? 256 colors? Madness. And what you can’t see are the fade effects between frames, courtesy in my case of rxvt-unicode.

Needless to say, that kind of wildness isn’t really available in my strict framebuffer environment (I didn’t try a framebuffer emulator. You try and tell me what happens), but I won’t hold it against you if you decide to join mdp’s team and work it from Xorg.

The second volley in mdp’s one-two punch on tpp is its compatibility with markdown. If you’ve ever edited a wiki page, or put together some blog posts with certain applications, or kept a journal of sorts, you probably already know some markdown.

Which means drafting an mdp presentation will be second nature for you. tpp’s “code” was never difficult to learn (the examples could teach you everything you needed to know in a matter of seconds), but using markdown as a background format is a natural choice.

And probably means you can easily convert some of your other markdown-ed projects into slides, in a jiffy.

To be sure, mdp still has a few hurdles to jump, before it catches up with some of tpp’s most basic features. For example, for what I’ve seen, mdp only does one transition. tpp has a little more variety in its presentation styles. And you can inject everyone’s favorite fatty text generator straight into tpp.

I don’t see that in mdp.

And tpp can drop into the shell, issue commands, and redirect the output into its presentation.

And mdp … ? Hmm. … :???:

Okay, so tpp still has some life in its old limbs. The newcomer may have a little more flash and dash, and may show more color and do a fancy fadeout between frames. But I’m afraid I might have to side with the incumbent this time.

Come back when you’ve learned a few more tricks, and we shall hold a battle royale for the crown of heavyweight text-based presentation tools. Tune in next time. … ;)

tagsistant: Tagging with a different approach

After my great delight at trying tmsu, I was willing to try out tagsistant on Eric Davis‘s suggestion. And between the two of them, I think Eric is right: tmsu might be a better fit for me too.


I can see similarities between tmsu and tagsistant; both use directory trees to arrange tags, and to show combinations between them. tagsistant seems very intuitive when it comes to finding mixed tags, with a simple plus sign showing combinations, and so forth.

tagistant “tags” files by “copying” them into a tag folder, which means adding an entire subfolder is a lot easier than tmsu was. And you can tag a directory itself, without necessarily applying the tag to files inside it. I can see where that might be preferable, and the home page suggests that will keep the database slim.

tagsistant is also file-manager friendly, and I suppose the same thing could be said about tmsu. Once I had a few files tagged and cross-tagged, I could work my way through the directory tree with Midnight Commander, and see how files were arranged between tags.

Probably the best part of tagsistant was the setup. The home page shows you in simple steps how to create a tag system, tag individual files and work the query process. It’s a very comfortable introduction.

My complaints against tagsistant are also simple and fairly straightforward: Perhaps biggest, there’s no way I could see to query the tag system without working through the folder tree.

With tmsu I could just ask it outright what tags were applied to a file, but I don’t see an analogue for that in tagsistant. Please point it out to me, if I’m just being dense.

Second, I see no expedient way to apply multiple tags at a time. The copy-file-to-tag motif is an interesting approach, but it doesn’t lend itself to adding three or four tags at once. I prefer tmsu’s approach, of just listing tags in quick succession.

That might go back to my first, and this last point, just that the tree structure for tagsistant is a useful format, but can be very cumbersome without a file manager. Tab completion helps, but each query up or down the tree is going to require some backspacing, correction and possibly even retyping. My advice? Pick a quick file manager. :\

(Of course, maybe if you could combine this with something like commacd, you might have a very powerful combination. … :| )

tagsistant is by no means an unusable tool, and depending on your files and tags, you may prefer this over other options. Definitely look through the advanced documentation, because it will help you with a lot of tagsistant’s finer points.

As for myself, I’ll stick with tmsu, unless one of Eric’s other recommendations wins me over. … ;)