mirror of
https://github.com/TrinityCore/TrinityCore.git
synced 2026-01-18 16:38:42 +01:00
Core/Wintergrasp: correctly fix collision for invisible wall in wg. also fixes recent crash. closes #7548
This commit is contained in:
@@ -1209,7 +1209,7 @@ struct BfWGGameObjectBuilding
|
||||
m_Build->SetDestructibleState(GO_DESTRUCTIBLE_REBUILDING, NULL, true);
|
||||
if (m_Build->GetEntry() == GO_WINTERGRASP_VAULT_GATE)
|
||||
if (GameObject* go = m_Build->FindNearestGameObject(GO_WINTERGRASP_KEEP_COLLISION_WALL, 10.0f))
|
||||
go->SetDestructibleState(GO_DESTRUCTIBLE_REBUILDING, NULL, true);
|
||||
go->EnableCollision(true);
|
||||
|
||||
// Update worldstate
|
||||
m_State = BATTLEFIELD_WG_OBJECTSTATE_ALLIANCE_INTACT - (m_Team * 3);
|
||||
@@ -1266,7 +1266,7 @@ struct BfWGGameObjectBuilding
|
||||
break;
|
||||
case BATTLEFIELD_WG_OBJECTTYPE_DOOR_LAST:
|
||||
if (GameObject* go = m_Build->FindNearestGameObject(GO_WINTERGRASP_KEEP_COLLISION_WALL, 10.0f))
|
||||
go->SetDestructibleState(GO_DESTRUCTIBLE_DESTROYED);
|
||||
go->EnableCollision(false);
|
||||
m_WG->SetRelicInteractible(true);
|
||||
if (m_WG->GetRelic())
|
||||
m_WG->GetRelic()->RemoveFlag(GAMEOBJECT_FLAGS, GO_FLAG_IN_USE);
|
||||
|
||||
Reference in New Issue
Block a user