Browse Source

Pets cannot aggro their master, this addresses charming a pet and being able to sent it to attack, follow you correctly without locking encounter

Emagi 1 year ago
parent
commit
4c5202e216
1 changed files with 2 additions and 0 deletions
  1. 2 0
      EQ2/source/WorldServer/NPC_AI.cpp

+ 2 - 0
EQ2/source/WorldServer/NPC_AI.cpp

@@ -204,6 +204,8 @@ void Brain::AddHate(Entity* entity, sint32 hate) {
 	// do not aggro when running back, despite taking damage
 	if (m_body->IsNPC() && ((NPC*)m_body)->m_runningBack)
 		return;
+	else if (m_body->IsPet() && m_body->IsEntity() && ((Entity*)m_body)->GetOwner() == entity)
+		return;
 
 	if(m_body->IsImmune(IMMUNITY_TYPE_TAUNT))
 	{