Botcraft 26.3
Loading...
Searching...
No Matches
ClientboundLevelParticlesPacket.hpp
Go to the documentation of this file.
1#pragma once
2
5#if PROTOCOL_VERSION < 766 /* < 1.20.5 */
8#endif
9
10
11namespace ProtocolCraft
12{
13 class ClientboundLevelParticlesPacket : public BasePacket<ClientboundLevelParticlesPacket>
14 {
15 public:
16 static constexpr std::string_view packet_name = "Level Particles";
17
18#if PROTOCOL_VERSION < 759 /* < 1.19 */
20#elif PROTOCOL_VERSION < 766 /* < 1.20.5 */
22#elif PROTOCOL_VERSION > 776 /* > 26.2 */
24#endif
25 SERIALIZED_FIELD(OverrideLimiter, bool);
26#if PROTOCOL_VERSION > 768 /* > 1.21.3 */
27 SERIALIZED_FIELD(AlwaysShow, bool);
28#endif
29#if PROTOCOL_VERSION < 573 /* < 1.15 */
30 SERIALIZED_FIELD(X, float);
31 SERIALIZED_FIELD(Y, float);
32 SERIALIZED_FIELD(Z, float);
33#else
34 SERIALIZED_FIELD(X, double);
35 SERIALIZED_FIELD(Y, double);
36 SERIALIZED_FIELD(Z, double);
37#endif
38 SERIALIZED_FIELD(XDist, float);
39 SERIALIZED_FIELD(YDist, float);
40 SERIALIZED_FIELD(ZDist, float);
41#if PROTOCOL_VERSION < 777 /* < 26.3 */
42 SERIALIZED_FIELD(MaxSpeed, float);
43 SERIALIZED_FIELD(Count, int);
44#else
45 SERIALIZED_FIELD(XMaxSpeed, float);
46 SERIALIZED_FIELD(YMaxSpeed, float);
47 SERIALIZED_FIELD(ZMaxSpeed, float);
49 SERIALIZED_FIELD(RandomizationType, VarInt);
50#endif
51#if PROTOCOL_VERSION < 766 /* < 1.20.5 */
53#elif PROTOCOL_VERSION < 777 /* < 26.3 */
55#endif
56
57#if PROTOCOL_VERSION < 766 /* < 1.20.5 */
60#endif
61
63 };
64} //ProtocolCraft
#define SERIALIZED_FIELD_WITHOUT_GETTER_SETTER(Name,...)
Define a field that will be automatically integrated in Read/Write and Json serialization We start by...
#define SERIALIZED_FIELD(Name,...)
#define GETTER(Name)
#define DYNAMIC_TYPE_SETTER(Name, DataName, Factory)
Public setter that also recreates the payload through Factory.
#define SERIALIZED_DYNAMIC_DATA_FIELD(Name, TypeField, Base, Factory)
A dynamic field that is created by Factory(value of Field)
SERIALIZED_FIELD(Particle, ProtocolCraft::Particle)
SERIALIZED_FIELD(RandomizationType, VarInt)
static std::shared_ptr< ParticleOption > CreateParticleOption(const ParticleType type)
Definition Particle.cpp:91
Just a simple type wrapper that will store with T1 and serialize as T2 (can be used for Enum/VarInt f...
Definition Templates.hpp:72