diff options
| author | Liberate <none@none> | 2010-10-07 16:49:35 +0200 |
|---|---|---|
| committer | Liberate <none@none> | 2010-10-07 16:49:35 +0200 |
| commit | 0a1d017b7d1f222a83bda8d5fc4f964ad2612c37 (patch) | |
| tree | cb04c21f20d3d65a4a186fc660f26213752548b1 /src | |
| parent | 6a504b983c6e5f1653f81574669bd4dcfb17c7a3 (diff) | |
Core/Arena: Add a missing change from revision 6802b3bf07. Also personal rating should now start at 1k again if the team rating is over 1k and a new member joins the team (and the start personal rating is set to 0 in the config).
Fixes issue #4283
--HG--
branch : trunk
Diffstat (limited to 'src')
| -rwxr-xr-x | src/server/game/Battlegrounds/ArenaTeam.cpp | 9 | ||||
| -rwxr-xr-x | src/server/game/Battlegrounds/ArenaTeam.h | 2 |
2 files changed, 9 insertions, 2 deletions
diff --git a/src/server/game/Battlegrounds/ArenaTeam.cpp b/src/server/game/Battlegrounds/ArenaTeam.cpp index 4823b159d1a..0e221256857 100755 --- a/src/server/game/Battlegrounds/ArenaTeam.cpp +++ b/src/server/game/Battlegrounds/ArenaTeam.cpp @@ -140,7 +140,14 @@ bool ArenaTeam::AddMember(const uint64& PlayerGuid) } plMMRating = sWorld.getIntConfig(CONFIG_ARENA_START_MATCHMAKER_RATING); - plPRating = sWorld.getIntConfig(CONFIG_ARENA_START_PERSONAL_RATING); + plPRating = 0; + + if (sWorld.getIntConfig(CONFIG_ARENA_START_PERSONAL_RATING) > 0) + plPRating = sWorld.getIntConfig(CONFIG_ARENA_START_PERSONAL_RATING); + else if (GetRating() >= 1000) + plPRating = 1000; + + sWorld.getIntConfig(CONFIG_ARENA_START_PERSONAL_RATING); QueryResult result = CharacterDatabase.PQuery("SELECT matchmaker_rating FROM character_arena_stats WHERE guid='%u' AND slot='%u'", GUID_LOPART(PlayerGuid), GetSlot()); if (result) diff --git a/src/server/game/Battlegrounds/ArenaTeam.h b/src/server/game/Battlegrounds/ArenaTeam.h index 9a9c9ab40d9..1df98fa9780 100755 --- a/src/server/game/Battlegrounds/ArenaTeam.h +++ b/src/server/game/Battlegrounds/ArenaTeam.h @@ -202,7 +202,7 @@ class ArenaTeam void MemberWon(Player * plr, uint32 againstMatchmakerRating, int32 teamratingchange = 12); int32 LostAgainst(uint32 againstRating); void MemberLost(Player * plr, uint32 againstMatchmakerRating, int32 teamratingchange = -12); - void OfflineMemberLost(uint64 guid, uint32 againstMatchmakerRating, int32 teamratingchange = 12); + void OfflineMemberLost(uint64 guid, uint32 againstMatchmakerRating, int32 teamratingchange = -12); void UpdateArenaPointsHelper(std::map<uint32, uint32> & PlayerPoints); |
