From 3daf253b7f4ed8243e3262faee35219335e3e088 Mon Sep 17 00:00:00 2001 From: 12xx12 <44411062+12xx12@users.noreply.github.com> Date: Sun, 7 Mar 2021 17:31:43 +0100 Subject: Some emplace_back replacements (#5149) * replace push_back with emplace_back when a new object was created in the function call --- src/Entities/ItemFrame.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'src/Entities/ItemFrame.cpp') diff --git a/src/Entities/ItemFrame.cpp b/src/Entities/ItemFrame.cpp index 807a67b15..ef2939e06 100644 --- a/src/Entities/ItemFrame.cpp +++ b/src/Entities/ItemFrame.cpp @@ -84,7 +84,7 @@ void cItemFrame::GetDrops(cItems & a_Items, cEntity * a_Killer) { if ((a_Killer != nullptr) && a_Killer->IsPlayer() && !static_cast(a_Killer)->IsGameModeCreative()) { - a_Items.push_back(cItem(E_ITEM_ITEM_FRAME)); + a_Items.emplace_back(E_ITEM_ITEM_FRAME); } } -- cgit v1.2.3