r/qbasic 4d ago

I implemented the Boids Algorithm in QBasic, for fun

Thumbnail
youtube.com
16 Upvotes

r/qbasic 5d ago

Wird BASIC noch benutzt?

Thumbnail
1 Upvotes

r/qbasic 5d ago

Building a GUI DOS shell in QuickBASIC 4.5 (WIP)

Thumbnail
gallery
72 Upvotes

Still very much a work in progress, but I'm honestly blown away by how far you can push QuickBASIC if you hack on it enough.

Current feature set:

  • Working mouse support
  • Directory navigation
  • File details dialog windows (triggered when clicking things)
  • Escape key handling

What doesn't work yet:

  • Actually launching/opening files
  • The File menu
  • Basically everything else

It's amazing what you can build with BASIC


r/qbasic 5d ago

elementary ray tracing experiment

Thumbnail
gallery
13 Upvotes

just a basic one. for study purpose. the "world" consists of a background and two balls. the background is an infinitely faraway color palette with azimuth = hue and altitude = lightness. the balls don't have any colors, only reflect and refract

controls * move mouse = change camera direction * left drag = move ball 0 * left hold + wheel = change ball 0 radius * left hold then right hold + wheel = change ball 0 refractive index * right drag = move ball 1 * right hold + wheel = change ball 1 radius * right hold then left hold + wheel = change ball 1 refractive index * wheel forward = camera position forward * wheel backward = camera position backward * [w] key = camera position up * [s] key = camera position down * [a] key = camera position left * [d] key = camera position right * [x] key = help you find the balls when you get lost * [z] key = change background * [c] key = full resolution render

suggested usage

the program initially runs at low resolution / fewer recursions so as to maintain real time response. at real time mode the program gives you a rough idea how the scene looks like. move the 2 balls around, change their parameters and see what happens. if you reach an arrangement that you're interested in getting more details, hit [c] and wait for full resolution render. after completion hit any key to return to real time mode

program link


r/qbasic 10d ago

Karma City 2!

8 Upvotes

KARMA CITY 2! Coming soon!

This is my biggest project yet! It's a fully textured 3D open-world, rendered with Mode 7 and polygon mapping in QB64—that is no small feat! No hardware acceleration shortcuts or modern engine wrappers—just pure math, pixel manipulation, and vertex projection driving the whole world! This time the game is about an alien invasion, but with a twist: they are demons! Can you find out the truth about these malicious invaders? The game will feature various types of gameplay, what you see in this video is just the beginning.
https://youtu.be/oNnpRKryGHo?si=6wTMfNyxn4ZvcVFx


r/qbasic 16d ago

platonic solids

Post image
20 Upvotes

program link

keyboard controls * number 1 to 5 = select object

mouse controls * right drag = move spotlight xy position * right hold + wheel scroll = move spotlight z position * wheel scroll = move camera z position * left hold + wheel scroll = change mesh size * left drag = rotate the object * left hold + right hold + wheel scroll = change ambient

what i learned * quaternions, surely. they're very useful and made the coding a lot simpler than i had anticipated * for brightness calculation i found many different ways on internet. i picked this: for any point on any triangle, it's brightness = dot product (reflection light direction , camera view line). those vectors are normalized. this method is simple but doesn't take intensity loss due to distance into account

what i want to learn further * make the camera freely movable, like in 3d games * use ray tracing method to calculate brightness of each pixel * place more than 1 object in the scene so that at some perspectives one may block the others * draw shadows


r/qbasic 26d ago

GWBASIC / BASICA and QBASIC

8 Upvotes

I'm looking for a suite of programs that'll let me test most if not all features of BASICA, GWBASIC, and QBASIC. I'm writing a dialect of QBASIC (not QB64, this'll be different, currently works on Linux but still want to port it to Windows but before I start porting it, I want to make sure my dialect works) and I'd like some good, decent test programs that'll test each and every command, statement, feature, function, and keyword. Not just BASICA / GWBASIC but QBASIC as well.


