mirror of
https://github.com/EQEmu/Server.git
synced 2026-05-19 13:28:25 +00:00
Retooled how cooldowns work so they should be more consistent with how the client shows them
This commit is contained in:
+2
-12
@@ -1137,26 +1137,16 @@ void Client::ActivateAlternateAdvancementAbility(int rank_id, int target_id) {
|
||||
// Bards can cast instant cast AAs while they are casting another song
|
||||
if(spells[rank->spell].cast_time == 0 && GetClass() == BARD && IsBardSong(casting_spell_id)) {
|
||||
if(!SpellFinished(rank->spell, entity_list.GetMob(target_id), 10, -1, -1, spells[rank->spell].ResistDiff, false)) {
|
||||
//Reset on failed cast
|
||||
SendAlternateAdvancementTimer(rank->spell_type, 0, -1);
|
||||
Message_StringID(15, ABILITY_FAILED);
|
||||
p_timers.Clear(&database, rank->spell_type + pTimerAAStart);
|
||||
return;
|
||||
}
|
||||
CastToClient()->GetPTimers().Start(rank->spell_type, cooldown);
|
||||
SendAlternateAdvancementTimer(rank->spell_type, 0, 0);
|
||||
ExpendAlternateAdvancementCharge(ability->id);
|
||||
} else {
|
||||
if(!CastSpell(rank->spell, target_id, USE_ITEM_SPELL_SLOT, -1, -1, 0, -1, rank->spell_type + pTimerAAStart, cooldown, 1, nullptr, ability->id)) {
|
||||
//Reset on failed cast
|
||||
SendAlternateAdvancementTimer(rank->spell_type, 0, -1);
|
||||
Message_StringID(15, ABILITY_FAILED);
|
||||
p_timers.Clear(&database, rank->spell_type + pTimerAAStart);
|
||||
return;
|
||||
}
|
||||
}
|
||||
|
||||
if(cooldown > 0) {
|
||||
SendAlternateAdvancementTimer(rank->spell_type, 0, 0);
|
||||
}
|
||||
}
|
||||
|
||||
int Mob::GetAlternateAdvancementCooldownReduction(AA::Rank *rank_in) {
|
||||
|
||||
Reference in New Issue
Block a user