aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorShauren <shauren.trinity@gmail.com>2021-08-28 18:03:30 +0200
committerShauren <shauren.trinity@gmail.com>2021-08-28 18:03:30 +0200
commitb9647bdecc08e63041bbf0d845d5c5b81705e180 (patch)
tree4efe9d916a16c7e2f6425d1c7d246493485fa474 /src
parent8cc418460fb8278002b0b8416b49728d0ff0ec76 (diff)
Core/Reputation: Fixed FriendshipReputationFlags::NoRepGainModifiers implementation
Diffstat (limited to 'src')
-rw-r--r--src/server/game/Entities/Player/Player.cpp13
1 files changed, 8 insertions, 5 deletions
diff --git a/src/server/game/Entities/Player/Player.cpp b/src/server/game/Entities/Player/Player.cpp
index 166b650f7e9..57a1d0b2b5c 100644
--- a/src/server/game/Entities/Player/Player.cpp
+++ b/src/server/game/Entities/Player/Player.cpp
@@ -6275,13 +6275,16 @@ int32 Player::CalculateReputationGain(ReputationSource source, uint32 creatureOr
float percent = 100.0f;
- float repMod = noQuestBonus ? 0.0f : float(GetTotalAuraModifier(SPELL_AURA_MOD_REPUTATION_GAIN));
+ if (!noBonuses)
+ {
+ float repMod = noQuestBonus ? 0.0f : float(GetTotalAuraModifier(SPELL_AURA_MOD_REPUTATION_GAIN));
- // faction specific auras only seem to apply to kills
- if (source == REPUTATION_SOURCE_KILL)
- repMod += GetTotalAuraModifierByMiscValue(SPELL_AURA_MOD_FACTION_REPUTATION_GAIN, faction);
+ // faction specific auras only seem to apply to kills
+ if (source == REPUTATION_SOURCE_KILL)
+ repMod += GetTotalAuraModifierByMiscValue(SPELL_AURA_MOD_FACTION_REPUTATION_GAIN, faction);
- percent += rep > 0 ? repMod : -repMod;
+ percent += rep > 0 ? repMod : -repMod;
+ }
float rate;
switch (source)