From b6c603dc230e3adbc36d2db4bf51113d43005d2c Mon Sep 17 00:00:00 2001 From: Wuzzy Date: Wed, 1 Feb 2017 22:12:08 +0100 Subject: [PATCH] More Minecraft-like light levels --- mods/mcl_core/nodes.lua | 8 ++++++-- mods/mcl_farming/pumpkin.lua | 1 + mods/mcl_fire/init.lua | 1 + mods/mcl_furnaces/init.lua | 2 +- mods/redstone/mesecons_lightstone/init.lua | 1 + mods/redstone/mesecons_torch/init.lua | 2 +- mods/torches/init.lua | 4 ++-- 7 files changed, 13 insertions(+), 6 deletions(-) diff --git a/mods/mcl_core/nodes.lua b/mods/mcl_core/nodes.lua index c1bd3d9b76..f8736c68d0 100644 --- a/mods/mcl_core/nodes.lua +++ b/mods/mcl_core/nodes.lua @@ -100,7 +100,7 @@ minetest.register_node("mcl_core:stone_with_redstone_lit", { description = "Lit Redstone Ore", tiles = {"default_stone.png^default_mineral_redstone.png"}, paramtype = "light", - light_source = 8, + light_source = 9, is_ground_content = true, stack_max = 64, groups = {cracky=2, not_in_creative_inventory=1}, @@ -451,6 +451,7 @@ minetest.register_node("mcl_core:sea_lantern", { paramtype2 = "facedir", is_ground_content = false, stack_max = 64, + -- Real light level: 15 (but Minetest caps at 14) light_source = 14, drop = { max_items = 1, @@ -1235,6 +1236,7 @@ minetest.register_node("mcl_core:lava_flowing", { }, paramtype = "light", paramtype2 = "flowingliquid", + -- Real light level: 15 (but Minetest caps at 14) light_source = 14, walkable = false, pointable = false, @@ -1272,6 +1274,7 @@ minetest.register_node("mcl_core:lava_source", { } }, paramtype = "light", + -- Real light level: 15 (but Minetest caps at 14) light_source = 14, walkable = false, pointable = false, @@ -1446,7 +1449,8 @@ minetest.register_node("mcl_core:glowstone", { {items = {'mcl_core:glowdust 2'}}, } }, - light_source = 12, + -- Real light level: 15 (but Minetest caps at 14) + light_source = 14, sounds = mcl_core.node_sound_stone_defaults(), }) diff --git a/mods/mcl_farming/pumpkin.lua b/mods/mcl_farming/pumpkin.lua index eaf1e33332..0af1280e64 100644 --- a/mods/mcl_farming/pumpkin.lua +++ b/mods/mcl_farming/pumpkin.lua @@ -270,6 +270,7 @@ minetest.register_node("mcl_farming:pumpkin_face_light", { description = "Jack o'Lantern", stack_max = 64, paramtype2 = "facedir", + -- Real light level: 15 (Minetest caps at 14) light_source = 14, tiles = {"farming_pumpkin_top.png", "farming_pumpkin_top.png", "farming_pumpkin_side.png", "farming_pumpkin_side.png", "farming_pumpkin_side.png", "farming_pumpkin_face_light.png"}, groups = {choppy=2, oddly_breakable_by_hand=2, building_block=1}, diff --git a/mods/mcl_fire/init.lua b/mods/mcl_fire/init.lua index f648113dec..c3cfde3324 100644 --- a/mods/mcl_fire/init.lua +++ b/mods/mcl_fire/init.lua @@ -7,6 +7,7 @@ minetest.register_node("mcl_fire:basic_flame", { animation={type="vertical_frames", aspect_w=32, aspect_h=32, length=1}, }}, inventory_image = "fire_basic_flame.png", + -- Real light level: 15 (but Minetest caps at 14) light_source = 14, groups = {igniter=2,dig_immediate=3,dig_by_water=1,not_in_creative_inventory=1}, drop = '', diff --git a/mods/mcl_furnaces/init.lua b/mods/mcl_furnaces/init.lua index 5dbc43850f..d0824df9f0 100644 --- a/mods/mcl_furnaces/init.lua +++ b/mods/mcl_furnaces/init.lua @@ -85,7 +85,7 @@ minetest.register_node("mcl_furnaces:furnace_active", { "default_furnace_side.png", "default_furnace_side.png", "default_furnace_front_active.png"}, paramtype2 = "facedir", is_ground_content = false, - light_source = 12, + light_source = 13, drop = "mcl_furnaces:furnace", groups = {cracky=2, not_in_creative_inventory=1}, sounds = mcl_core.node_sound_stone_defaults(), diff --git a/mods/redstone/mesecons_lightstone/init.lua b/mods/redstone/mesecons_lightstone/init.lua index 74bfd3e54d..49a053adbc 100644 --- a/mods/redstone/mesecons_lightstone/init.lua +++ b/mods/redstone/mesecons_lightstone/init.lua @@ -18,6 +18,7 @@ minetest.register_node("mesecons_lightstone:lightstone_on", { groups = {cracky=2,not_in_creative_inventory=1, mesecon = 2}, drop = "node mesecons_lightstone:lightstone_off", is_ground_content = false, + -- Real light level: 15 (Minetest caps at 14) light_source = 14, sounds = mcl_core.node_sound_stone_defaults(), mesecons = {effector = { diff --git a/mods/redstone/mesecons_torch/init.lua b/mods/redstone/mesecons_torch/init.lua index 84c12f8e9c..8c901d760f 100644 --- a/mods/redstone/mesecons_torch/init.lua +++ b/mods/redstone/mesecons_torch/init.lua @@ -79,7 +79,7 @@ minetest.register_node("mesecons_torch:mesecon_torch_on", { is_ground_content = false, selection_box = torch_selectionbox, groups = {dig_immediate=3, dig_by_water=1}, - light_source = 6, + light_source = 7, description="Redstone Torch", mesecons = {receptor = { state = mesecon.state.on, diff --git a/mods/torches/init.lua b/mods/torches/init.lua index e180e81a7c..20ce71b92f 100644 --- a/mods/torches/init.lua +++ b/mods/torches/init.lua @@ -18,7 +18,7 @@ minetest.register_node("torches:torch", { sunlight_propagates = true, walkable = false, liquids_pointable = false, - light_source = 13, + light_source = 14, groups = {choppy=2, dig_immediate=3, attached_node=1, torch=1, dig_by_water=1, deco_block=1}, drop = "torches:torch", selection_box = { @@ -77,7 +77,7 @@ minetest.register_node("torches:torch_wall", { paramtype2 = "wallmounted", sunlight_propagates = true, walkable = false, - light_source = 13, + light_source = 14, groups = {choppy=2, dig_immediate=3, not_in_creative_inventory=1, attached_node=1, torch=1, dig_by_water=1}, drop = "torches:torch", selection_box = {