View previous topic :: View next topic |
Author |
Message |
jabbercat Composer

Joined: 04 Sep 2003 Posts: 823 Location: Oxford
|
Posted: Fri May 07, 2004 10:34 am Post subject: OHR font encoding? |
|
|
Does anyone here know how the OHR fonts are encoded or formatted? I would like to use the ohr font files for my own text engine. |
|
Back to top |
|
 |
Bob the Hamster OHRRPGCE Developer

Joined: 22 Feb 2003 Posts: 2526 Location: Hamster Republic (Southern California Enclave)
|
Posted: Fri May 07, 2004 2:17 pm Post subject: |
|
|
Code: |
-------------------------------------------------------------------------
.FNT format -- Font.
---
Ignore 7byte BLOAD header.
ASCII characters 1-255, encoded like so..
Column 0
Column 1
Column 2
Column 3
Column 4
Column 5
Column 6
Column 7
Next character.
Each column is stored in one byte. The bits that are on are pixels and the bits that are off are transparent, So, 255 would be a solid vertical line
All characters are stored in normal bit ordering.. that is, bit 0=topmost pixel
-------------------------------------------------------------------------
|
|
|
Back to top |
|
 |
TMC On the Verge of Insanity
Joined: 05 Apr 2003 Posts: 3240 Location: Matakana
|
Posted: Fri May 07, 2004 6:08 pm Post subject: |
|
|
This reminds me.... James, I wanted to ask what the structure of plotscr.lst was. I had a look at it, and it looks like half of it is compounding gibberish, getting worse the more times scripts are imported.
I want to write a program to instanteously import hs files, and I have the actual importing part done and running, but I can corrupt the RPG file if I try to import hs files with new scripts, etc.
Also, if there are any other files that would need to be changed (NPC definitions, textboxs, items, shops, general?) I would try and code that in as well. I'm obviously hoping that changing plotscr.lst covers it.
I probably should have emailed this (you can email me instead) but thanks heaps for any help! _________________ "It is so great it is insanely great." |
|
Back to top |
|
 |
jabbercat Composer

Joined: 04 Sep 2003 Posts: 823 Location: Oxford
|
Posted: Sat May 08, 2004 3:07 am Post subject: |
|
|
So is it like:
or
Code: |
=1
=2
=3
=4
=5
=6
|
Also, how would I go about getting the true values of the bits? Would I have to make a function that decodes them to a char variable? Thanks for the help Lord Paige! |
|
Back to top |
|
 |
TMC On the Verge of Insanity
Joined: 05 Apr 2003 Posts: 3240 Location: Matakana
|
Posted: Sat May 08, 2004 3:01 pm Post subject: |
|
|
It says columns, jabber. So it's like this:
Code: |
0 1 2 3 4 5 6 7
= = = = = = = =
|
Alright. If you have your byte, you can get the value of the nth bit with
byte AND (2 ^ n)
Bitwise AND of course, n starting at 0. _________________ "It is so great it is insanely great." |
|
Back to top |
|
 |
|