mirror of
https://github.com/EQEmu/Server.git
synced 2026-05-19 17:38:26 +00:00
Implement duration ramp and war cry with new AA system
Rampage also correctly does a full attack round for classes other than monk and ranger
This commit is contained in:
+16
-37
@@ -638,42 +638,23 @@ bool Mob::SpellEffect(Mob* caster, uint16 spell_id, float partial, int level_ove
|
||||
snprintf(effect_desc, _EDLEN, "Group Fear Immunity");
|
||||
#endif
|
||||
//Added client messages to give some indication this effect is active.
|
||||
uint32 group_id_caster = 0;
|
||||
uint32 time = spell.base[i]*10;
|
||||
if(caster->IsClient())
|
||||
{
|
||||
if(caster->IsGrouped())
|
||||
{
|
||||
group_id_caster = GetGroup()->GetID();
|
||||
}
|
||||
else if(caster->IsRaidGrouped())
|
||||
{
|
||||
group_id_caster = (GetRaid()->GetGroup(CastToClient()) == 0xFFFF) ? 0 : (GetRaid()->GetGroup(CastToClient()) + 1);
|
||||
// Is there a message generated? Too disgusted by raids.
|
||||
uint32 time = spell.base[i] * 10 * 1000;
|
||||
if (caster->IsClient()) {
|
||||
if (caster->IsGrouped()) {
|
||||
auto group = caster->GetGroup();
|
||||
for (int i = 0; i < 6; ++i)
|
||||
if (group->members[i])
|
||||
group->members[i]->aa_timers[aaTimerWarcry].Start(time);
|
||||
} else if (caster->IsRaidGrouped()) {
|
||||
auto raid = caster->GetRaid();
|
||||
uint32 gid = raid->GetGroup(caster->CastToClient());
|
||||
if (gid < 12)
|
||||
for (int i = 0; i < MAX_RAID_MEMBERS; ++i)
|
||||
if (raid->members[i].member && raid->members[i].GroupNumber == gid)
|
||||
raid->members[i].member->aa_timers[aaTimerWarcry].Start(time);
|
||||
}
|
||||
}
|
||||
//old aa
|
||||
//if(group_id_caster){
|
||||
// Group *g = entity_list.GetGroupByID(group_id_caster);
|
||||
// uint32 time = spell.base[i]*10;
|
||||
// if(g){
|
||||
// for(int gi=0; gi < 6; gi++){
|
||||
// if(g->members[gi] && g->members[gi]->IsClient())
|
||||
// {
|
||||
// g->members[gi]->CastToClient()->EnableAAEffect(aaEffectWarcry , time);
|
||||
// if (g->members[gi]->GetID() != caster->GetID())
|
||||
// g->members[gi]->Message(13, "You hear the war cry.");
|
||||
// else
|
||||
// Message(13, "You let loose a fierce war cry.");
|
||||
// }
|
||||
// }
|
||||
// }
|
||||
//}
|
||||
//
|
||||
//else{
|
||||
// CastToClient()->EnableAAEffect(aaEffectWarcry , time);
|
||||
// Message(13, "You let loose a fierce war cry.");
|
||||
//}
|
||||
|
||||
break;
|
||||
}
|
||||
|
||||
@@ -2238,9 +2219,7 @@ bool Mob::SpellEffect(Mob* caster, uint16 spell_id, float partial, int level_ove
|
||||
#ifdef SPELL_EFFECT_SPAM
|
||||
snprintf(effect_desc, _EDLEN, "Duration Rampage");
|
||||
#endif
|
||||
//if (caster && caster->IsClient()) { // will tidy this up later so that NPCs can duration ramp from spells too
|
||||
// CastToClient()->DurationRampage(effect_value*12);
|
||||
//}
|
||||
aa_timers[aaTimerRampage].Start(effect_value * 10 * 1000); // Live bug, was suppose to be 1 second per value
|
||||
break;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user