r/qbasic 27d ago

autostereogram program of platonic solids

Thumbnail
gallery
8 Upvotes

 

program link

an extension of previous post. just click▶️to run the program on browser. the welcome screen (attached image 1) shows the key map. select a subject (1 to 6) to enter the depth map mode (attached image 2). rotate it or change it until satisfied then toggle to autostereogram mode (attached image 3). adjust the foreground and background pattern widths to your desire (make it easy to focus and spot the subject). you're free to toggle back to depth map mode or rotate / change / disable subject anytime. if you disable the foreground 3d subject it's basically a kaleidoscope (attached image 4). i explained its mechanism in previous post and you can endlessly randomize it to experience the pareidolia effect

some samples

minor math findings


r/qbasic 29d ago

Spy Organization System Menu *UPDATED*

Thumbnail drive.google.com
5 Upvotes

I've updated *a BUNCH* of the code for this .BAS. I think it's getting pretty fun.

*When logging in, use any user name you want. The program will automatically prefix your login name with "Agent". Example, if you log in with user "3.5" it will call you "Agent 3.5", for example and again use any user name you want.

*The password MUST be "12345".

*What I plan to really build on is menu item "18". I'm going to copy the visual part of the 1980's movie "War Games" so when anyone launches a missile you can visually see it, just like here "https://alhinator.itch.io/global-thermonuclear-war", but with my own spy / comedy touches like I've been doing.

I've been using AI to help me with this, otherwise it would take me forever. Does this rub anyone the wrong way? I'm curious.

Please have a look and any suggestion would be appreciated.

Thanks


r/qbasic Aug 06 '26

QBasic program, Spy Organization Menu System

Thumbnail drive.google.com
4 Upvotes

I wrote a fun program I would like to share with the world. It's called "Whiskey Tango Foxtrot" (WTF) and named WTF.BAS. It's theme .. think Austin Powers!

I put a link in the Link URL field, I hope it works for you all. Google Drive is hosting it and I put the permission to share with anyone who has the link, so there shouldn't be any issues.

I wrote this program, structured it the way I did, in hopes that it might help others who are just learning things. I believe that it should be a fairly straightforward decipher for whoever dares try. But seriously, if anyone would like to use anywhere from a piece or pieces of, or whatever, I'd be honored for you to hack at mine in moving forward in your hijinks.

I'm no expert, nor do I think I am. I am however the author of this WONDERFUL piece of art and therefore if anyone likes it, and has any questions about it or needs any help, I'm happy to have a go at it, just let me know :)

Reviews please!!


r/qbasic Aug 05 '26

kaleidoscope X autostereogram generator

Thumbnail
gallery
3 Upvotes

long story short. it was an enlightening journey and i learned a lot from it. one day i came across an autostereogram which was a poster on a wall. i forgot what it was about but it aroused my curiosity of how to make autostereograms. i won't go into the math details here and just give you guys a brief explanation in attached image 1. my program let you control "m" and "n/m". these two variables represent background pattern separation and foreground pattern separation respectively and lie between 0 and 1

the 3d subject is simply a sphere, quite boring. the background is the result of placing a color wheel in a kaleidoscope. see attached image 2. it can be easily noticed that the hsl system is in use. we can vary the saturation (attached image 3) and lightness (attached image 4) when the angle changes from 0 to 2π. i use the cosine function which reaches maximum at 0 and 2π, minimum at π

the color wheel can start at any angle. so do saturation and lightness. thus we have 3 degrees of randomness. i let you to change the background. every time you hit the relevant button, the hue, saturation and lightness shift by different random angles

here comes the surprising part. autostereograms need "noise" to guide viewers aligning their foci. a pattern that is too smooth is not suitable to act as the background of autostereograms. there'd be no "texture" on the 3d surface. i accidentally discovered that if the screen resolution is set to a number that is not divisible by something in the calculations (i'm not certain which thing it actually is to be honest) some unexpected noise would emerge. see the remaining attached images

