uniham/init.lua

36 lines
1.1 KiB
Lua
Raw Normal View History

-- Init
uniham = {}
uniham.modpath = minetest.get_modpath(minetest.get_current_modname())
uniham.syspath = uniham.modpath..DIR_DELIM..'system'
-- Register replacements for the hammer. Entry ID is the ID of the node to
-- replace and entry value is the ID of the node to replace with.
uniham.replacements = {
2018-09-22 17:33:55 +02:00
-- sefault stone crushing
['default:obsidian'] = 'default:stone',
['default:stone'] = 'default:cobble',
['default:cobble'] = 'default:gravel',
['default:gravel'] = 'default:sand',
2018-09-22 17:33:55 +02:00
-- sandstone types to sand
['default:sandstone'] = 'default:sand',
2018-09-22 17:33:55 +02:00
['default:desert_sandstone'] = 'default:desert_cobble',
['default:desert_cobble'] = 'default:desert_sand',
['default:silver_sandstone'] = 'default:silver_sand',
2018-09-22 01:15:44 +02:00
}
-- Load mod
dofile(uniham.syspath..DIR_DELIM..'use_hammer.lua')
dofile(uniham.syspath..DIR_DELIM..'register_hammer.lua')
dofile(uniham.syspath..DIR_DELIM..'registry.lua')
2018-09-22 01:15:44 +02:00
-- Clean up
2018-09-22 17:28:08 +02:00
--
-- `uniham.register_hammer` is kept available for API purposes
uniham.replacements = nil
uniham.syspath = nil
uniham.modpath = nil
uniham.use_hammer = nil