Tile textures?

Gatharoth
Member
 
Posts: 196
Joined: Thu Dec 22, 2011 02:54

Tile textures?

by Gatharoth » Fri Mar 16, 2012 01:49

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?
 

User avatar
Death Dealer
Member
 
Posts: 1379
Joined: Wed Feb 15, 2012 18:46

by Death Dealer » Fri Mar 16, 2012 02:47

All the side textures are the same thing. As is the same with top and bottom.
Keep calm and code python^_^
 

Gatharoth
Member
 
Posts: 196
Joined: Thu Dec 22, 2011 02:54

by Gatharoth » Fri Mar 16, 2012 02:57

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.
 

User avatar
Death Dealer
Member
 
Posts: 1379
Joined: Wed Feb 15, 2012 18:46

by Death Dealer » Fri Mar 16, 2012 03:41

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>_>
Keep calm and code python^_^
 

Gatharoth
Member
 
Posts: 196
Joined: Thu Dec 22, 2011 02:54

by Gatharoth » Fri Mar 16, 2012 03:48

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.
 

User avatar
Death Dealer
Member
 
Posts: 1379
Joined: Wed Feb 15, 2012 18:46

by Death Dealer » Fri Mar 16, 2012 04:15

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?
Keep calm and code python^_^
 

Gatharoth
Member
 
Posts: 196
Joined: Thu Dec 22, 2011 02:54

by Gatharoth » Fri Mar 16, 2012 04:33

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.
 

User avatar
Death Dealer
Member
 
Posts: 1379
Joined: Wed Feb 15, 2012 18:46

by Death Dealer » Fri Mar 16, 2012 04:38

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
Keep calm and code python^_^
 

kahrl
Member
 
Posts: 236
Joined: Fri Sep 02, 2011 07:51

by kahrl » Fri Mar 16, 2012 06:28

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.
 

Gatharoth
Member
 
Posts: 196
Joined: Thu Dec 22, 2011 02:54

by Gatharoth » Fri Mar 16, 2012 06:56

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.
 

User avatar
Trenton
Member
 
Posts: 22
Joined: Mon May 14, 2012 22:58

by Trenton » Thu May 17, 2012 20:21

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"},
Sorry for my poor english

>I'm still testing my mod. if you wanna help me contact me =)
 

User avatar
kddekadenz
Member
 
Posts: 323
Joined: Mon Jun 27, 2011 17:21
GitHub: tinyworlds

by kddekadenz » Sat May 19, 2012 15:19

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).
 


Return to Minetest General

Who is online

Users browsing this forum: No registered users and 7 guests

cron