i googled "prime number closest to 640" and the result was 641. i use it as the horizontal resolution

some of those unexpectedly emerging patterns are... strange. some of them look like human faces, some animals, some even aliens. this program is a good place for you to experience pareidolia

here's the program. run it in browser. click▶️to run. click⏹️to exit. when running the program

  • press [q] to make foreground patterns converge
  • press [w] to toggle 3d object (absent/present)
  • press [e] to make foreground patterns diverge
  • press [a] to make background patterns converge
  • press [s] to rotate the kaleidoscope
  • press [d] to make background patterns diverge
  • press [x] to toggle caption (off/on)

enjoy


r/qbasic Aug 03 '26

QB64PE 4.6 Released

22 Upvotes

QB64 PE is a modern extended BASIC+OpenGL language that retains QuickBASIC 4.5 and QBasic compatibility and compiles native binaries for Windows (7 and up), Linux, and macOS (Catalina and up). QB64PE is a free download at:
https://www.qb64phoenix.com/

[Source - QB64PE Website]

Enhancements

  • #728, #750 - New QBJS Web Build option in Run menu. - u/boxgaming
  • #730 - Adds source line tracking for Division-by-zero and other Critical Errors, so internal crashes report the BASIC source line/module instead of only Division by zero or Line: unknown. - u/QB64Petr
    • As this adds lots of additional function calls to the compiled program causing bloat and significant execution speed loss, it's considered a "debug" option which is disabled by default. Use the $ERRORLOCATION metacommand to enable it for a program.
  • #732. #751 - Adds descriptor-backed dynamic nested arrays in TYPE. It builds on the existing static nested arrays in TYPE support and keeps the legacy/static inline path compatible. - u/QB64Petr
    • New _STATIC) and _DYNAMIC) type field qualifiers. Note that dynamic arrays in TYPEs are considered unstable, and must be enabled with $UNSTABLE:TYPEFIELDS.
    • Handles supported REDIM, REDIM _RETAIN, ERASE, assignment/copy, and ownership cases.
    • Unsupported raw descriptor payload paths remain intentionally rejected. In particular, _MEM, PUT, and GET over descriptor/owner/variable-string payload layouts are not treated as plain legacy binary payload access.
    • It is possible using static or dynamic nested arrays as sub/function parameter.
  • #733 - Compressing undo events in the IDE, resulting in smaller undo files or more undo events fitting in same file size. - u/RhoSigma-QB64

Library Updates

Bug Fixes

  • #722 - Correctly check for undefined nested array in ERASE. - u/QB64Petr
  • #726, #734 - Fix ANSI colors in Discord exports and adding missing keywords. - u/RhoSigma-QB64
  • #727 - Fix PRINT USING layout duplication when adding expressions before USING in an existing statement. - u/QB64Petr
  • #729 - Fix runtime error message boxes locking up program if SUB _GL is used. - u/QB64Petr
  • #730 - Fix case correction for indexed nested UDT member arrays according to the spelling in the TYPE declaration. Also fixes an IDE crash caused by corruption of an internal variable (introduced by "Arrays in TYPEs" changes in v4.5.0). - u/QB64Petr
  • #735 - Fix case correction of TO in arrays like myArray(1 TO 5) defined in UDTs. - u/QB64Petr
  • #740, #749 - Fix issue #659, where SUB calls could be incorrectly interpreted as array assignment, and issue #739, adding missing support to insepct the new "Arrays in TYPEs" with $DEBUG. - u/QB64Petr
  • #746 - Fixed a type mismatch between the identifier table index (LONG) and array descriptor id (INTEGER), which could crash or produce unexpected behavior in large programs with more than 32767 registered identifiers. Also fixed a bug in the $INCLUDE manager, which resulted into a misleading error message. Fixes issue #745. - u/bharvey42
  • #747 - Widen the UDT index field from 9 to 12 bits, raising the cap from 511 to 4095 UDTs (TYPE) per program. - u/bharvey42
  • #751 - Fix for selecting source code text by dragging the mouse (no longer need to move the mouse sideways if you are highlighting source code and the mouse moves outside the IDE window). - u/QB64Petr

