Spell effect updates

This commit is contained in:
KayenEQ
2014-01-13 05:03:21 -05:00
parent f4e085c121
commit 32359da1cc
14 changed files with 406 additions and 129 deletions
+5 -4
View File
@@ -197,14 +197,15 @@ void Client::OPCombatAbility(const EQApplicationPacket *app) {
if (ca_atk->m_skill == SkillThrowing) {
SetAttackTimer();
ThrowingAttack(GetTarget());
if (CheckDoubleRangedAttack())
RangedAttack(GetTarget(), true);
return;
}
//ranged attack (archery)
if (ca_atk->m_skill == SkillArchery) {
SetAttackTimer();
RangedAttack(GetTarget());
bool test = CheckArcheryDoubleAttack();
if (CheckArcheryDoubleAttack())
if (CheckDoubleRangedAttack())
RangedAttack(GetTarget(), true);
return;
}
@@ -1119,12 +1120,12 @@ uint16 Mob::GetThrownDamage(int16 wDmg, int32& TotalDmg, int& minDmg)
return MaxDmg;
}
void Client::ThrowingAttack(Mob* other) { //old was 51
void Client::ThrowingAttack(Mob* other, bool CanDoubleAttack) { //old was 51
//conditions to use an attack checked before we are called
//make sure the attack and ranged timers are up
//if the ranged timer is disabled, then they have no ranged weapon and shouldent be attacking anyhow
if((attack_timer.Enabled() && !attack_timer.Check(false)) || (ranged_timer.Enabled() && !ranged_timer.Check())) {
if((!CanDoubleAttack && (attack_timer.Enabled() && !attack_timer.Check(false)) || (ranged_timer.Enabled() && !ranged_timer.Check()))) {
mlog(COMBAT__RANGED, "Throwing attack canceled. Timer not up. Attack %d, ranged %d", attack_timer.GetRemainingTime(), ranged_timer.GetRemainingTime());
// The server and client timers are not exact matches currently, so this would spam too often if enabled
//Message(0, "Error: Timer not up. Attack %d, ranged %d", attack_timer.GetRemainingTime(), ranged_timer.GetRemainingTime());