Botcraft
26.3
Loading...
Searching...
No Matches
ClientboundCustomSoundPacket.hpp
Go to the documentation of this file.
1
#if PROTOCOL_VERSION > 47
/* > 1.8.9 */
&& PROTOCOL_VERSION < 761
/* < 1.19.3 */
2
#pragma once
3
4
#include "
protocolCraft/BasePacket.hpp
"
5
6
namespace
ProtocolCraft
7
{
8
class
ClientboundCustomSoundPacket :
public
BasePacket<ClientboundCustomSoundPacket>
9
{
10
public
:
11
static
constexpr
std::string_view packet_name =
"Custom Sound"
;
12
13
SERIALIZED_FIELD
(Name_, std::string);
14
SERIALIZED_FIELD
(Source, VarInt);
15
SERIALIZED_FIELD
(X,
int
);
16
SERIALIZED_FIELD
(Y,
int
);
17
SERIALIZED_FIELD
(Z,
int
);
18
SERIALIZED_FIELD
(Volume,
float
);
19
#if PROTOCOL_VERSION < 210
/* < 1.10 */
20
SERIALIZED_FIELD
(Pitch,
unsigned
char
);
21
#else
22
SERIALIZED_FIELD
(Pitch,
float
);
23
#endif
24
#if PROTOCOL_VERSION > 758
/* > 1.18.2 */
25
SERIALIZED_FIELD
(Seed,
long
long
int
);
26
#endif
27
28
DECLARE_READ_WRITE_SERIALIZE
;
29
};
30
}
//ProtocolCraft
31
#endif
DECLARE_READ_WRITE_SERIALIZE
#define DECLARE_READ_WRITE_SERIALIZE
Define auto serializable utilities and declare ReadImpl, WriteImpl and SerializeImpl virtual function...
Definition
AutoSerializedMacros.hpp:123
SERIALIZED_FIELD
#define SERIALIZED_FIELD(Name,...)
Definition
AutoSerializedMacros.hpp:77
BasePacket.hpp
ProtocolCraft
Definition
ItemUtilities.hpp:8
protocolCraft
include
protocolCraft
Packets
Game
Clientbound
ClientboundCustomSoundPacket.hpp
Generated by
1.9.8