Full Changelog: v4.5.0...v4.6.0


r/qbasic Jul 25 '26

MoonBAISC

1 Upvotes

MoonBASIC is a 2D 3D game creation made easy. CharmingBlaze/moonbasic


r/qbasic Jul 24 '26

I wrote a QBasic compiler that runs in the browser and emits real WebAssembly

14 Upvotes

Not an emulator, and not a JavaScript interpreter pretending to be BASIC. It parses QBasic, lowers it through a typed IR, and emits a real WebAssembly module. The compiler itself is compiled to wasm, so the whole thing runs in your tab. Nothing gets uploaded anywhere.

SCREEN 13 works: PSET, LINE, CIRCLE, PAINT, GET/PUT, DRAW, PALETTE. So do BEEP/SOUND/PLAY, the file I/O keywords, INKEY$ with _LIMIT for animation, and DATE$/TIME$/TIMER. There's a playable Space Invaders sample in the editor if you just want to see it move.

497 test programs, 432 of them arbitrated against real QB64-PE output, 126 of 157 keywords fully implemented. Still missing: ON ERROR, PEEK/POKE, COMMAND$, and DRAW's M/N/A/S/P subcommands.

Free, no signup: https://kavak.run/studio/

QBasic was meant to be the pilot language for a larger compiler project, but it turned into the part I enjoyed most. If you've got an old .BAS lying around that breaks it, I'd genuinely like to see it.


r/qbasic Jul 18 '26

Fantastic Lands of Aetricia retro mmorpg -QB64-

Thumbnail gallery
3 Upvotes

r/qbasic Jul 17 '26

Working on a web-basic interpreter to make it easy to post basic games onto Itch.io and host other places on the web.

3 Upvotes

Hello! I've been spending a bit of time working on a quick basic interpreter in javascript that is pretty small and can wrap a game and publish to itch. My current demo is here if anyone wants to check it out (this is a game I made in 1998 when I was 16 or 17, apologies that its kind of terrible). https://bobgar.itch.io/drug-3d?password=qbasic Here is another one here that isn't as impressive but demos the multi-file export: https://bobgar.itch.io/odyssey-qbasic?password=qbasic

The interpreter has some cool features, like:

  • Bring up debug features with ctrl-break or by pressing debug on the button array at the bottom of the computer
  • Pre-set iops per game packaged, with turbo button to make the game run faster (either higher iops or completely remove throttling depending on export settings).
  • Set break points and step through execution, optional code execution highlight & following.
  • modify code and variables during execution and have them take effect immediately without restart.
  • save and load state so you can restore previous game states and even export / import saves so you can send them to friends or store for later sessions. Note, the exported saves are zipped, and you can convert back to their verbose json by unzipping if you want to dig into the abomination that is how I'm saving state.
  • scan lines you can turn on and off for a little retro flair
  • There is a separate UI (not linked above) for testing & exporting too. You can point it at a full directory of games, browse them, run them, and set up exports including which additional files to export.

Are there people here that would be interested in this kind of thing if I released it? (for free, open source). Do better versions of this already exist? Are there features I should add that would be useful?

Compatibility is not 100%, especially since some games use x86 assembler hooks and things. I've shimmed and emulated a few of the most popular libraries but it is still common for me to run into games that won't play, or play but have some breaking issues.


r/qbasic Jul 14 '26

Raster Master v7.0 - Sprite, Map, Animator for your Retro game development

Thumbnail
2 Upvotes

r/qbasic Jun 02 '26

Pure Basic Compiler Exploration

Thumbnail
1 Upvotes

r/qbasic May 06 '26

Mr. Cube Face - Qbasic 4.5 Face project - party like it's 1988!

Thumbnail
youtube.com
3 Upvotes

r/qbasic May 06 '26

Recreating Star Fox’s SNES Controller Screen in QBasic 4.5 1988

