void InstanceScript::DoRemoveAurasDueToSpellOnPlayers(uint32 spellId) { for (InstanceMap::iterator mapIter = m_InstanceMap.begin(); mapIter != m_InstanceMap.end(); ++mapIter) { for (auto& itr : mapIter->second->m_Player) { if (itr->HasAura(spellId)) { itr->RemoveAurasDueToSpell(spellId); } } } }
void InstanceScript::DoRemoveAurasDueToSpellOnPlayers() { for (InstanceMap::iterator mapIter = m_InstanceMap.begin(); mapIter != m_InstanceMap.end(); ++mapIter) { for (auto& itr : mapIter->second->m_Player) { itr->RemoveAllAuras(); } } }In this example, the function loops through all players in the instance and removes all auras from them. The package library that this function belongs to is likely a game server or game engine library, as it is specifically designed to work within a game instance, manipulating player auras and spells.