1
0
Fork 0

Remove clouds when in void

objects
Wuzzy 2017-06-11 02:34:34 +02:00
parent ea841eecfb
commit 8773c4b52f
3 changed files with 5 additions and 5 deletions

View File

@ -92,7 +92,7 @@ end
rain.remove_player = function(player)
local player_meta = weather.players[player:get_player_name()]
if player_meta ~= nil and player_meta.origin_sky ~= nil then
player:set_sky(player_meta.origin_sky[1], player_meta.origin_sky[2], player_meta.origin_sky[3])
player:set_sky(player_meta.origin_sky[1], player_meta.origin_sky[2], player_meta.origin_sky[3], true)
player:set_clouds({color="#FFF0F0E5"})
weather.players[player:get_player_name()] = nil
end

View File

@ -75,7 +75,7 @@ skycolor = {
for _, player in ipairs(players) do
local pos = player:getpos()
if pos.y >= mcl_vars.mg_bedrock_overworld_max then
player:set_sky(color, "plain", nil)
player:set_sky(color, "plain", nil, true)
end
end
end,
@ -113,7 +113,7 @@ skycolor = {
for _, player in ipairs(players) do
local pos = player:getpos()
if pos.y >= mcl_vars.mg_bedrock_overworld_max then
player:set_sky(color, "plain", nil)
player:set_sky(color, "plain", nil, true)
end
end
end,
@ -126,7 +126,7 @@ skycolor = {
for _, player in ipairs(players) do
local pos = player:getpos()
if pos.y >= mcl_vars.mg_bedrock_overworld_max then
player:set_sky(nil, "regular", nil)
player:set_sky(nil, "regular", nil, true)
end
end
end,

View File

@ -178,7 +178,7 @@ minetest.register_globalstep(function(dtime)
-- Apply black sky in the Void and deal Void damage
if pos.y < mcl_vars.mg_bedrock_overworld_max then
-- Player reached the void, set black sky box
player:set_sky("#000000", "plain")
player:set_sky("#000000", "plain", nil, false)
-- FIXME: Sky handling in MCL2 is held together with lots of duct tape.
-- This only works beause weather_pack currently does not touch the sky for players below the height used for this check.
-- There should be a real skybox API.