Font


And another ... i use int type, but it is too small for me ( What type i can use?
 
To creat a font for FENIX, you use a program called FNTEDIT.EXE. The program is in spanish, but you can figure out what most of the buttons do.

You load any of your system font in FNTEDIT and save them as FONTNAME.FNT
In Fenix, you use
font1=load_fnt("FONTNAME.FNT");

To display the font you:
write(font1,screenx,screeny,centering_flag,"This is what you type");
write(font1,0,0,0,"This is what you type");
Which would write "This is what you type" in the upper left corner of the screen.

(edit spelling)
One thing I've found is that you have to run the app/game in 16-bit color of the font kills the color palette.

-Kensupen
 
Is there a link for FNTEDIT.EXE? I didn't get it in the dev kit, and the Fenix site still appears broken.

Are there publicly available Fenix fonts we can borrow (not that the default isn't pretty cool, it's just a bit small).

Amusingly enough, I also needed longs while Fenix only has ints. I ended up building my own arbitrary length mathematics function. Yes, I'm actually making a game, not an app... Consider this a teaser... :)
 
You could use an unsigned int, if you don't need the negative numbers. You could also use a float, but that's not entirely awesome for larger numbers.
 
Sandman said:
You could use an unsigned int, if you don't need the negative numbers. You could also use a float, but that's not entirely awesome for larger numbers.
Unsigned int isn't big enough... I need more, MORE, *MORE*! BWAHAHAHAHA! But I'm all good now. I have a nice fast working library that does arbitrary length multiplication that doesn't memory leak.

Can anyone tell me about Fenix fonts? I could just swipe them from other games, but it's bad form..
 
Last edited by a moderator:
On Windows you can use ttf.dll to load a TTF and then save it as a fenix font with save_fnt(). This way you can use it on any platform, including the GP2X.
TTF.dll does a nice job imo. I don't know if there is an official 0.92a TTF.dll, but I recompiled it anyway.
 
Sandman said:
On Windows you can use ttf.dll to load a TTF and then save it as a fenix font with save_fnt(). This way you can use it on any platform, including the GP2X.
TTF.dll does a nice job imo. I don't know if there is an official 0.92a TTF.dll, but I recompiled it anyway.



Awesome, I'll have to give that a try.
 
Last edited by a moderator:
Sandman said:
On Windows you can use ttf.dll to load a TTF and then save it as a fenix font with save_fnt(). This way you can use it on any platform, including the GP2X.
TTF.dll does a nice job imo. I don't know if there is an official 0.92a TTF.dll, but I recompiled it anyway.



Are there any good instructions on how to use ttf.dll out there? I appear to be missing freetype.dll, and I know there's a freetype sourceforge project, but beyond that I'm lost...
 
Last edited by a moderator:
Back
Top