*Mangos [7031] Implement some mage, paladin dummy trigers.
*Mangos [7029] Some work vs aura charges:
Move to protected: need use SetAuraCharges, GetAuraCharges, DropAuraCharge
Now m_procCharges == 0 if infinite charges, and > 0 for limit
Remove not need UpdateAuraCharges()
By DiSlord.
--HG--
branch : trunk
This commit is contained in:
1 parent
b59020657b
commit
fbc82ae631
8 files changed
+143
-76
No files matched your search
+3
-3
@@ -14801,7 +14801,7 @@ void Player::_LoadAuras(QueryResult *result, uint32 timediff)
|
||||
remaincharges = spellproto->procCharges;
|
||||
}
|
||||
else
|
||||
remaincharges = -1;
|
||||
remaincharges = 0;
|
||||
|
||||
//do not load single target auras (unless they were cast by the player)
|
||||
if (caster_guid != GetGUID() && IsSingleTargetSpell(spellproto))
|
||||
@@ -15912,7 +15912,7 @@ void Player::_SaveAuras()
|
||||
{
|
||||
CharacterDatabase.PExecute("INSERT INTO character_aura (guid,caster_guid,spell,effect_index,stackcount,amount,maxduration,remaintime,remaincharges) "
|
||||
"VALUES ('%u', '" I64FMTD "' ,'%u', '%u', '%u', '%d', '%d', '%d', '%d')",
|
||||
GetGUIDLow(), itr2->second->GetCasterGUID(), (uint32)itr2->second->GetId(), (uint32)itr2->second->GetEffIndex(), (uint32)itr2->second->GetStackAmount(), itr2->second->GetModifier()->m_amount,int(itr2->second->GetAuraMaxDuration()),int(itr2->second->GetAuraDuration()),int(itr2->second->m_procCharges));
|
||||
GetGUIDLow(), itr2->second->GetCasterGUID(), (uint32)itr2->second->GetId(), (uint32)itr2->second->GetEffIndex(), (uint32)itr2->second->GetStackAmount(), itr2->second->GetModifier()->m_amount,int(itr2->second->GetAuraMaxDuration()),int(itr2->second->GetAuraDuration()),int(itr2->second->GetAuraCharges()));
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -18634,7 +18634,7 @@ void Player::SendAurasForTarget(Unit *target)
|
||||
// level
|
||||
data << uint8(aura->GetAuraLevel());
|
||||
// charges
|
||||
data << uint8(aura->m_procCharges >= 0 ? aura->m_procCharges : 0 );
|
||||
data << uint8(aura->GetAuraCharges());
|
||||
|
||||
if(!(auraFlags & AFLAG_NOT_CASTER))
|
||||
{
|
||||
|
||||
Reference in new issue
Block a user