mirror of
https://github.com/tobspr/shapez.io.git
synced 2025-06-13 13:04:03 +00:00
Fix belts
This commit is contained in:
parent
9d8ae031d0
commit
e5e12c3ff8
@ -123,10 +123,6 @@ export class BeltSystem extends GameSystemWithFilter {
|
|||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (this.root.immutableOperationRunning) {
|
|
||||||
return;
|
|
||||||
}
|
|
||||||
|
|
||||||
const metaBelt = gMetaBuildingRegistry.findByClass(MetaBeltBuilding);
|
const metaBelt = gMetaBuildingRegistry.findByClass(MetaBeltBuilding);
|
||||||
// Compute affected area
|
// Compute affected area
|
||||||
const originalRect = staticComp.getTileSpaceBounds();
|
const originalRect = staticComp.getTileSpaceBounds();
|
||||||
@ -168,7 +164,10 @@ export class BeltSystem extends GameSystemWithFilter {
|
|||||||
// Compute delta to see if anything changed
|
// Compute delta to see if anything changed
|
||||||
const newDirection = arrayBeltVariantToRotation[rotationVariant];
|
const newDirection = arrayBeltVariantToRotation[rotationVariant];
|
||||||
|
|
||||||
if (targetStaticComp.rotation !== rotation || newDirection !== targetBeltComp.direction) {
|
if (
|
||||||
|
!this.root.immutableOperationRunning &&
|
||||||
|
(targetStaticComp.rotation !== rotation || newDirection !== targetBeltComp.direction)
|
||||||
|
) {
|
||||||
const originalPath = targetBeltComp.assignedPath;
|
const originalPath = targetBeltComp.assignedPath;
|
||||||
|
|
||||||
// Ok, first remove it from its current path
|
// Ok, first remove it from its current path
|
||||||
|
Loading…
Reference in New Issue
Block a user