mirror of
https://github.com/mangosfour/server.git
synced 2025-12-14 16:37:01 +00:00
[7540] Move most reputation/force faction reaction code to new ReputationMgr.
This commit is contained in:
parent
ef014420a5
commit
c33eff13f4
19 changed files with 773 additions and 647 deletions
|
|
@ -5015,12 +5015,10 @@ bool ChatHandler::HandleQuestComplete(const char* args)
|
|||
if(uint32 repFaction = pQuest->GetRepObjectiveFaction())
|
||||
{
|
||||
uint32 repValue = pQuest->GetRepObjectiveValue();
|
||||
uint32 curRep = player->GetReputation(repFaction);
|
||||
uint32 curRep = player->GetReputationMgr().GetReputation(repFaction);
|
||||
if(curRep < repValue)
|
||||
{
|
||||
FactionEntry const *factionEntry = sFactionStore.LookupEntry(repFaction);
|
||||
player->SetFactionReputation(factionEntry,repValue);
|
||||
}
|
||||
if(FactionEntry const *factionEntry = sFactionStore.LookupEntry(repFaction))
|
||||
player->GetReputationMgr().SetReputation(factionEntry,repValue);
|
||||
}
|
||||
|
||||
// If the quest requires money
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue