A 4k-Room Text Adventure Written by One Human in QBasic No AI

129 pointsposted 5 days ago
by ATiredGoat

92 Comments

arscan

15 hours ago

The first program I ever wrote was a choose your own adventure, I think written on my family’s IBM PC jr in Basic. It’s pretty amazing how far a kid can get with GOTO statements and a lot of patience. But for some reason I couldn’t (or didn’t know how to) save it, so I’d work on it all day, have my sister and mom play it, and then shut off the computer thus losing my days work.

Or at least, that’s how I remember it. It’s been a good 40 years though and I wouldn’t be surprised if reality was quite a bit different.

Edit: I’ve been thinking about this a bit and honestly my motivation for writing software hasn’t really changed. The users, sure, but not the motivation. It’s just thrilling to share things I built with other people.

vunderba

14 hours ago

When I was first introduced to BASIC in elementary school, I was spending a lazy afternoon reading in the built-in QBasic docs (being able to hit F1 and get immediate help is still one of the coolest things ever IMHO) about the SOUND keyword, which let you set a frequency and duration.

I remember irritating the hell out of my parents (and our dog) with it until one day, by accident, I noticed they couldn’t hear the tone anymore. The frequency was somewhere in the range of 15-20 kHz IIRC.

So I wrote a “PASSWORD.BAS” source that would play that high pitched sound in short, one-tick intervals continuously while polling the keyboard for input but then stop after a random amount of time. To authenticate, the user had to hit the spacebar within a one second window of the sound’s termination. Hitting the spacebar too early would also result in access denied. Fun times!

analog8374

12 hours ago

I used to mess with sound on my commodore 64. 3 voices. ASDR. Square, sine, triangle. Chords were frequencies with common factors. The world of strange sounds is vast.

vunderba

11 hours ago

Nice! I still love that one of the ways that C64 composers worked around the limitations of 3 independent sound channels was to use a single voice to simulate a chord by playing the triad of notes in an continual extremely rapid arpeggiation.

Incidentally, if you're ever interested in playing around with one again, there's a really accurate VST emulator called Chipsynth C64 [1].

[1] https://www.plogue.com/products/chipsynth-c64.html

rectang

13 hours ago

When I was in Jr. High, we had an Atari 400. Mostly I used it to play Missile Command and Star Raiders, but it also came with a BASIC cartridge.

In the back of the manual were four BASIC programs. The first three were very simple, stuff like a loop that prints your name 10 times and then exits.

The last program balanced your checkbook. It was 4 pages long. I laboriously typed it in, hunt-and-peck style, which took hours... then I hit "run".

Nothing.

I couldn't debug it. Not only did I not really understand software, I didn't have a checkbook — hell I didn't even know what "balance your checkbook" meant.

We didn't have the exorbitantly expensive Atari floppy disk drive, nor the cassette drive, so I couldn't save my work. Still, I left that BASIC cartridge in there for several days, foregoing my games, because I didn't want to lose my investment.

Eventually, I turned off the computer and the program disappeared forever.

I didn't program again for 20 years.

DrSiemer

11 hours ago

In my experience, a core skill of programmers is that they are people who are able to deal with setbacks and frustration in a good way. Those come with the territory.

I've always wondered if there is a correlation between developers and people that can enjoy tough but fair games like Super Meat Boy because of this.

technothrasher

15 hours ago

I made some text adventures in elementary school on the school's Apple II machines in the early 80's after playing Scott Adams' games (as a side note, it was amazing to be able to tell him directly many years later how much he influenced my learning to program). Anyway, a few years after I graduated from the school, I went back to visit, and some kids figured out it was me who's adventures they'd been playing and asked how to get past the one point in one that they couldn't figure out. I had to tell them, much to their disappointment, that I hadn't actually finished that game.

EvanAnderson

14 hours ago

Similar background here. The public library had Apple II machines and I became quite enamored with making proto-text adventures in Applesoft BASIC. Because you had to sign-up for time I wrote a lot of my programs longhand on nth generation photocopies of "program template" sheets that they handed out at the library (lined paper with columns for line numbers, statements, comments, etc).

The spaghetti code was astounding, and I remember squeezing line numbers between existing code-- adding a "31 GOTO 40" so I could squeeze a "room" into lines 32-39.

