fix: extended block always main segment passed to on_iteract

This commit is contained in:
MihailRis
2024-10-15 05:24:52 +03:00
parent d59fac61bb
commit fbca439b2d
3 changed files with 15 additions and 2 deletions
+3 -1
View File
@@ -337,7 +337,9 @@ void Chunks::setRotation(int32_t x, int32_t y, int32_t z, uint8_t index) {
return;
}
if (def.rt.extended) {
setRotationExtended(def, vox->state, {x, y, z}, index);
auto origin = seekOrigin({x, y, z}, def, vox->state);
vox = get(origin);
setRotationExtended(def, vox->state, origin, index);
} else {
vox->state.rotation = index;
auto chunk = getChunkByVoxel(x, y, z);