mirror of
https://github.com/whoahq/whoa.git
synced 2026-11-29 01:02:27 +03:00
feat(object): add CGObject::IsA
This commit is contained in:
2 files changed
+5
No files matched your search
@@ -36,6 +36,10 @@ OBJECT_TYPE_ID CGObject::GetTypeID() const {
|
|||||||
return this->m_typeID;
|
return this->m_typeID;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
int32_t CGObject::IsA(OBJECT_TYPE type) const {
|
||||||
|
return (this->GetType() & type) != 0;
|
||||||
|
}
|
||||||
|
|
||||||
CGObjectData* CGObject::Obj() const {
|
CGObjectData* CGObject::Obj() const {
|
||||||
return this->m_obj;
|
return this->m_obj;
|
||||||
}
|
}
|
||||||
@@ -31,6 +31,7 @@ class CGObject {
|
|||||||
WOWGUID GetGUID() const;
|
WOWGUID GetGUID() const;
|
||||||
OBJECT_TYPE GetType() const;
|
OBJECT_TYPE GetType() const;
|
||||||
OBJECT_TYPE_ID GetTypeID() const;
|
OBJECT_TYPE_ID GetTypeID() const;
|
||||||
|
int32_t IsA(OBJECT_TYPE type) const;
|
||||||
|
|
||||||
protected:
|
protected:
|
||||||
// Protected member variables
|
// Protected member variables
|
||||||
|
|||||||
Reference in new issue
Block a user