1398 | | if (i == 3 && !itr->second->IsPassive()) |
1399 | | CharacterDatabase.PExecute("INSERT INTO pet_aura (guid,caster_guid,spell,effect_index,amount,maxduration,remaintime,remaincharges) " |
1400 | | "VALUES ('%u', '" I64FMTD "', '%u', '%u', '%d', '%d', '%d', '%d')", |
1401 | | m_charmInfo->GetPetNumber(), itr->second->GetCasterGUID(),(uint32)(*itr).second->GetId(), (uint32)(*itr).second->GetEffIndex(),(*itr).second->GetModifier()->m_amount,int((*itr).second->GetAuraMaxDuration()),int((*itr).second->GetAuraDuration()),int((*itr).second->m_procCharges)); |
| 1402 | if (i != 3) |
| 1403 | continue; |
| 1404 | |
| 1405 | if(itr->second->IsPassive()) |
| 1406 | continue; |
| 1407 | |
| 1408 | /// do not save single target auras (unless they were cast by the player) |
| 1409 | if (itr->second->GetCasterGUID() != GetGUID() && IsSingleTargetSpell(spellInfo)) |
| 1410 | continue; |
| 1411 | |
| 1412 | CharacterDatabase.PExecute("INSERT INTO pet_aura (guid,caster_guid,spell,effect_index,amount,maxduration,remaintime,remaincharges) " |
| 1413 | "VALUES ('%u', '" I64FMTD "', '%u', '%u', '%d', '%d', '%d', '%d')", |
| 1414 | m_charmInfo->GetPetNumber(), itr->second->GetCasterGUID(),(uint32)(*itr).second->GetId(), (uint32)(*itr).second->GetEffIndex(),(*itr).second->GetModifier()->m_amount,int((*itr).second->GetAuraMaxDuration()),int((*itr).second->GetAuraDuration()),int((*itr).second->m_procCharges)); |