I never did grok the idea of building an "engine". Mostly I had PRINTs, INPUTs, and IF/GOTOs.

Telemakhos

14 hours ago

One of the most humbling moments in my life was learning from a friend what a object was, and how that differed from GOTO statements. I had already done something similar by inventing abstraction, when I figured out that I could pre-define certain musical notes and then use those defined notes more simply in my BASIC code. I had not, however, made the leap between re-using notes and re-using rooms in a text adventure. That realization that all re-used things can be abstracted was formative, and I am very thankful to my friend for having explained what he was doing with rooms. At some level, I regret that I learned BASIC before an object-oriented language; at another, I'm glad that I did, because my training in stupidity made very obvious to me my shortcoming in logic when I learned a better way.

EvanAnderson

11 hours ago

I'm jealous of your experience. That sounds very cool.

Looking back I wish I'd had a mentor. I think I would have accomplished so much more if I'd had somebody to offer some guidance and gentle direction.

tkrn

an hour ago

>The spaghetti code was astounding, and I remember squeezing line numbers between existing code-- adding a "31 GOTO 40" so I could squeeze a "room" into lines 32-39.

I spent too many nights trying to implement complex text adventures in Commodore 64 Basic and I'm sure that instead of permanently damaging me (at least in the sense that Dijkstra meant) it just made me appreciate more all the abstractions later languages introduced to me.

vunderba

13 hours ago

By the time I was a kid, most of the x86 computers I was exposed to were running DOS with the included QBasic IDE so I never had to worry about things like this.

However, we had old stacks of Compute magazine [1] lying around with BASIC source games printed out - and I remember initially being confused as to why all the line numbers were separated by intervals of 10...

[1] https://en.wikipedia.org/wiki/Compute!

arscan

14 hours ago

Love it! It really is a good first program to write as a kid (at least those from a certain generation).

And my memory might be from our Apple 2gs and AppleScript, actually (hence my caveat in the comment). But I’m sure the program was just PRINTs, INPUTs, IFs and GOTOs :)

kqr

11 hours ago

It was the same for me, except I grew up slightly later and did it with HTML documents and hyperlinks! (And in one case, I even think I got some help with an imagemap. Clicking the little hole in the foundation to the house led to an easter egg.)

mromanuk

15 hours ago

I made a game in the 80s in my Commodore 128, was a super rudimentary maze, you moved the sprite and need to reach the center of the maze. That was it. It was very basic, but I was proud and showed it to some folks. I'd love to see the code and game now.

NBJack

12 hours ago

I got into coding at home when I realized ctrl-break gave me a BASIC command prompt on my Apple //c. It was really cool, and I spent a lot of time learning to code. There was one small problem: doing so on startup meant I didn't get a DOS. In other words, every program I wrote like that meant I couldn't keep it.

I eventually learned to get a ProDOS disk setup, and save my work, but it was still fun.

tlavoie

9 hours ago

This is probably a good place to mention a cool book, "50 Years of Text Games", at https://if50.textories.com/. Based on a blog series as I recall, but essentially takes a game from each year or so, to look at in detail for what was interesting at that time.

bartread

9 hours ago

This is very cool but:

> requirements are light

> 512 MB RAM

raised an eyebrow.

Granted I haven’t owned or used a computer with that little RAM since 2003 or so, discounting phones, but I was sort of hoping it would say 640 KB for that true DOS-era spec.

helpfulclippy

15 hours ago

I’m surprised to see a QBasic game with 1GHz CPU and 512MB RAM required! Is that because the game needs it, or because that’s what it takes to even run a modern OS with dosbox or something?

vunderba

14 hours ago

It's because it's not written in QBasic. It's written in a variant of QBasic called QB64 [1] - a spiritual successor to Microsoft's QBasic intended to run on modern 64-bit machines.

I went over the BAS source the last time this was posted a few weeks back and it has a lot of keywords that are specific to QB64 so unfortunately you can't run this on a true DOS machine (or DosBox).

[1] https://qb64.com

bdcravens

15 hours ago

The latter I assume. The game does load the text file into memory, so the old 640kb machines would probably struggle, but otherwise, it looks like it should run well enough on a 386 (or even a 286, where I wrote my first QBasic scripts, though they were nowhere nearly as polished)

