feat(Core/GameObject): Gob flag helpers (#11287)

This commit is contained in:
Kitzunu
2022-04-05 13:52:58 +02:00
committed by GitHub
parent edb7cac19b
commit b41967a067
54 changed files with 155 additions and 145 deletions
@@ -225,7 +225,7 @@ void BattlefieldWG::OnBattleStart()
// Update faction of relic, only attacker can click on
go->SetUInt32Value(GAMEOBJECT_FACTION, WintergraspFaction[GetAttackerTeam()]);
// Set in use (not allow to click on before last door is broken)
go->SetFlag(GAMEOBJECT_FLAGS, GO_FLAG_NOT_SELECTABLE);
go->SetGameObjectFlag(GO_FLAG_NOT_SELECTABLE);
// save guid
m_titansRelic = go->GetGUID();
@@ -1208,7 +1208,7 @@ struct BfWGGameObjectBuilding
case BATTLEFIELD_WG_OBJECTTYPE_DOOR_LAST:
m_WG->SetRelicInteractible(true);
if (GameObject* go = m_WG->GetRelic())
go->RemoveFlag(GAMEOBJECT_FLAGS, GO_FLAG_NOT_SELECTABLE);
go->RemoveGameObjectFlag(GO_FLAG_NOT_SELECTABLE);
else
LOG_ERROR("bg.battlefield", "BattlefieldWG: Relic not found.");
break;