added Honorable Defender buff for Eye of the storm nodes
ignore one unknown area trigger near fel reaver graveyard --HG-- branch : trunk
This commit is contained in:
@@ -409,6 +409,7 @@ void BattleGroundEY::HandleAreaTrigger(Player *Source, uint32 Trigger)
|
||||
case 4569:
|
||||
case 4570:
|
||||
case 4571:
|
||||
case 5866:
|
||||
break;
|
||||
default:
|
||||
sLog.outError("WARNING: Unhandled AreaTrigger in Battleground: %u", Trigger);
|
||||
@@ -694,6 +695,10 @@ void BattleGroundEY::EventTeamLostPoint(Player *Source, uint32 Point)
|
||||
|
||||
UpdatePointsIcons(Team, Point);
|
||||
UpdatePointsCount(Team);
|
||||
|
||||
//remove bonus honor aura trigger creature when node is lost
|
||||
if (Point < EY_POINTS_MAX)
|
||||
DelCreature(Point + 6);//NULL checks are in DelCreature! 0-5 spirit guides
|
||||
}
|
||||
|
||||
void BattleGroundEY::EventTeamCapturedPoint(Player *Source, uint32 Point)
|
||||
@@ -745,6 +750,22 @@ void BattleGroundEY::EventTeamCapturedPoint(Player *Source, uint32 Point)
|
||||
|
||||
UpdatePointsIcons(Team, Point);
|
||||
UpdatePointsCount(Team);
|
||||
|
||||
if (Point >= EY_POINTS_MAX)
|
||||
return;
|
||||
|
||||
Creature* trigger = GetBGCreature(Point + 6);//0-5 spirit guides
|
||||
if (!trigger)
|
||||
trigger = AddCreature(WORLD_TRIGGER,Point+6,Team,BG_EY_TriggerPositions[Point][0],BG_EY_TriggerPositions[Point][1],BG_EY_TriggerPositions[Point][2],BG_EY_TriggerPositions[Point][3]);
|
||||
|
||||
//add bonus honor aura trigger creature when node is accupied
|
||||
//cast bonus aura (+50% honor in 25yards)
|
||||
//aura should only apply to players who have accupied the node, set correct faction for trigger
|
||||
if (trigger)
|
||||
{
|
||||
trigger->setFaction(Team == ALLIANCE ? 84 : 83);
|
||||
trigger->CastSpell(trigger, SPELL_HONORABLE_DEFENDER_25Y, false);
|
||||
}
|
||||
}
|
||||
|
||||
void BattleGroundEY::EventPlayerCapturedFlag(Player *Source, uint32 BgObjectType)
|
||||
|
||||
@@ -143,7 +143,12 @@ enum EYBattleGroundCreaturesTypes
|
||||
EY_SPIRIT_MAIN_ALLIANCE = 4,
|
||||
EY_SPIRIT_MAIN_HORDE = 5,
|
||||
|
||||
BG_EY_CREATURES_MAX = 6
|
||||
EY_TRIGGER_FEL_REALVER = 6,
|
||||
EY_TRIGGER_BLOOD_ELF = 7,
|
||||
EY_TRIGGER_DRAENEI_RUINS = 8,
|
||||
EY_TRIGGER_MAGE_TOWER = 9,
|
||||
|
||||
BG_EY_CREATURES_MAX = 10
|
||||
};
|
||||
|
||||
enum EYBattleGroundObjectTypes
|
||||
@@ -244,6 +249,14 @@ struct BattleGroundEYPointIconsStruct
|
||||
uint32 WorldStateHordeControlledIndex;
|
||||
};
|
||||
|
||||
// x, y, z, o
|
||||
const float BG_EY_TriggerPositions[EY_POINTS_MAX][4] = {
|
||||
{2044.28f, 1729.68f, 1189.96f, -0.017453f}, // FEL_REALVER center
|
||||
{2048.83f, 1393.65f, 1194.49f, 0.20944f}, // BLOOD_ELF center
|
||||
{2286.56f, 1402.36f, 1197.11f, 3.72381f}, // DRAENEI_RUINS center
|
||||
{2284.48f, 1731.23f, 1189.99f, 2.89725f} // MAGE_TOWER center
|
||||
};
|
||||
|
||||
struct BattleGroundEYLoosingPointStruct
|
||||
{
|
||||
BattleGroundEYLoosingPointStruct(uint32 _SpawnNeutralObjectType, uint32 _DespawnObjectTypeAlliance, uint32 _MessageIdAlliance, uint32 _DespawnObjectTypeHorde, uint32 _MessageIdHorde)
|
||||
|
||||
Reference in New Issue
Block a user