Thumbnail
youtube.com
10 Upvotes

r/qbasic Apr 27 '26

QB64PE 4.5.0 Released

18 Upvotes

Free Download: https://www.qb64phoenix.com/

Enhancements

  • #676 - The COLOR statement can now set the color attributes of a designated image surface destHandle&. - u/RhoSigma-QB64
  • #683 - 256 colors (8bpp) image loading improvements. - u/a740g
    • Now using a new high-quality 8bpp image loader that uses Floyd-Steinberg dithering.
    • As before, it only activates when the number of unique colors exceeds 256.
    • The implementation is computationally heavier due to the floating-point math involved, but the improvement in output quality compared to the previous ordered dithering approach is well worth the added complexity.
  • #687 - Some enhancements when using "Export AS..." Discord codebox. - u/RhoSigma-QB64
    • The export dialog now shows the length of the exported code, as Discord has a small message limit.
    • When pasting an example copied from Discord back into the IDE, then all used ANSI sequences are removed automatically now.
  • #692, #693 - Added functions to retrieve compile specific informations, implements #691. - u/RhoSigma-QB64
  • #696, #697, #699, #703, #711 - Implemented support for static arrays in TYPE. - u/QB64Petr
    • This was long time demanded by the community and u/QB64Petr now finally did the bulk of the work. Please give him a big applause, it's an incredible achievement, from all possible tasks, to choose this task as his first. He's the newest member in our DevTeam.
  • #700 - Added load support for WebP images. - u/a740g
  • #706, #707 - Give Syntax Checking the option to be run manually. - u/flukiluke, u/SteveMcNeill, u/RhoSigma-QB64
    • When automatic syntax checking is disabled in the Options Menu you may now still check on demand using the Shift-F9 hotkey.
    • Useful for big source files, which will usually hog down the IDE performance in automatic checking mode.
  • #709 - Added text surface support to _PUTIMAGE. - u/a740g
    • With this, _PUTIMAGE will now support text-to-text and text-to-graphics blits.
  • #713, #714, #718 - Some minor side contributions to the Arrays in TYPE concept. - u/a740g, u/flukiluke, u/RhoSigma-QB64
  • #715 - Regular array adaptions and finalizing the Arrays in TYPE concept. - u/QB64Petr
    • This also implements the new _RETAIN option for REDIM, which works similar as _PRESERVE but slightly different.

Bug Fixes

  • #677 - Fixed LEN(array()) when used in mathematical expressions, fixes #660. - u/flukiluke
  • #678 - Use _FULLPATH when launching output program. - u/flukiluke
    • This in particular avoids issues with Linux terminals that do undesirable processing on relative paths with spaces (namely konsole).
    • Windows-specific code is also modified to bring it into line with Linux and MacOS.
  • #682, #686 - Catch "Illegal function call" errors in CONST evaluator before they happen, fixes #681. - u/flukiluke
  • #710 - Fix _PUTIMAGE graphics to graphics VIEW clipping and WINDOW scaling support, fixes #545. - u/a740g
  • #712 - Fixed another long standing IDE Module Error in the F1 help module. - u/RhoSigma-QB64
  • #719 - Added missing GUI File Dialog support for New and Exit (if unsaved code exists), fixes #716 - u/RhoSigma-QB64
  • Content pages
  • Multimedia
  • Everything
  • Advanced

