diff --git a/common/ruletypes.h b/common/ruletypes.h index 57721efa7..832878b40 100644 --- a/common/ruletypes.h +++ b/common/ruletypes.h @@ -763,7 +763,7 @@ RULE_REAL(Bots, ManaRegen, 2.0, "Adjust mana regen. Acts as a final multiplier, RULE_BOOL(Bots, PreferNoManaCommandSpells, true, "Give sorting priority to newer no-mana spells (i.e., 'Bind Affinity')") RULE_BOOL(Bots, QuestableSpawnLimit, false, "Optional quest method to manage bot spawn limits using the quest_globals name bot_spawn_limit, see: /bazaar/Aediles_Thrall.pl") RULE_INT(Bots, SpawnLimit, 71, "Number of bots a character can have spawned at one time, You + 71 bots is a 12 group pseudo-raid") -RULE_BOOL(Bots, BotGroupXP, false, "Determines whether client gets experience for bots outside their group") +RULE_BOOL(Bots, SameRaidGroupForXP, false, "Whether or not bots are required to be in the same raid group to give exp. Default false") RULE_BOOL(Bots, BotLevelsWithOwner, false, "Auto-updates spawned bots as owner levels/de-levels (false is original behavior)") RULE_INT(Bots, BotCharacterLevel, 0, "If level is greater that value player can spawn bots if BotCharacterLevelEnabled is true") RULE_INT(Bots, CasterStopMeleeLevel, 13, "Level at which caster bots stop melee attacks") diff --git a/zone/attack.cpp b/zone/attack.cpp index ceca940b7..d1c862096 100644 --- a/zone/attack.cpp +++ b/zone/attack.cpp @@ -2624,27 +2624,17 @@ bool NPC::Death(Mob* killer_mob, int64 damage, uint16 spell, EQ::skills::SkillTy bool owner_in_group = false; if ( - ( - give_exp->HasGroup() && - give_exp->GetGroup()->IsGroupMember(give_exp->GetUltimateOwner()) - ) || - ( - give_exp->IsPet() && - ( - give_exp->GetOwner()->IsClient() || - ( - give_exp->GetOwner()->HasGroup() && - give_exp->GetOwner()->GetGroup()->IsGroupMember(give_exp->GetOwner()->GetUltimateOwner()) - ) - ) - ) + give_exp->IsInGroupOrRaid(give_exp->GetUltimateOwner(), RuleB(Bots, SameRaidGroupForXP)) || + give_exp->IsPet() && + give_exp->GetOwner() && + give_exp->GetOwner()->IsInGroupOrRaid(give_exp->GetUltimateOwner(), RuleB(Bots, SameRaidGroupForXP)) ) { owner_in_group = true; } give_exp = give_exp->GetUltimateOwner(); - if (!RuleB(Bots, BotGroupXP) && !owner_in_group) { + if (!owner_in_group) { give_exp = nullptr; } }