Core/Misc:
- fixed an oracle/wolvar reputation change issue - moved texts of read pronouncement to db Closes #9105
This commit is contained in:
1 parent
816c8c1c7a
commit
5ad8dcc5d6
3 files changed
+21
-14
No files matched your search
@@ -2573,16 +2573,15 @@ class spell_gen_oracle_wolvar_reputation : public SpellScriptLoader
|
||||
{
|
||||
Player* player = GetCaster()->ToPlayer();
|
||||
uint32 factionId = GetSpellInfo()->Effects[effIndex].CalcValue();
|
||||
int32 repChange = GetSpellInfo()->Effects[EFFECT_1].CalcValue();
|
||||
int32 repChange = GetSpellInfo()->Effects[EFFECT_1].CalcValue();
|
||||
|
||||
FactionEntry const* factionEntry = sFactionStore.LookupEntry(factionId);
|
||||
|
||||
if (!factionEntry)
|
||||
return;
|
||||
|
||||
// Set rep to baserep + basepoints (expecting spillover for oposite faction -> become hated)
|
||||
// Not when player already has equal or higher rep with this faction
|
||||
if (player->GetReputationMgr().GetBaseReputation(factionEntry) < repChange)
|
||||
if (player->GetReputationMgr().GetReputation(factionEntry) <= repChange)
|
||||
player->GetReputationMgr().SetReputation(factionEntry, repChange);
|
||||
|
||||
// EFFECT_INDEX_2 most likely update at war state, we already handle this in SetReputation
|
||||
|
||||
Reference in new issue
Block a user