summaryrefslogtreecommitdiffstats
path: root/src/Generating/PieceGeneratorBFSTree.cpp
diff options
context:
space:
mode:
author12xx12 <44411062+12xx12@users.noreply.github.com>2021-03-07 17:31:43 +0100
committerGitHub <noreply@github.com>2021-03-07 17:31:43 +0100
commit3daf253b7f4ed8243e3262faee35219335e3e088 (patch)
tree72d7c719838d23c979fdc57f1d6053bab38d8275 /src/Generating/PieceGeneratorBFSTree.cpp
parentMitigate MSVC crash (#5146) (diff)
downloadcuberite-3daf253b7f4ed8243e3262faee35219335e3e088.tar
cuberite-3daf253b7f4ed8243e3262faee35219335e3e088.tar.gz
cuberite-3daf253b7f4ed8243e3262faee35219335e3e088.tar.bz2
cuberite-3daf253b7f4ed8243e3262faee35219335e3e088.tar.lz
cuberite-3daf253b7f4ed8243e3262faee35219335e3e088.tar.xz
cuberite-3daf253b7f4ed8243e3262faee35219335e3e088.tar.zst
cuberite-3daf253b7f4ed8243e3262faee35219335e3e088.zip
Diffstat (limited to 'src/Generating/PieceGeneratorBFSTree.cpp')
-rw-r--r--src/Generating/PieceGeneratorBFSTree.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/Generating/PieceGeneratorBFSTree.cpp b/src/Generating/PieceGeneratorBFSTree.cpp
index 4d9c78b45..2e26463f2 100644
--- a/src/Generating/PieceGeneratorBFSTree.cpp
+++ b/src/Generating/PieceGeneratorBFSTree.cpp
@@ -149,7 +149,7 @@ bool cPieceGeneratorBFSTree::TryPlacePieceAtConnector(
continue;
}
// Fits, add it to list of possibile connections:
- Connections.push_back(cConnection(**itrP, *itrC, NumCCWRotations, Weight));
+ Connections.emplace_back(**itrP, *itrC, NumCCWRotations, Weight);
WeightTotal += Weight;
} // for itrC - Connectors[]
} // for itrP - AvailablePieces[]
@@ -188,7 +188,7 @@ bool cPieceGeneratorBFSTree::TryPlacePieceAtConnector(
// This is the connector through which we have been connected to the parent, don't add
continue;
}
- a_OutConnectors.push_back(cFreeConnector(PlacedPiece.get(), Conn.m_Piece->RotateMoveConnector(*itr, Conn.m_NumCCWRotations, ConnPos.x, ConnPos.y, ConnPos.z)));
+ a_OutConnectors.emplace_back(PlacedPiece.get(), Conn.m_Piece->RotateMoveConnector(*itr, Conn.m_NumCCWRotations, ConnPos.x, ConnPos.y, ConnPos.z));
}
a_OutPieces.push_back(std::move(PlacedPiece));