Bugfix and publish
parent
086d399be4
commit
0397b33e53
|
@ -0,0 +1,15 @@
|
||||||
|
According to the origin author PilzAdam at https://forum.minetest.net/viewtopic.php?t=2777 , this mod is under the WTFPL License.
|
||||||
|
|
||||||
|
DO WHAT THE FUCK YOU WANT TO PUBLIC LICENSE
|
||||||
|
Version 2, December 2004
|
||||||
|
|
||||||
|
Copyright (C) 2004 Sam Hocevar <sam@hocevar.net>
|
||||||
|
|
||||||
|
Everyone is permitted to copy and distribute verbatim or modified
|
||||||
|
copies of this license document, and changing it is allowed as long
|
||||||
|
as the name is changed.
|
||||||
|
|
||||||
|
DO WHAT THE FUCK YOU WANT TO PUBLIC LICENSE
|
||||||
|
TERMS AND CONDITIONS FOR COPYING, DISTRIBUTION AND MODIFICATION
|
||||||
|
|
||||||
|
0. You just DO WHAT THE FUCK YOU WANT TO.
|
|
@ -0,0 +1,26 @@
|
||||||
|
local old_nodes = {"modname:foobar_node"}
|
||||||
|
-- TODO: Read list from another file
|
||||||
|
local old_entities = {}
|
||||||
|
|
||||||
|
for _,node_name in ipairs(old_nodes) do
|
||||||
|
minetest.register_node(":"..node_name, {
|
||||||
|
groups = {old=1},
|
||||||
|
})
|
||||||
|
end
|
||||||
|
|
||||||
|
minetest.register_abm({
|
||||||
|
nodenames = {"group:old"},
|
||||||
|
interval = 1,
|
||||||
|
chance = 1,
|
||||||
|
action = function(pos, node)
|
||||||
|
minetest.env:remove_node(pos)
|
||||||
|
end,
|
||||||
|
})
|
||||||
|
|
||||||
|
for _,entity_name in ipairs(old_entities) do
|
||||||
|
minetest.register_entity(":"..entity_name, {
|
||||||
|
on_activate = function(self, staticdata)
|
||||||
|
self.object:remove()
|
||||||
|
end,
|
||||||
|
})
|
||||||
|
end
|
Loading…
Reference in New Issue