Optimization interne de chunk!
This commit is contained in:
@@ -1,7 +1,7 @@
|
||||
#include "blockinfo.h"
|
||||
#include <iostream>
|
||||
|
||||
BlockInfo::BlockInfo(BlockType type, const std::string& name) : m_type(type), m_name(name), m_durability(1)
|
||||
BlockInfo::BlockInfo(BlockType type, const std::string& name, float u, float v, float s, int dur) : m_type(type), m_name(name), m_u(u), m_v(v), m_s(s), m_durability(dur)
|
||||
{
|
||||
}
|
||||
|
||||
@@ -24,11 +24,19 @@ int BlockInfo::GetDurability() const
|
||||
return m_durability;
|
||||
}
|
||||
|
||||
void BlockInfo::GetTexture(float& u, float& v, float& s)
|
||||
{
|
||||
u = m_u;
|
||||
v = m_v;
|
||||
s = m_s;
|
||||
}
|
||||
|
||||
void BlockInfo::Show() const
|
||||
{
|
||||
std::cout << "Type: " << m_type << std::endl;
|
||||
std::cout << "Nom: " << m_name << std::endl;
|
||||
std::cout << "Durabilite: " << m_durability << std::endl;
|
||||
std::cout << "Coordonnees Texture: " << m_u << ", " << m_v << ", " << m_s << std::endl;
|
||||
}
|
||||
|
||||
|
||||
|
Reference in New Issue
Block a user