lantern glow(WIP)

This commit is contained in:
D00Med 2017-05-11 07:02:33 +10:00
parent a2b305e257
commit 85a2f35ddc

View File

@ -82,6 +82,27 @@ minetest.register_node("decoblocks:lantern", {
end
})
minetest.register_abm({
nodenames = {"decoblocks:lantern"},
interval = 5,
chance = 1,
action = function(pos, node)
minetest.add_particle({
pos = {x=pos.x, y=pos.y, z=pos.z},
velocity = {x=0, y=0, z=0},
acceleration = {x=0, y=0, z=0},
expirationtime = 5,
size = 25,
collisiondetection = false,
collisionremoval = false,
vertical = true,
texture = "decoblocks_glow.png",
animation = {type = "vertical_frames", aspect_w = 32, aspect_h = 32, length = 2.00},
glow = 9
})
end
})
minetest.register_node("decoblocks:lantern_wall", {
drawtype = "mesh",
mesh = "lantern_wall.obj",