Page 1 of 1

FONTS

Posted: Thu Jul 13, 2017 11:16 pm
by Marscaleb
I've been working on creating some custom lettering for my mod today. This naturally leads me to ask: what does 3DGE support in terms of fonts?

I notice that edge2.wad has an image in it called "confont2" that is a straight image file of some ASCII-ordered characters, but I don't recognize that font being used anywhere in the game.
If 3DGE does support fonts stored in such a fashion, it would be exceedingly more convenient than saving each glyph as an individual file.

But having said that, I also see the slightly-smaller-than-the-small-font used in the menus is stored in that same wad as individual glyphs, which has me suspicious that 3DGE doesn't support anything other than one glyph per file.

Re: FONTS

Posted: Sun Jul 16, 2017 5:11 pm
by Marscaleb
Oh wait, duh, ConFont2 is the font used in the console. I don't usually use that and I forgot it was there.
Looking at how it is used, I notice that it is displayed as a monospace font, but you aren't using a font that works well in monospace.
I made a new version with an open source monospace font called "Hack." Also I added a black outline to make the font more readable. (Not really an issue with the console itself, but I did it anyway.)
Image
http://i.imgur.com/pGvhQzV.png

I was going to add the extended ASCII characters but I ran into a little trouble with them, so I left it as is.

So I'm pleased to see that we can submit a single image for a whole font, but I don't see any options for editing the spacing. For that matter, how can we go about selecting different fonts? I would be very pleased if I could select different fonts for various things, like in-game menus and dialogue.

(Edit: Whoops! Accidentally put in a second ampersand instead of the dollar sign!)

Re: FONTS

Posted: Mon Jul 17, 2017 12:51 pm
by Corbachu
Cool! Thanks for cleaning that up! I'll pop it in the 3DGE repo ASAP ;)

So, the way fonts are defined is (obviously) via FONTS.DDF. The way they are handled is via STYLES.DDF. The Wiki is sorely lacking on documentation relating to Styles.DDF, so I'll do my best here. I've marked it as a TO-DO.

So, take for example, the MAIN MENU entry:

[MENU] //Main Menu!
BACKGROUND.COLOUR=#000000; // Set Background Color
BACKGROUND.TRANSLUCENCY=64%;
BACKGROUND.IMAGE="NULL";
TEXT.FONT="DOOM"; // Set Text Font (defined in Fonts.ddf)
ALT.FONT="DOOM"; // Set Alternate Font

ALT.COLOURMAP="TEXT_YELLOW"; // Set Colormap for Alternate Font
TITLE.FONT="DOOM";
TITLE.COLOURMAP="TEXT_WHITE";
HELP.FONT="DOOM";
HELP.COLOURMAP="TEXT_GREEN";
SOUND.BEGIN = "SWTCHN"; // These entries set menu sounds!
SOUND.END = "SWTCHX";
SOUND.SELECT = "PISTOL";
SOUND.BACK = "SWTCHN";
SOUND.ERROR = "OOF";
SOUND.MOVE = "PSTOP";
SOUND.SLIDER = "STNMOV";

You can see what fonts are defined where there. So, Text.Font would be the name defined via FONTS.DDF.

The valid Styles are:

DEFAULT, MENU, OPTIONS, MESSAGES, CHAT, AUTOMAP, STATS, NET_STATS, RTS_TIP, CONSOLE (note that the TEXT.FONT options do not apply to the CONSOLE entry), CAST_SCREEN, RTS_MENU, MULTI_MENU, CHOOSE_EPISODE, CHOOSE_SKILL, LOAD_MENU, SAVE_MENU, DIALOG, KEYBOARD_CONTROLS, MOUSE_CONTROLS, GAMEPLAY_OPTIONS, VIDEO_OPTIONS, SET_RESOLUTION, SOUND_VOLUME, ADVANCED (Advanced Graphics), HOST_NETGAME, JOIN_NETGAME, NET_PLAYER_LIST.

So, what you are probably looking for is DIALOG, RTS_MENU, and RTS_TIP if you are using the RTS system for dialog or other stuff. "DEFAULT" will be the default HUD font for messages, which is normally "DOOM".

Re: FONTS

Posted: Tue Jul 18, 2017 12:43 am
by Marscaleb
ah duh, I should have been poking around in the ddf files. I don't know why I didn't think to do that. It's like I haven't touched 3DGE in several months or something.

Anyway, this is some very helpful information! I'll take a closer look at it when the time is right.