mirror of
https://github.com/tobspr/shapez.io.git
synced 2024-10-27 20:34:29 +00:00
Hotfix to prevent pasting locked buildings (#1272)
* fix to prevent pasting locked buildings * only check when in editor
This commit is contained in:
parent
62b6504917
commit
260041702b
@ -80,6 +80,15 @@ export class GameLogic {
|
||||
}
|
||||
|
||||
// Perform additional placement checks
|
||||
if (this.root.gameMode.getIsEditor()) {
|
||||
const toolbar = this.root.hud.parts.buildingsToolbar;
|
||||
const id = entity.components.StaticMapEntity.getMetaBuilding().getId();
|
||||
|
||||
if (toolbar.buildingHandles[id].puzzleLocked) {
|
||||
return false;
|
||||
}
|
||||
}
|
||||
|
||||
if (this.root.signals.prePlacementCheck.dispatch(entity, offset) === STOP_PROPAGATION) {
|
||||
return false;
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user