Don't Starve Together
Configs Extended
 กระทู้นี้ถูกปักหมุด เพราะฉะนั้นอาจเป็นกระทู้สำคัญ
Remi  [ผู้พัฒนา] 22 มี.ค. @ 1: 02am
Color config example
Since the version 0.4 the mod now supports color config options.
Here's a quick example:

In modinfo.lua:
configuration_options = { -- some other options... { name = "internal_name_here", -- this is passed to GetModConfigData label = "Display Name", -- this is shown to the player options = { {description = "Enable the mod!", data = {0.1,0.2,0.3,1}}, -- make sure... }, default = {0.1,0.2,0.3,1}, -- ...that the 2 color tables are the same is_rgb_config = true, -- or "is_rgba_config = true" if you want opacity to be changeable hover = "Shown when the player hovers their cursor over the option, optional.", }, -- some other options... }

Without comments or any extra fluff:
{ name = "name", label = "label", options = { {description = "desc", data = {0.1,0.2,0.3,1}}, }, default = {0.1,0.2,0.3,1}, is_rgb_config = true, hover = "hover", },

To obtain the value, call GetModConfigData in modmain.lua (or any modimport-ed script) and pass the internal config name as a parameter. The value will always be a table consisting of 4 numbers ranging from 0 to 1, each one representing a color component: red, green, blue, alpha (opacity).