mirror of
https://github.com/MihailRis/voxelcore.git
synced 2026-10-12 22:41:49 +00:00
custom model format changes
This commit is contained in:
parent
b5739c678f
commit
c4125058b4
7 changed files with 93 additions and 39 deletions
|
|
@ -66,17 +66,20 @@ enum class BlockModel {
|
|||
block, // default shape
|
||||
xsprite, // X-shape (grass)
|
||||
aabb, // box shaped as block hitbox
|
||||
customfaces // set of paired triangles (usual faces)
|
||||
custom
|
||||
};
|
||||
|
||||
using BoxModel = AABB;
|
||||
|
||||
class Block {
|
||||
public:
|
||||
std::string const name;
|
||||
// 0 1 2 3 4 5
|
||||
std::string textureFaces[6]; // -x,x, -y,y, -z,z
|
||||
std::vector<std::string> textureMoreFaces = {};
|
||||
std::vector<glm::vec3> customfacesPoints = {};
|
||||
std::vector<UVRegion> customfacesExtraUVs = {};
|
||||
std::vector<std::string> modelTextures = {};
|
||||
std::vector<BoxModel> modelBoxes = {};
|
||||
std::vector<glm::vec3> modelExtraPoints = {}; //initially made for tetragons
|
||||
std::vector<UVRegion> modelUVs = {}; // boxes' tex-UVs also there
|
||||
unsigned char emission[4] {0, 0, 0, 0};
|
||||
unsigned char drawGroup = 0;
|
||||
BlockModel model = BlockModel::block;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue