summaryrefslogtreecommitdiffstats
path: root/source/Entities/ProjectileEntity.cpp
diff options
context:
space:
mode:
authorTiger Wang <ziwei.tiger@hotmail.co.uk>2013-11-10 21:48:12 +0100
committerTiger Wang <ziwei.tiger@hotmail.co.uk>2013-11-10 21:48:12 +0100
commit71abbb2f56c15634cca8615343d9699d0c50724d (patch)
treef56c254125256cc23f481b4ac18c843bd7470566 /source/Entities/ProjectileEntity.cpp
parentRemoved cStringMap. (diff)
downloadcuberite-71abbb2f56c15634cca8615343d9699d0c50724d.tar
cuberite-71abbb2f56c15634cca8615343d9699d0c50724d.tar.gz
cuberite-71abbb2f56c15634cca8615343d9699d0c50724d.tar.bz2
cuberite-71abbb2f56c15634cca8615343d9699d0c50724d.tar.lz
cuberite-71abbb2f56c15634cca8615343d9699d0c50724d.tar.xz
cuberite-71abbb2f56c15634cca8615343d9699d0c50724d.tar.zst
cuberite-71abbb2f56c15634cca8615343d9699d0c50724d.zip
Diffstat (limited to '')
-rw-r--r--source/Entities/ProjectileEntity.cpp3
1 files changed, 3 insertions, 0 deletions
diff --git a/source/Entities/ProjectileEntity.cpp b/source/Entities/ProjectileEntity.cpp
index 1d5532718..08f46b3d9 100644
--- a/source/Entities/ProjectileEntity.cpp
+++ b/source/Entities/ProjectileEntity.cpp
@@ -425,6 +425,9 @@ bool cArrowEntity::CanPickup(const cPlayer & a_Player) const
void cArrowEntity::OnHitSolidBlock(const Vector3d & a_HitPos, char a_HitFace)
{
super::OnHitSolidBlock(a_HitPos, a_HitFace);
+
+ // Broadcast arrow hit sound
+ m_World->BroadcastSoundEffect("random.bowhit", (int)GetPosX() * 8, (int)GetPosY() * 8, (int)GetPosZ() * 8, 0.5, (float)(0.75 + ((float)((GetUniqueID() * 23) % 32)) / 64));
// Broadcast the position and speed packets before teleporting:
BroadcastMovementUpdate();