Module api.lua
-World Data Manager API
-- -
-Functions
-wdata.read (fname) | -Reads config file from world directory. | -||
wdata.write (fname, data[, flags]) | -Writes to config file in world directory. | +api | +World Data Manager API |
Tables
-FlagsDef | -Flags definition. | -
-
- - -
Functions
- --
-
- - - wdata.read (fname) - -
-
- Reads config file from world directory.
-
-
-
Parameters:
--
-
- fname - string - Base filename with optional directory structure (e.g. "my_mod/my_config") - -
Returns:
--
-
- table
- Table with contents read from json file or
nil
. -
- - - - wdata.write (fname, data[, flags]) - -
-
- Writes to config file in world directory.
-
-
-
Parameters:
--
-
- fname - string - Base filename with optional directory structure (e.g. "my_mod/my_config"). - -
- data - table - Table data to be written to config file. - -
- flags - FlagsDef - - - - (optional) - -
Returns:
--
-
- bool
-
true
if succeeded,false
if not. -
-
Tables
- --
-
- - - FlagsDef - -
-
- Flags definition.
-
-
-
Fields:
--
-
- styled
- bool
- Outputs in a human-readable format if this is set (default:
true
). - (optional) -
- - null_to_table
- bool
- "null" values will be converted to tables in output (default:
false
). - (optional) -
-
- - styled
- bool
- Outputs in a human-readable format if this is set (default:
generated by LDoc 1.4.6-antum-dev
-Last updated 2021-08-28 19:42:56
+Last updated 2021-08-28 19:45:59