2 * Copyright (C) 2005-2013 MaNGOS <http://getmangos.com/>
4 * This program is free software; you can redistribute it and/or modify
5 * it under the terms of the GNU General Public License as published by
6 * the Free Software Foundation; either version 2 of the License, or
7 * (at your option) any later version.
9 * This program is distributed in the hope that it will be useful,
10 * but WITHOUT ANY WARRANTY; without even the implied warranty of
11 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
12 * GNU General Public License for more details.
14 * You should have received a copy of the GNU General Public License
15 * along with this program; if not, write to the Free Software
16 * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
19 #ifndef WORLD_PVP_MGR_H
20 #define WORLD_PVP_MGR_H
23 #include "Policies/Singleton.h"
28 TIMER_OPVP_MGR_UPDATE
= MINUTE
* IN_MILLISECONDS
// 1 minute is enough for us but this might change with wintergrasp support
46 ZONE_ID_SILITHUS
= 1377,
47 ZONE_ID_TEMPLE_OF_AQ
= 3428,
48 ZONE_ID_RUINS_OF_AQ
= 3429,
49 ZONE_ID_GATES_OF_AQ
= 3478,
51 ZONE_ID_EASTERN_PLAGUELANDS
= 139,
52 ZONE_ID_STRATHOLME
= 2017,
53 ZONE_ID_SCHOLOMANCE
= 2057,
55 ZONE_ID_HELLFIRE_PENINSULA
= 3483,
56 ZONE_ID_HELLFIRE_RAMPARTS
= 3562,
57 ZONE_ID_HELLFIRE_CITADEL
= 3563,
58 ZONE_ID_BLOOD_FURNACE
= 3713,
59 ZONE_ID_SHATTERED_HALLS
= 3714,
60 ZONE_ID_MAGTHERIDON_LAIR
= 3836,
62 ZONE_ID_ZANGARMARSH
= 3521,
63 ZONE_ID_SERPENTSHRINE_CAVERN
= 3607,
64 ZONE_ID_STREAMVAULT
= 3715,
65 ZONE_ID_UNDERBOG
= 3716,
66 ZONE_ID_SLAVE_PENS
= 3717,
68 ZONE_ID_TEROKKAR_FOREST
= 3519,
69 ZONE_ID_SHADOW_LABYRINTH
= 3789,
70 ZONE_ID_AUCHENAI_CRYPTS
= 3790,
71 ZONE_ID_SETHEKK_HALLS
= 3791,
72 ZONE_ID_MANA_TOMBS
= 3792,
74 ZONE_ID_NAGRAND
= 3518,
76 ZONE_ID_GRIZZLY_HILLS
= 394
90 // load all outdoor pvp scripts
91 void InitOutdoorPvP();
93 // called when a player enters an outdoor pvp area
94 void HandlePlayerEnterZone(Player
* player
, uint32 zoneId
);
96 // called when player leaves an outdoor pvp area
97 void HandlePlayerLeaveZone(Player
* player
, uint32 zoneId
);
99 // return assigned outdoor pvp script
100 OutdoorPvP
* GetScript(uint32 zoneId
);
102 void Update(uint32 diff
);
104 // Save and load capture point slider values
105 float GetCapturePointSliderValue(uint32 entry
, float defaultValue
);
106 void SetCapturePointSlider(uint32 entry
, float value
) { m_capturePointSlider
[entry
] = value
; }
109 // return assigned outdoor pvp script
110 OutdoorPvP
* GetScriptOfAffectedZone(uint32 zoneId
);
112 // contains all outdoor pvp scripts
113 OutdoorPvP
* m_scripts
[MAX_OPVP_ID
];
115 typedef std::map
<uint32
/*capture point entry*/, float /*slider value*/> CapturePointSliderMap
;
117 CapturePointSliderMap m_capturePointSlider
;
120 ShortIntervalTimer m_updateTimer
;
123 #define sOutdoorPvPMgr MaNGOS::Singleton<OutdoorPvPMgr>::Instance()