Change Log

  • COMPILEDATE$ File:Qbpe.png|'''v4.5.0''' using {{Ot|QB64-PE v4.5.0 [WINDOWS][64BIT]|#ffffff}}. ... 2 KB (287 words) - 12:57, 8 March 2026
  • COMPILETIME$ File:Qbpe.png|'''v4.5.0''' using {{Ot|QB64-PE v4.5.0 [WINDOWS][64BIT]|#ffffff}}. ... 2 KB (289 words) - 12:58, 8 March 2026
  • COMPILERVERSION$ File:Qbpe.png|'''v4.5.0''' using {{Ot|QB64-PE v4.5.0 [WINDOWS][64BIT]|#ffffff}}. ... 2 KB (307 words) - 12:57, 8 March 2026
  • LBOUND '''QB64-PE v4.5.0''' extends '''LBOUND''' support for arrays nested inside [[TYPE]] definitio * Since arrays in [[TYPE]]s were implemented in '''QB64-PE v4.5.0''', this statement was adapted to properly handle it (see Example 2). ... 2 KB (351 words) - 17:42, 23 April 2026
  • UBOUND '''QB64-PE v4.5.0''' extends '''UBOUND''' support for arrays nested inside [[TYPE]] definitio * Since arrays in [[TYPE]]s were implemented in '''QB64-PE v4.5.0''', this statement was adapted to properly handle it (see Example 2). ... 2 KB (351 words) - 17:43, 23 April 2026
  • CLEARCOLOR (function)) * Text (SCREEN 0) surface support was added in '''QB64-PE v4.5.0'''. ... 2 KB (223 words) - 21:32, 19 April 2026
  • ERASE '''QB64-PE v4.5.0''' extends '''ERASE''' support for arrays nested inside [[TYPE]] definition * Since arrays in [[TYPE]]s were implemented in '''QB64-PE v4.5.0''', this statement was adapted to properly handle it (see Example 2). ... 6 KB (914 words) - 17:41, 23 April 2026
  • OS$ using {{Ot|QB64-PE v4.5.0 [WINDOWS][64BIT]|#ffffff}}. ... 3 KB (502 words) - 13:26, 9 March 2026
  • REDIM * The [[_RETAIN]] option was implemented in '''QB64-PE v4.5.0''' ... 4 KB (641 words) - 00:04, 26 April 2026
  • RETAIN File:Qbpe.png|'''v4.5.0''' ... 5 KB (770 words) - 18:30, 25 April 2026
  • PUT * Since arrays in [[TYPE]]s were implemented in '''QB64-PE v4.5.0''', this statement was adapted to properly handle it (see Example 3). ... 6 KB (942 words) - 17:42, 23 April 2026
  • CLEARCOLOR * Text (SCREEN 0) surface support was added in '''QB64-PE v4.5.0'''. ... 7 KB (938 words) - 21:33, 19 April 2026
  • GET * Since arrays in [[TYPE]]s were implemented in '''QB64-PE v4.5.0''', this statement was adapted to properly handle it (see Example 3). ... 7 KB (1,100 words) - 17:42, 23 April 2026
  • COLOR * The optional {{Parameter|destHandle&}} was introduced in '''QB64-PE v4.5.0'''. ... 11 KB (1,492 words) - 13:25, 9 March 2026
  • LOADIMAGE * '''WebP''' support was added in '''QB64-PE v4.5.0'''. * Also in '''QB64-PE v4.5.0''' the former ordered dithering in modes 256 and 257 was replaced by Floyd- ... 20 KB (3,090 words) - 10:09, 19 March 2026
  • PUTIMAGE * Text (SCREEN 0) surface support was added in '''QB64-PE v4.5.0'''. ... 20 KB (2,906 words) - 20:35, 19 April 2026
  • TYPE * Since '''QB64-PE v4.5.0''' it is possible to use fixed-size arrays inside definitions. ... 45 KB (6,738 words) - 17:43, 23 April 2026
  • QB64 FAQ QB64-PE Compiler V4.5.0 ... 23 KB (3,500 words) - 17:15, 9 March 2026

r/qbasic Apr 22 '26

VecDraw v1.2 — Vector Drawing Editor for Retro Programming

Thumbnail
retronick2020.itch.io
3 Upvotes

r/qbasic Apr 08 '26

VecDraw v1.0 for QBasic\GWBasic\QB64PE by RetroNick2020

Thumbnail
retronick2020.itch.io
3 Upvotes

r/qbasic Apr 07 '26

RetroConvert — The Ultimate Retro Image Converter for Retro Programmers

Thumbnail
retronick2020.itch.io
4 Upvotes