Fix cPawn pushing
cPawn instances can no longer push an entity they are attached to. cEntity now has a IsAttachedTo method.
This commit is contained in:
@@ -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;
|
||||
|
||||
Reference in New Issue
Block a user