skopje

13 hours ago

I downloaded the rooms.txt file and the word "handcrafted" is doing some heavy lifting. It's like one sentence per room. Did I miss something? I don't want to play the game (I hate text adventures), but I want an idea of how much effort went into this.

Example:

--ROOM 22 START-- Village of Oathmoor 23,0,0,21 You find yourself in a narrow, dimly lit alley. An ELDERLY WOMAN sits perched on a broken stool, her piercing gaze fixed on you with an unsettling intensity. --ROOM 22 END-- --ROOM 23 START-- Village of Oathmoor 24,22,0,0 The road ahead begins to slope gently upward, winding its way past abandoned, barren buildings whose windows gape like empty eyes. --ROOM 23 END-- --ROOM 24 START-- Village of Oathmoor 0,23,25,0 The eerie stillness around you is oppressive, broken only by the creeping sensation of unseen eyes upon you. A chill snakes down your spine. --ROOM 24 END-- --ROOM 25 START-- Village of Oathmoor 26,0,0,24 A faint melody drifts toward you, its haunting notes carried on the breeze. The aroma of a meal cooking over a distant fire stirs both hunger and curiosity. --ROOM 25 END-- --ROOM 26 START-- Village of Oathmoor 27,25,0,0 You stumble upon a makeshift camp where people dance in defiance of their sorrows. The leader of this ragtag group locks eyes with you, their expression unreadable. --ROOM 26 END--

arscan

13 hours ago

Even if it’s only 1 sentence per room (it’s not), that’s still 4000 sentences. I’d guess this is at least a few hundred pages of written work (without downloading it and just based on what you’ve shared). That seems pretty substantial to me.

Not sure what the length has to do with handcraftedness though. This comment is handcrafted even if it is short.

kqr

11 hours ago

Going by the sample rooms above, (27, 21, 24, 28, 27) words multiplied by 4000 rooms divided by 350–450 words per page yields 200–300 pages indeed. But if it's mainly exposition and not interactable I can see how it would become dull reading quickly.

armitron

9 hours ago

It is boring, there’s minimal interactivity. Quite a long way from the better text adventures out there.

jjmarr

13 hours ago

Presumably it's similar to Soda Drinker Pro, which is 102 rooms, each with terrible MS paint drawings, in which you drink a soda and walk around for a minute or two.

https://youtu.be/C40kq29Emn0

fasbiner

11 hours ago

I think you're saying what the average person is thinking but is worried about being impolite. You are of course correct: it is the kind of fact about a game that non-gamers might still mistake for quality or depth.

The horseshoe theory of ai generation tells us that handcrafting and content generation extremism end up very close to each other: https://emshort.blog/2016/09/21/bowls-of-oatmeal-and-text-ge...

The fact that something is generated or hand-crafted is not interesting by itself no matter how much people try to pretend otherwise for social cohesion purposes. Mediocre thing + no AI and Mediocre thing + AI seem to be orthogonal to what people actually care about at the end of the day.

quuxplusone

30 minutes ago

That Emily Short blog post is a good read, but I didn't find that it helped me learn what is "the horseshoe theory of AI generation" nor in what sense handcrafting should end up close to procgen or anything else. Can you elaborate and/or point to something that does?

chii

10 hours ago

I think it's more that the 'no ai' moniker is an advertising gimmick - similar to how food/produce being advertised as organic and naturally grown, or a piece of craft being handmade (as opposed to machine made).

gigatree

15 hours ago

Looking forward to most posts having “No AI” tagged on. Definitely a huge plus.

BiraIgnacio

15 hours ago

This makes me wonder if there will be a time when "No AI" will be considered up-scale (of sorts) like hand-sewn clothes or artisan bread

eru

14 hours ago

And, of course, it will be inferior to what the machines make.

Just like machine created cutlery is essentially perfect, but human smithed cutlery will have lots of small imperfections.

conception

11 hours ago

It won’t always be inferior. Some items are just not profitable or too bespoke for mass production.

oneeyedpigeon

8 hours ago

Cutlery is, of course, a very different thing from artistic works. Has a machine ever created cutlery as beautiful as a human being can?

eru

7 hours ago

