aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorXTZGZoReX <none@none>2010-08-06 23:22:21 +0200
committerXTZGZoReX <none@none>2010-08-06 23:22:21 +0200
commit2cdd8686455da998c4a00918c80b1d54f7bdc098 (patch)
tree40918481c101dbd70fbc704f9e4b8920624073a4 /src
parent0993b1fcb5f2d33543bfd61f4ddb91a7a2db6086 (diff)
parent1c39e1a2f569a443556f86a8dcfacadbfc435684 (diff)
* Merge.
--HG-- branch : trunk
Diffstat (limited to 'src')
-rw-r--r--src/server/game/BattleGrounds/BattleGround.cpp3
-rw-r--r--src/server/game/BattleGrounds/BattleGround.h3
2 files changed, 5 insertions, 1 deletions
diff --git a/src/server/game/BattleGrounds/BattleGround.cpp b/src/server/game/BattleGrounds/BattleGround.cpp
index d9d6dc98a58..bc2c629aaf5 100644
--- a/src/server/game/BattleGrounds/BattleGround.cpp
+++ b/src/server/game/BattleGrounds/BattleGround.cpp
@@ -806,7 +806,8 @@ void BattleGround::EndBattleGround(uint32 winner)
if (IsRandom() || BattleGroundMgr::IsBGWeekend(GetTypeID()))
{
UpdatePlayerScore(plr, SCORE_BONUS_HONOR, GetBonusHonorFromKill(win_kills));
- plr->ModifyArenaPoints(win_arena);
+ if (CanAwardArenaPoints())
+ plr->ModifyArenaPoints(win_arena);
if (!plr->GetRandomWinner())
plr->SetRandomWinner(true);
}
diff --git a/src/server/game/BattleGrounds/BattleGround.h b/src/server/game/BattleGrounds/BattleGround.h
index 586f0293d96..6fbd8d1e53c 100644
--- a/src/server/game/BattleGrounds/BattleGround.h
+++ b/src/server/game/BattleGrounds/BattleGround.h
@@ -311,6 +311,8 @@ enum BGHonorMode
BG_HONOR_MODE_NUM
};
+#define BG_AWARD_ARENA_POINTS_MIN_LEVEL 71
+
/*
This class is used to:
1. Add player to battleground
@@ -574,6 +576,7 @@ class BattleGround
int32 m_TeamScores[BG_TEAMS_COUNT];
void RewardXPAtKill(Player* plr, Player* victim);
+ bool CanAwardArenaPoints() const { return m_LevelMin >= BG_AWARD_ARENA_POINTS_MIN_LEVEL; }
protected:
//this method is called, when BG cannot spawn its own spirit guide, or something is wrong, It correctly ends BattleGround