override.lua 1.4 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445
  1. -- Prevent the carving of water/lava caves in these materials.
  2. minetest.override_item("rackstone:rackstone", {
  3. is_ground_content = false,
  4. })
  5. minetest.override_item("rackstone:redrack", {
  6. is_ground_content = false,
  7. })
  8. -- We need 2 types of nether stone, 1 type for below the brimstone ocean,
  9. -- and the second type for the nether above. The second type allows caves
  10. -- to be carved through it. That is the main reason for having a new
  11. -- node definition.
  12. -- Make a mapgen-specific copy of this nodetype.
  13. local rdef = table.copy(minetest.registered_nodes["rackstone:redrack"])
  14. rdef.is_ground_content = true
  15. rdef._is_bulk_mapgen_stone = true
  16. rdef.drop = "rackstone:redrack_cobble"
  17. rdef.after_place_node = function(pos) -- In case player manages to obtain.
  18. minetest.swap_node(pos, {name="rackstone:redrack_cobble"})
  19. end
  20. --[[
  21. rdef.drawtype = "airlike"
  22. rdef.paramtype = "light"
  23. rdef.sunlight_propagates = true
  24. rdef.light_source = 15
  25. rdef.pointable = false
  26. --]]
  27. minetest.register_node(":rackstone:mg_redrack", rdef)
  28. -- Make a mapgen-specific copy of this nodetype.
  29. local ddef = table.copy(minetest.registered_nodes["rackstone:rackstone"])
  30. ddef.is_ground_content = true
  31. ddef._is_bulk_mapgen_stone = true
  32. ddef.light_source = rackstone.light_source
  33. ddef.drop = "rackstone:cobble"
  34. ddef.after_place_node = function(pos) -- In case player manages to obtain.
  35. minetest.swap_node(pos, {name="rackstone:cobble"})
  36. end
  37. minetest.register_node(":rackstone:mg_rackstone", ddef)