Posts in category 'nethack'
Well, I promised some shots of my Nethack port in action, and I aim to please! Now, I couldn’t figure out how to get my code working with Desmume, so I just gave up and used a camera. You’ll have to forgive the consequent bluriness…
Here we see a newly minted game. On the bottom screen you can see the visible play area. On the top screen you can see the minimap, with a red box representing the displayed region on the lower screen, as well as the player’s status and the welcome message.
This shows the popup command menu. The user holds the L button (eventually this will be swappable, for you lefties) to make the menu popup, at which point the user can tap a command to have it execute. Much nicer than an on-screen keyboard, I think…
And this last shot shows the inventory list after selecting the Inventory command. As you can see, there’s a bit of clipping, but it otherwise works as advertised. If this were a Drop command or something similar, the user would be able to tap items to select them (multiple taps begin counting from 1).
So there you go! See, it’s not vapour after all! Well, not technically, anyway…
And now key remapping is implemented! This includes handedness swapping (swaps the shoulder buttons), and mapping commands to the joypad and the primary buttons. And the changes are persisted across sessions. Neat, eh?
NetHack + DS -> New Project!
When I first got my DS backup device, it didn’t take me long to track down, and quickly eliminate as impractical, the first, and to my knowledge, only attempt to make a DS NetHack Port. It’s a “port”, in the sense that it really just takes NetHack, shrinks it down, displays the virtually unreadable game on the upper screen, and a graphical keyboard on the bottom screen. Does it work? Sure. But only just barely.
So quite a while back, I decided I wanted to create a port of my own. Much initial hackery was begun, followed by the usual subsequent boredom, followed by the devastating loss of my DS and backup device in an unfortunate incident involving my crappy memory and an airplane seat pocket. The result was a project that languished in my subversion repository until, a few weeks back, my new R4 arrived in the mail which, when pared with the new DS my brother kindly bought me for my birthday, resulted in renewed homebrewing efforts!.
Since then, I’ve made enormous progress. The game is essentially playable right now, and sports:
- A top screen displaying a minimap, status and message display, and input prompt.
- A bottom screen showing the game map in unscaled, scrolling, tile-y glory.
- Support for movement using the joypad, as well as the stylus.
- A popup command list, toggled with the L-button, from which the user may select commands with the stylus.
- Full support for menus, again using the stylus for item selection.
- String input using a virtual keyboard.
- Save/Restore support.
Of course, if it were all roses, I’d release the thing right now. But there are bugs, and a few things on the TODO list, as well:
- Currently wide text is clipped… I’m not sure how to solve this, though.
- The menus should be pageable with the joypad.
- Quitting and saving should return the user to the flash cart menu, or possibly power off the DS.
- It desperately needs a left-handed mode.
- Keys need to be configurable.
And, of course, I need to test test test! I’m primarily worried about memory usage… I think I have most of the issues worked out, and I spent a fair bit of time teleporting around the game in wizard mode, causing general mayhem, and didn’t run across any issues. But I’d like more time with it to make sure the obvious bugs are ironed out.
And even with those problems fixed, I will fully admit that:
- It’s kinda fugly. But it’s fugly the way text-mode nethack is fugly, so it’s kinda charming that way, and
- The text rendering code, particularly for menus, is slow.
But, in short order, I’ll hopefully have a release out. Meanwhile, stay tuned for screenshots… assuming I can get desmume up and running and working with my port. :)
Oh, and BTW, if anyone has thoughts for a name (NethackDS is taken, so I was thinking something like “Nethack Touched!”, or possibly something even more lame, would work), please let me know! Plus, then I’d know if anyone’s bothering to read this thing, anymore. ;)
So it turns out that buying a new backup device for my DS has had an extremely detrimental effect on my writing frequency. Actually, it’s worse than that… it’s a combination of a new backup device, with Nethack. Not good.
In particular, I got the idea in my head to take NethackDS and basically rewrite the user interface, to make it more comfortable to use. See, NethackDS takes the simplest approach to a port, making extensive use of an on-screen keyboard and an ultra-small font to provide an experience very similar to Nethack for Unix. However, the interface is far from efficience, and is pretty tough to read, to boot.
And so I took it upon myself to spruce things up. Now, I haven’t gotten very far. In fact, I’ve only just gotten some text on the screen (though this required porting a BDF parser and writing a bit of rendering code), but progress is being made… so, hopefully in a few weeks, I’ll have a fancy new DS port of Nethack to play with.
I’m not sure this is a good thing.
Nethack is Destroying My Life
As if I didn’t have enough things to do, what with the ongoing writing project (the 1000 words/day project has languished after our last cold, but it’s still going… just not as quickly as I’d like), renewed cooking interests, the ever-recording PVR, books, etc, etc, but for some reason, in a fit of boredom while trying to figure out how to fill my hours at work, I made a huge mistake: I started playing Nethack.
For the uninitiated, Nethack is a 20-year-old game, still in active development, which traces it’s origins back to Rogue, a classic game for the Unix environment. It’s best described as a dungeon hack-and-slash, and has been cited as a direct influence for a number of modern games, including Diablo. The general idea is that you pick a class, race, gender, and possibly alignment, and then start fighting your way though the dungeon, in search of the fabled Amulet of Yendor, which exists somewhere beneath level 20. Once you get it, you must then make your way back up and out of the dungeon.
Yeah, I know, it doesn’t sound like much, but it does have a few things going for it:
- Randomly generated maps
- ASCII graphics
- An incredible depth and breadth of play
- A good sense of humour
Like the original rogue, every game of Nethack is different. While there are various areas to be discovered (the Gnome Mines, the Sokoban levels, and so forth), the levels themselves are randomly generated every time. Thus, it’s impossible to “finish” Nethack, in a real sense, as you can always come back and try again with an entirely new dungeon to explore. This does mean there’s an element of luck to one’s success in the game, but I think that’s mitigated, to a great extent, but the richness of gameplay available.
Secondly, Nethack is played using plain ol’ ASCII graphics. The walls are dashes and pipes, the doors plus and minus signs, the various items are punctuation marks, and the enemies are letters. Of course, if you like a little flash with your hack-and-slash, you can make use of colours, or even IBM high-ASCII graphics characters! But the purists will tell you that straight-up, B&W ASCII is the only way to go (personally, I like the flash). But why is this a plus, you ask? Because I can ssh to frodo and play from work! cough
Then we have the sheer complexity of the game. Nethack sports an immense number of weapons, armour, items, scrolls, potions, rings, amulets, and random junk, such as pick axes, lanterns, whistles, blindfolds… the list goes on and on. If that weren’t enough, there are a vast number of actions a character can perform, including dipping, throwing, kicking, reading, sitting, praying, eating, casting spells, and many more besides. And what’s truly amazing is that the developers seem to have thought of every possible combination of actions and items, so you can dip your sword in potions, wield rings as weapons, and stick gems in your sling-shot. In addition, your character typically starts off with a pet, which can be tamed and trained, and you can also tame other animals in the game (I was observing one game on nethack.alt.org (a free, public Nethack server) in which the person had tamed a giant of some description). These animals will fight for you, steal for you, and are generally quite useful. Then, to that, add the myriad actions and effects that can happen to your character, and the number of scenarios possible becomes truly bewildering. Get bit by a wererat? Turn into one yourself, randomly transforming into a rat (at least you get a pet rat as a consolation prize). Eat the corpse of a floating eye? Gain… oh, well, I won’t spoil that.
So, yeah… the game is remarkably rich.
Lastly, the game is just plain funny in many ways. As an example, if you eat slime mold, the game will tell you how delicious that slime mold was! Mmmm… and then there’s the grave stones you come across with amusing epitaphs on them, and the odd bit of writing on the floors. Heck, you’ll even occasionally come across your own ghosts from previous deaths (you even get the chance to loot your old corpse).
Unfortunately, the game is also legendary in it’s difficulty. I have yet to make it past level 7 (or was that 6) of the dungeon, and I often die in rather annoying ways (such as getting paralyzed by a floating eye, and then bitten to death by wererats). Oh, and when you die, you’re dead. No save points, no lives. That’s for losers who can’t handle a challenge. Sure, you can save your progress and pick up your game later (some may back up the save files, but this practice, known as “savescumming”, is rather frowned upon), but if you die, that’s it, game over. And yet, despite this, I keep coming back… the damn game is just addictive, somehow.
Which would be why I regret breaking out the Nethack. I just can’t stop playing it. “Maybe next time I’ll make it to level 8,” I tell myself. “Maybe I’ll be an Archaeologist next time! Or a human instead of a gnome. Or maybe I’ll spend some time in the Gnome Mines before going down the main dungeon. Or.. or… or…” It’s like frickin’ crack. I just wonder if I’ll ever be able to get this monkey off my back (or, at least tame him so he’ll steal stuff from shops and fight my enemies for me).
It’s 12:53am on Saturday night. I just finished watching an episode of Stargate and decided to pop open the laptop to quickly check email. And I seriously considered playing another frickin’ game of Nethack…