First of all, everybody, I *must* quite thank each and every rather one of you for the truly excellent welcome-back indeed... another reason why our FreeBASIC community is seriously a phenomenally brilliant,
splendidly well-creative one for sure!!!
:D !!
Talking right now of which, the main reason why I am so completely,
completely plain homesick for both you guys and our entire community is simply because after eight (8) consecutive years of missing all of you so much, it takes me then currently quite a few weeks straight or more for me to really and fully get back into the groove of things in major terms of what’s going on good with our community and the downright amazing things that you all have been doing using FreeBASIC... including so many of the recent, well-completed games that at least some-to-many of you have done since around 2010 or so... WOW, it has been that damn long ago!! Please, pardon me as I get back in the grand swing of things with all of you, so to speak.
^^
Now, I have just today updated AFlib III a bit to
v0.86 alpha test release for all of you, so please check the first post and replace that old version with the current one, as I have just notably added now a custom 4,096-color palette to be used within this FB game lib itself in any 15-, 16-, 24-, and 32-bit color graphics mode... more about how to use that new palette of mine later in this post. Stay tuned!!!
On the New Year’s Day of 2016, Pim Scheffers proudly wrote:He, (happy new-year by the way :-)
Thanks you, for this alpha release. (I like surprises on new-years day)
Your first library seriously got me into using FreeBASIC as my hobby language somewhere in 2010 I guess.
I've been creating a 2D platformer for a little over 2 years now (see a few topics down on this thread) and although not many AFlib1 subs / functions are directly used in the game, your library taught me FreeBASIC and retro graphics and got me into making this game.
Just downloaded the library and cannot wait what gems you have hidden in there this time ;-)
Thanks,
First of all for you, Pim, I gotta thank you personally for wishing me quite a happy new year for 2016... I TRULY appreciate that from the heart, man!!!
^-^=b !! Secondly, I am even truly happier that my AFlib2 (which was quite indeed my first created library that I did in FreeBASIC from way, wayyy back in 2005, by the way... WOW, that very long ago!!!) most genuinely taught you the ins-and-outs of FB and retro graphics as well as inspired you to create your game entitled “Slimo”. Speaking of your game here that you are currently working on, I have seen a video of it in action on YouTube (which is located
right here, by the way) just two days even before I already launched this very thread about AFlib III. And looking at your game and how it is built using your yet-to-be-released Mode13h library in FB, it just takes me back to the grand ‘ol days of DOS, QuickBASIC gaming, and RelLib and how I used to have tons and tons of fun with them all for years on end long before the rather days of FreeBASIC came along and extended QuickBASIC’s proudly masterful legacy in a monumentally resplendent way over to Windows and other OSes... THOSE WERE THE DAYS, my fine man, and they were just downright effing awesome stuff from our own youths, let’s get that most absolutely plain right!!!
;*)
Talking about games made in QuickBASIC, Pim, here is a most awesome-looking, brand-newest 2016 platformer by author ‘mangis’ entitled “
Magiduck” that is completely done entirely from scratch using both QB PDS 7.1 and Assembly language... ALL IN MS-DOS using just 16 colors exclusively in CGA 40x25 textmode alone, believe it or not — which is absolutely downright plain amazing in and of itself, as you do not get many top-tier quality new DOS games anymore these rather days, let alone in plain vanilla textmode indeed!!!
:o !! Now, you can check out all about it on YouTube
right here to see how it was all done, then check out
the original game post and as well as the downloadable freeware demo so far at
http://www.indiedb.com/games/magiduck and play the game for yourself in DOSBox. Let it and my AFlib III all inspire you and our FB community even further in creating your own next big rockin’ 2D game in FreeBASIC now...
let’s all quite do this together, shall we?
d=^_~=b !!
Next up, on that same day, dafhi also wrote:big plus for oldschool vibes and full source
running win, many fullscreen apps takeover and freeze my intel hd gfx.
the one file that did work (i didnt go thru all): ascii_testprimiives. suggestion: reduce num of tests to 2 or 3. triangle fill is always good.
welcome back :)
First of all, dafhi, as I was really quite hard at work on the additional features for AFlib III, I have just now updated the very many program examples to start by default at Windowed mode, just to make things a little easier for you and your users as well. What I have not done as of yet currently is the ability to select what specific drawing primitives to test alone, though that will come a little later on shortly as I continue to develop, so do hang tight for just a bit as I get there, ok please?
;)
As well, thank you quite so much for your time and support, and I want to make AFlib III the most easier-to-use Truecolor game lib there is in FreeBASIC... especially for you as well, I promise!!!
And later, on 1/10/2016, wallyg wrote:I downloaded your file and ran a few tests. I would certainly like to try my hand at using your library, do you have any documentation on how to use your system?
Thanks
WallyG
You are most entirely welcome, wallyg, and thank you so much for trying AFlib III out so far.
;) I have not printed out any documentation yet at this moment, but here is what I clearly notified to you from the beginning of this thread:
...when AFlib III is all finished and finalized, I will be adding in a FULL-color PDF documentation showing you all the commands that are featured in this lib, what they are about, and how they work according to their individual workings on their own.
...so to hold you over for now, I will — as I also said from the beginning of this thread — be adding in FB code snippets built specially for AFlib III to help you and our entire FreeBASIC community get the very most out of this very game library. Be sure not to miss ‘em!!
And to all of you, as promised, here come the new AFlib III code snippets.
First off, come the new AFlib III custom palette tests in any 15- to 32-bit custom graphics mode that you can handsomely create yourself to help get you started. These require
v0.86 alpha test release or higher of this lib in order for them to work properly. Here we go!!!
The 64-color Custom Palette Test:
Code: Select all
#include "AFlib3_Font.bi"
#include "AFlib3_Palette.bi"
#include "AFlib3_Miscellaneous.bi"
Dim PaletteType as Integer
PaletteType = 0 ' <---------- Pass '0' for Master System/Mark III Palette;
' '1' FC/FDS/NES Palette; or
' '2' FamiCube 64-color Palette.
Screenres 640, 480, 24, 0
WindowTitle "My 64-color Palette Display Test in a 15- to 32-bit Graphics Mode using AFlib III!!!"
Dim as Integer ColNumber = 0
Dim as Integer FontSelect = 7
Dim as String SetMessageA, SetMessageB = "64-color Custom Palette Test for AFlib III"
For PalRead_Y as Integer = 0 to 3
For PalRead_X as Integer = 0 to 15
Select Case PaletteType
Case is < 1
Line(PalRead_X * 16, PalRead_Y * 16)-((PalRead_X * 16) + 14, (PalRead_Y * 16) + 14), SMScol(ColNumber), bf
SetMessageA = "(Master System/Mark III Palette)"
Case 1
Line(PalRead_X * 16, PalRead_Y * 16)-((PalRead_X * 16) + 14, (PalRead_Y * 16) + 14), NEScol(ColNumber), bf
SetMessageA = "(Famicom/FDS/NES Palette)"
Case is > 1
Line(PalRead_X * 16, PalRead_Y * 16)-((PalRead_X * 16) + 14, (PalRead_Y * 16) + 14), FCUBEcol(ColNumber), bf
SetMessageA = "(Arne's Famicube 64-color Palette)"
End Select
ColNumber += 1
Next
Next
AFlibIII_Print SetMessageA, 1, 280, 1.5, 1, SMSeasy(1, 1, 1), 0, 2, FontSelect
AFlibIII_Print SetMessageA, 1, 281, 1.5, 1, SMSeasy(1, 1, 1), 0, 2, FontSelect
AFlibIII_Print SetMessageA, 0, 281, 1.5, 1, SMSeasy(1, 1, 1), 0, 2, FontSelect
AFlibIII_Print SetMessageA, 0, 280, 1.5, 1, SMSeasy(3, 3, 3), 0, 2, FontSelect
AFlibIII_Print SetMessageB, 1, 464, 1, 1, SMSeasy(1, 1, 1), 0, 2, FontSelect
AFlibIII_Print SetMessageB, 1, 465, 1, 1, SMSeasy(1, 1, 1), 0, 2, FontSelect
AFlibIII_Print SetMessageB, 0, 465, 1, 1, SMSeasy(1, 1, 1), 0, 2, FontSelect
AFlibIII_Print SetMessageB, 0, 464, 1, 1, SMSeasy(3, 3, 3), 0, 2, FontSelect
For R as Integer = 0 to 63
Select Case PaletteType
Case is < 1: Line(R * 3, 300)-((R * 3) + 2, 400), SMScol(R), BF
Case 1: Line(R * 3, 300)-((R * 3) + 2, 400), NEScol(R), BF
Case is > 1: Line(R * 3, 300)-((R * 3) + 2, 400), FCUBEcol(R), BF
End Select
Next
Sleep
AFlibIII_EndProgram
The 128-color Custom Palette Test:
Code: Select all
#include "AFlib3_Font.bi"
#include "AFlib3_Palette.bi"
#include "AFlib3_Miscellaneous.bi"
Dim PaletteType as Integer
PaletteType = 0 ' <---------- Pass '0' for Atari 2600 Palette (NTSC version);
' '1' for Atari 2600 Palette (PAL version);
' '2' for Commodore Plus/4 Palette; or
' '3' for Sam Coupe 128-color Palette.
Screenres 640, 480, 24, 0
WindowTitle "My 128-color Palette Display Test in a 15- to 32-bit Graphics Mode using AFlib III!!!"
Dim as Integer ColNumber = 0
Dim as Integer FontSelect = 7
Dim as String SetMessageA, SetMessageB = "128-color Custom Palette Test for AFlib III"
For PalRead_Y as Integer = 0 to 7
For PalRead_X as Integer = 0 to 15
Select Case PaletteType
Case is < 1
Line(PalRead_X * 16, PalRead_Y * 16)-((PalRead_X * 16) + 14, (PalRead_Y * 16) + 14), ATARI2600col(ColNumber), bf
SetMessageA = "(Atari 2600 NTSC Palette)"
Case 1
Line(PalRead_X * 16, PalRead_Y * 16)-((PalRead_X * 16) + 14, (PalRead_Y * 16) + 14), PAL2600col(ColNumber), bf
SetMessageA = "(Atari 2600 PAL Palette)"
Case 2
Line(PalRead_X * 16, PalRead_Y * 16)-((PalRead_X * 16) + 14, (PalRead_Y * 16) + 14), PLUS4col(ColNumber), bf
SetMessageA = "(Commodore Plus/4 Palette)"
Case is > 2
Line(PalRead_X * 16, PalRead_Y * 16)-((PalRead_X * 16) + 14, (PalRead_Y * 16) + 14), SAMCOUPEcol(ColNumber), bf
SetMessageA = "(SAM Coup"+chr(130)+" 128-color Palette)"
End Select
ColNumber += 1
Next
Next
AFlibIII_Print SetMessageA, 1, 280, 1.5, 1, ATARI2600col(1), 0, 2, FontSelect
AFlibIII_Print SetMessageA, 1, 281, 1.5, 1, ATARI2600col(1), 0, 2, FontSelect
AFlibIII_Print SetMessageA, 0, 281, 1.5, 1, ATARI2600col(1), 0, 2, FontSelect
AFlibIII_Print SetMessageA, 0, 280, 1.5, 1, ATARI2600col(7), 0, 2, FontSelect
AFlibIII_Print SetMessageB, 1, 464, 1, 1, ATARI2600col(1), 0, 2, FontSelect
AFlibIII_Print SetMessageB, 1, 465, 1, 1, ATARI2600col(1), 0, 2, FontSelect
AFlibIII_Print SetMessageB, 0, 465, 1, 1, ATARI2600col(1), 0, 2, FontSelect
AFlibIII_Print SetMessageB, 0, 464, 1, 1, ATARI2600col(7), 0, 2, FontSelect
For R as Integer = 0 to 127
Select Case PaletteType
Case is < 1: Line(R * 2, 300)-((R * 2) + 1, 400), ATARI2600col(R), B
Case 1: Line(R * 2, 300)-((R * 2) + 1, 400), PAL2600col(R), B
Case 2: Line(R * 2, 300)-((R * 2) + 1, 400), PLUS4col(R), B
Case is > 2: Line(R * 2, 300)-((R * 2) + 1, 400), SAMCOUPEcol(R), B
End Select
Next
Sleep
AFlibIII_EndProgram
The 256-color Custom Palette Test:
Code: Select all
#include "AFlib3_Font.bi"
#include "AFlib3_Palette.bi"
#include "AFlib3_Miscellaneous.bi"
Dim PaletteType as Integer
PaletteType = 0 ' <---------- Pass '0' for VGA Mode13h Normal Palette;
' '1' for Relsoft Palette;
' '2' for The Adigun Azikiwe Polack 256-Color Palette;
' '3' for Atari 400/800/XL/XE Palette;
' '4' for Atari 7800 Palette; or
' '5' for Enterprise Home Computer (64k and 128k models).
Screenres 640, 480, 24, 0
WindowTitle "My 256-color Palette Display Test in a 15- to 32-bit Graphics Mode using AFlib III!!!"
Dim as Integer ColNumber = 0
Dim as Integer FontSelect = 7
Dim as String SetMessageA, SetMessageB = "256-color Custom Palette Test for AFlib III"
For PalRead_Y as Integer = 0 to 15
For PalRead_X as Integer = 0 to 15
Select Case PaletteType
Case is < 1
Line(PalRead_X * 16, PalRead_Y * 16)-((PalRead_X * 16) + 14, (PalRead_Y * 16) + 14), VGAcol(ColNumber), bf
SetMessageA = "(VGA Mode13h Normal Palette)"
Case 1
Line(PalRead_X * 16, PalRead_Y * 16)-((PalRead_X * 16) + 14, (PalRead_Y * 16) + 14), RELcol(ColNumber), bf
SetMessageA = "(Relsoft Palette)"
Case 2
Line(PalRead_X * 16, PalRead_Y * 16)-((PalRead_X * 16) + 14, (PalRead_Y * 16) + 14), AAPcol(ColNumber), bf
SetMessageA = "(The AAP 256-color Palette)"
Case 3
Line(PalRead_X * 16, PalRead_Y * 16)-((PalRead_X * 16) + 14, (PalRead_Y * 16) + 14), ATARIcol(ColNumber), bf
SetMessageA = "(Atari 400/800/XL/XE Palette)"
Case 4
Line(PalRead_X * 16, PalRead_Y * 16)-((PalRead_X * 16) + 14, (PalRead_Y * 16) + 14), ATARI7800col(ColNumber), bf
SetMessageA = "(Atari 7800 Palette)"
Case is > 4
Line(PalRead_X * 16, PalRead_Y * 16)-((PalRead_X * 16) + 14, (PalRead_Y * 16) + 14), ENTERPRISEcol(ColNumber), bf
SetMessageA = "(Enterprise 64k/128k Palette)"
End Select
ColNumber += 1
Next
Next
AFlibIII_Print SetMessageA, 1, 280, 1.5, 1, VGAcol(8), 0, 2, FontSelect
AFlibIII_Print SetMessageA, 1, 281, 1.5, 1, VGAcol(8), 0, 2, FontSelect
AFlibIII_Print SetMessageA, 0, 281, 1.5, 1, VGAcol(8), 0, 2, FontSelect
AFlibIII_Print SetMessageA, 0, 280, 1.5, 1, VGAcol(15), 0, 2, FontSelect
AFlibIII_Print SetMessageB, 1, 464, 1, 1, VGAcol(8), 0, 2, FontSelect
AFlibIII_Print SetMessageB, 1, 465, 1, 1, VGAcol(8), 0, 2, FontSelect
AFlibIII_Print SetMessageB, 0, 465, 1, 1, VGAcol(8), 0, 2, FontSelect
AFlibIII_Print SetMessageB, 0, 464, 1, 1, VGAcol(15), 0, 2, FontSelect
For R as Integer = 0 to 255
Select Case PaletteType
Case is < 1: Line(R, 300)-(R, 400), VGAcol(R)
Case 1: Line(R, 300)-(R, 400), RELcol(R)
Case 2: Line(R, 300)-(R, 400), AAPcol(R)
Case 3: Line(R, 300)-(R, 400), ATARIcol(R)
Case 4: Line(R, 300)-(R, 400), ATARI7800col(R)
Case is > 4: Line(R, 300)-(R, 400), ENTERPRISEcol(R)
End Select
Next
Sleep
AFlibIII_EndProgram
The 512-color Custom Palette Test:
Code: Select all
#include "AFlib3_Font.bi"
#include "AFlib3_Palette.bi"
#include "AFlib3_Miscellaneous.bi"
Dim PaletteType as Integer
PaletteType = 0 ' <---------- Pass '0' for RGB 9-bit Custom Palette;
' '1' for Relsoft Extended 512-color Palette; or
' '2' for AAP Super-512 Palette (512 colors).
Screenres 640, 480, 24, 0
WindowTitle "My 512-color Palette Display Test in a 15- to 32-bit Graphics Mode using AFlib III!!!"
Dim as Integer ColNumber = 0
Dim as Integer FontSelect = 7
Dim as String SetMessageA, SetMessageB = "512-color Custom Palette Test for AFlib III"
For PalRead_Y as Integer = 0 to 15
For PalRead_X as Integer = 0 to 31
Select Case PaletteType
Case is < 1
Line(PalRead_X * 16, PalRead_Y * 16)-((PalRead_X * 16) + 14, (PalRead_Y * 16) + 14), RGB512col(ColNumber), bf
SetMessageA = "(RGB 9-bit Palette)"
Case 1
Line(PalRead_X * 16, PalRead_Y * 16)-((PalRead_X * 16) + 14, (PalRead_Y * 16) + 14), REL512col(ColNumber), bf
SetMessageA = "(Relsoft Extended 512-color Palette)"
Case is > 1
Line(PalRead_X * 16, PalRead_Y * 16)-((PalRead_X * 16) + 14, (PalRead_Y * 16) + 14), AAP512col(ColNumber), bf
SetMessageA = "(AAP Super-512 Palette)"
End Select
ColNumber += 1
Next
Next
AFlibIII_Print SetMessageA, 1, 280, 1.5, 1, AAP512col(13), 0, 2, FontSelect
AFlibIII_Print SetMessageA, 1, 281, 1.5, 1, AAP512col(13), 0, 2, FontSelect
AFlibIII_Print SetMessageA, 0, 281, 1.5, 1, AAP512col(13), 0, 2, FontSelect
AFlibIII_Print SetMessageA, 0, 280, 1.5, 1, AAP512col(31), 0, 2, FontSelect
AFlibIII_Print SetMessageB, 1, 464, 1, 1, AAP512col(13), 0, 2, FontSelect
AFlibIII_Print SetMessageB, 1, 465, 1, 1, AAP512col(13), 0, 2, FontSelect
AFlibIII_Print SetMessageB, 0, 465, 1, 1, AAP512col(13), 0, 2, FontSelect
AFlibIII_Print SetMessageB, 0, 464, 1, 1, AAP512col(31), 0, 2, FontSelect
For R as Integer = 0 to 511
Select Case PaletteType
Case is < 1: Line(R, 300)-(R, 400), RGB512col(R)
Case 1: Line(R, 300)-(R, 400), REL512col(R)
Case is > 1: Line(R, 300)-(R, 400), AAP512col(R)
End Select
Next
Sleep
AFlibIII_EndProgram
The 4,096-color Custom Palette Test:
Code: Select all
#include "AFlib3_Font.bi"
#include "AFlib3_Palette.bi"
#include "AFlib3_Miscellaneous.bi"
Screenres 640, 480, 24, 0
WindowTitle "My RGB 4096-color Palette Display Test in a 15- to 32-bit Graphics Mode using AFlib III!!!"
Dim as Integer ColNumber = 0
Dim as Integer FontSelect = 7
Dim as String SetMessageA, SetMessageB = "4096-color Custom Palette Test for AFlib III"
SetMessageA = "(RGB 12-bit Palette)"
For PalRead_Y as Integer = 0 to 31
For PalRead_X as Integer = 0 to 127
Line(PalRead_X * 5, PalRead_Y * 5)-((PalRead_X * 5) + 3, (PalRead_Y * 5) + 3), RGB4096col(ColNumber), bf
ColNumber += 1
Next
Next
AFlibIII_Print SetMessageA, 1, 240, 1.5, 1, RGB4096easy(3, 3, 3), 0, 2, FontSelect
AFlibIII_Print SetMessageA, 1, 241, 1.5, 1, RGB4096easy(3, 3, 3), 0, 2, FontSelect
AFlibIII_Print SetMessageA, 0, 241, 1.5, 1, RGB4096easy(3, 3, 3), 0, 2, FontSelect
AFlibIII_Print SetMessageA, 0, 240, 1.5, 1, RGB4096easy(15, 15, 15), 0, 2, FontSelect
AFlibIII_Print SetMessageB, 1, 464, 1, 1, RGB4096easy(3, 3, 3), 0, 2, FontSelect
AFlibIII_Print SetMessageB, 1, 465, 1, 1, RGB4096easy(3, 3, 3), 0, 2, FontSelect
AFlibIII_Print SetMessageB, 0, 465, 1, 1, RGB4096easy(3, 3, 3), 0, 2, FontSelect
AFlibIII_Print SetMessageB, 0, 464, 1, 1, RGB4096easy(15, 15, 15), 0, 2, FontSelect
For R as Integer = 0 to 511
For Lin as Integer = 0 to 7
Line(R, 260 + (Lin * 20))-(R, 279 + (Lin * 20)), RGB4096col(R + (Lin * 512))
Next
Next
Sleep
AFlibIII_EndProgram
These should warm all of you up in using AFlib III indeed. And here are quite some easy to use commands straight from the “
AFlib3_Palette.bi” module to help you out even further:
- • ENTERPRISEeasy
Code: Select all
Declare Function ENTERPRISEeasy ( Byval R_col as Integer, _
Byval G_col as Integer, _
Byval B_col as Integer ) as Integer
- R_col = the red shade level (0 to 7)
G_col = the green shade level (0 to 7)
B_col = the blue shade level (0 to 7)
• SAMCOUPEeasy
Code: Select all
Declare Function SAMCOUPEeasy ( Byval R_col as Integer, _
Byval G_col as Integer, _
Byval B_col as Integer, _
Byval Intensity as Integer = 0 ) as Integer
- R_col = the red shade level (0 to 3)
G_col = the green shade level (0 to 3)
B_col = the blue shade level (0 to 3)
Intensity = the intensity shade level of the resulting color (0 = Normal; 1 = Bright)
• SMSeasy
Code: Select all
Declare Function SMSeasy ( Byval R_col as Integer, _
Byval G_col as Integer, _
Byval B_col as Integer ) as Integer
- R_col = the red shade level (0 to 3)
G_col = the green shade level (0 to 3)
B_col = the blue shade level (0 to 3)
• RGB512easy
Code: Select all
Declare Function RGB512easy ( Byval R_col as Integer, _
Byval G_col as Integer, _
Byval B_col as Integer ) as Integer
- R_col = the red shade level (0 to 7)
G_col = the green shade level (0 to 7)
B_col = the blue shade level (0 to 7)
• RGB4096easy
Code: Select all
Declare Function RGB4096easy ( Byval R_col as Integer, _
Byval G_col as Integer, _
Byval B_col as Integer ) as Integer
- R_col = the red shade level (0 to 15)
G_col = the green shade level (0 to 15)
B_col = the blue shade level (0 to 15)
And I have even included full palettes from two very, VERY absolute rarest 1985-1990 computers that originated in the UK: the
SAM Coupé and the
Enterprise 64/128 home computers... both of which were actually quite “8-bit”-based. For instance, do check out the full, original SAM Coupé 128-color palette in all its glory
right here, and then check out these videos on YouTube showcasing the games and demonstration programs on the Enterprise 64/128
here and
here, respectively.
Goes to actually show you that I am a MASSIVE fan of high-quality, back-in-the-day retro graphics and the phenomenal classic gaming that it sure entails, to be quite flatly honest.
;) !! That is most seriously why I am sharing all this stuff with you amazing entire FB community, and creating for you AFlib III in the process as well.
That said, ladies and gentlemen, do fully enjoy this lib in FreeBASIC to your absolute heart’s content, and stay tuned for even more exciting new AFlib III code snippets from yours truly!!!