Deleted
Deleted Member
Posts: 0
|
Post by Deleted on Nov 11, 2015 9:22:07 GMT -5
Somewhat sizable update here: - Added a few more system variables (@sbs and @asm) - Added $INCLUDE "filepath\filename", @sbs (or @asm): Includes an ASM or SBS compatible file, example:
$INCLUDE "c:\test.sbs" ' If no argument is at the end, it defaults to @SBS $INCLUDE "c:\test.asm", @ASM ' Includes an ASM file
- Added in bit shifting - Fixed some math operators (now checks for integer or longs and assigns the appropriate operator to the ASM functions) - Added in the LOCATE command - Updated the PRINT command to accept "+" as either a math function or to append a string, for example: - Code Comments
print "Hello " + 1+2
The above outputs "Hello 3" - ELSEIF is now supported - Single line IF statements are also supported now - AND, OR, and XOR are supported in IF statements
|
|
Deleted
Deleted Member
Posts: 0
|
Post by Deleted on Nov 13, 2015 18:09:20 GMT -5
Here's a video update youtu.be/XjMke6HWg24Quite a few more commands and functions are now in the compiler: - SLEEP - FOR...NEXT loops - PALETTES - LBLPTR&() - DATA, DATAINT, and DATALONG - RELOAD and RESTORE One thing that annoyed me was that you can't use longs for the line/data label, so I added that in (here's the code in the video):
players = 1 IF players < 2 THEN pal& = LBLPTR&(sdpal) END IF PALETTES pal&,0,0,16,224 ' set the palette to black PRINT "Fading Test" FOR i = 7 TO 0 STEP -1 PALETTES pal&,0,0,16,i<<5 SLEEP 3 NEXT
sdpal: DATAINT $0EEE,$0EC4,$0EA2,$0CA4,$0C60,$06CE,$008E,$006E ' Palette: 0 DATAINT $000E,$0802,$0A82,$0000,$0CCC,$048E,$0ECE,$0ECE DATAINT $0CCC,$0CA2,$0C80,$0A82,$0A40,$04AC,$006C,$004C ' Palette: 0 DATAINT $000C,$0600,$0860,$0000,$0AAA,$024C,$0CAC,$0CAC DATAINT $0AAA,$0A82,$0A60,$0860,$0820,$028A,$004A,$002A ' Palette: 0 DATAINT $000A,$0400,$0640,$0000,$0888,$002A,$0A8A,$0A8A DATAINT $0888,$0860,$0840,$0640,$0600,$0068,$0028,$0008 ' Palette: 0 DATAINT $0008,$0200,$0420,$0000,$0666,$0008,$0868,$0868 DATAINT $0666,$0640,$0620,$0420,$0400,$0046,$0006,$0006 ' Palette: 0 DATAINT $0006,$0000,$0200,$0000,$0444,$0006,$0646,$0646 DATAINT $0444,$0420,$0400,$0200,$0200,$0024,$0004,$0004 ' Palette: 0 DATAINT $0004,$0000,$0000,$0000,$0222,$0004,$0424,$0424 DATAINT $0222,$0200,$0200,$0000,$0000,$0002,$0002,$0002 ' Palette: 0 DATAINT $0002,$0000,$0000,$0000,$0000,$0002,$0202,$0202 DATAINT $0000,$0000,$0000,$0000,$0000,$0000,$0000,$0000 ' Palette: 0 DATAINT $0000,$0000,$0000,$0000,$0000,$0000,$0000,$0000
Cheers!
|
|
|
Post by sega16 on Nov 14, 2015 15:24:43 GMT -5
This is very exciting for the BEX community. However after reading this thread I am still left with a few questions:
1) What language is this written in?
2) Will it be open source (I know that was asked already but it seems as if you all were just joking which may imply that it will be open source).
3) Although having a GUI is very nice for some people there are others who prefer a command line compiler. Is there going to be away to compile BEX programs via command line.
|
|
Deleted
Deleted Member
Posts: 0
|
Post by Deleted on Nov 14, 2015 16:04:34 GMT -5
1) What language is this written in? Visual Basic 2) Will it be open source (I know that was asked already but it seems as if you all were just joking which may imply that it will be open source). Nope, it won't be open source 3) Although having a GUI is very nice for some people there are others who prefer a command line compiler. Is there going to be away to compile BEX programs via command line. Yes, there will be a command line option for that. Is there any particular options you'd like for that aside from the input file and output file?
|
|
|
Post by sega16 on Nov 14, 2015 16:50:05 GMT -5
The reason I asked about what language was used and if it will be open source was because it I wanted to compile it for Linux. Fortunally I can do such because the Mono Project supports Visual Basic according to www.mono-project.com/docs/about-mono/languages/visualbasic/However since it is not open source I would just use WINE to run it. What advantage do you get my making it closed source? As for command line all that is needed is an input and output file.
|
|
Deleted
Deleted Member
Posts: 0
|
Post by Deleted on Nov 14, 2015 19:22:56 GMT -5
What advantage do you get my making it closed source? Personal choice. The compiler is nothing more than abusing string functions and a bunch of IF...END if blocks and SELECT CASE blocks
|
|
Deleted
Deleted Member
Posts: 0
|
Post by Deleted on Nov 14, 2015 19:24:47 GMT -5
Also, it's written in Visual Basic 6, not .NET
|
|
Deleted
Deleted Member
Posts: 0
|
Post by Deleted on Nov 15, 2015 16:55:30 GMT -5
With a working INCLUDE statement elusives BASIC should be eminently extendable. No need to be open source. You can obviously attach any license you want to your own code.
|
|
Deleted
Deleted Member
Posts: 0
|
Post by Deleted on Nov 16, 2015 0:27:04 GMT -5
Added quite a bit over the weekend New Commands: - DATA - DATAFILE - DATAINT - DATALONG - RELOAD - RESTORE - PALETTES - SLEEP - READ - READINT - READLONG - DRAWTILE - LOADTILES - SHADOWMODE New Functions: - LBLPTR&() - HFLIPTILE() The only new command added to Second Basic that isn't in BEX is SHADOWMODE. This just turns shadow/hilight mode on or off: shadowmode @on shadowmode @off shadowmode 1 shadowmode 0
|
|
|
Post by vetea on Nov 16, 2015 9:22:15 GMT -5
Nice. I hope you write a GOOD manual, not like the Bex one, you see what I mean .. ? Keep up the good work.
|
|
Deleted
Deleted Member
Posts: 0
|
Post by Deleted on Nov 16, 2015 16:13:47 GMT -5
Nice. I hope you write a GOOD manual, not like the Bex one, you see what I mean .. ? Keep up the good work. How's this look so far: iheartgk.com/SecondBasicUserGuide.pdfI'm trying to keep everything as organized and cleanly formatted as possible. If you have any suggestions, let me know! (when it's done, it'll be available in PDF, Word, and X/HTML)
|
|
|
Post by vetea on Nov 16, 2015 16:31:38 GMT -5
I read your manual, for now, it's perfect ! Clear, with explicit example. Good job !!
|
|
Deleted
Deleted Member
Posts: 0
|
Post by Deleted on Nov 16, 2015 16:44:32 GMT -5
I read your manual, for now, it's perfect ! Clear, with explicit example. Good job !! Thank you! One thing I've noticed is a lot of the beginner questions can be answered by the help documentation, though because of how messy it is, it's difficult to look for something when you have no idea where to look, which can push a person away from learning the language/platform. Hopefully people find it useful I will say that by writing the new parser/translator/compiler, I'm starting to learn ASM pretty decently (not enough to really do anything on my own yet, but to the point where I can understand what the code is doing and how to alter it and change what I need).
|
|
Deleted
Deleted Member
Posts: 0
|
Post by Deleted on Nov 19, 2015 0:25:09 GMT -5
Small update for the night:
- Single dimension arrays are now functional - Added in modulus - fixed a bug with the $INCLUDE command (it's now functional and can be nested across multiple files)
Cheers!
|
|
Deleted
Deleted Member
Posts: 0
|
Post by Deleted on Nov 19, 2015 16:06:26 GMT -5
An exciting update: Stef gave me permission to include his XGM driver into Second Basic! This is a great addition as a lot of new comers are always asking about music and sound effects, so at least they will have something to work with right away Cheers!
|
|