Compare commits

...

8 Commits

Author SHA1 Message Date
294276a7d1 Merge remote-tracking branch 'upstream/master' 2024-09-15 09:46:49 +02:00
xenurine
dbbbc3fb5f changed wooden scaffolding to group:wood 2024-08-10 20:59:59 +01:00
xenurine
4a4196d8a3 added fix to alpha bug 2024-08-10 16:53:46 +01:00
8ad6591315 Delete depends.txt, add mod.conf 2022-07-02 21:42:24 +02:00
5a785b4d00 Merge remote-tracking branch 'upstream/master' 2020-07-31 22:12:35 +02:00
adrido
930edb43d2 Merged in adrido/scaffolding (pull request #1)
Fixed "PNG warning: iCCP: known incorrect sRGB profile"
2020-07-27 13:42:40 +00:00
Adrian
0fb0cfea17 Fixed "PNG warning: iCCP: known incorrect sRGB profile" 2020-07-25 14:31:02 +02:00
2ff60245a9 Fix warnings on undeclared global variables 2020-07-20 02:20:06 +02:00
11 changed files with 22 additions and 9 deletions

View File

@ -1 +0,0 @@
default

View File

@ -1,7 +1,7 @@
local buildPlatform = function(node, pos, itemstack)
-- code for the building platforms
posZ = {'1', '0', '-1', '-1', '0', '0', '1', '1' };
posX = {'0', '-1', '0', '0', '1', '1', '0', '0' };
local posZ = {'1', '0', '-1', '-1', '0', '0', '1', '1' };
local posX = {'0', '-1', '0', '0', '1', '1', '0', '0' };
for nameCount = 1, 8 do
pos.z = pos.z + posZ[nameCount];
@ -20,8 +20,8 @@ local buildScaffolding = function(node, pos, itemstack, player)
-- many thanks to addi for improveing (rewriteing) my crappy code --
-- code for the building scaffolding
height = 0;
depth = 0; -- !!Note!! depth is not needed at the moment
local height = 0;
local depth = 0; -- !!Note!! depth is not needed at the moment
--[[ debug stuff ]]
@ -75,6 +75,7 @@ minetest.register_node("scaffolding:scaffolding", {
is_ground_content = true,
groups = {snappy=2,cracky=3,oddly_breakable_by_hand=3},
sounds = default.node_sound_wood_defaults(),
use_texture_alpha = "blend",
on_punch = function(pos, node, puncher)
local tool = puncher:get_wielded_item():get_name()
if tool and tool == "scaffolding:scaffolding_wrench" then
@ -132,6 +133,7 @@ minetest.register_node("scaffolding:reinforced_scaffolding", {
is_ground_content = true,
groups = {snappy=2,cracky=3,oddly_breakable_by_hand=3},
sounds = default.node_sound_wood_defaults(),
use_texture_alpha = "blend",
on_punch = function(pos, node, puncher)
local tool = puncher:get_wielded_item():get_name()
if tool and tool == "scaffolding:scaffolding_wrench" then
@ -177,6 +179,7 @@ minetest.register_node("scaffolding:reinforced_scaffolding", {
is_ground_content = true,
groups = {snappy=2,cracky=3,oddly_breakable_by_hand=3},
sounds = default.node_sound_wood_defaults(),
use_texture_alpha = "blend",
on_punch = function(pos, node, puncher)
local tool = puncher:get_wielded_item():get_name()
if tool and tool == "scaffolding:scaffolding_wrench" then
@ -217,6 +220,7 @@ minetest.register_node("scaffolding:reinforced_scaffolding", {
is_ground_content = true,
groups = {snappy=2,cracky=3,oddly_breakable_by_hand=3},
sounds = default.node_sound_wood_defaults(),
use_texture_alpha = "blend",
on_punch = function(pos, node, puncher)
local tool = puncher:get_wielded_item():get_name()
if tool and tool == "scaffolding:scaffolding_wrench" then
@ -250,6 +254,7 @@ minetest.register_node("scaffolding:reinforced_scaffolding", {
is_ground_content = true,
groups = {snappy=2,cracky=3},
sounds = default.node_sound_wood_defaults(),
use_texture_alpha = "blend",
node_box = {
type = "fixed",
fixed = {
@ -308,6 +313,7 @@ minetest.register_node("scaffolding:reinforced_scaffolding", {
is_ground_content = true,
groups = {snappy=2,cracky=3},
sounds = default.node_sound_wood_defaults(),
use_texture_alpha = "blend",
on_punch = function(pos, node, puncher)
local tool = puncher:get_wielded_item():get_name()
if tool and tool == "scaffolding:scaffolding_wrench" then
@ -353,6 +359,7 @@ minetest.register_node("scaffolding:reinforced_scaffolding", {
is_ground_content = true,
groups = {snappy=2,cracky=3},
sounds = default.node_sound_wood_defaults(),
use_texture_alpha = "blend",
on_punch = function(pos, node, puncher)
local tool = puncher:get_wielded_item():get_name()
if tool and tool == "scaffolding:scaffolding_wrench" then
@ -393,6 +400,7 @@ minetest.register_node("scaffolding:reinforced_scaffolding", {
is_ground_content = true,
groups = {snappy=2,cracky=3},
sounds = default.node_sound_wood_defaults(),
use_texture_alpha = "blend",
on_punch = function(pos, node, puncher)
local tool = puncher:get_wielded_item():get_name()
if tool and tool == "scaffolding:scaffolding_wrench" then
@ -421,18 +429,18 @@ minetest.register_node("scaffolding:reinforced_scaffolding", {
minetest.register_craft({
output = 'scaffolding:scaffolding 12',
recipe = {
{'default:wood', 'default:wood', 'default:wood'},
{'group:wood', 'group:wood', 'group:wood'},
{'default:stick', '', 'default:stick'},
{'default:wood', 'default:wood', 'default:wood'},
{'group:wood', 'group:wood', 'group:wood'},
}
})
minetest.register_craft({
output = 'scaffolding:scaffolding 4',
recipe = {
{'default:wood'},
{'group:wood'},
{'default:stick'},
{'default:wood'},
{'group:wood'},
}
})
@ -541,3 +549,5 @@ minetest.register_craft({
{'default:steel_ingot', '', ''},
}
})
minetest.log("action", "[scaffolding] loaded.")

4
mod.conf Normal file
View File

@ -0,0 +1,4 @@
name = scaffolding
title = Scaffolding
description = Adds the ability quickly build and remove scaffolding
depends = default

BIN
screenshot.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 1015 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 484 B

After

Width:  |  Height:  |  Size: 701 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 392 B

After

Width:  |  Height:  |  Size: 554 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 2.8 KiB

After

Width:  |  Height:  |  Size: 407 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 2.9 KiB

After

Width:  |  Height:  |  Size: 441 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 492 B

After

Width:  |  Height:  |  Size: 714 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 404 B

After

Width:  |  Height:  |  Size: 555 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 3.0 KiB

After

Width:  |  Height:  |  Size: 481 B