diff options
author | x12xx12x <44411062+12xx12@users.noreply.github.com> | 2022-04-19 20:30:12 +0200 |
---|---|---|
committer | Alexander Harkness <me@bearbin.net> | 2022-04-20 09:41:02 +0200 |
commit | 5ea7675eca4fe50feed7fc4b871075f8c937d8b1 (patch) | |
tree | 440c01c9c6b783b27155c631273c60d32092c38f /src/Protocol/Protocol_1_10.cpp | |
parent | Check height is within world for pistons and digging (#5396) (diff) | |
download | cuberite-5ea7675eca4fe50feed7fc4b871075f8c937d8b1.tar cuberite-5ea7675eca4fe50feed7fc4b871075f8c937d8b1.tar.gz cuberite-5ea7675eca4fe50feed7fc4b871075f8c937d8b1.tar.bz2 cuberite-5ea7675eca4fe50feed7fc4b871075f8c937d8b1.tar.lz cuberite-5ea7675eca4fe50feed7fc4b871075f8c937d8b1.tar.xz cuberite-5ea7675eca4fe50feed7fc4b871075f8c937d8b1.tar.zst cuberite-5ea7675eca4fe50feed7fc4b871075f8c937d8b1.zip |
Diffstat (limited to 'src/Protocol/Protocol_1_10.cpp')
-rw-r--r-- | src/Protocol/Protocol_1_10.cpp | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/src/Protocol/Protocol_1_10.cpp b/src/Protocol/Protocol_1_10.cpp index 4f3e1a52b..beca6db24 100644 --- a/src/Protocol/Protocol_1_10.cpp +++ b/src/Protocol/Protocol_1_10.cpp @@ -311,16 +311,16 @@ namespace Metadata //////////////////////////////////////////////////////////////////////////////// // cProtocol_1_10_0: -void cProtocol_1_10_0::SendSoundEffect(const AString & a_SoundName, double a_X, double a_Y, double a_Z, float a_Volume, float a_Pitch) +void cProtocol_1_10_0::SendSoundEffect(const AString & a_SoundName, Vector3d a_Origin, float a_Volume, float a_Pitch) { ASSERT(m_State == 3); // In game mode? cPacketizer Pkt(*this, pktSoundEffect); Pkt.WriteString(a_SoundName); Pkt.WriteVarInt32(0); // Master sound category (may want to be changed to a parameter later) - Pkt.WriteBEInt32(FloorC(a_X * 8.0)); - Pkt.WriteBEInt32(FloorC(a_Y * 8.0)); - Pkt.WriteBEInt32(FloorC(a_Z * 8.0)); + Pkt.WriteBEInt32(FloorC(a_Origin.x * 8.0)); + Pkt.WriteBEInt32(FloorC(a_Origin.y * 8.0)); + Pkt.WriteBEInt32(FloorC(a_Origin.z * 8.0)); Pkt.WriteBEFloat(a_Volume); Pkt.WriteBEFloat(a_Pitch); } |