mirror of
https://github.com/adrido/darkage.git
synced 2025-01-10 01:40:19 +01:00
version 1.0
bugfixes compatibility and dependence with moreblocks added 2 new blocks
This commit is contained in:
parent
c29eeaecfd
commit
082ae7190f
65
building.lua
65
building.lua
@ -1,6 +1,49 @@
|
|||||||
|
minetest.register_node("darkage:glass", {
|
||||||
|
description = "medieval Glass",
|
||||||
|
drawtype = "glasslike",
|
||||||
|
tiles = {"darkage_glass.png"},
|
||||||
|
inventory_image = minetest.inventorycube("darkage_glass.png"),
|
||||||
|
paramtype = "light",
|
||||||
|
sunlight_propagates = true,
|
||||||
|
is_ground_content = true,
|
||||||
|
groups = {snappy=2,cracky=3,oddly_breakable_by_hand=3},
|
||||||
|
sounds = default.node_sound_glass_defaults(),
|
||||||
|
})
|
||||||
|
|
||||||
|
minetest.register_node("darkage:glow_glass", {
|
||||||
|
description = "medieval glow glass",
|
||||||
|
drawtype = "glasslike",
|
||||||
|
tiles = {"darkage_glass.png"},
|
||||||
|
inventory_image = minetest.inventorycube("darkage_glass.png"),
|
||||||
|
paramtype = "light",
|
||||||
|
light_source = 18,
|
||||||
|
sunlight_propagates = true,
|
||||||
|
is_ground_content = true,
|
||||||
|
groups = {snappy=2,cracky=3,oddly_breakable_by_hand=3},
|
||||||
|
sounds = default.node_sound_glass_defaults(),
|
||||||
|
})
|
||||||
|
|
||||||
|
minetest.register_craft({
|
||||||
|
output = 'darkage:glow_glass 1',
|
||||||
|
recipe = {
|
||||||
|
{'darkage:glass', '', ''},
|
||||||
|
{'default:torch', '', ''},
|
||||||
|
{'', '', ''},
|
||||||
|
}
|
||||||
|
})
|
||||||
|
|
||||||
|
minetest.register_craft({
|
||||||
|
output = 'darkage:glass 8',
|
||||||
|
recipe = {
|
||||||
|
{'default:glass', 'default:steel_ingot', 'default:glass'},
|
||||||
|
{'default:steel_ingot', 'default:glass', 'default:steel_ingot'},
|
||||||
|
{'default:glass', 'default:steel_ingot', 'default:glass'},
|
||||||
|
}
|
||||||
|
})
|
||||||
|
|
||||||
minetest.register_node("darkage:reinforced_chalk", {
|
minetest.register_node("darkage:reinforced_chalk", {
|
||||||
description = "Reinforced Chalk",
|
description = "Reinforced Chalk",
|
||||||
tiles = {"darkage_reinforced_chalk.png"},
|
tiles = {"darkage_chalk.png^darkage_reinforce.png"},
|
||||||
is_ground_content = true,
|
is_ground_content = true,
|
||||||
groups = {cracky=3},
|
groups = {cracky=3},
|
||||||
sounds = default.node_sound_stone_defaults()
|
sounds = default.node_sound_stone_defaults()
|
||||||
@ -8,7 +51,7 @@ minetest.register_node("darkage:reinforced_chalk", {
|
|||||||
|
|
||||||
minetest.register_node("darkage:reinforced_wood", {
|
minetest.register_node("darkage:reinforced_wood", {
|
||||||
description = "Reinforced Wood",
|
description = "Reinforced Wood",
|
||||||
tiles = {"darkage_reinforced_wood.png"},
|
tiles = {"default_wood.png^darkage_reinforce.png"},
|
||||||
is_ground_content = true,
|
is_ground_content = true,
|
||||||
groups = {snappy=2,choppy=3,oddly_breakable_by_hand=3,flammable=3},
|
groups = {snappy=2,choppy=3,oddly_breakable_by_hand=3,flammable=3},
|
||||||
sounds = default.node_sound_wood_defaults()
|
sounds = default.node_sound_wood_defaults()
|
||||||
@ -31,15 +74,6 @@ minetest.register_node("darkage:reinforced_wood_left", {
|
|||||||
})
|
})
|
||||||
|
|
||||||
|
|
||||||
minetest.register_node("darkage:reinforced_wood", {
|
|
||||||
description = "Reinforced Wood",
|
|
||||||
tiles = {"darkage_reinforced_wood.png"},
|
|
||||||
is_ground_content = true,
|
|
||||||
groups = {snappy=2,choppy=3,oddly_breakable_by_hand=3,flammable=3},
|
|
||||||
sounds = default.node_sound_stone_defaults()
|
|
||||||
})
|
|
||||||
|
|
||||||
|
|
||||||
minetest.register_craft({
|
minetest.register_craft({
|
||||||
output = 'darkage:reinforced_chalk',
|
output = 'darkage:reinforced_chalk',
|
||||||
recipe = {
|
recipe = {
|
||||||
@ -49,6 +83,15 @@ minetest.register_craft({
|
|||||||
}
|
}
|
||||||
})
|
})
|
||||||
|
|
||||||
|
minetest.register_craft({
|
||||||
|
output = 'darkage:chalk',
|
||||||
|
recipe = {
|
||||||
|
{'darkage:chalk_powder','darkage:chalk_powder',''},
|
||||||
|
{'darkage:chalk_powder','darkage:chalk_powder',''},
|
||||||
|
{'','',''},
|
||||||
|
}
|
||||||
|
})
|
||||||
|
|
||||||
minetest.register_craft({
|
minetest.register_craft({
|
||||||
output = 'darkage:reinforced_wood',
|
output = 'darkage:reinforced_wood',
|
||||||
recipe = {
|
recipe = {
|
||||||
|
@ -27,7 +27,7 @@ minetest.register_node('darkage:box', {
|
|||||||
paramtype2 = "facedir",
|
paramtype2 = "facedir",
|
||||||
walkable = true,
|
walkable = true,
|
||||||
groups = { snappy = 3 },
|
groups = { snappy = 3 },
|
||||||
sounds = default.node_sound_leaves_defaults(),
|
sounds = default.node_sound_wood_defaults(),
|
||||||
on_construct = function(pos)
|
on_construct = function(pos)
|
||||||
local meta = minetest.env:get_meta(pos)
|
local meta = minetest.env:get_meta(pos)
|
||||||
meta:set_string("formspec",
|
meta:set_string("formspec",
|
||||||
@ -66,7 +66,7 @@ minetest.register_node('darkage:wood_shelves', {
|
|||||||
paramtype2 = "facedir",
|
paramtype2 = "facedir",
|
||||||
walkable = true,
|
walkable = true,
|
||||||
groups = { snappy = 3 },
|
groups = { snappy = 3 },
|
||||||
sounds = default.node_sound_leaves_defaults(),
|
sounds = default.node_sound_wood_defaults(),
|
||||||
on_construct = function(pos)
|
on_construct = function(pos)
|
||||||
local meta = minetest.env:get_meta(pos)
|
local meta = minetest.env:get_meta(pos)
|
||||||
meta:set_string("formspec",
|
meta:set_string("formspec",
|
||||||
|
551
init.lua
551
init.lua
@ -1,3 +1,4 @@
|
|||||||
|
<<<<<<< HEAD
|
||||||
print (" ---- Dark Age is Loading! ---- ")
|
print (" ---- Dark Age is Loading! ---- ")
|
||||||
-- Commend this lines if you don't like some of this features
|
-- Commend this lines if you don't like some of this features
|
||||||
dofile(minetest.get_modpath("darkage").."/mapgen.lua")
|
dofile(minetest.get_modpath("darkage").."/mapgen.lua")
|
||||||
@ -539,3 +540,553 @@ minetest.register_craft({
|
|||||||
}
|
}
|
||||||
})
|
})
|
||||||
|
|
||||||
|
=======
|
||||||
|
print (" ---- Dark Age is Loading! ---- ")
|
||||||
|
-- Commend this lines if you don't like some of this features
|
||||||
|
dofile(minetest.get_modpath("darkage").."/mapgen.lua")
|
||||||
|
dofile(minetest.get_modpath("darkage").."/building.lua")
|
||||||
|
dofile(minetest.get_modpath("darkage").."/furniture.lua")
|
||||||
|
dofile(minetest.get_modpath("darkage").."/stairs.lua")
|
||||||
|
|
||||||
|
----------
|
||||||
|
-- Items
|
||||||
|
----------
|
||||||
|
|
||||||
|
minetest.register_node("darkage:adobe", {
|
||||||
|
description = "Adobe",
|
||||||
|
tiles = {"darkage_adobe.png"},
|
||||||
|
is_ground_content = true,
|
||||||
|
groups = {crumbly=3},
|
||||||
|
sounds = default.node_sound_sand_defaults(),
|
||||||
|
})
|
||||||
|
|
||||||
|
minetest.register_node("darkage:basalt", {
|
||||||
|
description = "Basalt",
|
||||||
|
tiles = {"darkage_basalt.png"},
|
||||||
|
is_ground_content = true,
|
||||||
|
drop = 'darkage:basalt_cobble',
|
||||||
|
groups = {cracky=3},
|
||||||
|
sounds = default.node_sound_stone_defaults()
|
||||||
|
})
|
||||||
|
|
||||||
|
minetest.register_node("darkage:basalt_cobble", {
|
||||||
|
description = "Basalt Cobble",
|
||||||
|
tiles = {"darkage_basalt_cobble.png"},
|
||||||
|
is_ground_content = true,
|
||||||
|
groups = {cracky=3},
|
||||||
|
sounds = default.node_sound_stone_defaults()
|
||||||
|
})
|
||||||
|
|
||||||
|
minetest.register_node("darkage:chalk", {
|
||||||
|
description = "Chalk",
|
||||||
|
tiles = {"darkage_chalk.png"},
|
||||||
|
is_ground_content = true,
|
||||||
|
drop = 'darkage:chalk_powder 2',
|
||||||
|
groups = {crumbly=2,cracky=2},
|
||||||
|
sounds = default.node_sound_stone_defaults()
|
||||||
|
})
|
||||||
|
|
||||||
|
minetest.register_node("darkage:cobble_with_plaster", {
|
||||||
|
description = "Cobblestone With Plaster",
|
||||||
|
tiles = {"darkage_cobble_with_plaster_D.png", "darkage_cobble_with_plaster_B.png", "darkage_cobble_with_plaster_C.png",
|
||||||
|
"darkage_cobble_with_plaster_A.png", "default_cobble.png", "darkage_chalk.png"},
|
||||||
|
is_ground_content = true,
|
||||||
|
paramtype2 = "facedir",
|
||||||
|
drop = 'default:cobble',
|
||||||
|
groups = {cracky=3},
|
||||||
|
sounds = default.node_sound_stone_defaults(),
|
||||||
|
})
|
||||||
|
|
||||||
|
minetest.register_node("darkage:desert_stone_cobble", {
|
||||||
|
description = "Desert Stone Cobble",
|
||||||
|
tiles = {"darkage_desert_stone_cobble.png"},
|
||||||
|
is_ground_content = true,
|
||||||
|
groups = {cracky=3},
|
||||||
|
sounds = default.node_sound_stone_defaults()
|
||||||
|
})
|
||||||
|
|
||||||
|
minetest.register_node("darkage:desert_stone_with_iron", {
|
||||||
|
description = "Desert Iron Ore",
|
||||||
|
tiles = {"default_desert_stone.png^darkage_mineral_iron.png"},
|
||||||
|
is_ground_content = true,
|
||||||
|
groups = {cracky=3},
|
||||||
|
drop = 'default:iron_lump',
|
||||||
|
sounds = default.node_sound_stone_defaults(),
|
||||||
|
})
|
||||||
|
|
||||||
|
minetest.register_node("darkage:darkdirt", {
|
||||||
|
description = "Dark Dirt",
|
||||||
|
tiles = {"darkage_darkdirt.png"},
|
||||||
|
is_ground_content = true,
|
||||||
|
groups = {crumbly=2},
|
||||||
|
sounds = default.node_sound_dirt_defaults(),
|
||||||
|
})
|
||||||
|
|
||||||
|
minetest.register_node("darkage:dry_leaves", {
|
||||||
|
description = "Dry Leaves",
|
||||||
|
tiles = {"darkage_dry_leaves.png"},
|
||||||
|
is_ground_content = true,
|
||||||
|
paramtype = "light",
|
||||||
|
groups = {snappy=3, flammable=2},
|
||||||
|
sounds = default.node_sound_leaves_defaults()
|
||||||
|
})
|
||||||
|
|
||||||
|
minetest.register_node("darkage:gneiss", {
|
||||||
|
description = "Gneiss",
|
||||||
|
tiles = {"darkage_gneiss.png"},
|
||||||
|
is_ground_content = true,
|
||||||
|
groups = {cracky=3},
|
||||||
|
drop = {
|
||||||
|
max_items = 1,
|
||||||
|
items = {
|
||||||
|
{
|
||||||
|
-- player will get cobbles with 1/3 chance
|
||||||
|
items = {'darkage:gneiss_cobble'},
|
||||||
|
rarity = 3,
|
||||||
|
},
|
||||||
|
{
|
||||||
|
items = {'darkage:gneiss'},
|
||||||
|
}
|
||||||
|
}
|
||||||
|
},
|
||||||
|
sounds = default.node_sound_stone_defaults()
|
||||||
|
})
|
||||||
|
|
||||||
|
minetest.register_node("darkage:gneiss_cobble", {
|
||||||
|
description = "Gneiss Cobble",
|
||||||
|
tiles = {"darkage_gneiss_cobble.png"},
|
||||||
|
is_ground_content = true,
|
||||||
|
groups = {cracky=3},
|
||||||
|
sounds = default.node_sound_stone_defaults()
|
||||||
|
})
|
||||||
|
|
||||||
|
minetest.register_node("darkage:marble", {
|
||||||
|
description = "Marble",
|
||||||
|
tiles = {"darkage_marble.png"},
|
||||||
|
is_ground_content = true,
|
||||||
|
groups = {cracky=3},
|
||||||
|
sounds = default.node_sound_stone_defaults()
|
||||||
|
})
|
||||||
|
|
||||||
|
|
||||||
|
minetest.register_node("darkage:mud", {
|
||||||
|
description = "Mud",
|
||||||
|
tiles = {"darkage_mud_up.png","darkage_mud.png"},
|
||||||
|
is_ground_content = true,
|
||||||
|
groups = {crumbly=3},
|
||||||
|
drop = 'darkage:mud_lump 4',
|
||||||
|
sounds = default.node_sound_dirt_defaults({
|
||||||
|
footstep = "",
|
||||||
|
}),
|
||||||
|
})
|
||||||
|
|
||||||
|
minetest.register_node("darkage:ors", {
|
||||||
|
description = "Old Red Sandstone",
|
||||||
|
tiles = {"darkage_ors.png"},
|
||||||
|
is_ground_content = true,
|
||||||
|
drop = 'darkage:ors_cobble',
|
||||||
|
groups = {crumbly=2,cracky=2},
|
||||||
|
sounds = default.node_sound_stone_defaults()
|
||||||
|
})
|
||||||
|
|
||||||
|
minetest.register_node("darkage:ors_cobble", {
|
||||||
|
description = "Old Red Sandstone Cobble",
|
||||||
|
tiles = {"darkage_ors_cobble.png"},
|
||||||
|
is_ground_content = true,
|
||||||
|
groups = {crumbly=2,cracky=2},
|
||||||
|
sounds = default.node_sound_stone_defaults()
|
||||||
|
})
|
||||||
|
|
||||||
|
|
||||||
|
minetest.register_node("darkage:sandstone_cobble", {
|
||||||
|
description = "Sandstone Cobble",
|
||||||
|
tiles = {"darkage_sandstone_cobble.png"},
|
||||||
|
is_ground_content = true,
|
||||||
|
groups = {crumbly=2,cracky=2},
|
||||||
|
sounds = default.node_sound_stone_defaults()
|
||||||
|
})
|
||||||
|
|
||||||
|
minetest.register_node("darkage:serpentine", {
|
||||||
|
description = "Serpentine",
|
||||||
|
tiles = {"darkage_serpentine.png"},
|
||||||
|
is_ground_content = true,
|
||||||
|
groups = {cracky=3},
|
||||||
|
sounds = default.node_sound_stone_defaults()
|
||||||
|
})
|
||||||
|
|
||||||
|
minetest.register_node("darkage:shale", {
|
||||||
|
description = "Shale",
|
||||||
|
tiles = {"darkage_shale.png","darkage_shale.png","darkage_shale_side.png"},
|
||||||
|
is_ground_content = true,
|
||||||
|
groups = {crumbly=2,cracky=2},
|
||||||
|
sounds = default.node_sound_stone_defaults()
|
||||||
|
})
|
||||||
|
|
||||||
|
minetest.register_node("darkage:schist", {
|
||||||
|
description = "Schist",
|
||||||
|
tiles = {"darkage_schist.png"},
|
||||||
|
is_ground_content = true,
|
||||||
|
groups = {cracky=3},
|
||||||
|
sounds = default.node_sound_stone_defaults()
|
||||||
|
})
|
||||||
|
|
||||||
|
minetest.register_node("darkage:silt", {
|
||||||
|
description = "Silt",
|
||||||
|
tiles = {"darkage_silt.png"},
|
||||||
|
is_ground_content = true,
|
||||||
|
groups = {crumbly=3},
|
||||||
|
drop = 'darkage:silt_lump 4',
|
||||||
|
sounds = default.node_sound_dirt_defaults({
|
||||||
|
footstep = "",
|
||||||
|
}),
|
||||||
|
})
|
||||||
|
|
||||||
|
minetest.register_node("darkage:slate", {
|
||||||
|
description = "Slate",
|
||||||
|
tiles = {"darkage_slate.png","darkage_slate.png","darkage_slate_side.png"},
|
||||||
|
is_ground_content = true,
|
||||||
|
drop = 'darkage:slate_cobble',
|
||||||
|
groups = {cracky=2},
|
||||||
|
sounds = default.node_sound_stone_defaults()
|
||||||
|
})
|
||||||
|
|
||||||
|
minetest.register_node("darkage:slate_cobble", {
|
||||||
|
description = "Slate Cobble",
|
||||||
|
tiles = {"darkage_slate_cobble.png"},
|
||||||
|
is_ground_content = true,
|
||||||
|
groups = {cracky=2},
|
||||||
|
sounds = default.node_sound_stone_defaults()
|
||||||
|
})
|
||||||
|
|
||||||
|
minetest.register_node("darkage:slate_tale", {
|
||||||
|
description = "Slate Tale",
|
||||||
|
tiles = {"darkage_slate_tale.png"},
|
||||||
|
is_ground_content = true,
|
||||||
|
groups = {cracky=2},
|
||||||
|
sounds = default.node_sound_stone_defaults()
|
||||||
|
})
|
||||||
|
|
||||||
|
minetest.register_node("darkage:straw", {
|
||||||
|
description = "Straw",
|
||||||
|
tiles = {"darkage_straw.png"},
|
||||||
|
is_ground_content = true,
|
||||||
|
groups = {snappy=3, flammable=2},
|
||||||
|
sounds = default.node_sound_leaves_defaults(),
|
||||||
|
})
|
||||||
|
|
||||||
|
minetest.register_node("darkage:stone_brick", {
|
||||||
|
description = "Stone Brick",
|
||||||
|
tiles = {"darkage_stone_brick.png"},
|
||||||
|
is_ground_content = true,
|
||||||
|
groups = {cracky=3},
|
||||||
|
sounds = default.node_sound_stone_defaults()
|
||||||
|
})
|
||||||
|
|
||||||
|
minetest.register_node("darkage:straw_bale", {
|
||||||
|
description = "Straw Bale",
|
||||||
|
tiles = {"darkage_straw_bale.png"},
|
||||||
|
is_ground_content = true,
|
||||||
|
drop = 'darkage:straw 4',
|
||||||
|
groups = {snappy=2, flammable=2},
|
||||||
|
sounds = default.node_sound_leaves_defaults(),
|
||||||
|
})
|
||||||
|
|
||||||
|
minetest.register_node("darkage:marble", {
|
||||||
|
description = "Marble",
|
||||||
|
tiles = {"darkage_marble.png"},
|
||||||
|
is_ground_content = true,
|
||||||
|
groups = {cracky=2},
|
||||||
|
sounds = default.node_sound_stone_defaults()
|
||||||
|
})
|
||||||
|
|
||||||
|
--minetest.register_node("darkage:marble_tile", { --disabled because texture not found
|
||||||
|
-- description = "Marble Tile",
|
||||||
|
-- tiles = {"darkage_marble_tile.png"},
|
||||||
|
-- is_ground_content = true,
|
||||||
|
-- groups = {cracky=2},
|
||||||
|
-- sounds = default.node_sound_stone_defaults()
|
||||||
|
--})
|
||||||
|
|
||||||
|
---------------
|
||||||
|
-- Overrides
|
||||||
|
---------------
|
||||||
|
minetest.registered_nodes["default:desert_stone"].drop= {
|
||||||
|
max_items = 1,
|
||||||
|
items = {
|
||||||
|
{
|
||||||
|
-- player will get cobbles with 1/3 chance
|
||||||
|
items = {'darkage:desert_stone_cobble'},
|
||||||
|
rarity = 2,
|
||||||
|
},
|
||||||
|
{
|
||||||
|
items = {'default:desert_stone'},
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
---------------
|
||||||
|
-- Crafts Items
|
||||||
|
---------------
|
||||||
|
minetest.register_craftitem("darkage:chalk_powder", {
|
||||||
|
description = "Chalk Powder",
|
||||||
|
inventory_image = "darkage_chalk_powder.png",
|
||||||
|
})
|
||||||
|
|
||||||
|
minetest.register_craftitem("darkage:mud_lump", {
|
||||||
|
description = "Mud Lump",
|
||||||
|
inventory_image = "darkage_mud_lump.png",
|
||||||
|
})
|
||||||
|
|
||||||
|
minetest.register_craftitem("darkage:silt_lump", {
|
||||||
|
description = "Silt Lump",
|
||||||
|
inventory_image = "darkage_silt_lump.png",
|
||||||
|
})
|
||||||
|
|
||||||
|
minetest.register_craftitem("darkage:iron_stick", {
|
||||||
|
description = "Iron Stick",
|
||||||
|
inventory_image = "darkage_iron_stick.png",
|
||||||
|
})
|
||||||
|
|
||||||
|
|
||||||
|
----------
|
||||||
|
-- Crafts
|
||||||
|
----------
|
||||||
|
|
||||||
|
--sand+clay+water+straw
|
||||||
|
|
||||||
|
minetest.register_craft({
|
||||||
|
output = 'darkage:adobe 4',
|
||||||
|
recipe = {
|
||||||
|
{'default:sand','default:sand'},
|
||||||
|
{'default:clay_lump','darkage:straw'},
|
||||||
|
}
|
||||||
|
})
|
||||||
|
|
||||||
|
|
||||||
|
minetest.register_craft({
|
||||||
|
output = 'darkage:basalt_cobble 4',
|
||||||
|
recipe = {
|
||||||
|
{'default:cobble','default:cobble'},
|
||||||
|
{'default:coal_lump','default:coal_lump'},
|
||||||
|
}
|
||||||
|
})
|
||||||
|
|
||||||
|
minetest.register_craft({
|
||||||
|
output = 'darkage:cobble_with_plaster 2',
|
||||||
|
recipe = {
|
||||||
|
{'default:cobble','darkage:chalk_powder'},
|
||||||
|
{'default:cobble','darkage:chalk_powder'},
|
||||||
|
}
|
||||||
|
})
|
||||||
|
|
||||||
|
minetest.register_craft({
|
||||||
|
output = 'darkage:cobble_with_plaster 2',
|
||||||
|
recipe = {
|
||||||
|
{'darkage:chalk_powder','default:cobble'},
|
||||||
|
{'darkage:chalk_powder','default:cobble'},
|
||||||
|
}
|
||||||
|
})
|
||||||
|
|
||||||
|
minetest.register_craft({
|
||||||
|
output = 'darkage:darkdirt 4',
|
||||||
|
recipe = {
|
||||||
|
{'default:dirt','default:dirt'},
|
||||||
|
{'default:gravel','default:gravel'},
|
||||||
|
}
|
||||||
|
})
|
||||||
|
|
||||||
|
minetest.register_craft({
|
||||||
|
output = 'darkage:mud 3',
|
||||||
|
recipe = {
|
||||||
|
{'default:dirt','default:dirt'},
|
||||||
|
{'default:clay_lump','darkage:silt_lump'},
|
||||||
|
}
|
||||||
|
})
|
||||||
|
|
||||||
|
minetest.register_craft({
|
||||||
|
output = 'darkage:mud',
|
||||||
|
recipe = {
|
||||||
|
{'darkage:mud_lump','darkage:mud_lump'},
|
||||||
|
{'darkage:mud_lump','darkage:mud_lump'},
|
||||||
|
}
|
||||||
|
})
|
||||||
|
|
||||||
|
minetest.register_craft({
|
||||||
|
output = 'darkage:ors 4',
|
||||||
|
recipe = {
|
||||||
|
{'default:sandstone','default:sandstone'},
|
||||||
|
{'default:iron_lump','default:sandstone'},
|
||||||
|
}
|
||||||
|
})
|
||||||
|
|
||||||
|
minetest.register_craft({
|
||||||
|
output = 'darkage:ors_cobble 4',
|
||||||
|
recipe = {
|
||||||
|
{'darkage:sandstone_cobble','darkage:sandstone_cobble'},
|
||||||
|
{'default:iron_lump','darkage:sandstone_cobble'},
|
||||||
|
}
|
||||||
|
})
|
||||||
|
|
||||||
|
minetest.register_craft({
|
||||||
|
output = 'darkage:silt 3',
|
||||||
|
recipe = {
|
||||||
|
{'default:sand','default:sand'},
|
||||||
|
{'default:clay_lump','default:clay_lump'},
|
||||||
|
}
|
||||||
|
})
|
||||||
|
|
||||||
|
minetest.register_craft({
|
||||||
|
output = 'darkage:silt',
|
||||||
|
recipe = {
|
||||||
|
{'darkage:silt_lump','darkage:silt_lump'},
|
||||||
|
{'darkage:silt_lump','darkage:silt_lump'},
|
||||||
|
}
|
||||||
|
})
|
||||||
|
|
||||||
|
minetest.register_craft({
|
||||||
|
output = 'darkage:slate_tale 2',
|
||||||
|
recipe = {
|
||||||
|
{'darkage:slate_cobble','darkage:slate_cobble'},
|
||||||
|
{'darkage:slate_cobble','darkage:slate_cobble'},
|
||||||
|
}
|
||||||
|
})
|
||||||
|
|
||||||
|
minetest.register_craft({
|
||||||
|
output = 'darkage:stone_brick 9',--changed bacause conflicts with moreblocks
|
||||||
|
recipe = {
|
||||||
|
{'default:cobble','default:cobble','default:cobble'},--changed bacause conflicts with moreblocks
|
||||||
|
{'default:cobble','default:cobble','default:cobble'},--changed bacause conflicts with moreblocks
|
||||||
|
{'default:cobble','default:cobble','default:cobble'},--changed bacause conflicts with moreblocks
|
||||||
|
}
|
||||||
|
})
|
||||||
|
|
||||||
|
minetest.register_craft({
|
||||||
|
output = 'darkage:straw 2',
|
||||||
|
recipe = {
|
||||||
|
{'default:dry_shrub','default:dry_shrub'},
|
||||||
|
{'default:dry_shrub','default:dry_shrub'},
|
||||||
|
}
|
||||||
|
})
|
||||||
|
|
||||||
|
minetest.register_craft({
|
||||||
|
output = 'darkage:straw 2',
|
||||||
|
recipe = {
|
||||||
|
{'darkage:dry_leaves','darkage:dry_leaves'},
|
||||||
|
{'darkage:dry_leaves','darkage:dry_leaves'},
|
||||||
|
}
|
||||||
|
})
|
||||||
|
|
||||||
|
minetest.register_craft({
|
||||||
|
output = 'darkage:straw 4',
|
||||||
|
recipe = {
|
||||||
|
{'farming:wheat_harvested','farming:wheat_harvested'},
|
||||||
|
{'farming:wheat_harvested','farming:wheat_harvested'},
|
||||||
|
}
|
||||||
|
})
|
||||||
|
|
||||||
|
minetest.register_craft({
|
||||||
|
output = 'darkage:straw_bale',
|
||||||
|
recipe = {
|
||||||
|
{'darkage:straw','darkage:straw'},
|
||||||
|
{'darkage:straw','darkage:straw'},
|
||||||
|
}
|
||||||
|
})
|
||||||
|
|
||||||
|
minetest.register_craft({
|
||||||
|
output = 'darkage:iron_stick 4',
|
||||||
|
recipe = {
|
||||||
|
{'default:steel_ingot'},
|
||||||
|
}
|
||||||
|
})
|
||||||
|
|
||||||
|
-- Cookings
|
||||||
|
minetest.register_craft({
|
||||||
|
type = "cooking",
|
||||||
|
output = "darkage:basalt",
|
||||||
|
recipe = "darkage:basalt_cobble",
|
||||||
|
})
|
||||||
|
|
||||||
|
minetest.register_craft({
|
||||||
|
type = "cooking",
|
||||||
|
output = "default:desert_stone",
|
||||||
|
recipe = "darkage:desert_stone_cobble",
|
||||||
|
})
|
||||||
|
|
||||||
|
minetest.register_craft({
|
||||||
|
type = "cooking",
|
||||||
|
output = "darkage:dry_leaves",
|
||||||
|
recipe = "default:leaves",
|
||||||
|
})
|
||||||
|
|
||||||
|
minetest.register_craft({
|
||||||
|
type = "cooking",
|
||||||
|
output = "darkage:sandstone_cobble",
|
||||||
|
recipe = "default:sandstone",
|
||||||
|
})
|
||||||
|
|
||||||
|
minetest.register_craft({
|
||||||
|
type = "cooking",
|
||||||
|
output = "darkage:gneiss",
|
||||||
|
recipe = "darkage:schist",
|
||||||
|
})
|
||||||
|
|
||||||
|
minetest.register_craft({
|
||||||
|
type = "cooking",
|
||||||
|
output = "darkage:gneiss",
|
||||||
|
recipe = "darkage:gneiss_cobble",
|
||||||
|
})
|
||||||
|
|
||||||
|
minetest.register_craft({
|
||||||
|
type = "cooking",
|
||||||
|
output = "darkage:ors",
|
||||||
|
recipe = "darkage:ors_cobble",
|
||||||
|
})
|
||||||
|
|
||||||
|
|
||||||
|
minetest.register_craft({
|
||||||
|
type = "cooking",
|
||||||
|
output = "darkage:sandstone_cobble",
|
||||||
|
recipe = "default:sandstone",
|
||||||
|
})
|
||||||
|
|
||||||
|
minetest.register_craft({
|
||||||
|
type = "cooking",
|
||||||
|
output = "darkage:schist",
|
||||||
|
recipe = "darkage:slate",
|
||||||
|
})
|
||||||
|
|
||||||
|
minetest.register_craft({
|
||||||
|
type = "cooking",
|
||||||
|
output = "darkage:shale",
|
||||||
|
recipe = "darkage:mud",
|
||||||
|
})
|
||||||
|
|
||||||
|
minetest.register_craft({
|
||||||
|
type = "cooking",
|
||||||
|
output = "darkage:slate",
|
||||||
|
recipe = "darkage:shale",
|
||||||
|
})
|
||||||
|
|
||||||
|
minetest.register_craft({
|
||||||
|
type = "cooking",
|
||||||
|
output = "darkage:slate",
|
||||||
|
recipe = "darkage:slate_cobble",
|
||||||
|
})
|
||||||
|
|
||||||
|
-- Desert
|
||||||
|
minetest.register_craft({
|
||||||
|
type = "cooking",
|
||||||
|
output = "darkage:ors_cobble",
|
||||||
|
recipe = "default:desert_stone",
|
||||||
|
})
|
||||||
|
|
||||||
|
minetest.register_craft({
|
||||||
|
output = 'default:desert_stone 2',
|
||||||
|
recipe = {
|
||||||
|
{'default:desert_sand','default:desert_sand'},
|
||||||
|
{'default:desert_sand','default:desert_sand'},
|
||||||
|
}
|
||||||
|
})
|
||||||
|
|
||||||
|
>>>>>>> version 1.0
|
||||||
|
136
stairs.lua
136
stairs.lua
@ -1,111 +1,17 @@
|
|||||||
darkage = {}
|
darkage = {};
|
||||||
|
function darkage.register_stairs(modname, subname, groups, images, desc)
|
||||||
function darkage.register_stairs(modname, item, groups, images, description)
|
table.insert(circular_saw.known_stairs, modname..":"..subname);
|
||||||
local recipeitem = modname..":"..item
|
recipeitem = modname..":"..subname;
|
||||||
local itemname = modname..":stair_"..item
|
desc_stair = desc.." stair";
|
||||||
minetest.register_node(itemname, {
|
desc_slab = desc.." slab";
|
||||||
description = description.." stair",
|
desc_panel = desc.." panel";
|
||||||
drawtype = "nodebox",
|
desc_micro = desc.." micro";
|
||||||
tiles = images,
|
drop = subname
|
||||||
paramtype = "light",
|
register_stair(modname, subname, recipeitem, groups, images, desc_stair, drop)
|
||||||
paramtype2 = "facedir",
|
register_slab(modname, subname, recipeitem, groups, images, desc_slab, drop)
|
||||||
is_ground_content = true,
|
register_panel(modname, subname, recipeitem, groups, images, desc_panel, drop)
|
||||||
groups = groups,
|
register_micro(modname, subname, recipeitem, groups, images, desc_micro, drop)
|
||||||
node_box = {
|
|
||||||
type = "fixed",
|
|
||||||
fixed = {
|
|
||||||
{-0.5, -0.5, -0.5, 0.5, 0, 0.5},
|
|
||||||
{-0.5, 0, 0, 0.5, 0.5, 0.5},
|
|
||||||
},
|
|
||||||
},
|
|
||||||
})
|
|
||||||
|
|
||||||
minetest.register_craft({
|
|
||||||
output = itemname .. ' 4',
|
|
||||||
recipe = {
|
|
||||||
{recipeitem, "", ""},
|
|
||||||
{recipeitem, recipeitem, ""},
|
|
||||||
{recipeitem, recipeitem, recipeitem},
|
|
||||||
},
|
|
||||||
})
|
|
||||||
|
|
||||||
-- Flipped recipe for the silly minecrafters
|
|
||||||
minetest.register_craft({
|
|
||||||
output = itemname .. ' 4',
|
|
||||||
recipe = {
|
|
||||||
{"", "", recipeitem},
|
|
||||||
{"", recipeitem, recipeitem},
|
|
||||||
{recipeitem, recipeitem, recipeitem},
|
|
||||||
},
|
|
||||||
})
|
|
||||||
|
|
||||||
itemname=modname..":slab_" .. item
|
|
||||||
|
|
||||||
minetest.register_node(itemname, {
|
|
||||||
description = description.." slab",
|
|
||||||
drawtype = "nodebox",
|
|
||||||
tiles = images,
|
|
||||||
paramtype = "light",
|
|
||||||
is_ground_content = true,
|
|
||||||
groups = groups,
|
|
||||||
node_box = {
|
|
||||||
type = "fixed",
|
|
||||||
fixed = {-0.5, -0.5, -0.5, 0.5, 0, 0.5},
|
|
||||||
},
|
|
||||||
selection_box = {
|
|
||||||
type = "fixed",
|
|
||||||
fixed = {-0.5, -0.5, -0.5, 0.5, 0, 0.5},
|
|
||||||
},
|
|
||||||
on_place = function(itemstack, placer, pointed_thing)
|
|
||||||
if pointed_thing.type ~= "node" then
|
|
||||||
return itemstack
|
|
||||||
end
|
|
||||||
|
|
||||||
-- If it's being placed on an another similar one, replace it with
|
|
||||||
-- a full block
|
|
||||||
local slabpos = nil
|
|
||||||
local slabnode = nil
|
|
||||||
local p0 = pointed_thing.under
|
|
||||||
local p1 = pointed_thing.above
|
|
||||||
local n0 = minetest.env:get_node(p0)
|
|
||||||
local n1 = minetest.env:get_node(p1)
|
|
||||||
if n0.name == itemname then
|
|
||||||
slabpos = p0
|
|
||||||
slabnode = n0
|
|
||||||
elseif n1.name == itemname then
|
|
||||||
slabpos = p1
|
|
||||||
slabnode = n1
|
|
||||||
end
|
|
||||||
if slabpos then
|
|
||||||
-- Remove the slab at slabpos
|
|
||||||
minetest.env:remove_node(slabpos)
|
|
||||||
-- Make a fake stack of a single item and try to place it
|
|
||||||
local fakestack = ItemStack(recipeitem)
|
|
||||||
pointed_thing.above = slabpos
|
|
||||||
fakestack = minetest.item_place(fakestack, placer, pointed_thing)
|
|
||||||
-- If the item was taken from the fake stack, decrement original
|
|
||||||
if not fakestack or fakestack:is_empty() then
|
|
||||||
itemstack:take_item(1)
|
|
||||||
-- Else put old node back
|
|
||||||
else
|
|
||||||
minetest.env:set_node(slabpos, slabnode)
|
|
||||||
end
|
|
||||||
return itemstack
|
|
||||||
end
|
|
||||||
|
|
||||||
-- Otherwise place regularly
|
|
||||||
return minetest.item_place(itemstack, placer, pointed_thing)
|
|
||||||
end,
|
|
||||||
})
|
|
||||||
|
|
||||||
minetest.register_craft({
|
|
||||||
output = itemname .. ' 3',
|
|
||||||
recipe = {
|
|
||||||
{recipeitem, recipeitem, recipeitem},
|
|
||||||
},
|
|
||||||
})
|
|
||||||
end
|
end
|
||||||
|
|
||||||
darkage.register_stairs("darkage","basalt_cobble",
|
darkage.register_stairs("darkage","basalt_cobble",
|
||||||
{cracky=3},
|
{cracky=3},
|
||||||
{"darkage_basalt_cobble.png"},
|
{"darkage_basalt_cobble.png"},
|
||||||
@ -142,3 +48,19 @@ darkage.register_stairs("darkage","desert_stone_cobble",
|
|||||||
"Desert Stone Cobble"
|
"Desert Stone Cobble"
|
||||||
)
|
)
|
||||||
|
|
||||||
|
darkage.register_stairs("darkage","slate_cobble",
|
||||||
|
{cracky=3},
|
||||||
|
{"darkage_slate_cobble.png"},
|
||||||
|
"Slate Cobble"
|
||||||
|
)
|
||||||
|
darkage.register_stairs("darkage","sandstone_cobble",
|
||||||
|
{cracky=3},
|
||||||
|
{"darkage_sandstone_cobble.png"},
|
||||||
|
"Sandstone Cobble"
|
||||||
|
)
|
||||||
|
|
||||||
|
darkage.register_stairs("darkage","gneiss_cobble",
|
||||||
|
{cracky=3},
|
||||||
|
{"darkage_gneiss_cobble.png"},
|
||||||
|
"Gneiss Cobble"
|
||||||
|
)
|
BIN
textures/darkage_glass.png
Normal file
BIN
textures/darkage_glass.png
Normal file
Binary file not shown.
After Width: | Height: | Size: 1.3 KiB |
BIN
textures/darkage_glow_stone_lamp.png
Normal file
BIN
textures/darkage_glow_stone_lamp.png
Normal file
Binary file not shown.
After Width: | Height: | Size: 697 B |
Loading…
Reference in New Issue
Block a user