summaryrefslogtreecommitdiff
path: root/asphaltstairs
diff options
context:
space:
mode:
authorwebdesigner97 <Christian_D_97@gmx.de>2013-10-16 10:10:19 +0200
committerwebdesigner97 <Christian_D_97@gmx.de>2013-10-16 10:10:19 +0200
commit5508d85d407282c391336bdcb8937a26f21e8c6d (patch)
tree576e28479f4fd8f3647e970abaa2bccfecd42425 /asphaltstairs
parentfe7607750f24d1ee8daa38d648fc39e056ef6779 (diff)
downloadroads-5508d85d407282c391336bdcb8937a26f21e8c6d.tar
roads-5508d85d407282c391336bdcb8937a26f21e8c6d.tar.gz
roads-5508d85d407282c391336bdcb8937a26f21e8c6d.tar.bz2
roads-5508d85d407282c391336bdcb8937a26f21e8c6d.tar.xz
roads-5508d85d407282c391336bdcb8937a26f21e8c6d.zip
Lightened code
Diffstat (limited to 'asphaltstairs')
-rw-r--r--asphaltstairs/function.lua56
-rw-r--r--asphaltstairs/init.lua5
2 files changed, 2 insertions, 59 deletions
diff --git a/asphaltstairs/function.lua b/asphaltstairs/function.lua
deleted file mode 100644
index 9879d4c..0000000
--- a/asphaltstairs/function.lua
+++ /dev/null
@@ -1,56 +0,0 @@
--- StreetsMod needs a special slab definition, so it needs its own register_stair_and_slab
-streets.register_stair_and_slab = function(node,desc,tile,item)
- minetest.register_node(":streets:"..node.."_stair",{
- description = desc.."stair",
- groups = {cracky = 3},
- tiles = tile,
- paramtype = "light",
- paramtype2 = "facedir",
- drawtype = "nodebox",
- 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_node(":streets:"..node.."_slab",{
- description = desc.." slab",
- groups = {cracky = 3},
- tiles = tile,
- paramtype = "light",
- paramtype2 = "facedir",
- drawtype = "nodebox",
- node_box = {
- type = "fixed",
- fixed = {
- {-0.5, -0.5, -0.5, 0.5, 0, 0.5},
- }
- }
- })
- minetest.register_craft({
- output = "streets:"..node.."_stair 4",
- recipe = {
- {"","",item},
- {"",item,item},
- {item,item,item}
- }
- })
- minetest.register_craft({
- output = "streets:"..node.."_stair 4",
- recipe = {
- {item,"",""},
- {item,item,""},
- {item,item,item}
- }
- })
- minetest.register_craft({
- output = "streets:"..node.."_slab 3",
- recipe = {
- {"","",""},
- {"","",""},
- {item,item,item}
- }
- })
-end \ No newline at end of file
diff --git a/asphaltstairs/init.lua b/asphaltstairs/init.lua
index 7c1c181..aae9e22 100644
--- a/asphaltstairs/init.lua
+++ b/asphaltstairs/init.lua
@@ -1,7 +1,7 @@
--[[
StreetsMod: Asphalt stairs
]]
-if streets.extendedBy.moreblocks == true then
+if type(register_stair_slab_panel_micro) ~= "function" then return end
-- Asphalt
register_stair_slab_panel_micro("streets", "asphalt", "streets:asphalt", {cracky=3}, {"streets_asphalt.png"}, "Asphalt", "asphalt", nil)
minetest.register_alias("streets:asphalt_stair","stairs:stair_asphalt")
@@ -224,5 +224,4 @@ if streets.extendedBy.moreblocks == true then
type = "shapeless",
output = "streets:asphalt_side_l",
recipe = {"streets:asphalt_side_r"}
- })
-end \ No newline at end of file
+ }) \ No newline at end of file