467 lines
21 KiB
Lua
Executable File
467 lines
21 KiB
Lua
Executable File
local S = minetest.get_translator(minetest.get_current_modname())
|
|
local name = minetest.get_current_modname()
|
|
local path = minetest.get_modpath(name)
|
|
|
|
local hoe_on_place_function = function(wear_divisor) --Copy-past from mcl_farming ( in mc it local func adn can 't access to mod ')
|
|
return function(itemstack, user, pointed_thing)
|
|
-- Call on_rightclick if the pointed node defines it
|
|
local node = minetest.get_node(pointed_thing.under)
|
|
if user and not user:get_player_control().sneak then
|
|
if minetest.registered_nodes[node.name] and minetest.registered_nodes[node.name].on_rightclick then
|
|
return minetest.registered_nodes[node.name].on_rightclick(pointed_thing.under, node, user, itemstack) or itemstack
|
|
end
|
|
end
|
|
|
|
if minetest.is_protected(pointed_thing.under, user:get_player_name()) then
|
|
minetest.record_protection_violation(pointed_thing.under, user:get_player_name())
|
|
return itemstack
|
|
end
|
|
|
|
if create_soil(pointed_thing.under, user:get_inventory()) then
|
|
if not minetest.is_creative_enabled(user:get_player_name()) then
|
|
itemstack:add_wear(65535/wear_divisor)
|
|
end
|
|
return itemstack
|
|
end
|
|
end
|
|
end
|
|
|
|
|
|
--delite vanila ores (dont foget make confige for it)
|
|
--[[local ore_for_delite ={"mcl_core:stone_with_coal","mcl_core:stone_with_iron","mcl_core:stone_with_redstone","mcl_core:stone_with_lapis","mcl_core:stone_with_diamond",}
|
|
for i, value in ipairs(ore_for_delite) do
|
|
minetest.unregister_item(ore_for_delite[i])
|
|
end]]
|
|
--wanila res remove !!!!
|
|
|
|
-- 1)tech_name 2)useal name 3)ineed ore ? 4)pickasxe_level 5)color 6)intrument uses
|
|
local metals_ore_array={
|
|
{"iron","Iron ",true,3,"#f7f7f7",125},
|
|
{"copper","Copper ",true,2,"#ff5e00",75},
|
|
{"tin","Tin ",true,2,"#c9c9c9",88},
|
|
{"gold","Gold ",true,2,"#ffe600",50},
|
|
{"silver","Silver ",true,3,"#d1d1d1",62},
|
|
{"lead","Lead ",true,3,"#9092ab",62},
|
|
{"steal","Steal ",false,3,"#575757",300},
|
|
{"bronze","Bronze ",false,3,"#a35900",200},
|
|
}
|
|
--make metals ALL
|
|
for i, value in ipairs(metals_ore_array) do
|
|
--ore
|
|
if metals_ore_array[i][3] then
|
|
minetest.register_node("owl_tech:"..metals_ore_array[i][1].."_ore", {
|
|
description = S(metals_ore_array[i][2].." ore"),
|
|
_doc_items_longdesc = S(metals_ore_array[i][2]..' ore'),
|
|
_doc_items_hidden = false,
|
|
tiles = {"default_stone.png^(owl_tech_ore_base.png^[colorize:"..metals_ore_array[i][5]..":128)"},
|
|
is_ground_content = true,
|
|
stack_max = 64,
|
|
groups = {pickaxey=metals_ore_array[i][4], building_block=1, material_stone=1, blast_furnace_smeltable=1},
|
|
drop = "owl_tech:"..metals_ore_array[i][1].."_ore",
|
|
sounds = mcl_sounds.node_sound_stone_defaults(),
|
|
_mcl_blast_resistance = 3,
|
|
_mcl_hardness = 3,
|
|
_mcl_silk_touch_drop = true,
|
|
})
|
|
end
|
|
--Nugget
|
|
minetest.register_craftitem("owl_tech:"..metals_ore_array[i][1].."_nugget", {
|
|
description = S(metals_ore_array[i][2].. " Nugget"),
|
|
_doc_items_longdesc = S(metals_ore_array[i][2].. " Nugget"),
|
|
inventory_image = "mcl_core_iron_nugget.png^[colorize:"..metals_ore_array[i][5]..":128",
|
|
stack_max = 64,
|
|
groups = { craftitem=1 },
|
|
})
|
|
--Ingot
|
|
minetest.register_craftitem("owl_tech:"..metals_ore_array[i][1].."_ingot", {
|
|
description = S(metals_ore_array[i][2].. " Ingot"),
|
|
_doc_items_longdesc = S(metals_ore_array[i][2].. " Ingot"),
|
|
inventory_image = "default_steel_ingot.png^[colorize:"..metals_ore_array[i][5]..":128",
|
|
stack_max = 64,
|
|
groups = { craftitem=1 },
|
|
})
|
|
--dust
|
|
minetest.register_craftitem("owl_tech:"..metals_ore_array[i][1].."_dust", {
|
|
description = S(metals_ore_array[i][2].. " dust"),
|
|
_doc_items_longdesc = S(metals_ore_array[i][2].. " dust"),
|
|
inventory_image = "owl_tech_dust.png^[colorize:"..metals_ore_array[i][5]..":128",
|
|
stack_max = 64,
|
|
groups = { craftitem=1 },
|
|
})
|
|
--dirt dust
|
|
minetest.register_craftitem("owl_tech:"..metals_ore_array[i][1].."_dirt_dust", {
|
|
description = S(metals_ore_array[i][2].. " dirt dust"),
|
|
_doc_items_longdesc = S(metals_ore_array[i][2].. " dirt dust"),
|
|
inventory_image = "owl_tech_dirt_dust.png^[colorize:"..metals_ore_array[i][5]..":128",
|
|
stack_max = 64,
|
|
groups = { craftitem=1 },
|
|
})
|
|
--plate
|
|
minetest.register_craftitem("owl_tech:"..metals_ore_array[i][1].."_plate", {
|
|
description = S(metals_ore_array[i][2].. " plate"),
|
|
_doc_items_longdesc = S(metals_ore_array[i][2].. " plate"),
|
|
inventory_image = "owl_tech_plate.png^[colorize:"..metals_ore_array[i][5]..":128",
|
|
stack_max = 64,
|
|
groups = { craftitem=1 },
|
|
})
|
|
--pick
|
|
minetest.register_tool("owl_tech:pick_".. metals_ore_array[i][1], {
|
|
description = S( metals_ore_array[i][2].." Pickaxe"),
|
|
_doc_items_longdesc = "Pick from owl tech",
|
|
inventory_image = "(owl_tech_pick_head.png^[colorize:"..metals_ore_array[i][5]..":128)^owl_tech_pick_stick.png", --owl_tech_pick_head.png owl_tech_pick_stick.png
|
|
wield_scale = mcl_vars.tool_wield_scale,
|
|
groups = { tool=1, pickaxe=1, dig_speed_class=4, enchantability=14 },
|
|
tool_capabilities = {
|
|
-- 1/1.2
|
|
full_punch_interval = 0.83333333,
|
|
max_drop_level=4,
|
|
damage_groups = {fleshy=4},
|
|
punch_attack_uses = (metals_ore_array[i][6]),
|
|
},
|
|
sound = { breaks = "default_tool_breaks" },
|
|
_repair_material = "owl_tech:"..metals_ore_array[i][1].."_ingot",
|
|
_mcl_toollike_wield = true,
|
|
_mcl_diggroups = {
|
|
pickaxey = { speed = 6, level = 4, uses = metals_ore_array[i][6]*2}
|
|
},
|
|
})
|
|
-- make pick head
|
|
minetest.register_craftitem("owl_tech:pick_head_"..metals_ore_array[i][1], {
|
|
description = S("Pick head "..metals_ore_array[i][1]),
|
|
_doc_items_longdesc = S("Pick head use for crafte pick in any place"),
|
|
inventory_image = "(owl_tech_pick_head.png^[colorize:"..metals_ore_array[i][5]..":128)",
|
|
stack_max = 64,
|
|
groups = { craftitem=1 },
|
|
})
|
|
--Crafte pick from pick head
|
|
minetest.register_craft({
|
|
type = "shapeless",
|
|
output = "owl_tech:pick_"..metals_ore_array[i][1],
|
|
recipe = {"owl_tech:pick_head"..metals_ore_array[i][1],"mcl_core:stick"}
|
|
})
|
|
--axe
|
|
minetest.register_tool("owl_tech:axe_".. metals_ore_array[i][1], {
|
|
description = S(metals_ore_array[i][2].." axe"),
|
|
_doc_items_longdesc = "Axe owl tech",
|
|
inventory_image = "(owl_tech_axe_head.png^[colorize:"..metals_ore_array[i][5]..":128)^owl_tech_pick_stick.png",
|
|
wield_scale = mcl_vars.tool_wield_scale,
|
|
groups = { tool=1, axe=1, dig_speed_class=4, enchantability=14 },
|
|
tool_capabilities = {
|
|
-- 1/0.9
|
|
full_punch_interval = 1.11111111,
|
|
max_drop_level=4,
|
|
damage_groups = {fleshy=9},
|
|
punch_attack_uses = (metals_ore_array[i][6]),
|
|
},
|
|
on_place = make_stripped_trunk,
|
|
sound = { breaks = "default_tool_breaks" },
|
|
_repair_material = "owl_tech:"..metals_ore_array[i][1].."_ingot",
|
|
_mcl_toollike_wield = true,
|
|
_mcl_diggroups = {
|
|
axey = { speed = 6, level = 4, uses = metals_ore_array[i][6]*2 }
|
|
},
|
|
})
|
|
--axe head item
|
|
minetest.register_craftitem("owl_tech:axe_head_"..metals_ore_array[i][1], {
|
|
description = S("Axe head "..metals_ore_array[i][1]),
|
|
_doc_items_longdesc = S("Axe head use for crafte axe in any place"),
|
|
inventory_image = "(owl_tech_axe_head.png^[colorize:"..metals_ore_array[i][5]..":128)",
|
|
stack_max = 64,
|
|
groups = { craftitem=1 },
|
|
})
|
|
--Crafte axe from axe head
|
|
minetest.register_craft({
|
|
type = "shapeless",
|
|
output = "owl_tech:axe_"..metals_ore_array[i][1],
|
|
recipe = {"owl_tech:axe_head"..metals_ore_array[i][1],"mcl_core:stick"}
|
|
})
|
|
--Sword
|
|
minetest.register_tool("owl_tech:sword_"..metals_ore_array[i][1], {
|
|
description = S(metals_ore_array[i][2].." sword"),
|
|
_doc_items_longdesc = "Owl tech sword",
|
|
inventory_image = "(owl_tech_sword_blade.png^[colorize:"..metals_ore_array[i][5]..":128)^owl_tech_sword_stick.png",
|
|
wield_scale = mcl_vars.tool_wield_scale,
|
|
groups = { weapon=1, sword=1, dig_speed_class=4, enchantability=14 },
|
|
tool_capabilities = {
|
|
full_punch_interval = 0.625,
|
|
max_drop_level=4,
|
|
damage_groups = {fleshy=6},
|
|
punch_attack_uses = metals_ore_array[i][6],
|
|
},
|
|
sound = { breaks = "default_tool_breaks" },
|
|
_repair_material = "owl_tech:"..metals_ore_array[i][1].."_ingot",
|
|
_mcl_toollike_wield = true,
|
|
_mcl_diggroups = {
|
|
swordy = { speed = 6, level = 4, uses = metals_ore_array[i][6]*2 },
|
|
swordy_cobweb = { speed = 6, level = 4, uses = metals_ore_array[i][6]*2 }
|
|
},
|
|
})
|
|
--sword head
|
|
minetest.register_craftitem("owl_tech:sword_head_"..metals_ore_array[i][1], {
|
|
description = S("Sword head "..metals_ore_array[i][1]),
|
|
_doc_items_longdesc = S("Sword head use for crafte sword in any place"),
|
|
inventory_image = "(owl_tech_sword_blade.png^[colorize:"..metals_ore_array[i][5]..":128)",
|
|
stack_max = 64,
|
|
groups = { craftitem=1 },
|
|
})
|
|
--Crafte sword from sword head
|
|
minetest.register_craft({
|
|
type = "shapeless",
|
|
output = "owl_tech:sword_"..metals_ore_array[i][1],
|
|
recipe = {"owl_tech:sword_head"..metals_ore_array[i][1],"mcl_core:stick"}
|
|
})
|
|
--shovel
|
|
minetest.register_tool("owl_tech:shovel_"..metals_ore_array[i][1], {
|
|
description = S(metals_ore_array[i][2].." Shovel"),
|
|
_doc_items_longdesc = "Owl tech shovel",
|
|
_doc_items_usagehelp = shovel_use,
|
|
inventory_image = "(owl_tech_shovel_head.png^[colorize:"..metals_ore_array[i][5]..":128)^owl_tech_shovel_stick.png",
|
|
wield_scale = wield_scale,
|
|
groups = { tool=1, shovel=1, dig_speed_class=4, enchantability=14 },
|
|
tool_capabilities = {
|
|
full_punch_interval = 1,
|
|
max_drop_level=4,
|
|
damage_groups = {fleshy=4},
|
|
punch_attack_uses = metals_ore_array[i][6],
|
|
},
|
|
on_place = make_grass_path,
|
|
sound = { breaks = "default_tool_breaks" },
|
|
_repair_material = "owl_tech:"..metals_ore_array[i][1].."_ingot",
|
|
_mcl_toollike_wield = true,
|
|
_mcl_diggroups = {
|
|
shovely = { speed = 6, level = 4, uses = metals_ore_array[i][6]*2 }
|
|
},
|
|
})
|
|
--Shovel head
|
|
minetest.register_craftitem("owl_tech:shovel_head"..metals_ore_array[i][1], {
|
|
description = S("Shovel head "..metals_ore_array[i][1]),
|
|
_doc_items_longdesc = S("Shovel head use for crafte pick in any place"),
|
|
inventory_image = "(owl_tech_pick_head.png^[colorize:"..metals_ore_array[i][5]..":128)",
|
|
stack_max = 64,
|
|
groups = { craftitem=1 },
|
|
})
|
|
--Crafte sword from sword head
|
|
minetest.register_craft({
|
|
type = "shapeless",
|
|
output = "owl_tech:shovel_"..metals_ore_array[i][1],
|
|
recipe = {"owl_tech:shovel_head"..metals_ore_array[i][1],"mcl_core:stick"}
|
|
})
|
|
--Hoe
|
|
minetest.register_tool("owl_tech:hoe_"..metals_ore_array[i][1], {
|
|
description = S(metals_ore_array[i][1].." Hoe"),
|
|
--_tt_help = hoe_tt.."\n"..S("Uses: @1", uses.iron),
|
|
_doc_items_longdesc = "Owl tech hoe",
|
|
inventory_image = "(owl_tech_hoe_head.png^[colorize:"..metals_ore_array[i][5]..":128)^owl_tech_hoe_stick.png",
|
|
wield_scale = mcl_vars.tool_wield_scale,
|
|
on_place = hoe_on_place_function(metals_ore_array[i][6]),
|
|
groups = { tool=1, hoe=1, enchantability=14 },
|
|
tool_capabilities = {
|
|
-- 1/3
|
|
full_punch_interval = 0.33333333,
|
|
damage_groups = { fleshy = 1, },
|
|
punch_attack_uses = metals_ore_array[i][6],
|
|
},
|
|
_repair_material = "mcl_core:iron_ingot",
|
|
_mcl_toollike_wield = true,
|
|
_mcl_diggroups = {
|
|
hoey = { speed = 6, level = 4, uses = 251 }
|
|
},
|
|
})
|
|
--Hoe head
|
|
minetest.register_craftitem("owl_tech:hoe_head_"..metals_ore_array[i][1], {
|
|
description = S("Hoe head "..metals_ore_array[i][1]),
|
|
_doc_items_longdesc = S("Hoe head use for crafte hoe in any place"),
|
|
inventory_image = "(owl_tech_hoe_head.png^[colorize:"..metals_ore_array[i][5]..":128)",
|
|
stack_max = 64,
|
|
groups = { craftitem=1 },
|
|
})
|
|
--Crafte hoe from hoe head
|
|
minetest.register_craft({
|
|
type = "shapeless",
|
|
output = "owl_tech:hoe_"..metals_ore_array[i][1],
|
|
recipe = {"owl_tech:hoe_head"..metals_ore_array[i][1],"mcl_core:stick"}
|
|
})
|
|
--stick
|
|
minetest.register_craftitem("owl_tech:"..metals_ore_array[i][1].."_stick", {
|
|
description = S(metals_ore_array[i][2].. " stick"),
|
|
_doc_items_longdesc = S(metals_ore_array[i][2].. " stick"),
|
|
inventory_image = "owl_tech_stick.png^[colorize:"..metals_ore_array[i][5]..":128",
|
|
stack_max = 64,
|
|
groups = { craftitem=1 },
|
|
})
|
|
--Block
|
|
minetest.register_node("owl_tech:"..metals_ore_array[i][1].."block", {
|
|
description = S("Block of "..metals_ore_array[i][2]),
|
|
_doc_items_longdesc = S("Block of "..metals_ore_array[i][2]),
|
|
tiles = {"default_steel_block.png^[colorize:"..metals_ore_array[i][5]..":128"},
|
|
is_ground_content = false,
|
|
stack_max = 64,
|
|
groups = {pickaxey=metals_ore_array[i][4], building_block=1},
|
|
sounds = mcl_sounds.node_sound_metal_defaults(),
|
|
_mcl_blast_resistance = 6,
|
|
_mcl_hardness = 5,
|
|
})
|
|
--Block dust
|
|
minetest.register_node("owl_tech:"..metals_ore_array[i][1].."_dust_block", {
|
|
description = S("Dust block of "..metals_ore_array[i][2]),
|
|
_doc_items_longdesc = S("Block of "..metals_ore_array[i][2]),
|
|
tiles = {"owl_tech_dust_block_1.png^[colorize:"..metals_ore_array[i][5]..":128"},
|
|
is_ground_content = false,
|
|
stack_max = 64,
|
|
groups = {pickaxey=metals_ore_array[i][4], building_block=1},
|
|
sounds = mcl_sounds.node_sound_metal_defaults(),
|
|
_mcl_blast_resistance = 6,
|
|
_mcl_hardness = 5,
|
|
})
|
|
--Crafte ingot from nugets
|
|
minetest.register_craft({
|
|
type = "shaped",
|
|
output = "owl_tech:"..metals_ore_array[i][1].."_ingot",
|
|
recipe = {
|
|
{"owl_tech:"..metals_ore_array[i][1].."_nugget","owl_tech:"..metals_ore_array[i][1].."_nugget","owl_tech:"..metals_ore_array[i][1].."_nugget"},
|
|
{"owl_tech:"..metals_ore_array[i][1].."_nugget","owl_tech:"..metals_ore_array[i][1].."_nugget","owl_tech:"..metals_ore_array[i][1].."_nugget"},
|
|
{"owl_tech:"..metals_ore_array[i][1].."_nugget","owl_tech:"..metals_ore_array[i][1].."_nugget","owl_tech:"..metals_ore_array[i][1].."_nugget"}
|
|
}
|
|
})
|
|
--Crafte block from ingots
|
|
minetest.register_craft({
|
|
type = "shaped",
|
|
output = "owl_tech:"..metals_ore_array[i][1].."block",
|
|
recipe = {
|
|
{"owl_tech:"..metals_ore_array[i][1].."_ingot","owl_tech:"..metals_ore_array[i][1].."_ingot","owl_tech:"..metals_ore_array[i][1].."_ingot"},
|
|
{"owl_tech:"..metals_ore_array[i][1].."_ingot","owl_tech:"..metals_ore_array[i][1].."_ingot","owl_tech:"..metals_ore_array[i][1].."_ingot"},
|
|
{"owl_tech:"..metals_ore_array[i][1].."_ingot","owl_tech:"..metals_ore_array[i][1].."_ingot","owl_tech:"..metals_ore_array[i][1].."_ingot"}
|
|
}
|
|
})
|
|
--Crafte block dust from ingots
|
|
minetest.register_craft({
|
|
type = "shaped",
|
|
output = "owl_tech:"..metals_ore_array[i][1].."_dust_block",
|
|
recipe = {
|
|
{"owl_tech:"..metals_ore_array[i][1].."_dust","owl_tech:"..metals_ore_array[i][1].."_dust","owl_tech:"..metals_ore_array[i][1].."_dust"},
|
|
{"owl_tech:"..metals_ore_array[i][1].."_dust","owl_tech:"..metals_ore_array[i][1].."_dust","owl_tech:"..metals_ore_array[i][1].."_dust"},
|
|
{"owl_tech:"..metals_ore_array[i][1].."_dust","owl_tech:"..metals_ore_array[i][1].."_dust","owl_tech:"..metals_ore_array[i][1].."_dust"}
|
|
}
|
|
})
|
|
--Crafte ingots from block
|
|
minetest.register_craft({
|
|
type = "shapeless",
|
|
output = "owl_tech:"..metals_ore_array[i][1].."_ingot 9",
|
|
recipe = {"owl_tech:"..metals_ore_array[i][1].."block"}
|
|
})
|
|
--Crafte dust from block
|
|
minetest.register_craft({
|
|
type = "shapeless",
|
|
output = "owl_tech:"..metals_ore_array[i][1].."_dust 9",
|
|
recipe = {"owl_tech:"..metals_ore_array[i][1].."_dust_block"}
|
|
})
|
|
|
|
end
|
|
-- 1)tech_name 2)useal name 3)need ore ? 4)pickasxe_level 5)color 6)gem_base 7)gem_block_base 8)dust_block 9)burn fuel
|
|
|
|
local gems_orew_array={
|
|
{"coal","Coal ",true,1,"#1b1b1b","owl_tech_gem_1.png","owl_tech_gem_block_1.png","owl_tech_dust_block_1.png",80},
|
|
{"sulfur","Sulfur ",true,1,"#c2a800","owl_tech_gem_1.png","owl_tech_gem_block_1.png","owl_tech_dust_block_1.png",0},
|
|
{"saltpeter","Saltpeter ",true,1,"#b3e6ee","owl_tech_gem_1.png","owl_tech_gem_block_1.png","owl_tech_dust_block_1.png",0},
|
|
{"diamond","Diamond ",true,3,"#77cefb","owl_tech_gem_2.png","owl_tech_gem_block_2.png","owl_tech_dust_block_1.png",0},
|
|
|
|
}
|
|
for i, value in ipairs(gems_orew_array) do
|
|
--ore
|
|
if gems_orew_array[i][3] then
|
|
minetest.register_node("owl_tech:"..gems_orew_array[i][1].."_ore", {
|
|
description = S(gems_orew_array[i][2].." ore"),
|
|
_doc_items_longdesc = S(gems_orew_array[i][2]..' ore'),
|
|
_doc_items_hidden = false,
|
|
tiles = {"default_stone.png^(owl_tech_ore_base.png^[colorize:"..gems_orew_array[i][5]..":128)"},
|
|
is_ground_content = true,
|
|
stack_max = 64,
|
|
groups = {pickaxey=gems_orew_array[i][4], building_block=1, material_stone=1, blast_furnace_smeltable=1},
|
|
drop = "owl_tech:coal_ore",
|
|
sounds = mcl_sounds.node_sound_stone_defaults(),
|
|
_mcl_blast_resistance = 3,
|
|
_mcl_hardness = 3,
|
|
_mcl_silk_touch_drop = true,
|
|
})
|
|
end
|
|
--dust
|
|
minetest.register_craftitem("owl_tech:"..gems_orew_array[i][1].."_dust", {
|
|
description = S(gems_orew_array[i][2].. " dust"),
|
|
_doc_items_longdesc = S(gems_orew_array[i][2].. " dust"),
|
|
inventory_image = "owl_tech_dust.png^[colorize:"..gems_orew_array[i][5]..":128",
|
|
stack_max = 64,
|
|
groups = { craftitem=1 },
|
|
})
|
|
--dirt dust
|
|
minetest.register_craftitem("owl_tech:"..gems_orew_array[i][1].."_dirt_dust", {
|
|
description = S(gems_orew_array[i][2].. " dirt dust"),
|
|
_doc_items_longdesc = S(gems_orew_array[i][2].. " dirt dust"),
|
|
inventory_image = "owl_tech_dirt_dust.png^[colorize:"..gems_orew_array[i][5]..":128",
|
|
stack_max = 64,
|
|
groups = { craftitem=1 },
|
|
})
|
|
--gem
|
|
minetest.register_craftitem("owl_tech:"..gems_orew_array[i][1], {
|
|
description = S(gems_orew_array[i][2]),
|
|
_doc_items_longdesc = S(gems_orew_array[i][2]),
|
|
inventory_image = gems_orew_array[i][6].."^[colorize:"..gems_orew_array[i][5]..":128",
|
|
stack_max = 64,
|
|
groups = { craftitem=1 },
|
|
})
|
|
--plate
|
|
minetest.register_craftitem("owl_tech:"..gems_orew_array[i][1].."_plate", {
|
|
description = S(gems_orew_array[i][2].. " plate"),
|
|
_doc_items_longdesc = S(gems_orew_array[i][2].. " plate"),
|
|
inventory_image = "owl_tech_plate.png^[colorize:"..gems_orew_array[i][5]..":128",
|
|
stack_max = 64,
|
|
groups = { craftitem=1 },
|
|
})
|
|
--stick
|
|
minetest.register_craftitem("owl_tech:"..gems_orew_array[i][1].."_stick", {
|
|
description = S(gems_orew_array[i][2].. " stick"),
|
|
_doc_items_longdesc = S(gems_orew_array[i][2].. " stick"),
|
|
inventory_image = "owl_tech_stick.png^[colorize:"..gems_orew_array[i][5]..":128",
|
|
stack_max = 64,
|
|
groups = { craftitem=1 },
|
|
})
|
|
--burn time gem
|
|
if gems_orew_array[i][9]>0 then
|
|
minetest.register_craft({
|
|
type = "fuel",
|
|
recipe = "owl_tech:"..gems_orew_array[i][1],
|
|
burntime = gems_orew_array[i][9],
|
|
})
|
|
end
|
|
--Block
|
|
minetest.register_node("owl_tech:"..gems_orew_array[i][1].."_block", {
|
|
description = S("Block of "..gems_orew_array[i][2]),
|
|
_doc_items_longdesc = S("Block of "..gems_orew_array[i][2]),
|
|
tiles = {gems_orew_array[i][7].."^[colorize:"..gems_orew_array[i][5]..":128"},
|
|
is_ground_content = false,
|
|
stack_max = 64,
|
|
groups = {pickaxey=gems_orew_array[i][4], building_block=1},
|
|
sounds = mcl_sounds.node_sound_metal_defaults(),
|
|
_mcl_blast_resistance = 6,
|
|
_mcl_hardness = 5,
|
|
})
|
|
--burn time block
|
|
if gems_orew_array[i][9]>0 then
|
|
minetest.register_craft({
|
|
type = "fuel",
|
|
recipe = "owl_tech:"..gems_orew_array[i][1].."_block",
|
|
burntime = gems_orew_array[i][9]*9,
|
|
})
|
|
end
|
|
--Block dust
|
|
minetest.register_node("owl_tech:"..gems_orew_array[i][1].."_dust_block", {
|
|
description = S("Block of "..gems_orew_array[i][2]),
|
|
_doc_items_longdesc = S("Block of "..gems_orew_array[i][2]),
|
|
tiles = {gems_orew_array[i][8].."^[colorize:"..gems_orew_array[i][5]..":128"},
|
|
is_ground_content = false,
|
|
stack_max = 64,
|
|
groups = {pickaxey=gems_orew_array[i][4], building_block=1},
|
|
sounds = mcl_sounds.node_sound_metal_defaults(),
|
|
_mcl_blast_resistance = 6,
|
|
_mcl_hardness = 5,
|
|
})
|
|
end |