Page 1 of 1

Tile textures?

PostPosted: Fri Mar 16, 2012 01:49
by Gatharoth
Alright, so we've all seen nodes with multiple textures. Like trees, they have the bark on the 4 sides, and the rings on the top and bottom.

Okay so what I'd like to know, is there a specific order for the tile images?

So like this

Your phone or window isn't wide enough to display the code box. If it's a phone, try rotating it to landscape mode.
Code: Select all
minetest.register_node('somemod:somenod', {
   drawtype = normal
   tile_images ={'top', 'bottom', 'side', 'side', 'side', 'side'}


Or does it not really matter?

PostPosted: Fri Mar 16, 2012 02:47
by Death Dealer
All the side textures are the same thing. As is the same with top and bottom.

PostPosted: Fri Mar 16, 2012 02:57
by Gatharoth
Death Dealer wrote:All the side textures are the same thing. As is the same with top and bottom.


If that is true, then explain why one side is different from the others on jejia's switch in his mesecon mod.

PostPosted: Fri Mar 16, 2012 03:41
by Death Dealer
Gatharoth wrote:
Death Dealer wrote:All the side textures are the same thing. As is the same with top and bottom.


If that is true, then explain why one side is different from the others on jejia's switch in his mesecon mod.

I'm not saying that's the problem. I'm saying I have that problem sometimes, and that's what caused it. If there's other problems maybe you should post them to. Not barking at someone tring to help with all the other problems your having>_>

PostPosted: Fri Mar 16, 2012 03:48
by Gatharoth
Death Dealer wrote:
Gatharoth wrote:
Death Dealer wrote:All the side textures are the same thing. As is the same with top and bottom.


If that is true, then explain why one side is different from the others on jejia's switch in his mesecon mod.

I'm not saying that's the problem. I'm saying I have that problem sometimes, and that's what caused it. If there's other problems maybe you should post them to. Not barking at someone tring to help with all the other problems your having>_>



I'm not having a problem; I'm having a question. That is why I posted here in the general discussion.

I'm not barking at you, I'm questioning your statement based on what I've seen. Since you said all side textures are the same thing, and jejia's switch has 3 same-side textures, and 1 different, I'm asking you to explain why his has 2 side textures. You are taking offense to something that is just a simple statement.

I'm working on a bed mod, but I'm not sure how tile textures work. I've only used one texture for every side. And I have multiple textures for the bed, so I'm wondering if I have to put them in a certain order, or it doesn't matter and I just have to put them in, or what.

PostPosted: Fri Mar 16, 2012 04:15
by Death Dealer
I completely misinterpreted exactly what you were asking sorry, I'm sure there's an order to it.
Can't look at the texture for the switch on mescons?

PostPosted: Fri Mar 16, 2012 04:33
by Gatharoth
Death Dealer wrote:I completely misinterpreted exactly what you were asking sorry, I'm sure there's an order to it.
Can't look at the texture for the switch on mescons?


I have, but it doesn't tell me exactly everything I need.

I'm not sure about this, but if you put in 6 different textures into the "tile_images = {}" then the 6th one is the one that faces the player.

PostPosted: Fri Mar 16, 2012 04:38
by Death Dealer
Gatharoth wrote:
Death Dealer wrote:I completely misinterpreted exactly what you were asking sorry, I'm sure there's an order to it.
Can't look at the texture for the switch on mescons?


I have, but it doesn't tell me exactly everything I need.

I'm not sure about this, but if you put in 6 different textures into the "tile_images = {}" then the 6th one is the one that faces the player.

I'm sorry I wish I knew more: / I'm sure someone will help you with this tommorow.
Anybody that knows for sure isn't online right now. I only sleep 3 hours out of the day so I'm normally on:/. Anyways good luck with the bed mod I'm sure you'll figure it out:D

PostPosted: Fri Mar 16, 2012 06:28
by kahrl
from mapblock_mesh.cpp:

Your phone or window isn't wide enough to display the code box. If it's a phone, try rotating it to landscape mode.
Code: Select all
// 0  +X  +Y  +Z   0  -Z  -Y  -X
   0,  2,  0,  4,  0,  5,  1,  3,  // facedir = 0


So the order is +Y (top), -Y (bottom), +X, -X, +Z, -Z.

PostPosted: Fri Mar 16, 2012 06:56
by Gatharoth
kahrl wrote:from mapblock_mesh.cpp:

Your phone or window isn't wide enough to display the code box. If it's a phone, try rotating it to landscape mode.
Code: Select all
// 0  +X  +Y  +Z   0  -Z  -Y  -X
   0,  2,  0,  4,  0,  5,  1,  3,  // facedir = 0


So the order is +Y (top), -Y (bottom), +X, -X, +Z, -Z.

:D Thanks kahrl! I had been looking through some of the .cpp files, but apparently I wasn't looking through the right ones.

PostPosted: Thu May 17, 2012 20:21
by Trenton
Maybe this can help you


the default wood node use this code for the texture:

Your phone or window isn't wide enough to display the code box. If it's a phone, try rotating it to landscape mode.
Code: Select all
    tile_images = {"default_tree_top.png", "default_tree_top.png", "default_tree.png"},



while the "dirt with grass" use this:

Your phone or window isn't wide enough to display the code box. If it's a phone, try rotating it to landscape mode.
Code: Select all
tile_images = {"default_grass.png", "default_dirt.png", "default_dirt.png^default_grass_side.png"},

PostPosted: Sat May 19, 2012 15:19
by kddekadenz
Trenton wrote:Maybe this can help you


the default wood node use this code for the texture:

Your phone or window isn't wide enough to display the code box. If it's a phone, try rotating it to landscape mode.
Code: Select all
    tile_images = {"default_tree_top.png", "default_tree_top.png", "default_tree.png"},



while the "dirt with grass" use this:

Your phone or window isn't wide enough to display the code box. If it's a phone, try rotating it to landscape mode.
Code: Select all
tile_images = {"default_grass.png", "default_dirt.png", "default_dirt.png^default_grass_side.png"},


'texture1^texture2' will combine texture1 and texture 2 to one texture (texture1 at bottom).