1
0

Fix use after move in cItemBowHandler::OnItemShoot

This commit is contained in:
peterbell10 2017-08-21 21:25:03 +01:00 committed by Lukas Pioch
parent c1b1cb87a1
commit 0854ed01a4

View File

@ -1,4 +1,4 @@

// ItemBow.h // ItemBow.h
// Declares the cItemBowHandler class representing the itemhandler for bows // Declares the cItemBowHandler class representing the itemhandler for bows
@ -91,16 +91,15 @@ public:
} }
else else
{ {
Arrow->SetPickupState(cArrowEntity::psNoPickup); ArrowPtr->SetPickupState(cArrowEntity::psNoPickup);
} }
a_Player->UseEquippedItem(); a_Player->UseEquippedItem();
} }
if (a_Player->GetEquippedItem().m_Enchantments.GetLevel(cEnchantments::enchFlame) > 0) if (a_Player->GetEquippedItem().m_Enchantments.GetLevel(cEnchantments::enchFlame) > 0)
{ {
Arrow->StartBurning(100); ArrowPtr->StartBurning(100);
} }
} }
} ; } ;