Rewrite. Reduced size and use alpha instead of images

This commit is contained in:
DonBatman 2015-05-06 10:04:22 -07:00
parent a757537caa
commit ac2d332eff
32 changed files with 25 additions and 26 deletions

View File

@ -3,34 +3,35 @@ dofile(minetest.get_modpath("mymulch").."/machine.lua")
local mulch_tab = {
{"black", "Black", "mymulch_black.png"},
{"blue", "Blue", "mymulch_blue.png"},
{"brown", "Brown", "mymulch_brown.png"},
{"cyan", "Cyan", "mymulch_cyan.png"},
{"dark_green", "Dark Green", "mymulch_dark_green.png"},
{"dark_grey", "Dark Grey", "mymulch_dark_grey.png"},
{"green", "Green", "mymulch_green.png"},
{"grey", "Grey", "mymulch_grey.png"},
{"magenta", "Magenta", "mymulch_magenta.png"},
{"orange", "Orange", "mymulch_orange.png"},
{"pink", "Pink", "mymulch_pink.png"},
{"red", "Red", "mymulch_red.png"},
{"violet", "Violet", "mymulch_violet.png"},
{"white", "White", "mymulch_white.png"},
{"yellow", "Yellow", "mymulch_yellow.png"},
{"tan", "Tan", "mymulch_tan.png"},
{"black", "Black", "mymulch_black.png", "^[colorize:black:240"},
{"blue", "Blue", "mymulch_blue.png", "^[colorize:#0404B4:100"},
{"brown", "Brown", "mymulch_brown.png", "^[colorize:#190B07:160"},
{"cyan", "Cyan", "mymulch_cyan.png", "^[colorize:cyan:120"},
{"dark_green", "Dark Green", "mymulch_dark_green.png", "^[colorize:#071907:200"},
{"dark_grey", "Dark Grey", "mymulch_dark_grey.png", "^[colorize:black:200"},
{"green", "Green", "mymulch_green.png", "^[colorize:green:160"},
{"grey", "Grey", "mymulch_grey.png", "^[colorize:black:150"},
{"magenta", "Magenta", "mymulch_magenta.png", "^[colorize:magenta:160"},
{"orange", "Orange", "mymulch_orange.png", "^[colorize:orange:220"},
{"pink", "Pink", "mymulch_pink.png", "^[colorize:#FE2E9A:200"},
{"red", "Red", "mymulch_red.png", "^[colorize:#B40404:200"},
{"violet", "Violet", "mymulch_violet.png", "^[colorize:#2F0B3A:220"},
{"white", "White", "mymulch_white.png", "^[colorize:white:200"},
{"yellow", "Yellow", "mymulch_yellow.png", "^[colorize:yellow:200"},
{"tan", "Tan", "mymulch_tan.png", ""},
}
for i in ipairs (mulch_tab) do
local mat = mulch_tab[i][1]
local desc = mulch_tab[i][2]
local image = mulch_tab[i][3]
local dye = mulch_tab[i][4]
minetest.register_node("mymulch:mulch_"..mat, {
description = desc.." Mulch",
drawtype = "normal",
tiles = {
image
"mymulch_tan.png"..dye.."^mymulch_top.png"
},
paramtype = "light",
is_ground_content = true,

View File

@ -130,7 +130,7 @@ end,
on_construct = function(pos)
local meta = minetest.env:get_meta(pos)
meta:set_string("formspec", "invsize[8,10;]"..
"background[-0.15,-0.25;8.40,10.75;mysiding_background.png]"..
"background[-0.15,-0.25;8.40,10.75;mymulch_background.png]"..
"label[1.5,0.5; Craft Mulch]"..
"list[current_name;craft1;1.5,1;1,1; ]"..
@ -138,17 +138,15 @@ on_construct = function(pos)
"list[current_name;craft3;2.5,1;1,1; ]"..
"list[current_name;craft4;2.5,2;1,1; ]"..
"button[4,1;1,1;make;Make]"..
-- "label[4.5,1.5;Output:]"..
"list[current_name;res;4,2;1,1;]"..
"label[5,2; +]"..
-- "list[current_name;mulch;7,1;1,1;]"..
"label[5.5,0.5; Dye]"..
"list[current_name;dye;5.5,1;1,1;]"..
"button[5.5,2;1,1;color;Color]"..
"label[5.5,1.5; Dye]"..
"list[current_name;dye;5.5,2;1,1;]"..
"button[5.5,3;1,1;color;Color]"..
"label[5.5,3;Output]"..
"list[current_name;res2;5.5,3.5;1,1;]"..
"label[5.5,4;Output]"..
"list[current_name;res2;5.5,4.5;1,1;]"..
"label[0.5,5.5;2 Mulch = 1 Dirt]"..

View File

@ -26,7 +26,7 @@ minetest.register_node("mymulch:mulch_"..mat, {
description = desc.." Mulch",
drawtype = "normal",
tiles = {
image
"mymulch_tan.png^[colorize:"..mat..":120"
},
paramtype = "light",
is_ground_content = true,

Binary file not shown.

Before

Width:  |  Height:  |  Size: 2.0 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 2.2 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 2.2 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 2.3 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.9 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 307 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 294 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 216 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 309 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 325 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 388 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 343 B

View File

Before

Width:  |  Height:  |  Size: 524 B

After

Width:  |  Height:  |  Size: 524 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 248 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 380 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 678 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 380 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 331 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 293 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 380 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 314 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 380 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 376 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 298 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 387 B

BIN
textures/mymulch_top.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 216 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 380 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 319 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 376 B