Fix crash when deleting buildings.

Can't check getHasDirectionLockAvailable() on a building you are currently deleting because it doesn't exist.
pull/192/head
Derek Hoagland 4 years ago committed by GitHub
parent bbd50fdce9
commit ddb5aae327
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

@ -162,6 +162,7 @@ export class HUDBuildingPlacer extends BaseHUDPart {
// Check for direction lock
if (
metaBuilding &&
metaBuilding.getHasDirectionLockAvailable() &&
this.root.keyMapper.getBinding(KEYMAPPINGS.placement.lockBeltDirection).isCurrentlyPressed()
) {

Loading…
Cancel
Save