mirror of
https://github.com/t-affeldt/climate_api.git
synced 2024-11-14 14:40:27 +01:00
16 lines
278 B
Lua
16 lines
278 B
Lua
local default_state = {
|
|
heat = 1,
|
|
humidity = 1,
|
|
wind_x = 0.5,
|
|
wind_z = 0.5,
|
|
time_last_check = 0,
|
|
time_current_day = 1
|
|
}
|
|
|
|
local state = minetest.get_mod_storage()
|
|
|
|
if not state:contains("time_last_check") then
|
|
state:from_table({ fields = default_state })
|
|
end
|
|
|
|
return state |