Minetest  5.4.0
TileLayer Struct Reference

Defines a layer of a tile. More...

#include <tile.h>

+ Collaboration diagram for TileLayer:

Public Member Functions

 TileLayer ()=default
 
bool operator== (const TileLayer &other) const
 
bool operator!= (const TileLayer &other) const
 
void applyMaterialOptions (video::SMaterial &material) const
 
void applyMaterialOptionsWithShaders (video::SMaterial &material) const
 
bool isTileable () const
 

Public Attributes

video::ITexture * texture = nullptr
 
video::ITexture * normal_texture = nullptr
 
video::ITexture * flags_texture = nullptr
 
u32 shader_id = 0
 
u32 texture_id = 0
 
u16 animation_frame_length_ms = 0
 
u16 animation_frame_count = 1
 
u8 material_type = TILE_MATERIAL_BASIC
 
u8 material_flags
 
bool has_color = false
 If true, the tile has its own color. More...
 
std::vector< FrameSpec > * frames = nullptr
 
video::SColor color
 
u8 scale
 

Detailed Description

Defines a layer of a tile.

Constructor & Destructor Documentation

◆ TileLayer()

TileLayer::TileLayer ( )
default

Member Function Documentation

◆ applyMaterialOptions()

void TileLayer::applyMaterialOptions ( video::SMaterial &  material) const
inline

◆ applyMaterialOptionsWithShaders()

void TileLayer::applyMaterialOptionsWithShaders ( video::SMaterial &  material) const
inline

◆ isTileable()

bool TileLayer::isTileable ( ) const
inline

◆ operator!=()

bool TileLayer::operator!= ( const TileLayer other) const
inline

Two tiles are not equal if they must have different vertices.

◆ operator==()

bool TileLayer::operator== ( const TileLayer other) const
inline

Two layers are equal if they can be merged.

References color, material_flags, material_type, scale, and texture_id.

Member Data Documentation

◆ animation_frame_count

u16 TileLayer::animation_frame_count = 1

◆ animation_frame_length_ms

u16 TileLayer::animation_frame_length_ms = 0

◆ color

video::SColor TileLayer::color

The color of the tile, or if the tile does not own a color then the color of the node owning this tile.

Referenced by applyTileColor(), fillTileAttribs(), getItemMesh(), ParticleManager::getNodeParticleParams(), getNodeTileN(), MapblockMeshGenerator::getSpecialTile(), operator==(), postProcessNodeMesh(), and WieldMeshSceneNode::setItem().

◆ flags_texture

video::ITexture* TileLayer::flags_texture = nullptr

◆ frames

◆ has_color

◆ material_flags

u8 TileLayer::material_flags

◆ material_type

u8 TileLayer::material_type = TILE_MATERIAL_BASIC

◆ normal_texture

video::ITexture* TileLayer::normal_texture = nullptr

◆ scale

◆ shader_id

u32 TileLayer::shader_id = 0

Referenced by fillTileAttribs().

◆ texture

◆ texture_id


The documentation for this struct was generated from the following file: