Make sure a spawn that is available gets locked into the encounter if the encounter size is 0.
This commit is contained in:
parent
cde778bb1a
commit
80f56f68c4
@ -1342,7 +1342,7 @@ void Entity::AddHate(Entity* attacker, sint32 hate) {
|
|||||||
((NPC*)this)->Brain()->AddHate(attacker, hate);
|
((NPC*)this)->Brain()->AddHate(attacker, hate);
|
||||||
int8 loot_state = ((NPC*)this)->GetLockedNoLoot();
|
int8 loot_state = ((NPC*)this)->GetLockedNoLoot();
|
||||||
// if encounter size is 0 then add the attacker to the encounter
|
// if encounter size is 0 then add the attacker to the encounter
|
||||||
if ((loot_state != ENCOUNTER_STATE_AVAILABLE && loot_state != ENCOUNTER_STATE_BROKEN && ((NPC*)this)->Brain()->GetEncounterSize() == 0)) {
|
if ((loot_state != ENCOUNTER_STATE_BROKEN && ((NPC*)this)->Brain()->GetEncounterSize() == 0)) {
|
||||||
((NPC*)this)->Brain()->AddToEncounter(attacker);
|
((NPC*)this)->Brain()->AddToEncounter(attacker);
|
||||||
AddTargetToEncounter(attacker);
|
AddTargetToEncounter(attacker);
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user