Merge remote-tracking branch 'mcl2/master' into testing
|
@ -96,9 +96,8 @@ minetest.register_abm({
|
|||
chance = 1,
|
||||
action = function(pos, node, active_object_count, active_object_count_wider)
|
||||
local light = minetest.get_node_light(pos, nil)
|
||||
local time = minetest.get_us_time()
|
||||
|
||||
if light >= 14 and time > 6000 then
|
||||
if light >= 12 and minetest.get_timeofday() > 0.2 and minetest.get_timeofday() < 0.8 then
|
||||
minetest.set_node(pos, {name="mesecons_solarpanel:solar_panel_on", param2=node.param2})
|
||||
mesecon.receptor_on(pos, mesecon.rules.pplate)
|
||||
end
|
||||
|
@ -112,9 +111,8 @@ minetest.register_abm({
|
|||
chance = 1,
|
||||
action = function(pos, node, active_object_count, active_object_count_wider)
|
||||
local light = minetest.get_node_light(pos, nil)
|
||||
local time = minetest.get_us_time()
|
||||
|
||||
if light < 14 and time > 18000 then
|
||||
if light < 12 then
|
||||
minetest.set_node(pos, {name="mesecons_solarpanel:solar_panel_off", param2=node.param2})
|
||||
mesecon.receptor_off(pos, mesecon.rules.pplate)
|
||||
end
|
||||
|
@ -205,9 +203,8 @@ minetest.register_abm({
|
|||
chance = 1,
|
||||
action = function(pos, node, active_object_count, active_object_count_wider)
|
||||
local light = minetest.get_node_light(pos, nil)
|
||||
local time = minetest.get_us_time()
|
||||
|
||||
if light < 14 and time > 18000 then
|
||||
if light < 12 then
|
||||
minetest.set_node(pos, {name="mesecons_solarpanel:solar_panel_inverted_on", param2=node.param2})
|
||||
mesecon.receptor_on(pos, mesecon.rules.pplate)
|
||||
end
|
||||
|
@ -221,9 +218,8 @@ minetest.register_abm({
|
|||
chance = 1,
|
||||
action = function(pos, node, active_object_count, active_object_count_wider)
|
||||
local light = minetest.get_node_light(pos, nil)
|
||||
local time = minetest.get_us_time()
|
||||
|
||||
if light >= 14 and time > 6000 then
|
||||
if light >= 12 and minetest.get_timeofday() > 0.8 and minetest.get_timeofday() < 0.2 then
|
||||
minetest.set_node(pos, {name="mesecons_solarpanel:solar_panel_inverted_off", param2=node.param2})
|
||||
mesecon.receptor_off(pos, mesecon.rules.pplate)
|
||||
end
|
||||
|
|
|
@ -5,10 +5,11 @@ local mod_doc = minetest.get_modpath("doc")
|
|||
minetest.register_node("mcl_core:glass", {
|
||||
description = S("Glass"),
|
||||
_doc_items_longdesc = S("A decorative and mostly transparent block."),
|
||||
drawtype = "glasslike",
|
||||
drawtype = "glasslike_framed_optional",
|
||||
is_ground_content = false,
|
||||
tiles = {"default_glass.png"},
|
||||
tiles = {"default_glass.png", "default_glass_detail.png"},
|
||||
paramtype = "light",
|
||||
paramtype2 = "glasslikeliquidlevel",
|
||||
sunlight_propagates = true,
|
||||
stack_max = 64,
|
||||
groups = {handy=1, glass=1, building_block=1, material_glass=1},
|
||||
|
@ -39,10 +40,11 @@ function mcl_core.add_stained_glass(desc, recipeitem, colorgroup, color)
|
|||
_doc_items_create_entry = create_entry,
|
||||
_doc_items_entry_name = entry_name,
|
||||
_doc_items_longdesc = longdesc,
|
||||
drawtype = "glasslike",
|
||||
drawtype = "glasslike_framed_optional",
|
||||
is_ground_content = false,
|
||||
tiles = {"mcl_core_glass_"..color..".png"},
|
||||
tiles = {"mcl_core_glass_"..color..".png", "mcl_core_glass_"..color.."_detail.png"},
|
||||
paramtype = "light",
|
||||
paramtype2 = "glasslikeliquidlevel",
|
||||
sunlight_propagates = true,
|
||||
use_texture_alpha = minetest.features.use_texture_alpha_string_modes and "blend" or true,
|
||||
stack_max = 64,
|
||||
|
|
After Width: | Height: | Size: 4.8 KiB |
After Width: | Height: | Size: 4.6 KiB |
After Width: | Height: | Size: 4.6 KiB |
After Width: | Height: | Size: 4.6 KiB |
After Width: | Height: | Size: 4.6 KiB |
After Width: | Height: | Size: 4.6 KiB |
After Width: | Height: | Size: 4.6 KiB |
After Width: | Height: | Size: 4.6 KiB |
After Width: | Height: | Size: 4.6 KiB |
After Width: | Height: | Size: 4.6 KiB |
After Width: | Height: | Size: 4.6 KiB |
After Width: | Height: | Size: 4.6 KiB |
After Width: | Height: | Size: 4.6 KiB |
After Width: | Height: | Size: 4.6 KiB |
After Width: | Height: | Size: 4.6 KiB |
After Width: | Height: | Size: 4.6 KiB |
After Width: | Height: | Size: 4.6 KiB |
|
@ -552,7 +552,8 @@ mcl_damage.register_modifier(function(obj, damage, reason)
|
|||
node = minetest.get_node(pos)
|
||||
end
|
||||
if node then
|
||||
if minetest.registered_nodes[node.name].walkable then
|
||||
local def = minetest.registered_nodes[node.name]
|
||||
if not def or def.walkable then
|
||||
return
|
||||
end
|
||||
if minetest.get_item_group(node.name, "water") ~= 0 then
|
||||
|
|