Files
assaultcube-/config/font.cfg
T
ac-stef b650fca2ca persistidents cleanup
Restore the old persistidents system from AC 1.0, since it's working as
intended - if used properly.

As a reminder:

  * aliases created by "const" and "tempalias" are never persistent
  * aliases created or altered by "alias" or "=" become persistent, if
    the persistidents flag is set during that operation
  * persistidents if false during the execution of almost all config files
    during game start - those files can create aliases with default values
    which will not be persistent (until changed later while the flag is
    set)
  * before saved.cfg is executed, the flag is set and stays set all
    throughout the game - which means, that all changes (from menus, for
    example) will change the altered alias to "persistent"
  * exceptions for map or model config files are unnecessary, since those
    run restricted and can't create aliases anyway
  * exceptions are necessary for "late run" config files like those in
    config/opt/

The new command "persistidents" may be used to manually set or clear the
flag. It also returns the current state of the flag. If used in a config
file, the flag is restored to its original value when the file ends
execution.

In short: only late-run config files (meaning: run after saved.cfg was
restored) may need to manually set/reset the flag. Use const and tempalias
where appropriate and clear persistidents before creating an alias with a
not-to-save default value that may be changed and made persistent later.

DOCREF persistidents
2017-05-05 15:50:59 +02:00

78 lines
2.9 KiB
INI

// To add your own fonts, create a seperate font file and execute like this:
exec config/font_default.cfg // Must be executed! DO NOT MODIFY.
exec config/font_monospace.cfg // Must be executed! DO NOT MODIFY.
exec config/font_serif.cfg
// Then, in that file, define the font. To do this, first define the font file.
// See: ./docs/reference.xml#identifier_font for the command to do this.
// Then, each font character.
// See: ./docs/reference.xml#identifier_fontchar for the command to do this.
// Once defined, you can use the command "setfont" to switch between fonts
// See: ./docs/reference.xml#identifier_setfont
// See the other font files for an example on how to define these fonts.
// Note that the fonts are defined in the particular order shown in the comments.
// You can also use the "TTF2Font" tool to assist you:
// https://sourceforge.net/projects/bloodfrontier/files/Vault/TTF2Font/
// DO NOT MODIFY THE BELOW
// These are used for displaying the HUD, rather than fonts.
// Changing these settings may leave AssaultCube unplayable.
font huddigits "packages/misc/huddigits.png" 40 64
fontskip 47
fontchar 476 64 24 64 // /
fontchar 4 64 40 64 // 0
fontchar 52 64 40 64 // 1
fontchar 100 64 40 64 // 2
fontchar 148 64 40 64 // 3
fontchar 196 64 40 64 // 4
fontchar 244 64 40 64 // 5
fontchar 292 64 40 64 // 6
fontchar 340 64 40 64 // 7
fontchar 388 64 40 64 // 8
fontchar 436 64 40 64 // 9
font serverquality "packages/misc/serverquality.png" 48 64
fontskip 48
fontchar 0 64 48 64 // 0 - "Unknown"
fontchar 48 64 48 64 // 1 - "Very bad"
fontchar 96 64 48 64 // 2 - "Bad"
fontchar 144 64 48 64 // 3 - "Medium"
fontchar 192 64 48 64 // 4 - "Good"
fontchar 240 64 48 64 // 5 - "Very good"
font bargraphs "packages/misc/bargraphs.png" 32 64
fontskip 48
fontchar 0 64 32 64 //0 [ ][ ]
fontchar 32 64 32 64 //1 [x][ ]
fontchar 64 64 32 64 //2 [ ][x]
fontchar 96 64 32 64 //3 [x][x]
fontchar 128 64 64 64 //4 [Black]
fontchar 192 64 64 64 //5 [Green]
fontchar 256 64 64 64 //6 [Yellow]
fontchar 320 64 64 64 //7 [Red]
font radaricons "packages/misc/radaricons.png" 64 64
fontskip 65
fontchar 0 0 64 64 //A red small triangle
fontchar 64 0 64 64 //B red cross
fontchar 128 0 64 64 //C red big triangle
fontchar 192 0 64 64 //D red flag
fontchar 0 64 64 64 //E blue small triangle
fontchar 64 64 64 64 //F blue cross
fontchar 128 64 64 64 //G blue big triangle
fontchar 192 64 64 64 //H blue flag
fontchar 0 128 64 64 //I green small triangle
fontchar 64 128 64 64 //J green cross
fontchar 128 128 64 64 //K green big triangle
fontchar 192 128 64 64 //L yellow flag
fontchar 0 192 64 64 //M red circle
fontchar 64 192 64 64 //N blue circle
fontchar 128 192 64 64 //O green circle