Commit 01ed125 1 parent 3014af7 commit 01ed125 Copy full SHA for 01ed125
File tree 2 files changed +9
-9
lines changed
2 files changed +9
-9
lines changed Original file line number Diff line number Diff line change @@ -42,18 +42,18 @@ class ConfigManager {
42
42
43
43
/* *
44
44
* @brief Retrieves a float configuration value from the configuration manager, with an optional rounding.
45
- *
45
+ *
46
46
* 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
48
48
* specifies whether the retrieved float should be rounded to two decimal places.
49
- *
49
+ *
50
50
* @param L Pointer to the Lua state. The first argument must be a valid enum key, and the second argument (optional)
51
51
* can be a boolean indicating whether to round the result.
52
- *
52
+ *
53
53
* @return Returns 1 after pushing the result onto the Lua stack, indicating the number of return values.
54
- *
54
+ *
55
55
* @exception reportErrorFunc Throws an error if the first argument is not a valid enum.
56
- *
56
+ *
57
57
* Usage:
58
58
* local result = ConfigManager.getFloat(ConfigKey.SomeKey)
59
59
* local result_rounded = ConfigManager.getFloat(ConfigKey.SomeKey, false)
Original file line number Diff line number Diff line change @@ -19,15 +19,15 @@ class ConfigFunctions final : LuaScriptInterface {
19
19
private:
20
20
/* *
21
21
* @brief Pushes a potentially rounded floating-point configuration value to Lua.
22
- *
22
+ *
23
23
* This function retrieves a configuration value based on the specified key,
24
24
* optionally rounds it to two decimal places to address floating-point precision issues,
25
25
* and then pushes this value to the Lua stack depending on the rounding flag provided.
26
- *
26
+ *
27
27
* @param L Pointer to the Lua state.
28
28
* @param roundFlag A boolean value to determine if rounding should be applied.
29
29
* @return Returns 1, the number of values pushed onto the Lua stack.
30
- *
30
+ *
31
31
* @note If roundFlag is true, the function rounds the float to two decimal places,
32
32
* reducing typical floating-point representation errors.
33
33
*/
You can’t perform that action at this time.
0 commit comments