use nodebox for hopper

master
Martin Doege 2015-04-16 13:37:06 +02:00
parent be65b0841e
commit b8745c48fe
6 changed files with 37 additions and 12 deletions

View File

@ -13,7 +13,13 @@ for _, row in ipairs(dye.dyes) do
local desc = string.gsub(" "..str, "%W%l", string.upper):sub(2)
minetest.register_node(cname, {
description = desc,
drawtype = "raillike",
drawtype = "nodebox",
node_box = {
type = "fixed",
fixed = {
{-0.5, -0.5, -0.5, 0.5, -0.5+.5/16, 0.5},
},
},
tiles = {img},
inventory_image = img,
wield_image = img,
@ -23,7 +29,7 @@ minetest.register_node(cname, {
buildable_to = true,
selection_box = {
type = "fixed",
fixed = {-1/2, -1/2, -1/2, 1/2, -1/2+1/16, 1/2},
fixed = {-1/2, -1/2, -1/2, 1/2, -1/2+.5/16, 1/2},
},
groups = {dig_immediate=2},
})

View File

@ -678,6 +678,12 @@ minetest.register_craft({
--
-- Cooking recipes
--
minetest.register_craft({
type = "cooking",
output = "dye:dark_green",
recipe = "default:cactus",
})
minetest.register_craft({
type = "cooking",
output = "default:charcoal",

View File

@ -60,13 +60,13 @@ minetest.register_craft({
dyelocal.mixbases = {"magenta", "red", "orange", "brown", "yellow", "green", "dark_green", "cyan", "blue", "violet", "black", "dark_grey", "grey", "white"}
dyelocal.mixes = {
-- magenta, red, orange, brown, yellow, green, dark_green, cyan, blue, violet, black, dark_grey, grey, white
white = {"pink", "pink", "orange", "orange", "yellow", "green", "green", "grey", "cyan", "violet", "grey", "grey", "white", "white"},
grey = {"pink", "pink", "orange", "orange", "yellow", "green", "green", "grey", "cyan", "pink", "dark_grey","grey", "grey"},
dark_grey={"brown","brown", "brown", "brown", "brown","dark_green","dark_green","blue","blue","violet","black", "black"},
black = {"black", "black", "black", "black", "black", "black", "black", "black", "black", "black", "black"},
violet= {"magenta","magenta","red", "brown", "red", "cyan", "brown", "blue", "violet","violet"},
blue = {"violet", "magenta","brown","brown","dark_green","cyan","cyan", "cyan", "blue"},
-- magenta, red, orange, brown, yellow, green, dark_green, cyan, blue, violet, black, dark_grey, grey, white
white = {"pink", "pink", "orange", "orange", "yellow", "green", "green", "grey", "light_blue", "violet", "dark_grey", "grey", "white", "white"},
grey = {"pink", "pink", "orange", "orange", "yellow", "green", "green", "grey", "cyan", "pink", "dark_grey","grey", "grey"},
dark_grey={"brown","brown", "brown", "brown", "brown","dark_green","dark_green","blue","blue", "violet","black", "black"},
black = {"black", "black", "black", "black", "black", "black", "black", "black", "black", "black", "black"},
violet= {"magenta","magenta","red", "brown", "red", "cyan", "brown", "blue", "violet", "violet"},
blue = {"violet", "violet","brown","brown","dark_green","cyan","cyan", "cyan", "blue"},
cyan = {"blue","brown","dark_green","dark_grey","green","cyan","dark_green","cyan"},
dark_green={"brown","brown","brown", "brown", "green", "green", "dark_green"},
green = {"brown", "yellow","yellow","dark_green","green","green"},

View File

@ -1,7 +1,20 @@
minetest.register_node("hopper:hopper", {
description = "Hopper",
drawtype = "normal",
tiles = {"hopper_top.png", "hopper_outside.png", "hopper_outside.png", "hopper_outside.png", "hopper_outside.png", "hopper_outside.png"},
drawtype = "nodebox",
paramtype = "light",
sunlight_propagates = true,
node_box = {
type = "fixed",
fixed = {
{-16/32, 1/6, -0.5, -12/32, .5, 0.5},
{12/32, 1/6, -0.5, 16/32, .5, 0.5},
{-0.5, 1/6, -16/32, 0.5, .5, -12/32},
{-0.5, 1/6, 12/32, 0.5, .5, 16/32},
{-0.5+2/16, -1/6, -0.5+2/16, 0.5-2/16, 1/6, 0.5-2/16},
{-0.5+4/16, -0.5, -0.5+4/16, 0.5-4/16, -1/6, 0.5-4/16},
},
},
inventory_image = "hopper.png",
groups = {cracky=2,level=1},
})

View File

@ -1,5 +1,5 @@
minetest.register_node("jumping:trampoline", {
description = "Slime block",
description = "Slime Block",
paramtype = "light",
tiles = {
"slime.png",

View File

@ -31,7 +31,7 @@ function mesecon.lightstone_add(name, base_item, texture_off, texture_on)
tiles = {texture_on},
groups = {cracky=2,not_in_creative_inventory=1, mesecon = 2},
drop = "mesecons_lightstone:lightstone_" .. name .. "_off",
light_source = LIGHT_MAX-2,
light_source = LIGHT_MAX-1,
sounds = default.node_sound_stone_defaults(),
mesecons = {effector = {
rules = lightstone_rules,