Variable block sizes
Variable block sizes
I am working on a mod (just to mess around, I'm not sure if I'll finish it or not), and I was wondering how to make a block not be the normal size. For example, having a block be 3 high, 2 long, and 2 wide. Does anyone know if this would be possible? Thanks for your help in advance!
Dogecoin: DM33mpJVPMNiaTxBoBpiJChBrnLBQFyaw9
The nodeboxes are working great, but now I have another issue; the player falls through the node when walking on top of it. I set walkable to true, but that didn't fix it. The player only goes through the node from the top, not the sides. Any ideas on what could be wrong?
Last edited by theblob on Mon Jan 27, 2014 20:59, edited 1 time in total.
Dogecoin: DM33mpJVPMNiaTxBoBpiJChBrnLBQFyaw9
I don't know if it's the best solution, but you could try:theblob wrote:The nodeboxes are working great, but now I have another issue; the player falls through the node when walking on top of it. I set walkable to true, but that didn't fix it. The player only goes through the node from the top, not the sides. Any ideas on what could be wrong?
climbable = true,
Although one probably still can climb into it then.
That's not working either, but thanks for the suggestion. Something else that's odd is that the node looks like it's covered in a shadow, no matter where it is placed.Topywo wrote:I don't know if it's the best solution, but you could try:theblob wrote:The nodeboxes are working great, but now I have another issue; the player falls through the node when walking on top of it. I set walkable to true, but that didn't fix it. The player only goes through the node from the top, not the sides. Any ideas on what could be wrong?
climbable = true,
Although one probably still can climb into it then.
Dogecoin: DM33mpJVPMNiaTxBoBpiJChBrnLBQFyaw9
I don't directly know what is causing that. However I found some old code from my sea modpack that I've tried out. I don't see strange shadows and I don't go through the node (tested it also with one of the later minetest versions). Just look for the differences with your code. I hope it helps!
Code:
If you want to see it working, you can download the nodebox version 0.2.1 of the sea modpack (under the spoiler older versions)
Edit: Typo's.
Code:
Code: Select all
minetest.register_node("seaplants:stemsgreen", {
description = 'Stems green',
tiles = {
"default_sand.png", -- up
"default_sand.png", -- down
"seaplants_yellowgreenlight.png", -- right
"seaplants_greenyellowdark.png", -- left
"seaplants_greenyellowlight.png", -- front
"seaplants_yellowgreendark.png", -- back
},
drawtype = "nodebox",
sunlight_propagates = true,
-- light_source = 1,
paramtype = 'light',
paramtype2 = "facedir",
node_box = {
type = "fixed",
fixed = {
-- stem_bottom
{-0.02, 0.500, -0.01, 0.02, 1, 0.01},
{-0.0175, 0.500, -0.0125, 0.0175, 1, 0.0125},
{-0.015, 0.500, -0.015, 0.015, 1, 0.015},
{a lot more like this]
{-0.0075+d, 1.5+h, -0.0125+d, 0.0075+d, 2+h, 0.0125+d},
{-0.005+d, 1.5+h, -0.015+d, 0.005+d, 2+h, 0.0150+d},
-- block
{-0.502, 0.50, -0.502, 0.502, 0.502, 0.502},
{-0.502, -0.502, -0.502, 0.50, 0.502, 0.502},
{-0.502, -0.502, -0.502, 0.502, 0.50, 0.502},
{-0.502, -0.502, -0.502, 0.502, 0.502, 0.50},
{-0.50, -0.502, -0.502, 0.502, 0.502, 0.502},
{-0.502, -0.502, -0.50, 0.502, 0.502, 0.502}
},
},
selection_box = {
type = "fixed",
fixed = {
-- block
{-0.502, 0.50, -0.502, 0.502, 0.502, 0.502},
{-0.502, -0.502, -0.502, 0.50, 0.502, 0.502},
{-0.502, -0.502, -0.502, 0.502, 0.50, 0.502},
{-0.502, -0.502, -0.502, 0.502, 0.502, 0.50},
{-0.50, -0.502, -0.502, 0.502, 0.502, 0.502},
{-0.502, -0.502, -0.50, 0.502, 0.502, 0.502}
},
},
drop = "seaplants:chewstickgreen",
groups = {snappy=2,choppy=2,oddly_breakable_by_hand=2},
sounds = default.node_sound_leaves_defaults()
})
If you want to see it working, you can download the nodebox version 0.2.1 of the sea modpack (under the spoiler older versions)
Edit: Typo's.
Last edited by Topywo on Tue Jan 28, 2014 22:28, edited 1 time in total.
Who is online
Users browsing this forum: No registered users and 19 guests