Improved the compatibility with older versions, and made small change to readme

This commit is contained in:
bas080 2014-06-03 15:31:35 +02:00
parent 22d89767a3
commit 2485345132
2 changed files with 28 additions and 3 deletions

View File

@ -405,7 +405,31 @@
},
})
--ALIASES
minetest.register_alias('bees:hive', 'bees:hive_wild')
minetest.register_alias('bees:hive_artificial_inhabited', 'bees:hive_artificial')
--ALIASES (enable once old nodes have been changed to the new versions)
--minetest.register_alias('bees:hive', 'bees:hive_wild')
--minetest.register_alias('bees:hive_artificial_inhabited', 'bees:hive_artificial')
--COMPATIBILTY --remove after all has been updated
minetest.register_abm({
nodenames = {'bees:hive', 'bees:hive_artificial_inhabited'},
interval = 0,
chance = 1,
action = function(pos, node)
if node.name == 'bees:hive' then
minetest.set_node(pos, { name = 'bees:hive_wild' })
local meta = minetest.get_meta(pos)
local inv = meta:get_inventory()
inv:set_stack('queen', 1, 'bees:queen')
end
if node.name == 'bees:hive_artificial_inhabited' then
minetest.set_node(pos, { name = 'bees:hive_artificial_inhabited' })
local meta = minetest.get_meta(pos)
local inv = meta:get_inventory()
inv:set_stack('queen', 1, 'bees:queen')
local timer = minetest.get_node_timer(pos)
timer:start(60)
end
end,
})
print('[Mod]Bees Loaded!')

View File

@ -15,6 +15,7 @@ FUTURE
- a centrifuge to extract the honey from the frames
- more realistic spawning of wild bee hives
- improved textures
- pipeworks compatibility (Industrial beehive)
CONTRIBUTORS
------------