summaryrefslogtreecommitdiffstats
path: root/src/Entities/Entity.cpp
diff options
context:
space:
mode:
authorMarvin Kopf <marvinkopf@posteo.de>2016-02-02 14:44:10 +0100
committerMarvin Kopf <marvinkopf@posteo.de>2016-02-02 14:57:20 +0100
commita1c48f4853b234e920e96671c4ff218567d4f2d4 (patch)
treeb6f5c8c073837c43f15b68414db1aaa92bbbab6a /src/Entities/Entity.cpp
parentMerge pull request #2936 from mathias-github/master (diff)
downloadcuberite-a1c48f4853b234e920e96671c4ff218567d4f2d4.tar
cuberite-a1c48f4853b234e920e96671c4ff218567d4f2d4.tar.gz
cuberite-a1c48f4853b234e920e96671c4ff218567d4f2d4.tar.bz2
cuberite-a1c48f4853b234e920e96671c4ff218567d4f2d4.tar.lz
cuberite-a1c48f4853b234e920e96671c4ff218567d4f2d4.tar.xz
cuberite-a1c48f4853b234e920e96671c4ff218567d4f2d4.tar.zst
cuberite-a1c48f4853b234e920e96671c4ff218567d4f2d4.zip
Diffstat (limited to 'src/Entities/Entity.cpp')
-rw-r--r--src/Entities/Entity.cpp13
1 files changed, 13 insertions, 0 deletions
diff --git a/src/Entities/Entity.cpp b/src/Entities/Entity.cpp
index d4097f734..593bc6aca 100644
--- a/src/Entities/Entity.cpp
+++ b/src/Entities/Entity.cpp
@@ -1864,6 +1864,19 @@ bool cEntity::IsA(const char * a_ClassName) const
+bool cEntity::IsAttachedTo(const cEntity * a_Entity) const
+{
+ if ((m_AttachedTo != nullptr) && (a_Entity->GetUniqueID() == m_AttachedTo->GetUniqueID()))
+ {
+ return true;
+ }
+ return false;
+}
+
+
+
+
+
void cEntity::SetHeadYaw(double a_HeadYaw)
{
m_HeadYaw = a_HeadYaw;