Well, conventionally a human being designs the cutlery, and a machine produces to that design.

And yes, they can be quite pretty.

What you see as the absolutely most beautify fork is in the eye of the beholder, of course.

fennecbutt

6 hours ago

Handmade cutlery is an artistic work. Machine made cutlery is an artistic work.

Remember, the benchmark for art is a banana taped to a wall.

defrost

6 hours ago

the benchmark for art is the first banana taped to a wall.

whtrbt

13 hours ago

In what way do those imperfections make something like cutlery inferior?

pjmlp

8 hours ago

And yet many people pay small fortunes to get those small imperfections instead of the machine ones, nowadays considered collection items.

eru

7 hours ago

Yes, humans pay for all kinds of interesting quirks.

pjmlp

8 hours ago

Yes, like proper cooking became slow food, we will get slow programming.

gigatree

11 hours ago

Yeah, I imagine “hand-coded” will be a common phrase on a lot of repos soon

_blaise_

11 hours ago

All of the code will be handcrafted, bespoke and artisanal. Written in heirloom editors. The comments could be described as ambrosial, whilst the code reads in a piquant and succulent manner.

oneeyedpigeon

8 hours ago

Maybe one day but, right now, I think the onus is on the minority of AI repos to declare it rather than the other way round.

gigatree

7 hours ago

Agree, but they have no incentive to. I always tell Claude to remove its attribution from commits because it’s not a great signal.

_def

37 minutes ago

Of course you are free to do that, but doesn't that make the situation worse for everyone?

baobun

10 hours ago

"brain-coded" is where it's at.

nomel

14 hours ago

You might like Neal Stephenson's "The Diamond Age".

droolboy

13 hours ago

When I was in my first year of junior high they had formal dances. But for the (cooler) nerdy kids with no dates they opened up the computer room. One of the older kids had a big floppy he brought from home. On it he had a simple QBasic RPG. If you ran into an enemy it would start an RPG battle and all the graphics were made from 2D arrays. It was awesome! It blew my mind and I spent the rest of the year learning and building my own. Great times! Thanks!

zem

15 hours ago

that's pretty awesome, a real labour of love. wonder how hard it would be to convert to a MUD so that people could wander around the world together.

ianbicking

11 hours ago

Anyone got it running on a Mac? It says to use DOSBox, but that doesn't work for me. (Sure would be nice if this could run on the web...)

vunderba

10 hours ago

See my reply here:

https://news.ycombinator.com/item?id=45612521

But basically no. It's possible an earlier version of the game might have been backwards compatible with QBasic, but the current source is QB64-specific and thus will never work in DosBox.

To play it you'll either need a compiled Mac binary or run it in QB64.

egypturnash

15 hours ago

If you are trying to beat the record for “most rooms in a text adventure”, I’m afraid you’ve got a long way to go - Level 9’s Snowball has more than 7k rooms.

selcuka

14 hours ago

> over 6800 of these rooms are essentially identical. Snowball is used in this context as the ultimate illustration of the absurdities of old-school adventures, with their mazes and sprawling geographies full of corridors and empty rooms. [1]

[1] https://www.filfre.net/2013/06/snowball/

Jemaclus

14 hours ago

IIRC, AvatarMUD (avatar.outland.org) has 20,000+ rooms in it. It's been a long time since I played, but it's absolutely massive!

astrobe_

4 hours ago

Yes, I remembered that some MUDs touted much more rooms. I've found Aarchon (15K) [1] and SlothMUD (23K) [2]. And that's just the number of rooms, the other numbers (8K mobs, 7K items, 12K NPCs) are massive as well.

But big MUDs usually have "builder" teams so the comparison is unfair. However, these numbers have hardly been matched by game studios - WoW or Runescape comes to mind. And then there's Dwarf Fortress which reaches the infinite in some categories thanks to procedural generation.

[1] https://www.aarchonmud.com/arc/features

[2] https://www.mudportal.com/listings/by-genre/hack-slash/item/...

sdenton4

11 hours ago

Yah, aardwolf (the one o played in ancient times) apparently has 35,000 rooms.

Collaborative building over decades adds up!

ATiredGoat

5 days ago

