Skip to content

Commit 01ed125

Browse files
Code format - (Clang-format)
1 parent 3014af7 commit 01ed125

File tree

2 files changed

+9
-9
lines changed

2 files changed

+9
-9
lines changed

src/config/configmanager.hpp

+6-6
Original file line numberDiff line numberDiff line change
@@ -42,18 +42,18 @@ class ConfigManager {
4242

4343
/**
4444
* @brief Retrieves a float configuration value from the configuration manager, with an optional rounding.
45-
*
45+
*
4646
* This function is a Lua binding used to get a float value from the configuration manager. It requires
47-
* a key as the first argument, which should be a valid enumeration. An optional second boolean argument
47+
* a key as the first argument, which should be a valid enumeration. An optional second boolean argument
4848
* specifies whether the retrieved float should be rounded to two decimal places.
49-
*
49+
*
5050
* @param L Pointer to the Lua state. The first argument must be a valid enum key, and the second argument (optional)
5151
* can be a boolean indicating whether to round the result.
52-
*
52+
*
5353
* @return Returns 1 after pushing the result onto the Lua stack, indicating the number of return values.
54-
*
54+
*
5555
* @exception reportErrorFunc Throws an error if the first argument is not a valid enum.
56-
*
56+
*
5757
* Usage:
5858
* local result = ConfigManager.getFloat(ConfigKey.SomeKey)
5959
* local result_rounded = ConfigManager.getFloat(ConfigKey.SomeKey, false)

src/lua/functions/core/game/config_functions.hpp

+3-3
Original file line numberDiff line numberDiff line change
@@ -19,15 +19,15 @@ class ConfigFunctions final : LuaScriptInterface {
1919
private:
2020
/**
2121
* @brief Pushes a potentially rounded floating-point configuration value to Lua.
22-
*
22+
*
2323
* This function retrieves a configuration value based on the specified key,
2424
* optionally rounds it to two decimal places to address floating-point precision issues,
2525
* and then pushes this value to the Lua stack depending on the rounding flag provided.
26-
*
26+
*
2727
* @param L Pointer to the Lua state.
2828
* @param roundFlag A boolean value to determine if rounding should be applied.
2929
* @return Returns 1, the number of values pushed onto the Lua stack.
30-
*
30+
*
3131
* @note If roundFlag is true, the function rounds the float to two decimal places,
3232
* reducing typical floating-point representation errors.
3333
*/

0 commit comments

Comments
 (0)