[Bug Fix] Fix Swarm Pet Flurry/Rampages Messages (#2444)

* Fix Swarm Pet Flurry/Rampages Messages

* Fixed formatting
This commit is contained in:
Aeadoin 2022-09-25 13:00:43 -04:00 committed by GitHub
parent c826d3b4e9
commit 2b203c0ebe
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -2114,12 +2114,12 @@ bool Mob::Flurry(ExtraAttackOptions *opts)
// this is wrong, flurry is extra attacks on the current target
Mob *target = GetTarget();
if (target) {
if (!IsPet()) {
if (IsPet() || IsTempPet() || IsCharmed() || IsAnimation()) {
entity_list.MessageCloseString(
this,
true,
200,
Chat::NPCFlurry,
Chat::PetFlurry,
NPC_FLURRY,
GetCleanName(),
target->GetCleanName());
@ -2128,7 +2128,7 @@ bool Mob::Flurry(ExtraAttackOptions *opts)
this,
true,
200,
Chat::PetFlurry,
Chat::NPCFlurry,
NPC_FLURRY,
GetCleanName(),
target->GetCleanName());
@ -2167,11 +2167,11 @@ void Mob::ClearRampage()
bool Mob::Rampage(ExtraAttackOptions *opts)
{
int index_hit = 0;
if (!IsPet())
entity_list.MessageCloseString(this, true, 200, Chat::NPCRampage, NPC_RAMPAGE, GetCleanName());
else
if (IsPet() || IsTempPet() || IsCharmed() || IsAnimation()){
entity_list.MessageCloseString(this, true, 200, Chat::PetFlurry, NPC_RAMPAGE, GetCleanName());
} else {
entity_list.MessageCloseString(this, true, 200, Chat::NPCRampage, NPC_RAMPAGE, GetCleanName());
}
int rampage_targets = GetSpecialAbilityParam(SPECATK_RAMPAGE, 1);
if (rampage_targets == 0) // if set to 0 or not set in the DB
rampage_targets = RuleI(Combat, DefaultRampageTargets);
@ -2224,10 +2224,10 @@ bool Mob::Rampage(ExtraAttackOptions *opts)
void Mob::AreaRampage(ExtraAttackOptions *opts)
{
int index_hit = 0;
if (!IsPet()) { // do not know every pet AA so thought it safer to add this
entity_list.MessageCloseString(this, true, 200, Chat::NPCRampage, AE_RAMPAGE, GetCleanName());
} else {
if (IsPet() || IsTempPet() || IsCharmed() || IsAnimation()) { // do not know every pet AA so thought it safer to add this
entity_list.MessageCloseString(this, true, 200, Chat::PetFlurry, AE_RAMPAGE, GetCleanName());
} else {
entity_list.MessageCloseString(this, true, 200, Chat::NPCRampage, AE_RAMPAGE, GetCleanName());
}
int rampage_targets = GetSpecialAbilityParam(SPECATK_AREA_RAMPAGE, 1);