From 30c8470a524f5d09f157d5c1c59eb72c205d5085 Mon Sep 17 00:00:00 2001 From: Lane Kolbly Date: Tue, 19 Sep 2017 09:12:54 -0500 Subject: Changed BroadcastSoundEffect, SendSoundEffect, and CastThunderbolt parameters to vectors (#3959) * Made BroadcastSoundEffect take vector parameters. * Added docs for new vectored methods * Removed old code * Fixed lua warnings * Made old BroadcastSoundEffect not an override. * m_Block to m_BlockPos, used Vector3d constructor where prettier. * a_Block to a_BlockPos * Changed thunderbolt a_Block to a_BlockPos --- src/Items/ItemThrowable.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'src/Items/ItemThrowable.h') diff --git a/src/Items/ItemThrowable.h b/src/Items/ItemThrowable.h index 7bdba17cc..18dd9e801 100644 --- a/src/Items/ItemThrowable.h +++ b/src/Items/ItemThrowable.h @@ -36,7 +36,7 @@ public: Vector3d Speed = a_Player->GetLookVector() * m_SpeedCoeff; // Play sound - a_World->BroadcastSoundEffect("entity.arrow.shoot", a_Player->GetPosX(), a_Player->GetPosY() - a_Player->GetHeight(), a_Player->GetPosZ(), 0.5f, 0.4f / GetRandomProvider().RandReal(0.8f, 1.2f)); + a_World->BroadcastSoundEffect("entity.arrow.shoot", a_Player->GetPosition() - Vector3d(0, a_Player->GetHeight(), 0), 0.5f, 0.4f / GetRandomProvider().RandReal(0.8f, 1.2f)); if (a_World->CreateProjectile(Pos.x, Pos.y, Pos.z, m_ProjectileKind, a_Player, &a_Player->GetEquippedItem(), &Speed) == cEntity::INVALID_ID) { -- cgit v1.2.3