This commit is contained in:
committed by
Stoabrogga
parent
69ebb5081b
commit
5e2ac17888
@@ -437,6 +437,9 @@ void BattlegroundAV::PostUpdateImpl(uint32 diff)
|
|||||||
|
|
||||||
void BattlegroundAV::StartingEventCloseDoors()
|
void BattlegroundAV::StartingEventCloseDoors()
|
||||||
{
|
{
|
||||||
|
SpawnBGObject(BG_AV_OBJECT_DOOR_A, RESPAWN_IMMEDIATELY);
|
||||||
|
SpawnBGObject(BG_AV_OBJECT_DOOR_H, RESPAWN_IMMEDIATELY);
|
||||||
|
|
||||||
DoorClose(BG_AV_OBJECT_DOOR_A);
|
DoorClose(BG_AV_OBJECT_DOOR_A);
|
||||||
DoorClose(BG_AV_OBJECT_DOOR_H);
|
DoorClose(BG_AV_OBJECT_DOOR_H);
|
||||||
}
|
}
|
||||||
@@ -1208,15 +1211,6 @@ GraveyardStruct const* BattlegroundAV::GetClosestGraveyard(Player* player)
|
|||||||
bool BattlegroundAV::SetupBattleground()
|
bool BattlegroundAV::SetupBattleground()
|
||||||
{
|
{
|
||||||
// Create starting objects
|
// Create starting objects
|
||||||
if (
|
|
||||||
// alliance gates
|
|
||||||
!AddObject(BG_AV_OBJECT_DOOR_A, BG_AV_OBJECTID_GATE_A, BG_AV_DoorPositons[0][0], BG_AV_DoorPositons[0][1], BG_AV_DoorPositons[0][2], BG_AV_DoorPositons[0][3], 0, 0, sin(BG_AV_DoorPositons[0][3]/2), cos(BG_AV_DoorPositons[0][3]/2), RESPAWN_IMMEDIATELY)
|
|
||||||
// horde gates
|
|
||||||
|| !AddObject(BG_AV_OBJECT_DOOR_H, BG_AV_OBJECTID_GATE_H, BG_AV_DoorPositons[1][0], BG_AV_DoorPositons[1][1], BG_AV_DoorPositons[1][2], BG_AV_DoorPositons[1][3], 0, 0, sin(BG_AV_DoorPositons[1][3]/2), cos(BG_AV_DoorPositons[1][3]/2), RESPAWN_IMMEDIATELY))
|
|
||||||
{
|
|
||||||
sLog->outErrorDb("BatteGroundAV: Failed to spawn some object Battleground not created!1");
|
|
||||||
return false;
|
|
||||||
}
|
|
||||||
|
|
||||||
//spawn node-objects
|
//spawn node-objects
|
||||||
for (uint8 i = BG_AV_NODES_FIRSTAID_STATION; i < BG_AV_NODES_MAX; ++i)
|
for (uint8 i = BG_AV_NODES_FIRSTAID_STATION; i < BG_AV_NODES_MAX; ++i)
|
||||||
@@ -1387,9 +1381,7 @@ bool BattlegroundAV::SetupBattleground()
|
|||||||
}
|
}
|
||||||
|
|
||||||
//snowfall and the doors
|
//snowfall and the doors
|
||||||
for (i = BG_AV_OBJECT_FLAG_N_SNOWFALL_GRAVE; i <= BG_AV_OBJECT_DOOR_A; i++)
|
SpawnBGObject(BG_AV_OBJECT_FLAG_N_SNOWFALL_GRAVE, RESPAWN_IMMEDIATELY);
|
||||||
SpawnBGObject(i, RESPAWN_IMMEDIATELY);
|
|
||||||
|
|
||||||
SpawnBGObject(BG_AV_OBJECT_AURA_N_SNOWFALL_GRAVE, RESPAWN_IMMEDIATELY);
|
SpawnBGObject(BG_AV_OBJECT_AURA_N_SNOWFALL_GRAVE, RESPAWN_IMMEDIATELY);
|
||||||
|
|
||||||
// Handpacked snowdrift, only during holiday
|
// Handpacked snowdrift, only during holiday
|
||||||
@@ -1429,6 +1421,17 @@ bool BattlegroundAV::SetupBattleground()
|
|||||||
for (i = AV_NPC_A_MARSHAL_SOUTH; i <= AV_NPC_H_MARSHAL_WTOWER; i++)
|
for (i = AV_NPC_A_MARSHAL_SOUTH; i <= AV_NPC_H_MARSHAL_WTOWER; i++)
|
||||||
AddAVCreature(i, AV_CPLACE_A_MARSHAL_SOUTH + (i - AV_NPC_A_MARSHAL_SOUTH));
|
AddAVCreature(i, AV_CPLACE_A_MARSHAL_SOUTH + (i - AV_NPC_A_MARSHAL_SOUTH));
|
||||||
AddAVCreature(AV_NPC_HERALD, AV_CPLACE_HERALD);
|
AddAVCreature(AV_NPC_HERALD, AV_CPLACE_HERALD);
|
||||||
|
|
||||||
|
if (
|
||||||
|
// alliance gates
|
||||||
|
!AddObject(BG_AV_OBJECT_DOOR_A, BG_AV_OBJECTID_GATE_A, BG_AV_DoorPositons[0][0], BG_AV_DoorPositons[0][1], BG_AV_DoorPositons[0][2], BG_AV_DoorPositons[0][3], 0, 0, sin(BG_AV_DoorPositons[0][3]/2), cos(BG_AV_DoorPositons[0][3]/2), RESPAWN_IMMEDIATELY)
|
||||||
|
// horde gates
|
||||||
|
|| !AddObject(BG_AV_OBJECT_DOOR_H, BG_AV_OBJECTID_GATE_H, BG_AV_DoorPositons[1][0], BG_AV_DoorPositons[1][1], BG_AV_DoorPositons[1][2], BG_AV_DoorPositons[1][3], 0, 0, sin(BG_AV_DoorPositons[1][3]/2), cos(BG_AV_DoorPositons[1][3]/2), RESPAWN_IMMEDIATELY))
|
||||||
|
{
|
||||||
|
sLog->outErrorDb("BatteGroundAV: Failed to spawn some object Battleground not created!1");
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user