Font mod: needed files and tools ?


(nUllSkillZ) #1

Hi,

I’m trying to create a font mod.
I’ve found the following files:


/fonts/ariblk_16.dat
/fonts/ariblk_0_16.tga
/fonts/ariblk_27.dat
/fonts/ariblk_0_27.tga
/fonts/ariblk_1_27.tga
/fonts/courbd_21.dat
/fonts/courbd_0_21.tga
/fonts/courbd_30.dat
/fonts/courbd_0_30.tga
/fonts/courbd_1_30.tga

/gfx/2d/consolechars.tga
/gfx/2d/hudchars.tga

/menu/art/font1_prop.tga
/menu/art/font1_prop_glo.tga
/menu/art/font2_prop.tga

/ui/assets/portraits/text_allies.tga
/ui/assets/portraits/text_axis.tga
/ui/assets/portraits/text_win.tga

Are there more files that have to be changed?
Are all of these files used?
Are there any tools to create these files?
(I know the Q3Font-Tool to create the files in the font subfolder.)

Thanks for your help.


(Jaquboss) #2

i dont think there is more, q3font is only tool needed


(nUllSkillZ) #3

Actually the


/gfx/2d/consolechars.tga
/gfx/2d/hudchars.tga

have to be changed too.
The consolechars appear in the console and the hudchars appear in the HUD (in addition to the /fonts/…).
But q3font isn’t able to generate these, isn’t it?


(Ragnar_40k) #4

All characters have the same size, so I guess no dat file is needed for these two (its generated automatically?). Maybe you could edit one character and see if it appears altered in console. As long as you keep roughly the size and position of a character, everything should be safe. Alternativly you could create a font with Q3Font and make the characters match the character grid manually afterwards.

Afaik the dat-files are binary copies of the fontInfo_t structure (defined in q_shared.h) for the specific font.


(nUllSkillZ) #5

Thanks for this idea.
At the moment I’m doing all by hand.
Have to try to copy the letters from a q3font created TGA to the hud-/consolechars TGA.


(Ragnar_40k) #6

I guess the best way would be to edit the characters as a greyscale image and then to use this image as a mask to create the alpha channel in the font tga.
E.g. with Paintshop:[ul][li]Open a font image file (consolechars.tga)
[/li][li]Fill the image with black
[/li][li]Layers->Load/Save Mask->Load Mask From Alpha Channel (promote to full layer if needed)
[/li][]Click “Load”[]Save image with white as background color (and w/o alpha channel)[/ul]and you should have a nice, easy to edit, image.


(nUllSkillZ) #7

Thanks again for the idea Ragnar_40k.
Works great.
I’ve added all of the upper cases now.
Actually this will be some kind of “Lord Of The Ring” font mod.


(Ragnar_40k) #8

Here some inspiration: http://www.dafont.com/search.php?q=lord+of+the+rings
:drink:


(nUllSkillZ) #9

Thanks again for the fonts.
I’ve found already Tolkien.
Which isn’t listed there.
But it looks much like the Stonehenge.


(Ragnar_40k) #10

Any progress?


(nUllSkillZ) #11

Sorry, I haven’t had that much time this week.
Although it should only take a few hours to create this mod.
I’ve “measured” all the No.'s and lower case letters as well now (upper left corner + width + height).


(Schaffer) #12

You will also have to edit the menus since you can only have a maximum of 6 fonts in ET. If you had a set of fonts in the menu which are different in game then you run into problems but only after you start a server.

The menu definitions for the fonts are in both global.menu which links the font and the size and also in menudef.h which allocates the reference identifier. These reference identifiers (probnably a much better name to call them than this) are then used through out the menus to indicate which font to use.

Be careful of the use of some sort of old world style font as this will be very difficult to read


(nUllSkillZ) #13

Thanks for the info Schaffer.
Actually the font I have chosen isn’t readable that good.
Especially in lower resolutions (don’t know if it’s my TFT).

I think the letters shouldn’t be too small.
It should be a bold font type.
And if the TGA’s should be changed also the width of the letters should be more or less equal (for example: width I = width M).