DOWNLOAD DEMO #4 NOW!by (no login)Link to .zip file (~5MB): http://www.mediafire.com/?ctmxcjjwu3v Known issues: *comventional memory string descriptors cannot be freed and cause an out of memory error if too many strings referenced by 16-bit memory referencing are allocated (can be fixed easily by the next demo). *INPUT doesn't accept arrays as arguments yet *RND without brackets freezes the compiler *NEXT x,y won't work yet. Use NEXT x: NEXT y *IF a=1 GOTO 4 doesn't work yet. Use IF a=1 THEN GOTO 4 Thank you again, for supporting QB64. Galleon (the below is copied from README.TXT) QB64 COMPILER V0.4 DOCUMENTATION ================================ Thanks for trying QB64! What's NEW in this demo? -arrays -16 bit memory referencing (DEF SEG, PEEK, POKE, VARSEG, VARPTR, VARPTR$, SADD) -CLS -PRINT (improved) -error handling (ON ERROR..., RESUME, ERROR, ERL, ERR, etc.) -GOSUB/RETURN -numbers written in source code (eg. -5.06E+1) work -some floating point math improvements -SIN,COS,SQR -ABS -CHR$ ...and many, many other important improvements "under the hood" To compile a QBASIC/QB4.5 .BAS program simply run the program COMPILE.BAT. It will prompt you to enter the .BAS file's name. *****MAKE SURE YOUR .BAS FILE IS SAVED IN TEXT FORMAT***** RE: INCLUDED SAMPLE .BAS PROGRAMS I TAKE NO CREDIT FOR PROGRAMMING THESE SAMPLES (EXCEPT howclose.bas & memtest.bas) SOME PROGRAMS WERE MODIFIED TO MAKE THEM RUN UNDER DEMO #4 PLEASE DON'T DISTRIBUTE THESE SAMPLES UNLESS FOR THE SOLE PURPOSE OF TESTING DEMO #4 SOME RUN WAY TOO FAST! TRY THEM UNDER QBASIC TO "GET THE IDEA" flormap.bas: a raycaster-like floor mapper lines.bas: nice effect using intersecting lines which create various patterns wheel.bas: nice effect by joining lines at varying intervals around a circle matrix.bas: like the movie! a scrolling text effect pattern.bas: makes wierd patterns in SCREEN 13 (bizarre) rotozoom.bas: rotates and zooms an image in and out at the same time starwars.bas: plays a starwars tune fracmand.bas: draw a mandelbrot fractal (same as in Demo #3) fracnice.bas: draws a fractal and cycles its colors fracfern.bas: draws a fern howclose.bas: visual representation of an algorithm to identify nearby points quickly flame.bas: draws a cool flame effect memtest.bas: demonstrates QB64 can handle ALL 16-bit memory referencing IMPORTANT NOTES: -Still lots of bugs/loose ends to fix, please report your findings, but take into account what is/isn't supported before saying something doesn't work (listed below). -If C++ COMPILATION FAILS, it doesn't mean there is something wrong with the C++ compiler it means that the C++ code generated by COMPILE.EXE was wrong, and that the QB64 compiler wasn't good enough to find the problem (as it is in the early stages of development). -ONLY WINDOWS executable programs are possible atm (no Linux or Mac compilations yet). -You can also enter the name of the program to compile on the command line: (eg.) COMPILE frac.bas -You don't need to "INSTALL" QB64, just extract it using its current directory structure. WHAT IS NOT SUPPORTED YET: -Subs/functions -User defined types -File access -Select case -EXIT DO/FOR/etc. -ELSEIF -String comparison using <,<=,>= (=,<>,> ARE supported) -REM (use ' instead!) -Any QB statement/function not listed below, or usage of a function below which requires one of the above WHAT IS SUPPORTED: (and known limitations) IF-THEN-ELSE-ENDIF DO-LOOP FOR-NEXT (may not work with bit-length variables) WHILE-WEND GOTO DIM DEFINT/etc. LINE SOUND TIMER RND (must use RND(...), without brackets the compiler will freeze!) RANDOMIZE OUT (but only to palette registers in SCREEN 13) PCOPY VIEW (graphics) VIEW (text) INPUT (but not line input! also, inputting of bitlength-variables is unfinished) WINDOW LOCATE COLOR PALETTE WIDTH SCREEN PSET ASC LEN INKEY$ STR$ UCASE$ LCASE$ LEFT$ RIGHT$ LTRIM$ RTRIM$ DEF SEG, PEEK, POKE, VARSEG, VARPTR, VARPTR$, SADD CLS GOSUB/RETURN ON ERROR RESUME SIN COS SQR CHR$ ABS ERL ERR ERROR REDIM WHAT'S NEW IN QB64? (COMPARED TO QBASIC) INPUT PROTECTION: Say good-bye to "REDO FROM START" messages with input protection which stops the user from typing in invalid data before they even press ENTER. Try it with fixed length strings to limit how many characters a user can enter. DATA TYPES & THEIR USAGE: _BIT name` _UNSIGNED _BIT name~` _BIT*4 name`4 _UNSIGNED _BIT*4 name~`4 _BYTE name%% _UNSIGNED _BYTE name~%% INTEGER name% _UNSIGNED INTEGER name~% LONG name& _UNSIGNED LONG name~& _INTEGER64 name&& _UNSIGNED _INTEGER64 name~&& SINGLE name! DOUBLE name# _FLOAT name## STRING name$ STRING*100 name$100 THE NEW _DEFINE COMMAND: Instead of having DEFBIT,DEFUBT,DEFBYT,DEFUBY etc. for all the new data types there is a simple command which can be used like DEFINT for new types (or old types if you want to) as follows... _DEFINE A-C,Z AS DOUBLE 'the same as DEFDBL A-C,Z from IP address 58.110.130.42 |
| Response Title | Author and Date |
| * Looks good | qbguy on Nov 24 |
| * did you mean IF a=1 THEN 4 doesn't work. I'm pretty sure THEN is always required. | qbguy on Nov 24 |
| RE: IF a=1 GOTO 10 | on Nov 24 |
| * Does " IF a THEN" work? | on Nov 27 |
| *Yes, because like QBASIC, QB64 evaluates "IF"s as =0 or <>0 expressions | Galleon on Nov 27 |
| * But QB true = -1 which is also not zero eh........ | on Nov 28 |
| I ran some quick tests | roy on Nov 25 |
| Real nice! | on Nov 27 |
| Noticed one thing. The window size changes | on Nov 28 |
| Explaination about why window changes size in different video modes | Galleon on Nov 28 |
| 13 should be 640 X 400 I think. | on Nov 28 |
| qbasic commands | vaibhav on Mar 4 |
| Click here | on Mar 4 |