Rename mod: hardened_clay → mcl_colorblocks
3
mods/mcl_colorblocks/depends.txt
Normal file
|
@ -0,0 +1,3 @@
|
|||
mcl_core
|
||||
mcl_sounds
|
||||
mcl_dye
|
1
mods/mcl_colorblocks/description.txt
Normal file
|
@ -0,0 +1 @@
|
|||
Adds blocks which can be colored, namely hardened clay.
|
65
mods/mcl_colorblocks/init.lua
Normal file
|
@ -0,0 +1,65 @@
|
|||
local init = os.clock()
|
||||
|
||||
local block = {}
|
||||
block.dyes = {
|
||||
{"white", "White", "white"},
|
||||
{"grey", "Grey", "dark_grey"},
|
||||
{"silver", "Light Gray", "grey"},
|
||||
{"black", "Black", "black"},
|
||||
{"red", "Red", "red"},
|
||||
{"yellow", "Yellow", "yellow"},
|
||||
{"green", "Green", "dark_green"},
|
||||
{"cyan", "Cyan", "cyan"},
|
||||
{"blue", "Blue", "blue"},
|
||||
{"magenta", "Magenta", "magenta"},
|
||||
{"orange", "Orange", "orange"},
|
||||
{"purple", "Purple", "violet"},
|
||||
{"brown", "Brown", "brown"},
|
||||
{"pink", "Pink", "pink"},
|
||||
{"lime", "Lime", "green"},
|
||||
{"light_blue", "Light Blue", "lightblue"},
|
||||
}
|
||||
|
||||
minetest.register_node("mcl_colorblocks:hardened_clay", {
|
||||
description = "Hardened Clay",
|
||||
tiles = {"hardened_clay.png"},
|
||||
stack_max = 64,
|
||||
groups = {cracky=3,hardened_clay=1,building_block=1},
|
||||
sounds = mcl_sounds.node_sound_stone_defaults(),
|
||||
})
|
||||
|
||||
minetest.register_craft({
|
||||
type = "cooking",
|
||||
output = "mcl_colorblocks:hardened_clay",
|
||||
recipe = "mcl_core:clay",
|
||||
cooktime = 10,
|
||||
})
|
||||
|
||||
|
||||
for _, row in ipairs(block.dyes) do
|
||||
local name = row[1]
|
||||
local desc = row[2]
|
||||
local craft_color_group = row[3]
|
||||
-- Node Definition
|
||||
minetest.register_node("mcl_colorblocks:hardened_clay_"..name, {
|
||||
description = desc.." Hardened Clay",
|
||||
tiles = {"hardened_clay_stained_"..name..".png"},
|
||||
groups = {cracky=3,hardened_clay=1,building_block=1},
|
||||
stack_max = 64,
|
||||
sounds = mcl_sounds.node_sound_stone_defaults(),
|
||||
})
|
||||
if craft_color_group then
|
||||
minetest.register_craft({
|
||||
output = 'mcl_colorblocks:'..name..' 8',
|
||||
recipe = {
|
||||
{'mcl_colorblocks:hardened_clay', 'mcl_colorblocks:hardened_clay', 'mcl_colorblocks:hardened_clay'},
|
||||
{'mcl_colorblocks:hardened_clay', 'mcl_dye:'..craft_color_group, 'mcl_colorblocks:hardened_clay'},
|
||||
{'mcl_colorblocks:hardened_clay', 'mcl_colorblocks:hardened_clay', 'mcl_colorblocks:hardened_clay'},
|
||||
},
|
||||
})
|
||||
end
|
||||
end
|
||||
|
||||
local time_to_load= os.clock() - init
|
||||
print(string.format("[MOD] "..minetest.get_current_modname().." loaded in %.4f s", time_to_load))
|
||||
|
1
mods/mcl_colorblocks/mod.conf
Normal file
|
@ -0,0 +1 @@
|
|||
name = mcl_colorblocks
|
BIN
mods/mcl_colorblocks/textures/hardened_clay.png
Normal file
After Width: | Height: | Size: 1.7 KiB |
BIN
mods/mcl_colorblocks/textures/hardened_clay_stained_black.png
Normal file
After Width: | Height: | Size: 855 B |
BIN
mods/mcl_colorblocks/textures/hardened_clay_stained_blue.png
Normal file
After Width: | Height: | Size: 1.2 KiB |
BIN
mods/mcl_colorblocks/textures/hardened_clay_stained_brown.png
Normal file
After Width: | Height: | Size: 1.1 KiB |
BIN
mods/mcl_colorblocks/textures/hardened_clay_stained_cyan.png
Normal file
After Width: | Height: | Size: 1.3 KiB |
BIN
mods/mcl_colorblocks/textures/hardened_clay_stained_green.png
Normal file
After Width: | Height: | Size: 1.1 KiB |
BIN
mods/mcl_colorblocks/textures/hardened_clay_stained_grey.png
Normal file
After Width: | Height: | Size: 1 KiB |
After Width: | Height: | Size: 1.2 KiB |
BIN
mods/mcl_colorblocks/textures/hardened_clay_stained_lime.png
Normal file
After Width: | Height: | Size: 1.4 KiB |
BIN
mods/mcl_colorblocks/textures/hardened_clay_stained_magenta.png
Normal file
After Width: | Height: | Size: 1.4 KiB |
BIN
mods/mcl_colorblocks/textures/hardened_clay_stained_orange.png
Normal file
After Width: | Height: | Size: 1.8 KiB |
BIN
mods/mcl_colorblocks/textures/hardened_clay_stained_pink.png
Normal file
After Width: | Height: | Size: 1.8 KiB |
BIN
mods/mcl_colorblocks/textures/hardened_clay_stained_purple.png
Normal file
After Width: | Height: | Size: 1.3 KiB |
BIN
mods/mcl_colorblocks/textures/hardened_clay_stained_red.png
Normal file
After Width: | Height: | Size: 1.3 KiB |
BIN
mods/mcl_colorblocks/textures/hardened_clay_stained_silver.png
Normal file
After Width: | Height: | Size: 1.2 KiB |
BIN
mods/mcl_colorblocks/textures/hardened_clay_stained_white.png
Normal file
After Width: | Height: | Size: 1.5 KiB |
BIN
mods/mcl_colorblocks/textures/hardened_clay_stained_yellow.png
Normal file
After Width: | Height: | Size: 1.8 KiB |