In an age where games are written by algorithms and dialogue is generated by AI, The Labyrinth of Time’s Edge stands apart. It’s the first open world "like" modern text adventure written entirely by a single human being, no AI, no procedural generation, no corporate fingerprints. Just words, code, and imagination. Built in pure QBasic, The Labyrinth of Time’s Edge now spans over 3,900 handcrafted rooms which will be released in a week's time. Each one written line by line by one programmer-adventurer determined to prove that storytelling still belongs to people. Explore haunted villages, forgotten catacombs, and worlds born from candlelight and memory. It’s free to play, made from love, obsession, and a refusal to let imagination be automated.

XiZhao

16 hours ago

This comment reads like it was ai generated

hatthew

16 hours ago

AI, or press release

andrewflnr

15 hours ago

I guess part of what's annoying about LLMs is that they write like press releases.

eru

14 hours ago

And like Americans.

andrewflnr

13 hours ago

I know what you mean, but also, I only wish most of my fellow Americans even aspired to the command of English that LLMs possess.

yodon

16 hours ago

>This comment reads like it was ai generated

It must be amazing to feel that way about the totality of human literature. Might want to adjust your priors somewhat.

cheschire

16 hours ago

Ehh, I think GP was saying it doesn’t fit with the tone of a message board reply, so it seems cut and paste from some outside place. Either a press release, a review snippet, or AI.

CuriouslyC

14 hours ago

Maybe "human generated" is your marketing hook, but I personally don't care what the source of something is, I care about the quality.

oneeyedpigeon

8 hours ago

Well, the current rule of thumb, speaking generally, is that human work is of a much higher quality than AI work, so the original comment seems fair.

CuriouslyC

5 hours ago

You realize that's the same arguments racists use for their racism, right?

Also, as fast as models are improving it's not a useful heuristic anyhow.

lukas099

2 hours ago

Well that escalated quickly.

CuriouslyC

2 hours ago

The degree isn't the point here, it's the sameness of logic. I wasn't disparaging him, but the pattern of thought.

ToucanLoucan

2 hours ago

> You realize that's the same arguments racists use for their racism, right?

Attempting to use the legacy of actual maligned minority groups to justify your sense of outrage that people aren't interested in products you weren't interested enough in producing to actually produce is disgusting.

> Also, as fast as models are improving it's not a useful heuristic anyhow.

They aren't improving, not particularly. They finally got the video generators to kiiind ooooof maintain a character's appearance between shots. Usually.

AI is spottable, often obvious, looks cheap, lacks intent, and boring. If you actually want to create, that's great. I suggest you do what every human before you did, and invest the time and effort to learn a craft with which to do so. If you aren't interested in doing that, that's completely fine, but I am conversely uninterested in viewing whatever you are uninterested in making.

Instead of automating creativity, I suggest we automate CEOs and managers. They don't do much besides generate pages upon pages of vacuous nothing and LLM's are great at that, and they're FAR more expensive for our enterprises than graphic designers.

CuriouslyC

an hour ago

The thing that is giving the right juice is that they can hold up meritocracy and victory of ideas under fair competition in response to identity politics. If we just framed things in terms of fighting poverty and systemic bias instead of reparations they wouldn't have a leg to stand on. We're giving them the ammunition they're blowing holes in us with.

Human vs AI is the same debate. No matter how good AI is, nothing is stopping you from creating. People have freedom of choice in terms of what they can consume, and if AI is a better creator than you, why should you make people's experiences worse by ramming your mediocrity down their throat with the battle cry of "human made"? You don't deserve an audience just because you're made of meat.

If you hate slop, hate it because it's bad, and hate human slop equally.

For reference, I'm a published artist and I'm currently querying for a manuscript. I use AI to scaffold projects quickly to ~80% then finish it myself, just like the the masters of the Italian renaissance did with apprentices.

oneeyedpigeon

8 hours ago

> games are written by algorithms and dialogue is generated by AI

I don't think we're there quite yet, and hopefully we never will be. A tiny minority of games, maybe.

citizenkeen

15 hours ago

> It’s the first open world "like" modern text adventure written entirely by a single human being

This rings false

armitron

8 hours ago

It is a gross exaggeration. There are far better modern text adventures out there written by one person (ie see the games of Andrew Plotkin).

