254 lines
6.6 KiB
Lua
254 lines
6.6 KiB
Lua
minetest.register_tool("tapes:ducttape_black", {
|
|
description = "Black Duct Tape",
|
|
inventory_image = "tapes_ducttape_black.png",
|
|
})
|
|
|
|
minetest.register_tool("tapes:surgicaltape", {
|
|
description = "Surgical Tape",
|
|
inventory_image = "tapes_surgicaltape.png",
|
|
on_use = function(itemstack, player, pointed_thing)
|
|
player:set_hp(player:get_hp() + 10)
|
|
itemstack:add_wear(20000)
|
|
return itemstack
|
|
end
|
|
})
|
|
|
|
--Spiketapes
|
|
minetest.register_node("tapes:piece_spiketape_orange", {
|
|
description = "Orange Spiketape Piece",
|
|
drawtype = "raillike",
|
|
paramtype = "light",
|
|
is_ground_content = false,
|
|
sunlight_propagates = true,
|
|
walkable = false,
|
|
tiles = {
|
|
"tapes_piece_spiketape_orange.png",
|
|
"tapes_piece_spiketape_orange_curve.png",
|
|
"tapes_piece_spiketape_orange_t.png",
|
|
"tapes_piece_spiketape_orange_cross.png"
|
|
},
|
|
inventory_image = "tapes_piece_spiketape_orange.png",
|
|
wield_image = "tapes_piece_spiketape_orange.png",
|
|
groups = {tapey = 2, snappy = 1, oddly_breakable_by_hand = 1, not_in_creative_inventory = 1, connect_to_raillike = minetest.raillike_group("spiketape_orange")},
|
|
selection_box = {
|
|
type = "fixed",
|
|
fixed = {-1/2, -1/2, -1/2, 1/2, -1/2+1/16, 1/2},
|
|
},
|
|
|
|
|
|
})
|
|
|
|
minetest.register_node("tapes:piece_spiketape_black", {
|
|
description = "Black Spiketape Piece",
|
|
drawtype = "raillike",
|
|
paramtype = "light",
|
|
is_ground_content = false,
|
|
sunlight_propagates = true,
|
|
walkable = false,
|
|
tiles = {
|
|
"tapes_piece_spiketape_black.png",
|
|
"tapes_piece_spiketape_black_curve.png",
|
|
"tapes_piece_spiketape_black_t.png",
|
|
"tapes_piece_spiketape_black_cross.png"
|
|
},
|
|
inventory_image = "tapes_piece_spiketape_black.png",
|
|
wield_image = "tapes_piece_spiketape_black.png",
|
|
groups = {tapey = 2, snappy = 1, oddly_breakable_by_hand = 1, not_in_creative_inventory = 1, connect_to_raillike = minetest.raillike_group("spiketape_black")},
|
|
selection_box = {
|
|
type = "fixed",
|
|
fixed = {-1/2, -1/2, -1/2, 1/2, -1/2+1/16, 1/2},
|
|
},
|
|
|
|
|
|
})
|
|
|
|
minetest.register_tool("tapes:spiketape_orange", {
|
|
description = "Orange Spiketape",
|
|
inventory_image = "tapes_spiketape_orange.png",
|
|
on_use = function(itemstack, player, pointed_thing)
|
|
minetest.set_node(pointed_thing.above, {name = "tapes:piece_spiketape_orange"})
|
|
itemstack:add_wear(2000)
|
|
return itemstack
|
|
end
|
|
})
|
|
|
|
minetest.register_tool("tapes:spiketape_black", {
|
|
description = "Black Spiketape",
|
|
inventory_image = "tapes_spiketape_black.png",
|
|
on_use = function(itemstack, player, pointed_thing)
|
|
minetest.set_node(pointed_thing.above, {name = "tapes:piece_spiketape_black"})
|
|
itemstack:add_wear(2000)
|
|
return itemstack
|
|
end
|
|
})
|
|
|
|
--Mese Tape
|
|
minetest.register_node("tapes:piece_mesetape", {
|
|
description = "Mese Tape Net",
|
|
drawtype = "signlike",
|
|
paramtype = "light",
|
|
paramtype2 = "wallmounted",
|
|
is_ground_content = false,
|
|
sunlight_propagates = true,
|
|
walkable = false,
|
|
tiles = {"tapes_piece_mesenet.png",},
|
|
inventory_image = "tapes_piece_mesenet.png",
|
|
wield_image = "tapes_piece_mesenet.png",
|
|
groups = {cracky = 1, not_in_creative_inventory = 1},
|
|
|
|
liquid_viscosity = 30,
|
|
liquid_range = 0,
|
|
liquidtype = "source",
|
|
liquid_renewable = false,
|
|
liquid_alternative_flowing = "tapes:piece_mesetape",
|
|
liquid_alternative_source = "tapes:piece_mesetape",
|
|
|
|
selection_box = {
|
|
type = "wallmounted",
|
|
},
|
|
|
|
|
|
})
|
|
|
|
minetest.register_tool("tapes:mesetape", {
|
|
description = "Mese Tape",
|
|
inventory_image = "tapes_mesetape.png",
|
|
on_use = function(itemstack, player, pointed_thing)
|
|
minetest.set_node(pointed_thing.above, {name = "tapes:piece_mesetape", param2 = minetest.dir_to_wallmounted({x = 0, y = -1, z = 0})})
|
|
itemstack:add_wear(5000)
|
|
return itemstack
|
|
end
|
|
})
|
|
|
|
minetest.register_tool("tapes:boxknife", {
|
|
description = "Box Knife",
|
|
inventory_image = "tapes_boxknife.png",
|
|
tool_capabilities = {
|
|
full_punch_interval = 0.5,
|
|
max_drop_level=1,
|
|
groupcaps={
|
|
tapey = {times={[1]=3.50, [2]=1.90, [3]=1.00}, uses=3000},
|
|
snappy = {times={[1]=4.50, [2]=2.90, [3]=2.00}, uses=800},
|
|
fleshy = {times={[1]=2.50, [2]=1.50, [3]=0.50}, uses=1500},
|
|
},
|
|
damage_groups = {fleshy = 6, snappy = 4},
|
|
},
|
|
})
|
|
|
|
--CraftItems
|
|
minetest.register_craftitem("tapes:fabric_thin", {
|
|
description = "Thin Fabric",
|
|
inventory_image = "tapes_thinfabric.png",
|
|
})
|
|
|
|
minetest.register_craftitem("tapes:fabric_thick", {
|
|
description = "Thick Fabric",
|
|
inventory_image = "tapes_thickfabric.png",
|
|
})
|
|
|
|
minetest.register_craftitem("tapes:adhesive_bottle", {
|
|
description = "Adhesive",
|
|
inventory_image = "tapes_adhesive_normal_bottle.png",
|
|
})
|
|
|
|
minetest.register_craftitem("tapes:adhesive_strong_bottle", {
|
|
description = "Strong Adhesive",
|
|
inventory_image = "tapes_adhesive_strong_bottle.png",
|
|
})
|
|
|
|
minetest.register_craftitem("tapes:adhesive_mese_bottle", {
|
|
description = "Mese Adhesive",
|
|
inventory_image = "tapes_adhesive_mese_bottle.png",
|
|
})
|
|
|
|
--Crafts
|
|
minetest.register_craft({
|
|
output = "tapes:fabric_thin",
|
|
recipe = {
|
|
{"", "", ""},
|
|
{"farming:cotton", "farming:cotton", "farming:cotton"},
|
|
{"", "", ""},
|
|
}
|
|
})
|
|
|
|
minetest.register_craft({
|
|
output = "tapes:fabric_thick",
|
|
recipe = {
|
|
{"", "", ""},
|
|
{"tapes:fabric_thin", "tapes:fabric_thin", "tapes:fabric_thin"},
|
|
{"", "", ""},
|
|
}
|
|
})
|
|
|
|
minetest.register_craft({
|
|
output = "tapes:adhesive_bottle",
|
|
recipe = {
|
|
{"", "", ""},
|
|
{"group:leaves", "group:leaves", "group:leaves"},
|
|
{"", "", ""},
|
|
}
|
|
})
|
|
|
|
minetest.register_craft({
|
|
output = "tapes:adhesive_strong_bottle",
|
|
recipe = {
|
|
{"group:leaves", "group:leaves", "group:leaves"},
|
|
{"group:leaves", "group:leaves", "group:leaves"},
|
|
{"group:leaves", "group:leaves", "group:leaves"},
|
|
}
|
|
})
|
|
|
|
minetest.register_craft({
|
|
output = "tapes:adhesive_mese_bottle",
|
|
recipe = {
|
|
{"", "", ""},
|
|
{"tapes:adhesive_strong_bottle", "default:mese_crystal", "tapes:adhesive_strong_bottle"},
|
|
{"", "", ""},
|
|
}
|
|
})
|
|
|
|
minetest.register_craft({
|
|
output = "tapes:mesetape",
|
|
recipe = {
|
|
{"", "", ""},
|
|
{"tapes:adhesive_mese_bottle", "default:mese_block", "tapes:adhesive_mese_bottle"},
|
|
{"", "", ""},
|
|
}
|
|
})
|
|
|
|
minetest.register_craft({
|
|
output = "tapes:spiketape_orange",
|
|
recipe = {
|
|
{"", "dye:orange", ""},
|
|
{"tapes:adhesive_strong_bottle", "tapes:fabric_thick", "tapes:adhesive_strong_bottle"},
|
|
{"", "", ""},
|
|
}
|
|
})
|
|
|
|
minetest.register_craft({
|
|
output = "tapes:spiketape_black",
|
|
recipe = {
|
|
{"", "dye:black", ""},
|
|
{"tapes:adhesive_strong_bottle", "tapes:fabric_thick", "tapes:adhesive_strong_bottle"},
|
|
{"", "", ""},
|
|
}
|
|
})
|
|
|
|
minetest.register_craft({
|
|
output = "tapes:ducttape_black",
|
|
recipe = {
|
|
{"", "dye:black", ""},
|
|
{"tapes:adhesive_strong_bottle", "tapes:fabric_thin", "tapes:adhesive_strong_bottle"},
|
|
{"", "", ""},
|
|
}
|
|
})
|
|
|
|
minetest.register_craft({
|
|
output = "tapes:surgicaltape",
|
|
recipe = {
|
|
{"", "", ""},
|
|
{"tapes:adhesive_bottle", "tapes:fabric_thick", "tapes:adhesive_bottle"},
|
|
{"", "", ""},
|
|
}
|
|
})
|