Guide:INI Syntax: Difference between revisions
m (→Naming Convention: -- more formatting cleanup (I really should use preview next time)) |
mNo edit summary |
||
(3 intermediate revisions by 2 users not shown) | |||
Line 1: | Line 1: | ||
[[Category:Configuration Settings]] | [[Category:Configuration Settings]] | ||
== Introduction == | == Introduction == | ||
INI files are used by all game engines to define various game-specific settings. The most recognizable changes relate to the hardware on which the game is run. On first run of almost every game, the user will be presented with either a configuration menu or a message saying something like, "optimum settings are being detected". This is the game engine assigning INI values for that game. | |||
The most | |||
Other INI settings may be set by the GUI to change '''difficulty''', '''screen size''', '''audio quality''' or many other options that are directly tied to INI parameters. The same result could be accomplished by editing the INI directly, which is why this guide exists: INI settings are often esoteric programming terms that have little meaning to the user, regardless of their experience with that game. | |||
=== | === Naming Convention === | ||
The terms listed below are in [https://en.wikipedia.org/wiki/Hungarian_notation Hungarian Notation]. I.e., the name indicates the type of function the setting changes. | |||
Specifically, the initial letter provides the indication of what is expected in the {{fc|#ddd|value}} part of the setting. ie. the part after the = | |||
===== Common value types: ===== | |||
<code> | * <code>iNumThreads</code> This is an [https://en.wikipedia.org/wiki/Integer_(computer_science) integer], which means any whole number within range (between -2147483648 and 2147483647 for the i32 bit storage typically used in games.) | ||
This | * <code>bHavokDebug</code> This is a [https://en.wikipedia.org/wiki/Boolean_data_type boolean]. The value can be only one of two options: on/off, yes/no, true/false or 1/0 | ||
<code> | * <code>fMaxTime</code> This is a [https://en.wikipedia.org/wiki/Floating_point float] value. The value can be a number with a precision of the first 3-7 significant digits (depending on storage). This is typically used to handle small precise numbers (e.g. 0.6125) or very large numbers (e.g. 800000). The file format accepts also floating point scientific with "e" as the denotation for the power of 10. For very large or very small values it may be preferable to use this. (e.g. 8.5e12 for 8.5 trillion or 4.25e-9 for 4.25 billionths). Most games use Half or Single precision floating point with FastMath type calculation optimizations (favoring speed over precision.) See the linked Wikipedia article for details. | ||
* <code>sStartingCellY</code> This denotes a [https://en.wikipedia.org/wiki/String_(computer_science)#String_datatypes string], a line of text that is read and interpreted as is. "''Text that is shown in game''" or a path, filename or extension recognized by the game | |||
* <code>uTicksToWait</code> The is an unsigned [https://en.wikipedia.org/wiki/Integer_(computer_science) integer], meaning it is an integer where the value can't be negative. | |||
If a setting is placed in the wrong section the game engine SHOULD disregard it, so always be mindful of the [Section Headings]. | |||
If a setting is placed in the wrong section the game engine SHOULD disregard it |
Latest revision as of 20:28, December 8, 2021
Introduction[edit | edit source]
INI files are used by all game engines to define various game-specific settings. The most recognizable changes relate to the hardware on which the game is run. On first run of almost every game, the user will be presented with either a configuration menu or a message saying something like, "optimum settings are being detected". This is the game engine assigning INI values for that game.
Other INI settings may be set by the GUI to change difficulty, screen size, audio quality or many other options that are directly tied to INI parameters. The same result could be accomplished by editing the INI directly, which is why this guide exists: INI settings are often esoteric programming terms that have little meaning to the user, regardless of their experience with that game.
Naming Convention[edit | edit source]
The terms listed below are in Hungarian Notation. I.e., the name indicates the type of function the setting changes.
Specifically, the initial letter provides the indication of what is expected in the value part of the setting. ie. the part after the =
Common value types:[edit | edit source]
iNumThreads
This is an integer, which means any whole number within range (between -2147483648 and 2147483647 for the i32 bit storage typically used in games.)
bHavokDebug
This is a boolean. The value can be only one of two options: on/off, yes/no, true/false or 1/0
fMaxTime
This is a float value. The value can be a number with a precision of the first 3-7 significant digits (depending on storage). This is typically used to handle small precise numbers (e.g. 0.6125) or very large numbers (e.g. 800000). The file format accepts also floating point scientific with "e" as the denotation for the power of 10. For very large or very small values it may be preferable to use this. (e.g. 8.5e12 for 8.5 trillion or 4.25e-9 for 4.25 billionths). Most games use Half or Single precision floating point with FastMath type calculation optimizations (favoring speed over precision.) See the linked Wikipedia article for details.
sStartingCellY
This denotes a string, a line of text that is read and interpreted as is. "Text that is shown in game" or a path, filename or extension recognized by the game
uTicksToWait
The is an unsigned integer, meaning it is an integer where the value can't be negative.
If a setting is placed in the wrong section the game engine SHOULD disregard it, so always be mindful of the [Section Headings].