Add obsidian
authorjojoa1997 <jkanawalliii@earthlink.net>
Sun, 10 Mar 2013 21:01:58 +0000 (17:01 -0400)
committerPilzAdam <pilzadam@minetest.net>
Sun, 17 Mar 2013 16:31:51 +0000 (17:31 +0100)
mods/default/README.txt
mods/default/init.lua
mods/default/textures/default_obsidian.png [new file with mode: 0644]
mods/default/textures/default_obsidian_glass.png [new file with mode: 0644]
mods/default/textures/default_obsidian_shard.png [new file with mode: 0644]

index e4227b952161ca727fbb7bd83a4eb4fd1c59c5fa..ce82282bfc15db0513e3f026d67ba4b2f6914218 100644 (file)
@@ -93,6 +93,11 @@ PilzAdam (WTFPL):
   default_jungleleaves.png
   default_junglesapling.png
   default_junglewood.png
+  default_obsidian_glass.png
+  default_obsidian_shard.png
+
+jojoa1997 (WTFPL):
+  default_obsidian.png
 
 Glass breaking sounds (CC BY 3.0):
   1: http://www.freesound.org/people/cmusounddesign/sounds/71947/
index b0329413104dea5e391258ef5c1da463c06c072a..5453d2d519f52dd2ebeec618b29522484f7c4c2e 100644 (file)
@@ -516,6 +516,21 @@ minetest.register_craft({
        }
 })
 
+minetest.register_craft({
+       output = 'default:obsidian_shard 9',
+       recipe = {
+               {'default:obsidian'}
+       }
+})
+
+minetest.register_craft({
+       output = 'default:obsidian',
+       recipe = {
+               {'default:obsidian_shard', 'default:obsidian_shard', 'default:obsidian_shard'},
+               {'default:obsidian_shard', 'default:obsidian_shard', 'default:obsidian_shard'},
+               {'default:obsidian_shard', 'default:obsidian_shard', 'default:obsidian_shard'},
+       }
+})
 --
 -- Crafting (tool repair)
 --
@@ -534,6 +549,12 @@ minetest.register_craft({
        recipe = "group:sand",
 })
 
+minetest.register_craft({
+       type = "cooking",
+       output = "default:obsidian_glass",
+       recipe = "default:obsidian_shard",
+})
+
 minetest.register_craft({
        type = "cooking",
        output = "default:stone",
@@ -1641,6 +1662,26 @@ minetest.register_node("default:mese", {
 })
 minetest.register_alias("default:mese_block", "default:mese")
 
+
+minetest.register_node("default:obsidian_glass", {
+       description = "Obsidian Glass",
+       drawtype = "glasslike",
+       tiles = {"default_obsidian_glass.png"},
+       is_ground_content = true,
+       paramtype = "light",
+       sunlight_propagates = true,
+       sounds = default.node_sound_glass_defaults(),
+       groups = {snappy=2,cracky=3,oddly_breakable_by_hand=3},
+})
+
+minetest.register_node("default:obsidian", {
+       description = "Obsidian",
+       tiles = {"default_obsidian.png"},
+       is_ground_content = true,
+       sounds = default.node_sound_stone_defaults(),
+       groups = {cracky=1,level=2},
+})
+
 minetest.register_node("default:nyancat", {
        description = "Nyan Cat",
        tiles = {"default_nc_side.png", "default_nc_side.png", "default_nc_side.png",
@@ -1769,6 +1810,11 @@ minetest.register_craftitem("default:scorched_stuff", {
        inventory_image = "default_scorched_stuff.png",
 })
 
+minetest.register_craftitem("default:obsidian_shard", {
+       description = "Obsidian Shard",
+       inventory_image = "default_obsidian_shard.png",
+})
+
 -- Support old code
 function default.spawn_falling_node(p, nodename)
        spawn_falling_node(p, nodename)
@@ -1814,11 +1860,11 @@ minetest.register_on_punchnode(on_punchnode)
 --
 
 default.cool_lava_source = function(pos)
-       minetest.env:set_node(pos, {name="default:stone"})
+       minetest.env:set_node(pos, {name="default:obsidian"})
 end
 
 default.cool_lava_flowing = function(pos)
-       minetest.env:set_node(pos, {name="default:cobble"})
+       minetest.env:set_node(pos, {name="default:stone"})
 end
 
 minetest.register_abm({
diff --git a/mods/default/textures/default_obsidian.png b/mods/default/textures/default_obsidian.png
new file mode 100644 (file)
index 0000000..60a0456
Binary files /dev/null and b/mods/default/textures/default_obsidian.png differ
diff --git a/mods/default/textures/default_obsidian_glass.png b/mods/default/textures/default_obsidian_glass.png
new file mode 100644 (file)
index 0000000..49a1c96
Binary files /dev/null and b/mods/default/textures/default_obsidian_glass.png differ
diff --git a/mods/default/textures/default_obsidian_shard.png b/mods/default/textures/default_obsidian_shard.png
new file mode 100644 (file)
index 0000000..e2e2586
Binary files /dev/null and b/mods/default/textures/default_obsidian_shard.png differ