feat(Core/Players): PlayerFlag helpers (#11294)

* feat(Core/Players): PlayerFlag helpers

* Update Player.h

* fix build
This commit is contained in:
Kitzunu
2022-04-05 18:53:50 +02:00
committed by GitHub
parent 9f234ea489
commit b709a22ddc
19 changed files with 83 additions and 74 deletions

View File

@@ -345,7 +345,7 @@ bool OPvPCapturePointNA::HandleCustomSpell(Player* player, uint32 spellId, GameO
nodes[0] = FlightPathStartNodes[NA_ROOST_N];
nodes[1] = FlightPathEndNodes[NA_ROOST_N];
player->ActivateTaxiPathTo(nodes);
player->SetFlag(PLAYER_FLAGS, PLAYER_FLAGS_IN_PVP);
player->SetPlayerFlag(PLAYER_FLAGS_IN_PVP);
player->UpdatePvP(true, true);
retval = true;
break;
@@ -353,7 +353,7 @@ bool OPvPCapturePointNA::HandleCustomSpell(Player* player, uint32 spellId, GameO
nodes[0] = FlightPathStartNodes[NA_ROOST_S];
nodes[1] = FlightPathEndNodes[NA_ROOST_S];
player->ActivateTaxiPathTo(nodes);
player->SetFlag(PLAYER_FLAGS, PLAYER_FLAGS_IN_PVP);
player->SetPlayerFlag(PLAYER_FLAGS_IN_PVP);
player->UpdatePvP(true, true);
retval = true;
break;
@@ -361,7 +361,7 @@ bool OPvPCapturePointNA::HandleCustomSpell(Player* player, uint32 spellId, GameO
nodes[0] = FlightPathStartNodes[NA_ROOST_W];
nodes[1] = FlightPathEndNodes[NA_ROOST_W];
player->ActivateTaxiPathTo(nodes);
player->SetFlag(PLAYER_FLAGS, PLAYER_FLAGS_IN_PVP);
player->SetPlayerFlag(PLAYER_FLAGS_IN_PVP);
player->UpdatePvP(true, true);
retval = true;
break;
@@ -369,7 +369,7 @@ bool OPvPCapturePointNA::HandleCustomSpell(Player* player, uint32 spellId, GameO
nodes[0] = FlightPathStartNodes[NA_ROOST_E];
nodes[1] = FlightPathEndNodes[NA_ROOST_E];
player->ActivateTaxiPathTo(nodes);
player->SetFlag(PLAYER_FLAGS, PLAYER_FLAGS_IN_PVP);
player->SetPlayerFlag(PLAYER_FLAGS_IN_PVP);
player->UpdatePvP(true, true);
retval = true;
break;