There’s minimal if any interactivity in this “game” and I deleted it after 10 minutes of one screen with one line of text after another.

xnx

16 hours ago

4K resolution text?! 4000 rooms?! Ah, 4 kilobytes.

dfxm12

2 hours ago

Based on the hyphen, we know "4k-room" is a compound adjective. There's no basis to infer that 4k might refer to resolution or kilobytes.

hatthew

16 hours ago

From the article, 4000 separate ingame rooms to explore

hilti

11 hours ago

You instantly got me when I read „Written by one human“

deadbabe

12 hours ago

A text adventure of all things seems like it’d be great for AI though. You could have natural open ended conversations with NPCs to learn whatever they can tell you about the world, for example. This is one area where human generated content isn’t really better, you’d just end up with boring dialog trees to traverse.

vunderba

11 hours ago

AI Dungeon was an open-ended interactive fiction game powered by GPT-2 that went viral back in 2019.

https://en.wikipedia.org/wiki/AI_Dungeon

Where AI has the power to shine isn't necessarily in the creation of novel stories, but in the capacity to act as a significantly more powerful and flexible text parser for player input.

Get ye flask and all that...

kqr

11 hours ago

It doesn't work as well as you think it would. There are no AIs today that model the world well enough to drive a text adventure. They can be used to embellish a more primitive world model, but then they tend to invent details that don't exist. People have tried, it's just not been very good compared to a hand-crafted text adventure.

kqr

18 minutes ago

I forgot to say why it's a problem LLMs invent details: which details are implemented and which are left out is an important part of how the implementer of a text adventure communicates to the player what sort of interaction they should pay attention to and not. Text adventures are incredibly open games so the players need subtle hints on what they should focus exploration on.

This is an important part of designing a text adventure that LLMs just do not care about.

deadbabe

2 minutes ago

It is assumed that any system that uses AI for conversation in games would also implement a sufficiently advanced RAG system and careful prompts to ensure the AI is only talking about approved facts or talking points.

Customer service AI already is a thing and it works pretty well, games are just an extension of that built upon fictional world data and dynamic events.

ianbicking

11 hours ago

Text adventures and AI-driven interactions are surprisingly different I've found... https://ianbicking.org/blog/2025/07/intra-llm-text-adventure – still not sure what the right fusion might be.

tkrn

2 hours ago

I could see LLMs being useful as just an UI layer on top of traditional interactive fiction engines? Having a voice-operated IF assistant/narrator paired with tools for note taking and such could offer an accessible alternative interface to the large existing IF library (or maybe something like that exists already?).

Taken further the assistant's role could be expanded with greater autonomy. Games could include metadata and authors hints & directives for the narrator. Or a limited interface for manipulating the game state and shifting the traditional IF model closer to a two player collaborative game. Using the LLM to transform and extend pre-authored text might actually offer new narrative possibilities, assuming the model could do it subtly and well enough, the style, POV, mood an so on of prewritten content could be freely modified in some interesting ways. E.g introduce unreliable narrators, describe the player's actions from a point of a security camera or their dog, rewind and replay events from some other characters POV. Simulate psychological issues by subtly rewriting the player's (or the narrator's or NPCs) perception of the world and have them navigate a little twisty maze of emotional states, all different.

Restricting the model into operating strictly within the limits of human authored content could bypass some of the usual problems associated with purely AI generated games and the approach seems fitting for the genre and it's pre-existing rich tooling and talent.

lexicality

2 hours ago

"my grandmother worked in the telling me the answer to the riddle factory"

gerdesj

16 hours ago

Give your preferred AI agent internet search powers and look up how Elite managed to cram rather a lot of game into a nominal 64KB on a C64 or 32KB on a BBC model B.

That's a first person 3D space craft simulation with a very impressive Heads Up Display with vector graphics (unfilled on BBC and C64, filled on PC). It is also a commodity trading game to improve your spaceship etc and with a massive amount of variety in a binary smaller than an empty Word doc. Also: joystick and keyboard drivers and so on.

It's quite a tale.

antod

15 hours ago

It sure was. Although my favourite Elite port was the Amiga one.

Another one I was amazed by was Tomahawk on the Spectrum. A wireframe helicopter gunship flight sim with live ground campaign happening around you in 48k.