Just sharing DOS bitmap font.
Neil Roy

I wanted a DOS 8x8 bitmap font for Allegro 5, so I managed to whip this up. It has a transparent background (in case you're wondering why it looks so white) and so should work with Allegro 5 as is if anyone is interested in it.

606245

I coloured it green to look like the old monochrome DOS terminal.

Trent Gamblin

If you color it white then you can use the tinting parameter to color it any color you want.

SiegeLord

Also note that since A5 uses Unicode, the bottom half of that font is not readily accessible as it uses code page 437 while Unicode will treat the bottom half as Latin-1. You'll need to use al_grab_font_from_bitmap's ranges parameter with a 1 character range essentially for every character in the bottom half (the range values can be found in the first Wikipedia link).

Although, if you're actually using the graphical characters towards the end you'll probably be using character numbers anyway, so it's not a problem... but don't expect al_draw_text("Ñá"); to work if you don't map it out properly.

Neil Roy

It's a DOS font, I find it useless without the DOS graphic characters. It's part of what I like about it. ;) I do have a white version as well. I put this together because all the font generating software doesn't make a true 8x8 bit DOS font. The best I could get was a 6 x 12 version.

606249

Anyhow, the white version. ;)

SiegeLord said:

Although, if you're actually using the graphical characters towards the end you'll probably be using character numbers anyway, so it's not a problem... but don't expect al_draw_text("Ñá"); to work if you don't map it out properly.

Thanks, I'll keep that in mind.

Luiji99

That looks pretty cool! About those characters in the top-right corner, what code points are those? I've seen them in other fonts and have no idea how to make Allegro draw them.

Also, what license are you releasing this font under?

Neil Roy

Public domain I guess. No license... take your pick, I won't sue you. ;D Just trying to give a little something back. ;)

Oh, and those characters range from 0 to 255, so you may have to refer to some of the characters by number. I haven't played around with it much under Allegro 5 yet, just starting making some bitmaps for A5 for my own games in the past few days.

Here's another really nice one I just created. I'll be using this in an upcoming game if anyone is interested, just give me credit if you use it. :)

I call it "FatFont", I actually edited this pixel by pixel, no preloaded fonts, so it took me a while to make, and remake (lots of errors). ;)

Looks best against a dark (ie:black) background. It is transparent and so works as is with Allegro 5.

{"name":"606264","src":"\/\/djungxnpq2nug.cloudfront.net\/image\/cache\/9\/f\/9f5061f3618449d40408fdc664095279.png","w":257,"h":127,"tn":"\/\/djungxnpq2nug.cloudfront.net\/image\/cache\/9\/f\/9f5061f3618449d40408fdc664095279"}606264

Thomas Fjellstrom

public domain isn't "a thing" in some countries. So there at least it'd be considered non re-distributable legally.

Neil Roy

I honestly hate all the legalities these days. Why can't I just give something away free to use? ;) I haven't got a clue which license. Whatever one allows you to use it freely in commercial or otherwise. Credit is nice, but I don't care. ;)

Thomas Fjellstrom

Creative Commons? That aught to work. Pick one of them :)

Neil Roy

Yeah, http://creativecommons.org/licenses/by-sa/3.0/ (creative commons ShareAlike) sounds right up my alley. ;)

Steve Terry

Hey I wrote a chess game once only using the low and high ascii set in DOS mode so I actually know most of those characters :-)

Neil Walker

Hey I wrote a chess game once only using the low and high ascii set in DOS mode so I actually know most of those characters

consider yourself lucky, when I was young I had to know all those characters and every ESC/p command/function in order to send formatted data to a printer.

LennyLen

consider yourself lucky, when I was young I had to know all those characters and every ESC/p command/function in order to send formatted data to a printer.

When I was young and didn't have a card with a graphics mode, I overwrote the area of memory the character set was written to so I could 'print' my own sprites to the screen. :)

Neil Walker

