16 Commits

Author SHA1 Message Date
d66e04f9b1 Merge remote-tracking branch 'upstream/master' 2020-12-24 21:10:26 +01:00
2e035f37e9 Fix strong window panel recipe collision with dark glass pane 2020-12-23 20:29:43 +01:00
d3d6a7bf79 Merge remote-tracking branch 'upstream/master' 2020-12-18 12:21:17 +01:00
178fd9c48b fix too large nodebox of "scifi_nodes:light_dynamic" 2020-12-16 09:21:07 +01:00
e34fdde795 Merge remote-tracking branch 'upstream/master' 2020-12-15 23:41:17 +01:00
d2dd770635 Preserve the metadata of items in the itemholder by converting to string instead of taking name 2020-12-14 07:54:40 +01:00
1993068ed1 Merge remote-tracking branch 'upstream/master' 2020-11-12 22:04:59 +01:00
eed0d601be add contentdb badge 2020-11-11 12:13:38 +01:00
436f51ab0d Merge remote-tracking branch 'upstream/master' 2020-11-10 19:59:40 +01:00
16ff4dcdb8 fix recipe typo for "scifi_nodes:stripes2top" 2020-11-07 19:20:53 +01:00
749d59a530 Merge remote-tracking branch 'upstream/master' 2020-09-13 12:28:42 +02:00
b54333d56b fix nodeboxes of double- and offset pane 2020-09-11 21:19:50 +02:00
bd58dbc48b Merge remote-tracking branch 'upstream/master' 2020-07-23 11:42:19 +02:00
6492d311c8 fix "walk-through" glass panes (wrong nodebox) 2020-07-22 20:23:54 +02:00
4eaba4f6e1 Adds loading message in the Action Log 2020-07-21 11:52:47 +02:00
03d097abf8 add pane variants of the octagon glass nodes (single, double and offset) (#41)
* add pane variants of the octagon glass nodes (single, double and offset)
* fix some indent issues
* added dark glass pane

Co-authored-by: BuckarooBanzay <BuckarooBanzay@users.noreply.github.com>
2020-07-14 07:37:51 +02:00
5 changed files with 127 additions and 6 deletions

View File

@ -4,6 +4,7 @@
![](https://github.com/D00Med/scifi_nodes/workflows/luacheck/badge.svg)
![](https://github.com/D00Med/scifi_nodes/workflows/integration-test/badge.svg)
[![ContentDB](https://content.minetest.net/packages/D00Med/scifi_nodes/shields/downloads/)](https://content.minetest.net/packages/D00Med/scifi_nodes/)
Minetest mod that adds scifi themed blocks, doors, materials, plants and other assets.

View File

@ -1282,10 +1282,13 @@ minetest.register_craft({
})
-- https://forum.minetest.net/viewtopic.php?f=10&t=13125&p=261481#p261481
-- with modified recipe
minetest.register_craft({
output = 'scifi_nodes:windowpanel 4',
output = 'scifi_nodes:windowpanel',
recipe = {
{"scifi_nodes:glass","",""}
{"scifi_nodes:glass_pane","scifi_nodes:glass_pane",""},
{"scifi_nodes:glass_pane","scifi_nodes:glass_pane",""},
{"","",""}
}
})
@ -1680,7 +1683,7 @@ minetest.register_craft({
minetest.register_craft({
output = 'scifi_nodes:stripes2top 3',
recipe = {
{"scifi_nodes:black","scifi_noedes:black","scifi_nodes:black"},
{"scifi_nodes:black","scifi_nodes:black","scifi_nodes:black"},
{"default:silver_sand","default:silver_sand","default:silver_sand"}
}
})
@ -1692,4 +1695,3 @@ minetest.register_craft({
{"scifi_nodes:stripes"}
}
})

View File

@ -20,4 +20,6 @@ dofile(MP.."/nodeboxes.lua")
dofile(MP.."/palm_scanner.lua")
dofile(MP.."/digicode.lua")
dofile(MP.."/models.lua")
dofile(MP.."/octagon_panes.lua")
dofile(MP.."/crafts.lua")
minetest.log("action", "[scifi_nodes] loaded.")

View File

@ -475,6 +475,12 @@ minetest.register_node("scifi_nodes:light_dynamic", {
type = "wallmounted",
fixed = {-0.5, -0.5, -0.5, -0.45, 0.5, 0.5}
},
node_box = {
type = "fixed",
fixed = {
fixed = {-0.5, -0.5, -0.5, -0.45, 0.5, 0.5}
}
},
paramtype2 = "wallmounted",
light_source = default.LIGHT_MAX,
groups = {cracky=1, oddly_breakable_by_hand=1},
@ -1080,10 +1086,9 @@ minetest.register_node("scifi_nodes:itemholder", {
local meta = minetest.get_meta(pos)
if name == meta:get_string("owner") or
minetest.check_player_privs(name, "protection_bypass") then
local wield_item = clicker:get_wielded_item():get_name()
local taken = item:take_item()
if taken and not taken:is_empty() then
minetest.add_item(pos, wield_item)
minetest.add_item(pos, taken:to_string())
return item
end
end

111
octagon_panes.lua Normal file
View File

@ -0,0 +1,111 @@
local function register(basename, description, texture)
local nodename_single = "scifi_nodes:" .. basename .. "_pane"
local nodename_double = "scifi_nodes:" .. basename .. "_pane_double"
local nodename_offset = "scifi_nodes:" .. basename .. "_pane_offset"
local recipe_ingredient = "scifi_nodes:" .. basename
-- single height
minetest.register_node(nodename_single, {
description = description,
drawtype = "nodebox",
tiles = {
texture
},
wield_image = texture,
paramtype = "light",
paramtype2 = "facedir",
sunlight_propagates = true,
is_ground_content = false,
node_box = {
type = "fixed",
fixed = {{-0.5, -0.5, -0.03125, 0.5, 0.5, 0.03125}},
},
selection_box = {
type = "fixed",
fixed = {{-0.5, -0.5, -0.25, 0.5, 0.5, 0.25}},
},
groups = {cracky = 3, oddly_breakable_by_hand = 3},
use_texture_alpha = true,
sounds = default.node_sound_glass_defaults()
})
-- double height
minetest.register_node(nodename_double, {
description = description,
drawtype = "nodebox",
tiles = {
texture
},
wield_image = texture,
paramtype = "light",
paramtype2 = "facedir",
sunlight_propagates = true,
is_ground_content = false,
node_box = {
type = "fixed",
fixed = {{-0.5, -0.5, -0.03125, 0.5, 1.5, 0.03125}},
},
selection_box = {
type = "fixed",
fixed = {{-0.5, -0.5, -0.25, 0.5, 1.5, 0.25}},
},
groups = {cracky = 3, oddly_breakable_by_hand = 3},
use_texture_alpha = true,
sounds = default.node_sound_glass_defaults()
})
-- single height with offset
minetest.register_node(nodename_offset, {
description = description,
drawtype = "nodebox",
tiles = {
texture
},
wield_image = texture,
paramtype = "light",
paramtype2 = "facedir",
sunlight_propagates = true,
is_ground_content = false,
node_box = {
type = "fixed",
fixed = {{-0.5, -0.5, 0.96875, 0.5, 0.5, 1.03125}},
},
selection_box = {
type = "fixed",
fixed = {{-0.5, -0.5, 0.75, 0.5, 0.5, 1.25}},
},
groups = {cracky = 3, oddly_breakable_by_hand = 3},
use_texture_alpha = true,
sounds = default.node_sound_glass_defaults()
})
-- register recipes
minetest.register_craft({
output = nodename_single .. " 16",
recipe = {
{recipe_ingredient}
},
})
minetest.register_craft({
output = nodename_double .. " 16",
recipe = {
{recipe_ingredient},
{recipe_ingredient}
},
})
minetest.register_craft({
output = nodename_offset,
type = "shapeless",
recipe = {nodename_single},
})
end
register("octrng", "Orange Octagon Glass pane", "scifi_nodes_octrng.png")
register("octgrn", "Green Octagon Glass pane", "scifi_nodes_octgrn.png")
register("octbl", "Blue Octagon Glass pane", "scifi_nodes_octbl.png")
register("octppl", "Purple Octagon Glass pane", "scifi_nodes_octppl.png")
register("glass", "Dark Glass pane", "scifi_nodes_glass.png")