forked from mtcontrib/weather_pack
improve underwater check #2 for particles displaying
This commit is contained in:
parent
da308cbac2
commit
268fa33638
|
@ -53,8 +53,8 @@ weather.is_underwater = function(player)
|
||||||
local player_eye_pos = {x = ppos.x + offset.x,
|
local player_eye_pos = {x = ppos.x + offset.x,
|
||||||
y = ppos.y + offset.y + 1.5,
|
y = ppos.y + offset.y + 1.5,
|
||||||
z = ppos.z + offset.z}
|
z = ppos.z + offset.z}
|
||||||
|
local node_level = minetest.get_node_level(player_eye_pos)
|
||||||
if minetest.get_node_level(player_eye_pos) == 8 then
|
if node_level == 8 or node_level == 7 then
|
||||||
return true
|
return true
|
||||||
end
|
end
|
||||||
return false
|
return false
|
||||||
|
|
Loading…
Reference in New Issue
Block a user