[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 488: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 488: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 488: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 488: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 488: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 488: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 488: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 488: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 488: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 488: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 488: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 488: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 488: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 488: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 488: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 488: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 488: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 488: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 488: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 488: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 488: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 488: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 488: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 488: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 488: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 488: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/functions.php on line 4787: Cannot modify header information - headers already sent by (output started at [ROOT]/includes/functions.php:3922)
[phpBB Debug] PHP Warning: in file [ROOT]/includes/functions.php on line 4789: Cannot modify header information - headers already sent by (output started at [ROOT]/includes/functions.php:3922)
[phpBB Debug] PHP Warning: in file [ROOT]/includes/functions.php on line 4790: Cannot modify header information - headers already sent by (output started at [ROOT]/includes/functions.php:3922)
[phpBB Debug] PHP Warning: in file [ROOT]/includes/functions.php on line 4791: Cannot modify header information - headers already sent by (output started at [ROOT]/includes/functions.php:3922)
InsideQC Forums • View topic - FTEQW: using TTF for menus and other text

FTEQW: using TTF for menus and other text

Discuss programming topics for the various GPL'd game engine sources.

Moderator: InsideQC Admins

FTEQW: using TTF for menus and other text

Postby JasonX » Sun Aug 21, 2011 8:47 pm

I couldn't find any docs on this, so do you guys know how to make FTEQW stop using the conchars and use a TTF font?

Also, how do i change the mouse icon to be something other than a crosshair?
JasonX
 
Posts: 422
Joined: Tue Apr 21, 2009 2:08 pm

Postby Spike » Sun Aug 21, 2011 10:41 pm

First cvar:
com_parseutf8 1
this cvar will allow FTE to read strings as full UTF-8 strings. Basically stating that whatever happens, a string which is not in the utf-8 charset is a malformed string and that you're willing to accept that...
(quake's regular charset is not utf-8 compatible, which means its generally incompatible with most fonts.
Any decoding errors will disable utf-8 decoding for the rest of the string - mods/players need to use utf-8-safe strings/names. Use the q3-derived markup for funny characters.
A setting of 0 generally fails to make use of custom fonts. I'd like to fix that but for now it tries to play safe. So use a value of 1 for now if you actually want to see your ttf font.

Second cvar:
gl_font foo
This cvar says which font to load.
This can be either a tga/jpeg/png/etc image which is used for the first block of 256 chars, or it can be a ttf file.
As a special extension, it can also be the base name of a ttf file from your windows directory, so if you're on windows, "arial" is usually a valid setting.
Until fairly recently, paths were relative to the exe, rather than the mod. So you might need to prefix with id1/ or fte/ or something.

Third cvar:
vid_conautoscale 1.5
Totally optional, just most fonts look really bad when smaller than 12*12 pixels (default size is 8*8).

Required DLL:
FTE requires the freetype2 library to load ttf fonts.
The FTE team do not currently distribute this library in any form, however, . Specifically, that link will contain a zip with a few directories inside. Inside there is a bin/ subdirectory, which contains a freetype6.dll - you need only this file, and this dll must be copied into the same directory as your fteqw exe in order to enable loading of any ttf fonts.

Bonus feature:
echo ^Ue108
will show you a 'char' which is a lightning gun, regardless of other all settings. You can use that markup for team messages and stuff. There are others in the e1XX range which are other various images. e126 is red armour, e135 is quad, for instance.
.
Spike
 
Posts: 2914
Joined: Fri Nov 05, 2004 3:12 am
Location: UK

Postby JasonX » Sun Aug 21, 2011 11:36 pm

Thank you sir! :)
JasonX
 
Posts: 422
Joined: Tue Apr 21, 2009 2:08 pm


Return to Engine Programming

Who is online

Users browsing this forum: No registered users and 2 guests