Ralph Versteegen wrote:
2009/3/8 James Paige <b...@hamsterrepublic.com>:
On Sun, Mar 08, 2009 at 04:55:52AM +1300, Ralph Versteegen wrote:
2009/3/8  <subvers...@hamsterrepublic.com>:
teeemcee
2009-03-07 07:04:11 -0800 (Sat, 07 Mar 2009)
1392
Complete text rendering rewrite. Adds fonts:
-A font can be one or two layers. The bottom layer is drawn first for the whole 
string, then the top one. This is to let shadows and effects like edgeprint for 
neighbouring characters overlap. Edgeprint now draws a string twice instead of 
5 times.
-Each character can be a variable width
-Each sprite for each layer for each character can be any size, placed in any 
position relative to the character, and use 256 colours. So you can add huge 
graffiti like tails and things which extend all over the place.

There are two fonts currently loaded for each game: the base game font, and the 
game font plus edges. To try out new font features at the moment need to use 
hardcoded fonts, modify setfont. font_loadbmps is there for this.

The font code is incomplete, eventually it should have more support for 
palettes and colour manipulation, multiple fonts, and font effects like shadows 
and gradients.

I also changed the way Frame masks act. 0x00 is now transparent and 0xff is 
opaque, instead of the other way around. masks are also now optional for 
transparent blitting using draw_ohr. I believe there are only two places where 
they are actually needed: enemies fading out, and scaled blitting 
(sprite_draw). Everything else could now be changed to use half as much memory. 
However, fonts are the only thing taking advantage of this at the moment.
---
U   wip/allmodex.bas
U   wip/allmodex.bi
U   wip/common.bas
U   wip/common.bi
U   wip/udts.bi
Example, a small (2x6 to 6x6 per char) monochrome font I quickly drew,
lowercase letters only:
http://tmc.castleparadox.com/ohr/smallfont.png
To use it, unzip
http://tmc.castleparadox.com/ohr/smallfont.zip
to executable directory and modify setfont.
Is there something funky about that zip file?

ja...@atmaweapon:~/src/ohr/wip$ unzip smallfont.zip
Archive:  smallfont.zip
  skipping: testfont/100.bmp        `(null)' method not supported
  skipping: testfont/101.bmp        `(null)' method not supported
  skipping: testfont/102.bmp        `(null)' method not supported
  skipping: testfont/103.bmp        `(null)' method not supported
  skipping: testfont/104.bmp        `(null)' method not supported
  skipping: testfont/105.bmp        `(null)' method not supported
  skipping: testfont/106.bmp        `(null)' method not supported
  skipping: testfont/107.bmp        `(null)' method not supported
  skipping: testfont/108.bmp        `(null)' method not supported
  skipping: testfont/109.bmp        `(null)' method not supported
  skipping: testfont/110.bmp        `(null)' method not supported
  skipping: testfont/111.bmp        `(null)' method not supported
  skipping: testfont/112.bmp        `(null)' method not supported
  skipping: testfont/113.bmp        `(null)' method not supported
  skipping: testfont/114.bmp        `(null)' method not supported
  skipping: testfont/115.bmp        `(null)' method not supported
  skipping: testfont/116.bmp        `(null)' method not supported
  skipping: testfont/117.bmp        `(null)' method not supported
  skipping: testfont/118.bmp        `(null)' method not supported
  skipping: testfont/119.bmp        `(null)' method not supported
  skipping: testfont/120.bmp        `(null)' method not supported
  skipping: testfont/121.bmp        `(null)' method not supported
  skipping: testfont/122.bmp        `(null)' method not supported
  skipping: testfont/97.bmp         `(null)' method not supported
  skipping: testfont/98.bmp         `(null)' method not supported
  skipping: testfont/99.bmp         `(null)' method not supported
  creating: testfont/

---
James

Hmm yeah, me too. I think I might have used 7zip to zip it, it has all
kinds of funky options.
http://tmc.castleparadox.com/ohr/smallfont.tar.gz

(The zip file worked for me, with Winzip)

--
Mike
_______________________________________________
Ohrrpgce mailing list
ohrrpgce@lists.motherhamster.org
http://lists.motherhamster.org/listinfo.cgi/ohrrpgce-motherhamster.org

Reply via email to