diff options
author | PilzAdam <adam-k@outlook.com> | 2012-11-01 18:49:12 +0100 |
---|---|---|
committer | PilzAdam <adam-k@outlook.com> | 2012-11-01 18:49:12 +0100 |
commit | 7fcf153adab121bfd50b246f32e074adab3a3b6d (patch) | |
tree | 80a4ecd155f29abed596f9874b7f3c5651a83aee /games/minimal/mods/default/init.lua | |
parent | 0443d36abf56c7c62a59940ae696f53e26b4c0de (diff) | |
download | minetest-7fcf153adab121bfd50b246f32e074adab3a3b6d.tar.gz minetest-7fcf153adab121bfd50b246f32e074adab3a3b6d.tar.bz2 minetest-7fcf153adab121bfd50b246f32e074adab3a3b6d.zip |
Add functions to the default mod of minimal game to support old code
Diffstat (limited to 'games/minimal/mods/default/init.lua')
-rw-r--r-- | games/minimal/mods/default/init.lua | 16 |
1 files changed, 16 insertions, 0 deletions
diff --git a/games/minimal/mods/default/init.lua b/games/minimal/mods/default/init.lua index cf2805843..5f4d8e063 100644 --- a/games/minimal/mods/default/init.lua +++ b/games/minimal/mods/default/init.lua @@ -1586,6 +1586,22 @@ minetest.register_alias("mapgen_stone_with_coal", "default:stone_with_coal") minetest.register_alias("mapgen_stone_with_iron", "default:stone_with_iron") minetest.register_alias("mapgen_mese", "default:mese") +-- Support old code +function default.spawn_falling_node(p, nodename) + spawn_falling_node(p, nodename) +end + +-- Horrible crap to support old code +-- Don't use this and never do what this does, it's completely wrong! +-- (More specifically, the client and the C++ code doesn't get the group) +function default.register_falling_node(nodename, texture) + minetest.log("error", debug.traceback()) + minetest.log('error', "WARNING: default.register_falling_node is deprecated") + if minetest.registered_nodes[nodename] then + minetest.registered_nodes[nodename].groups.falling_node = 1 + end +end + -- -- Global callbacks -- |