mirror of
https://github.com/mangosfour/server.git
synced 2025-12-13 13:37:05 +00:00
[11631] Fix wrong overriding aura stack amount and proc charges at loading
Need to consider spell mods, partial dispels and etc...
This commit is contained in:
parent
6945d86e67
commit
10865b633f
3 changed files with 5 additions and 24 deletions
|
|
@ -1321,20 +1321,10 @@ void Pet::_LoadAuras(uint32 timediff)
|
||||||
}
|
}
|
||||||
|
|
||||||
// prevent wrong values of remaincharges
|
// prevent wrong values of remaincharges
|
||||||
uint32 procCharges = spellproto->procCharges;
|
if (spellproto->procCharges == 0)
|
||||||
if (procCharges)
|
|
||||||
{
|
|
||||||
if (remaincharges <= 0 || remaincharges > procCharges)
|
|
||||||
remaincharges = procCharges;
|
|
||||||
}
|
|
||||||
else
|
|
||||||
remaincharges = 0;
|
remaincharges = 0;
|
||||||
|
|
||||||
if (!spellproto->StackAmount)
|
if (stackcount == 0)
|
||||||
stackcount = 1;
|
|
||||||
else if (spellproto->StackAmount < stackcount)
|
|
||||||
stackcount = spellproto->StackAmount;
|
|
||||||
else if (!stackcount)
|
|
||||||
stackcount = 1;
|
stackcount = 1;
|
||||||
|
|
||||||
SpellAuraHolder *holder = CreateSpellAuraHolder(spellproto, this, NULL);
|
SpellAuraHolder *holder = CreateSpellAuraHolder(spellproto, this, NULL);
|
||||||
|
|
|
||||||
|
|
@ -16041,19 +16041,10 @@ void Player::_LoadAuras(QueryResult *result, uint32 timediff)
|
||||||
}
|
}
|
||||||
|
|
||||||
// prevent wrong values of remaincharges
|
// prevent wrong values of remaincharges
|
||||||
if (spellproto->procCharges)
|
if (spellproto->procCharges == 0)
|
||||||
{
|
|
||||||
if (remaincharges <= 0 || remaincharges > spellproto->procCharges)
|
|
||||||
remaincharges = spellproto->procCharges;
|
|
||||||
}
|
|
||||||
else
|
|
||||||
remaincharges = 0;
|
remaincharges = 0;
|
||||||
|
|
||||||
if (!spellproto->StackAmount)
|
if (stackcount == 0)
|
||||||
stackcount = 1;
|
|
||||||
else if (spellproto->StackAmount < stackcount)
|
|
||||||
stackcount = spellproto->StackAmount;
|
|
||||||
else if (!stackcount)
|
|
||||||
stackcount = 1;
|
stackcount = 1;
|
||||||
|
|
||||||
SpellAuraHolder *holder = CreateSpellAuraHolder(spellproto, this, NULL);
|
SpellAuraHolder *holder = CreateSpellAuraHolder(spellproto, this, NULL);
|
||||||
|
|
|
||||||
|
|
@ -1,4 +1,4 @@
|
||||||
#ifndef __REVISION_NR_H__
|
#ifndef __REVISION_NR_H__
|
||||||
#define __REVISION_NR_H__
|
#define __REVISION_NR_H__
|
||||||
#define REVISION_NR "11630"
|
#define REVISION_NR "11631"
|
||||||
#endif // __REVISION_NR_H__
|
#endif // __REVISION_NR_H__
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue