Live data from Hacker News

The best QBasic game ever?

pcworld.com

91–100 of 102 posts

Re: The best QBasic game ever?

#91
post #10

This is very, very cool. Speaking as someone who also wrote QBASIC games as a child, this evokes sharp pangs of nostalgia. I happen to have an old QBASIC book (pub 1993) next to me, and was skimming through it shortly before coming across this article. Random file I/O : OPEN filename$ FOR RANDOM AS [#]filenumber LEN=recordlength The book then goes on to provide helpful ways to guesstimate at the record length of a fi…

This was my very first programming book:

http://www.amazon.com/Absolute-Beginners-Guide-Qbasic-Perry/...

Amazon doesn't have the cover art, but it was very similar to this one:

http://ecx.images-amazon.com/images/I/51VswbyvRHL._SL500_SS5...

Re: The best QBasic game ever?

#92
post #10

This is very, very cool. Speaking as someone who also wrote QBASIC games as a child, this evokes sharp pangs of nostalgia. I happen to have an old QBASIC book (pub 1993) next to me, and was skimming through it shortly before coming across this article. Random file I/O : OPEN filename$ FOR RANDOM AS [#]filenumber LEN=recordlength The book then goes on to provide helpful ways to guesstimate at the record length of a fi…

Just realised, same indentation and no-end-character rules as python :) Although I've been writing qbasic back in the days and now writing python for fun, I've never realized this before...

The IDE forced those formatting conventions on you, but QBasic doesn't actually have any indentation rules at all, and IIRC that stuff was also configurable.

Re: The best QBasic game ever?

#93
post #17
post #8

Wow, as someone who played with making games using QBasic on a 486 as a pre-teen I am seriously impressed. I have to chuckle at requiring such a fast processor to run well though. Assuming the author doesn't rely on too many DOS game programming tricks (I remember having to peek and poke various memory locations to trigger esoteric video resolutions, etc.) it probably wouldn't be too hard to convert this to run on vi…

He's already using SDL. Plus, QBASIC64 isn't a DOS environment. In fact, when you look at the specs for QBASIC64 then it's a little less impressive than first made out. It also makes me wander why he didn't just learn VB anyway (as the libraries in QBASIC64 would have required additional learning anyway). Even VB classic would have made more sense. Anyhow, this at least reminds the language elitists that a language i…

QB64 appears to compile to various platforms, while VB does not.

Also, VB is pretty GUI and event-centric. QBasic is a pretty good local maximum of being quite expressive while still being a strictly procedural language.

Re: The best QBasic game ever?

#94
post #68
post #63

Earlier quoted context omitted.

I think you're being a little harsh on him--regardless of what language this game was written in it looks great. This is obviously a labor of love and not something made to get press attention. If someone wanted to get a story written about them in PC World I would venture there are much easier ways to do it than spend a year slaving away at writing a modern game in basic.

I think he's being quite fair as he's acknowledged the hard work behind this game (any modern game written in any language is impressive work), he's just saying that this project is getting a lot of media attention because it's advertised as using certain tools which it actually isn't. If I'm honest, I feel the same way as the aforementioned poster. Writing any modern game in QBasic is akin to A-Team style engineerin…

The confusion here stems from the fact that the term QBasic is ambiguous. On the one hand, it refers to the IDE and interpreter included with later releases of MS-DOS. On the other, it refers to the language accepted by that interpreter. Since QB64 is specifically designed to accept that same language (FreeBasic has a mode for this as well), I don't think it's unreasonable to consider QB64 a QBasic compiler. Would you find it similarly unjust if someone claimed to write a game in Python but they really wrote it in PyPy?

> QB64, however, is basically just like any other modern scripting language.

QB64 is not a scripting language. It compiles the QBasic language (with a few extensions) to C++ and passes it on to gcc. It seems like you're making a lot of assumptions about QB64 when you could instead be looking for facts.

Re: The best QBasic game ever?

#95
post #67
post #19

When I was a child, nibbles was my favorite: http://www.youtube.com/watch?v=fZF6tnrfAX0

Somewhere in the depths I've got a version of this I customised ... up to 4 players, powerups, cheats and about 20 levels.. [and probably loads of bugs]

That's pretty awesome. I wrote a SCREEN 13 graphical version from scratch. IIRC, the snake sprites were gradient blocks that were procedurally generated, and then used GET and PUT to pick and place them.

Wish I still had a copy of that stuff that I could put on Github!

Re: The best QBasic game ever?

#96
post #42

I think Gorrila's was the ultimate Qbasic game. It was "Scorched Earth" before Scorched Earth was a game. I learned programming by turning Gorrila's in to a game with buildings that moved every turn, and changing the graphics.

According to Wikipedia, that style of game goes back to at least 1976: http://en.wikipedia.org/wiki/Artillery_game

Re: The best QBasic game ever?

#97
post #69

Earlier quoted context omitted.

Sorry to nitpick, but "QBasic" is an IDE (Just like QuickBASIC, which incidentally is the predecessor of QBasic). The language is just called "BASIC". Also you're not compiling anything. It's all interpreted at run time (which is why performance is dog slow).

No, QBasic is also a language variant. QBasic has functions, user-defined types, no line numbers, and a pretty big standard library that plain BASIC did not have.

Yeah I'm familiar with what QBasic is and many of the other BASIC dialects that preceded it (I'm old :P). I'd agree that it's a language variant / dialect. My issues is when people talk about QBasic as if it was it's own single entity. But then I guess where do you draw the line? eg by my same logic, C++ just a variant of C, yet it's clearly sane to describe them separately. So perhaps I was being overly picky.

