mirror of
https://github.com/MihailRis/voxelcore.git
synced 2026-10-09 21:11:50 +00:00
Merge branch 'main' into entities
This commit is contained in:
commit
7487c55e0c
4 changed files with 21 additions and 5 deletions
|
|
@ -206,4 +206,13 @@ public:
|
|||
Block(const Block&) = delete;
|
||||
};
|
||||
|
||||
inline glm::ivec3 get_ground_direction(const Block* def, int rotation) {
|
||||
const auto& profileName = def->rotations.name;
|
||||
if (profileName == BlockRotProfile::PIPE_NAME) {
|
||||
return -def->rotations.variants[rotation].axisY;
|
||||
} else {
|
||||
return glm::ivec3(0, -1, 0);
|
||||
}
|
||||
}
|
||||
|
||||
#endif // VOXELS_BLOCK_HPP_
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue