mirror of
https://github.com/luanti-org/minetest_game.git
synced 2025-05-20 14:23:16 -04:00
Fix mixed tabs & spaces
This commit is contained in:
parent
ed3bdceabb
commit
d993c846ab
1 changed files with 16 additions and 16 deletions
|
@ -153,17 +153,17 @@ local function purge_effects()
|
||||||
timer = nil
|
timer = nil
|
||||||
end
|
end
|
||||||
-- reset changed player tables to default values
|
-- reset changed player tables to default values
|
||||||
for _, player in ipairs(minetest.get_connected_players()) do
|
for _, player in ipairs(minetest.get_connected_players()) do
|
||||||
if randomize_clouds then
|
if randomize_clouds then
|
||||||
player:set_clouds({})
|
player:set_clouds({})
|
||||||
end
|
end
|
||||||
-- NOTE: set_lighting doesn't allow empty table to reset
|
-- NOTE: set_lighting doesn't allow empty table to reset
|
||||||
player:set_lighting({
|
player:set_lighting({
|
||||||
shadows = {
|
shadows = {
|
||||||
intensity = 0
|
intensity = 0
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
|
|
||||||
|
@ -179,22 +179,22 @@ end)
|
||||||
|
|
||||||
local is_enabled = true
|
local is_enabled = true
|
||||||
weather.is_enabled = function()
|
weather.is_enabled = function()
|
||||||
return settings_enabled and is_enabled
|
return settings_enabled and is_enabled
|
||||||
end
|
end
|
||||||
|
|
||||||
weather.set_enabled = function(enable)
|
weather.set_enabled = function(enable)
|
||||||
if enable and not is_enabled then
|
if enable and not is_enabled then
|
||||||
-- restart stopped update cycle
|
-- restart stopped update cycle
|
||||||
cyclic_update()
|
cyclic_update()
|
||||||
elseif not enable and is_enabled then
|
elseif not enable and is_enabled then
|
||||||
-- stop update cycle and remove effects
|
-- stop update cycle and remove effects
|
||||||
purge_effects()
|
purge_effects()
|
||||||
end
|
end
|
||||||
is_enabled = enable
|
is_enabled = enable
|
||||||
end
|
end
|
||||||
|
|
||||||
weather.on_update = function(player, overrides)
|
weather.on_update = function(player, overrides)
|
||||||
return overrides
|
return overrides
|
||||||
end
|
end
|
||||||
|
|
||||||
-- End API definition
|
-- End API definition
|
||||||
|
|
Loading…
Add table
Reference in a new issue