add new block.get_AXIS functions overloads & add rotation support to base:falling_block

This commit is contained in:
MihailRis
2024-12-29 21:48:36 +03:00
parent 9a190acb8b
commit ab5a62c3aa
9 changed files with 72 additions and 75 deletions
+3 -3
View File
@@ -41,9 +41,9 @@ void BlocksController::updateSides(int x, int y, int z, int w, int h, int d) {
voxel* vox = blocks_agent::get(chunks, x, y, z);
const auto& def = level.content.getIndices()->blocks.require(vox->id);
const auto& rot = def.rotations.variants[vox->state.rotation];
const auto& xaxis = rot.axisX;
const auto& yaxis = rot.axisY;
const auto& zaxis = rot.axisZ;
const auto& xaxis = rot.axes[0];
const auto& yaxis = rot.axes[1];
const auto& zaxis = rot.axes[2];
for (int ly = -1; ly <= h; ly++) {
for (int lz = -1; lz <= d; lz++) {
for (int lx = -1; lx <= w; lx++) {