diff options
Diffstat (limited to 'init.lua')
-rw-r--r-- | init.lua | 66 |
1 files changed, 66 insertions, 0 deletions
diff --git a/init.lua b/init.lua new file mode 100644 index 0000000..fac7378 --- /dev/null +++ b/init.lua @@ -0,0 +1,66 @@ +if minetest.setting_getbool("gloopblocks_lavacooling") ~= false then + --This part comes directly from gloopblocks, just running it here again in case techage changed it + --(it may or may not depending on load order) + default.cool_lava = function(pos, node) + if node.name == "default:lava_source" then + if gloopblocks_search_nearby_nodes(pos,"default:water_source") + or gloopblocks_search_nearby_nodes(pos,"default:water_flowing") then + minetest.set_node(pos, {name="gloopblocks:obsidian_cooled"}) + end + else -- Lava flowing + if gloopblocks_search_nearby_nodes(pos,"default:water_source") then + minetest.set_node(pos, {name="gloopblocks:basalt_cooled"}) + elseif gloopblocks_search_nearby_nodes(pos,"default:water_flowing") then + minetest.set_node(pos, {name="gloopblocks:pumice_cooled"}) + end + end + end +end + +minetest.register_alias_force("techage:basalt_stone","gloopblocks:basalt") + +for nname,def in pairs(minetest.registered_nodes) do + if type(def.tiles) == "table" then + local tiles = table.copy(def.tiles) + local changed = false + for k,v in ipairs(tiles) do + if v == "default_stone.png^[brighten" then + tiles[k] = "gloopblocks_basalt.png" + changed = true + end + end + if changed then + minetest.override_item(nname,{tiles=tiles}) + end + end + if nname == "techage:water_stop" then + def.groups.not_in_creative_inventory = 1 + minetest.override_item(nname,{groups=def.groups}) + end +end + +local unreg = { + "minecart:cart", + "minecart:buffer", + "minecart:cart_pusher", + "minecart:landmark", + "minecart:speed1", + "minecart:speed2", + "minecart:speed4", + "minecart:speed8", + "minecart:terminal", + "techage:chest_cart", + "techage:ta3_cartdetector_off", + "techage:tank_cart", + "techage:ta3_drillbox_pas", + "techage:oil_drillbit", + "techage:ta3_drill_pipe_wrench", + "techage:assembly_tool", + "techage:forceload", + "techage:forceloadtile", + "techage:ta2_quarry_pas", + "techage:ta3_quarry_pas", + "techage:ta4_quarry_pas", +} + +for _,item in ipairs(unreg) do minetest.unregister_item(item) end |