summaryrefslogtreecommitdiffstats
path: root/src/Items
diff options
context:
space:
mode:
authormadmaxoft <github@xoft.cz>2014-09-01 14:03:39 +0200
committermadmaxoft <github@xoft.cz>2014-09-01 14:03:39 +0200
commit9a4e8bf83fef9614bfe9efdc341c2ed2c7e108ed (patch)
treec232526f4bc7b6d5bd2d67356ada8b18378fcc00 /src/Items
parentAvoid false positive in style check. (diff)
parentFixed style (diff)
downloadcuberite-9a4e8bf83fef9614bfe9efdc341c2ed2c7e108ed.tar
cuberite-9a4e8bf83fef9614bfe9efdc341c2ed2c7e108ed.tar.gz
cuberite-9a4e8bf83fef9614bfe9efdc341c2ed2c7e108ed.tar.bz2
cuberite-9a4e8bf83fef9614bfe9efdc341c2ed2c7e108ed.tar.lz
cuberite-9a4e8bf83fef9614bfe9efdc341c2ed2c7e108ed.tar.xz
cuberite-9a4e8bf83fef9614bfe9efdc341c2ed2c7e108ed.tar.zst
cuberite-9a4e8bf83fef9614bfe9efdc341c2ed2c7e108ed.zip
Diffstat (limited to 'src/Items')
-rw-r--r--src/Items/ItemBow.h12
1 files changed, 11 insertions, 1 deletions
diff --git a/src/Items/ItemBow.h b/src/Items/ItemBow.h
index fdc24689c..f29cc5d59 100644
--- a/src/Items/ItemBow.h
+++ b/src/Items/ItemBow.h
@@ -75,7 +75,6 @@ public:
Arrow = NULL;
return;
}
-
a_Player->GetWorld()->BroadcastSoundEffect("random.bow", a_Player->GetPosX(), a_Player->GetPosY(), a_Player->GetPosZ(), 0.5, (float)Force);
if (!a_Player->IsGameModeCreative())
{
@@ -83,8 +82,19 @@ public:
{
a_Player->GetInventory().RemoveItem(cItem(E_ITEM_ARROW));
}
+ else
+ {
+ Arrow->SetPickupState(cArrowEntity::psNoPickup);
+ }
+
+
a_Player->UseEquippedItem();
}
+
+ if (a_Player->GetEquippedItem().m_Enchantments.GetLevel(cEnchantments::enchFlame) > 0)
+ {
+ Arrow->StartBurning(100);
+ }
}
} ;