diff options
author | Simon Pribylski <66266021+Persson-dev@users.noreply.github.com> | 2022-04-20 12:21:30 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2022-04-20 12:21:30 +0200 |
commit | 21bcb2a7578e6b25faadda89345684871c7144aa (patch) | |
tree | 24f7ad32dcf681360e7c73f5467c073369096f35 /src/Protocol/Protocol_1_8.h | |
parent | handled the infinite loop and style (diff) | |
download | cuberite-21bcb2a7578e6b25faadda89345684871c7144aa.tar cuberite-21bcb2a7578e6b25faadda89345684871c7144aa.tar.gz cuberite-21bcb2a7578e6b25faadda89345684871c7144aa.tar.bz2 cuberite-21bcb2a7578e6b25faadda89345684871c7144aa.tar.lz cuberite-21bcb2a7578e6b25faadda89345684871c7144aa.tar.xz cuberite-21bcb2a7578e6b25faadda89345684871c7144aa.tar.zst cuberite-21bcb2a7578e6b25faadda89345684871c7144aa.zip |
Diffstat (limited to '')
-rw-r--r-- | src/Protocol/Protocol_1_8.h | 14 |
1 files changed, 7 insertions, 7 deletions
diff --git a/src/Protocol/Protocol_1_8.h b/src/Protocol/Protocol_1_8.h index f32754d87..59dacbca0 100644 --- a/src/Protocol/Protocol_1_8.h +++ b/src/Protocol/Protocol_1_8.h @@ -156,9 +156,16 @@ protected: Returns -1 if the protocol version doesn't support this animation. */ virtual signed char GetProtocolEntityStatus(EntityAnimation a_Animation) const; + /** Converts an entity to a protocol-specific entity type. + Only entities that the Send Spawn Entity packet supports are valid inputs to this method */ + virtual UInt8 GetProtocolEntityType(const cEntity & a_Entity) const; + /** Converts eMonsterType to protocol-specific mob types */ virtual UInt32 GetProtocolMobType(eMonsterType a_MobType) const; + /** The 1.8 protocol use a particle id instead of a string. This function converts the name to the id. If the name is incorrect, it returns 0. */ + virtual int GetProtocolParticleID(const AString & a_ParticleName) const; + /** Returns the protocol version. */ virtual Version GetProtocolVersion() const override; @@ -254,13 +261,6 @@ private: /** Adds the received (unencrypted) data to m_ReceivedData, parses complete packets */ void AddReceivedData(cByteBuffer & a_Buffer, ContiguousByteBufferView a_Data); - /** Converts an entity to a protocol-specific entity type. - Only entities that the Send Spawn Entity packet supports are valid inputs to this method */ - static UInt8 GetProtocolEntityType(const cEntity & a_Entity); - - /** The 1.8 protocol use a particle id instead of a string. This function converts the name to the id. If the name is incorrect, it returns 0. */ - static int GetProtocolParticleID(const AString & a_ParticleName); - /** Converts a statistic to a protocol-specific string. Protocols <= 1.12 use strings, hence this is a static as the string-mapping was append-only for the versions that used it. Returns an empty string, handled correctly by the client, for newer, unsupported statistics. */ |