As a side note, QBasic does support line numbers - albeit for legacy reasons and not recommended syntax. And some dialects of BASIC did support functions - though the syntax was awkward so I usually just used GOSUB / RETURN when I needed procedures with no return values.

Re: The best QBasic game ever?

#98
post #68

Earlier quoted context omitted.

I think he's being quite fair as he's acknowledged the hard work behind this game (any modern game written in any language is impressive work), he's just saying that this project is getting a lot of media attention because it's advertised as using certain tools which it actually isn't. If I'm honest, I feel the same way as the aforementioned poster. Writing any modern game in QBasic is akin to A-Team style engineerin…

The confusion here stems from the fact that the term QBasic is ambiguous. On the one hand, it refers to the IDE and interpreter included with later releases of MS-DOS. On the other, it refers to the language accepted by that interpreter. Since QB64 is specifically designed to accept that same language (FreeBasic has a mode for this as well), I don't think it's unreasonable to consider QB64 a QBasic compiler. Would yo…

> The confusion here stems from the fact that the term QBasic is ambiguous. On the one hand, it refers to the IDE and interpreter included with later releases of MS-DOS. On the other, it refers to the language accepted by that interpreter. Since QB64 is specifically designed to accept that same language (FreeBasic has a mode for this as well), I don't think it's unreasonable to consider QB64 a QBasic compiler. Would you find it similarly unjust if someone claimed to write a game in Python but they really wrote it in PyPy?

But the BASIC dialect that QB64 compiles is more than just QBasic in much the same way that QBasic was an advance on QuickBasic/BASIC.

I'm not familiar with PyPy (from a developers perspective) so I can't comment on that comparison.

> QB64 is not a scripting language.

I didn't say it was. What I said was that it's LIKE a scripting language. And the context of that (which you've kindly cropped out thus distorting the point I was making) was in terms of the way how the language is extended via additional libraries (eg Perl libraries can be Perl modules or bootstrapped from C++ - and QB64 libraries have that same 'feel' to them) and the nature of the language (it compiles to byte code rather than machine code†, the relatively limited scope of the language without the C++ libraries and it's performance, etc).

† It's also mentioning here that most scripting languages compile these days too, it's just that few offer a standalone ELF / PE with the runtime included (there's a limited need for the latter unless it's a niche language).

Just to be clear, saying something is LIKE something else is a comparison, it's not the same as saying something IS something else. And the very nature of comparisons is that there will be elements of the comparison which are not equivalent (which is why comparisons rarely work in arguments as the opponents will focus in the differences rather than the similarities)

> It compiles the QBasic language (with a few extensions) to C++ and passes it on to gcc. It seems like you're making a lot of assumptions about QB64 when you could instead be looking for facts.

I've played around in QB64, compiled and decompiled binaries in it and browsed it's source. Where else would you suggest I "be looking for facts"?

Re: The best QBasic game ever?

#99
post #98

Earlier quoted context omitted.

The confusion here stems from the fact that the term QBasic is ambiguous. On the one hand, it refers to the IDE and interpreter included with later releases of MS-DOS. On the other, it refers to the language accepted by that interpreter. Since QB64 is specifically designed to accept that same language (FreeBasic has a mode for this as well), I don't think it's unreasonable to consider QB64 a QBasic compiler. Would yo…

> The confusion here stems from the fact that the term QBasic is ambiguous. On the one hand, it refers to the IDE and interpreter included with later releases of MS-DOS. On the other, it refers to the language accepted by that interpreter. Since QB64 is specifically designed to accept that same language (FreeBasic has a mode for this as well), I don't think it's unreasonable to consider QB64 a QBasic compiler. Would…

> But the BASIC dialect that QB64 compiles is more than just QBasic in much the same way that QBasic was an advance on QuickBasic/BASIC.

The QBasic language is almost exactly the same as QuickBASIC 4.5. Every version of any Basic that Microsoft release had advances over previous ones. Furthermore, modern additions to the standard library hardly constitute a language change.

> I didn't say it was. What I said was that it's LIKE a scripting language.

You're right; I read into that too much. Though I still contend QB64 is no more like a scripting language than QB45 was. I didn't mean to imply that scripting languages cannot be compiled or that all interpreted languages are scripting languages. In my mind, something is a scripting language if it's primarily used for (read: makes easy) at least one of two purposes: automation or extension. Of course, nobody agrees on what constitutes a scripting language just like nobody agrees on what constitutes anything in programming.

> I've played around in QB64, compiled and decompiled binaries in it and browsed it's source. Where else would you suggest I "be looking for facts"?

Those are good places to look. Documentation is also a good place. I don't mean to be spewing condescending crap, but a lot of the comments in this thread seriously irked me. It's a problem with programming as a field that many (maybe even most) terms are ambiguous or nebulously defined.

Re: The best QBasic game ever?

#100
post #44

I learned how to program by reading through the code for qbasic gorillas (the game in the video in the article) back when I was a wee lad. Therefore, gorillas is the best game ever to me. That said, qbasic was maybe not a best first language - I became a much better programmer when I learned C++ years later. Still, I really really appreciate that as a young child I had access to a fun game with the source code reveal…

I am also very thankful for the source for Gorillas and many simpler BASIC games before it. I started out by adding color to many existing text BASIC games and then moved on to writing my own.

Years later a friend of mine and I added modem support to Gorillas so we could play each other from our houses. Of course Scorched Earth would have been better, but we didn't have the source to that, nor the programming ability to add it at the time.

Post reply on HN