[9187] Fixed problem with non-attackable pes/totems at arenas

... and other FFA areas. Problem is result chnages in related flags work after old 3.x switch.

* Added high-level functions for FFAPvP state set for unit
* Apply FFA PvP to all controlled units also at set, and at summon/load
This commit is contained in:
VladimirMangos 2010-01-16 05:37:57 +03:00
parent 6704929d56
commit cc062f16ac
9 changed files with 45 additions and 15 deletions

View file

@ -749,7 +749,7 @@ void WorldSession::HandlePlayerLogin(LoginQueryHolder *holder)
// Set FFA PvP for non GM in non-rest mode
if(sWorld.IsFFAPvPRealm() && !pCurrChar->isGameMaster() && !pCurrChar->HasFlag(PLAYER_FLAGS,PLAYER_FLAGS_RESTING) )
pCurrChar->SetByteFlag(UNIT_FIELD_BYTES_2, 1, UNIT_BYTE2_FLAG_FFA_PVP);
pCurrChar->SetFFAPvP(true);
if(pCurrChar->HasFlag(PLAYER_FLAGS, PLAYER_FLAGS_CONTESTED_PVP))
pCurrChar->SetContestedPvP();