Some emplace_back replacements (#5149)
* replace push_back with emplace_back when a new object was created in the function call
This commit is contained in:
@@ -34,7 +34,7 @@ void cPainting::GetDrops(cItems & a_Items, cEntity * a_Killer)
|
||||
{
|
||||
if ((a_Killer != nullptr) && a_Killer->IsPlayer() && !static_cast<cPlayer *>(a_Killer)->IsGameModeCreative())
|
||||
{
|
||||
a_Items.push_back(cItem(E_ITEM_PAINTING));
|
||||
a_Items.emplace_back(E_ITEM_PAINTING);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user