[7426] Mounted players now can capture tower point in Eye of Storm. Author: Triply
Renamed function isAllowUseBattleGroundObject to CanUseBattleGroundObject --HG-- branch : trunk
This commit is contained in:
+16
-8
@@ -20104,15 +20104,23 @@ void Player::SetFarsightTarget(WorldObject* obj)
|
||||
SetFarSightGUID(obj->GetGUID());
|
||||
}
|
||||
|
||||
bool Player::isAllowUseBattleGroundObject()
|
||||
bool Player::CanUseBattleGroundObject()
|
||||
{
|
||||
return ( //InBattleGround() && // in battleground - not need, check in other cases
|
||||
!IsMounted() && // not mounted
|
||||
!isTotalImmunity() && // not totally immuned
|
||||
!HasStealthAura() && // not stealthed
|
||||
!HasInvisibilityAura() && // not invisible
|
||||
!HasAura(SPELL_RECENTLY_DROPPED_FLAG, 0) && // can't pickup
|
||||
isAlive() // live player
|
||||
return ( //InBattleGround() && // in battleground - not need, check in other cases
|
||||
//!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
|
||||
);
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user