Botcraft 1.21.5
Loading...
Searching...
No Matches
ChickenEntity.hpp
Go to the documentation of this file.
1#pragma once
2
4
5namespace Botcraft
6{
8 {
9 protected:
10#if PROTOCOL_VERSION < 770 /* < 1.21.5 */
11 static constexpr int metadata_count = 0;
12#else
13 static constexpr int metadata_count = 1;
14 static const std::array<std::string, metadata_count> metadata_names;
15#endif
17
18 public:
20 virtual ~ChickenEntity();
21
22 // Object related stuff
23 virtual std::string GetName() const override;
24 virtual EntityType GetType() const override;
25
26 // Static stuff, for easier comparison
27 static std::string GetClassName();
28 static EntityType GetClassType();
29
30#if PROTOCOL_VERSION > 769 /* > 1.21.4 */
31 virtual ProtocolCraft::Json::Value Serialize() const override;
32
33 // Metadata stuff
34 virtual void SetMetadataValue(const int index, const std::any& value) override;
35
36 int GetDataVariantId() const;
37
38 void SetDataVariantId(const int data_variant_id);
39#endif
40
41 protected:
42 virtual double GetWidthImpl() const override;
43 virtual double GetHeightImpl() const override;
44
45 };
46}
static constexpr int metadata_count
static constexpr int hierarchy_metadata_count
virtual ProtocolCraft::Json::Value Serialize() const override
virtual std::string GetName() const override
static constexpr int hierarchy_metadata_count
static constexpr int metadata_count
void SetDataVariantId(const int data_variant_id)
virtual double GetWidthImpl() const override
static EntityType GetClassType()
static std::string GetClassName()
virtual void SetMetadataValue(const int index, const std::any &value) override
virtual double GetHeightImpl() const override
static const std::array< std::string, metadata_count > metadata_names
virtual EntityType GetType() const override
Main class, basically a JsonVariant with extra utility functions it doesn't inherit JsonVariant direc...
Definition Json.hpp:45