Use warps object/def

From warps mod by sofar
This commit is contained in:
James Stevenson 2016-07-03 16:17:39 -04:00
parent 26622dd1dd
commit 970dd3fab2
3 changed files with 95 additions and 10 deletions

View file

@ -428,16 +428,31 @@ local function trans_dig(pos, node, digger)
end
end
local newnode = fun_caves.clone_node("default:steelblock")
newnode.description = "Translocator"
newnode.tiles = {'fun_caves_translocator.png'}
newnode.on_rightclick = translocate
newnode.on_use = trans_use
newnode.on_place = trans_place
newnode.on_dig = trans_dig
newnode.stack_max = 1
newnode.groups = {cracky = 3, oddly_breakable_by_hand = 3}
minetest.register_node("fun_caves:translocator", newnode)
minetest.register_node("fun_caves:translocator", {
visual = 'mesh',
mesh = "fun_caves_translocator.obj",
description = 'Translocator',
tiles = {'fun_caves_translocator.png'},
drawtype = 'mesh',
--wield_scale = {x = 1.5, y = 1.5, z = 1.5},
sunlight_propagates = true,
walkable = false,
paramtype = 'light',
paramtype2 = 'facedir',
use_texture_alpha = true,
groups = {cracky = 3, oddly_breakable_by_hand = 3},
light_source = 13,
sounds = default.node_sound_glass_defaults(),
stack_max = 1,
selection_box = {
type = "fixed",
fixed = {-0.25, -0.5, -0.25, 0.25, 0.5, 0.25}
},
on_rightclick = translocate,
on_use = trans_use,
on_place = trans_place,
on_dig = trans_dig,
})
for _, gem in pairs(gems) do
minetest.register_craft({