• This is a read only backup of the old Emudevs forum. If you want to have anything removed, please message me on Discord: KittyKaev

[SOLVED] BG Reward's

Status
Not open for further replies.

Come2WoW

Respected Member
hi, sry im english is bad :D
i need a script for BG.when win in the BG reward 3 Token and when los reward 1 token.
 

Hamar

BETA Tester
hi, sry im english is bad :D
i need a script for BG.when win in the BG reward 3 Token and when los reward 1 token.

This can be found in the battleground.cpp file
find this:
Code:
        // Reward winner team
        if (team == winner)
        {
            if (IsRandom() || BattlegroundMgr::IsBGWeekend(GetTypeID()))
            {
                UpdatePlayerScore(player, SCORE_BONUS_HONOR, GetBonusHonorFromKill(winner_kills));
                if (CanAwardArenaPoints())
                    player->ModifyArenaPoints(winner_arena);
                if (!player->GetRandomWinner())
                    player->SetRandomWinner(true);
            }

            player->UpdateAchievementCriteria(ACHIEVEMENT_CRITERIA_TYPE_WIN_BG, 1);
        }
        else
        {
            if (IsRandom() || BattlegroundMgr::IsBGWeekend(GetTypeID()))
                UpdatePlayerScore(player, SCORE_BONUS_HONOR, GetBonusHonorFromKill(loser_kills));
        }

and replace it with this:
Code:
        if (team == winner)
        {
            if (IsRandom() || BattlegroundMgr::IsBGWeekend(GetTypeID()))
            {
                UpdatePlayerScore(player, SCORE_BONUS_HONOR, GetBonusHonorFromKill(winner_kills));
                if (CanAwardArenaPoints())
                    player->ModifyArenaPoints(winner_arena);
                if (!player->GetRandomWinner())
                    player->SetRandomWinner(true);
            }
            // Reward winner team player here.
            player->AddItem(23423, 3);
            player->UpdateAchievementCriteria(ACHIEVEMENT_CRITERIA_TYPE_WIN_BG, 1);
        }
        else
        {
            if (IsRandom() || BattlegroundMgr::IsBGWeekend(GetTypeID()))
                UpdatePlayerScore(player, SCORE_BONUS_HONOR, GetBonusHonorFromKill(loser_kills));

            // Reward looser team player here.
            player->AddItem(23423, 1);
        }

You can find it around lines 894+ (If you're on latest trinitycore revision)
 
Status
Not open for further replies.
Top