^ that's what you did/do with the ZX Spectrum :)

Neil Roy

I have you all beat, when I was young we had to press keys which caused these metal arms to come up and hit some paper. They were called type writers and they were not electric yet. ;) We had to manually push them to get a carriage return! ;D :D

But then again, I'm older than my countries' flag. :P

LennyLen said:

When I was young and didn't have a card with a graphics mode, I overwrote the area of memory the character set was written to so I could 'print' my own sprites to the screen. :)

Sounds like a Commodore 64. I done that, used hidden memory, that was so much fun when I first discovered how to access that. :)

I also used the C64 print command to "print" sounds into memory by redirecting where the print command printed to. It was a great trick you could use for sprites etc. I still have some yellowed paper with the code stashed around here somewhere. :D

Hey I wrote a chess game once only using the low and high ascii set in DOS mode so I actually know most of those characters :-)

I'm seriously considering sitting down and DOSBOX and writing something for DOS just for old time sake. Maybe even the C64 too! LMAO

LennyLen
Neil Roy said:

Sounds like a Commodore 64. I done that, used hidden memory, that was so much fun when I first discovered how to access that

I first did this on 8bit Ataris. Then on an IBM PC-XT. With the Atari, I didn't even have any library books to use as references for memory locations, so had to discover them by sequentially changing values in meory with POKE to see the results. I had to reboot a LOT.

Steve Terry

You damn kids... why back in my day if you needed to write something you had to use sticks and stones. Could write a word a week if I kept at it most of the day! Now get off my lawn!

Neil Roy

Ahoy! magazine and especially Compute! were probably the best for learning to program with their type in games. Also the Commodore 64 Programmer's Reference Guide was handy. As well as BBSes. I didn't own an IBM at the time, but I used to experiment on PC JRs and such at various places. I think part of the success story behind IBMs was things like QBasic or BasicA which made it easy for anyone to program them with "high resolution" graphics.

I definitely miss those days.

LennyLen
Neil Roy said:

Ahoy! magazine and especially Compute! were probably the best for learning to program with their type in games.

Unfortunately, they were very hard to come by in New Zealand in the 80s.

Neil Roy

They used to have those magazines, well, Compute! anyhow, at our public library. Ahoy! was my favorite of the bunch, had some of the best games you typed in. A couple were "3D", I still have them for my C64 emulator. :) I actually still have most of the magazines I bought back then, I'm a hoarder of those types of things. :)

(looks in drawer under old Heavy Metal magazines)I have the first issue of Compute! I ever bought, July 1986. :)

Dramier

I dunno about missing the old Basic days. Just thinking about all those lines of Poke and Peek to make a sprite makes me very thankful for the stuff we have now.

Although I do miss getting a new issue of whatever magazine was hot at the time and spending an hour or so plugging in lines of code just so you could debug it for another two hours to get it to run.

Load "*", 8, 1

I can't believe I still remember that.

Neil Roy

Don't forget: Load "$",8 then LIST for the device 8 directory. :)

Clear the SID (sound) chip:

POKE 209,0: POKE 210,212: POKE 211,0: ?"@@@@@@@@@@@@@@@@@@@@@@@@@";

That same trick could be used (with different pokes) to redirect the print command to the sprite area and instantly create sprites. Change some of those @'s (which is a C64 zero character) to others to instantly create sound effects. Pretty kewl stuff. :)

If you recall the IBM's BasicA "LOCATE" command which could locate the cursor on screen anywhere, the C64 had annoying graphics you had to repeat to move the cursor, but it actually had a LOCATE command, it just didn't have a basic word for it, it was available for assembly programmers. From your programs you used:

POKE 211,X: POKE 214,Y: SYS58732

I would put this into a function you would GOSUB to with X and Y set.

Machine language programming on the C64 was the most fun. The 6510 CPU was very easy to program. Fun times. Gonna have to boot up the emulator again I think. ;)

Thread #610576. Printed from Allegro.cc