mirror of
https://github.com/mangosfour/server.git
synced 2025-12-14 16:37:01 +00:00
[7426] Mounted players now can capture tower point in Eye of Storm.
Renamed function isAllowUseBattleGroundObject to CanUseBattleGroundObject Signed-off-by: Triply <triply@getmangos.com>
This commit is contained in:
parent
1c8f8a2e13
commit
52696ce029
7 changed files with 21 additions and 11 deletions
|
|
@ -19396,13 +19396,22 @@ bool ItemPosCount::isContainedIn(ItemPosCountVec const& vec) const
|
|||
return false;
|
||||
}
|
||||
|
||||
bool Player::isAllowUseBattleGroundObject()
|
||||
bool Player::CanUseBattleGroundObject()
|
||||
{
|
||||
return ( //InBattleGround() && // in battleground - not need, check in other cases
|
||||
!IsMounted() && // not mounted
|
||||
//!IsMounted() && - not correct, player is dismounted when he clicks on flag
|
||||
!HasStealthAura() && // not stealthed
|
||||
!HasInvisibilityAura() && // not invisible
|
||||
!HasAura(SPELL_RECENTLY_DROPPED_FLAG, 0) && // can't pickup
|
||||
//TODO player cannot use object when he is invulnerable (immune) - (ice block, divine shield, divine protection, divine intervention ...)
|
||||
isAlive() // live player
|
||||
);
|
||||
}
|
||||
|
||||
bool Player::CanCaptureTowerPoint()
|
||||
{
|
||||
return ( !HasStealthAura() && // not stealthed
|
||||
!HasInvisibilityAura() && // not invisible
|
||||
isAlive() // live player
|
||||
);
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue