Merge pull request #13077 from mik1893/fear_vs_possess
Core/Unit: Do not give client control back to player after fear/confuse if player is under player charm (UNIT_STATE_POSSESSED)
This commit is contained in:
@@ -15707,7 +15707,8 @@ void Unit::SetFeared(bool apply)
|
||||
}
|
||||
|
||||
if (Player* player = ToPlayer())
|
||||
player->SetClientControl(this, !apply);
|
||||
if(!player->HasUnitState(UNIT_STATE_POSSESSED))
|
||||
player->SetClientControl(this, !apply);
|
||||
}
|
||||
|
||||
void Unit::SetConfused(bool apply)
|
||||
@@ -15729,7 +15730,8 @@ void Unit::SetConfused(bool apply)
|
||||
}
|
||||
|
||||
if (Player* player = ToPlayer())
|
||||
player->SetClientControl(this, !apply);
|
||||
if (!player->HasUnitState(UNIT_STATE_POSSESSED))
|
||||
player->SetClientControl(this, !apply);
|
||||
}
|
||||
|
||||
bool Unit::SetCharmedBy(Unit* charmer, CharmType type, AuraApplication const* aurApp)
|
||||
|
||||
Reference in New Issue
Block a user