Show
Ignore:
Timestamp:
11/19/08 13:29:16 (17 years ago)
Author:
yumileroy
Message:

[svn] Enabled game events to change the honor and reputation gaining speed in battlegrounds. This is done by a new table in the world database, game_event_battleground_holiday. Structure is the following:
event - id of the game event
bgflag - bitmask, used to set which battleground(s) give extra honor/reputation when the event is active. To add extra honor on a battleground, use 2 bgTypeId as mask. Multiple battlegrounds can be set by logical 'or' ('|') operation.
You will need database data for the table, please check trinitydatabase.org.

Original author: w12x
Date: 2008-10-17 16:36:07-05:00

Files:
1 modified

Legend:

Unmodified
Added
Removed
  • trunk/src/game/BattleGroundAB.cpp

    r44 r50  
    3030#include "World.h" 
    3131#include "Util.h" 
     32 
     33// these variables aren't used outside of this file, so declare them only here 
     34uint32 BG_AB_HonorScoreTicks[BG_HONOR_MODE_NUM] = { 
     35    330, // normal honor 
     36    200  // holiday 
     37}; 
     38 
     39uint32 BG_AB_ReputationScoreTicks[BG_HONOR_MODE_NUM] = { 
     40    200, // normal honor 
     41    150  // holiday 
     42}; 
    3243 
    3344BattleGroundAB::BattleGroundAB() 
     
    187198                m_HonorScoreTics[team] += BG_AB_TickPoints[points]; 
    188199                m_ReputationScoreTics[team] += BG_AB_TickPoints[points]; 
    189                 if( m_ReputationScoreTics[team] >= 200 ) 
     200                if( m_ReputationScoreTics[team] >= BG_AB_ReputationScoreTicks[m_HonorMode] ) 
    190201                { 
    191202                    (team == BG_TEAM_ALLIANCE) ? RewardReputationToTeam(509, 10, ALLIANCE) : RewardReputationToTeam(510, 10, HORDE); 
    192                     m_ReputationScoreTics[team] -= 200; 
     203                    m_ReputationScoreTics[team] -= BG_AB_ReputationScoreTicks[m_HonorMode]; 
    193204                } 
    194                 if( m_HonorScoreTics[team] >= BG_HONOR_SCORE_TICKS ) 
     205                if( m_HonorScoreTics[team] >= BG_AB_HonorScoreTicks[m_HonorMode] ) 
    195206                { 
    196207                    (team == BG_TEAM_ALLIANCE) ? RewardHonorToTeam(20, ALLIANCE) : RewardHonorToTeam(20, HORDE); 
    197                     m_HonorScoreTics[team] -= BG_HONOR_SCORE_TICKS; 
     208                    m_HonorScoreTics[team] -= BG_AB_HonorScoreTicks[m_HonorMode]; 
    198209                } 
    199210                if( !m_IsInformedNearVictory && m_TeamScores[team] > 1800 )