refactor(Core): replace NULL with nullptr (#4593)

This commit is contained in:
Kitzunu
2021-03-02 01:34:20 +01:00
committed by GitHub
parent dbefa17a53
commit 28f1dc5c0c
231 changed files with 923 additions and 923 deletions

View File

@@ -290,7 +290,7 @@ void Spell::EffectInstaKill(SpellEffIndex /*effIndex*/)
data << uint32(m_spellInfo->Id);
m_caster->SendMessageToSet(&data, true);
Unit::DealDamage(m_caster, unitTarget, unitTarget->GetHealth(), NULL, NODAMAGE, SPELL_SCHOOL_MASK_NORMAL, NULL, false);
Unit::DealDamage(m_caster, unitTarget, unitTarget->GetHealth(), nullptr, NODAMAGE, SPELL_SCHOOL_MASK_NORMAL, nullptr, false);
}
void Spell::EffectEnvironmentalDMG(SpellEffIndex /*effIndex*/)
@@ -1092,7 +1092,7 @@ void Spell::EffectTriggerRitualOfSummoning(SpellEffIndex effIndex)
finish();
m_caster->CastSpell((Unit*)NULL, spellInfo, false);
m_caster->CastSpell((Unit*)nullptr, spellInfo, false);
}
void Spell::EffectJump(SpellEffIndex effIndex)
@@ -1669,7 +1669,7 @@ void Spell::DoCreateItem(uint8 /*effIndex*/, uint32 itemId)
ItemTemplate const* pProto = sObjectMgr->GetItemTemplate(newitemid);
if (!pProto)
{
player->SendEquipError(EQUIP_ERR_ITEM_NOT_FOUND, NULL, nullptr);
player->SendEquipError(EQUIP_ERR_ITEM_NOT_FOUND, nullptr, nullptr);
return;
}
@@ -1762,7 +1762,7 @@ void Spell::DoCreateItem(uint8 /*effIndex*/, uint32 itemId)
// was it successful? return error if not
if (!pItem)
{
player->SendEquipError(EQUIP_ERR_ITEM_NOT_FOUND, NULL, nullptr);
player->SendEquipError(EQUIP_ERR_ITEM_NOT_FOUND, nullptr, nullptr);
return;
}
@@ -2854,7 +2854,7 @@ void Spell::EffectEnchantItemPerm(SpellEffIndex effIndex)
unitTarget = p_caster;
// and add a scroll
DoCreateItem(effIndex, m_spellInfo->Effects[effIndex].ItemType);
itemTarget = NULL;
itemTarget = nullptr;
m_targets.SetItemTarget(nullptr);
}
else
@@ -3422,7 +3422,7 @@ void Spell::EffectWeaponDmg(SpellEffIndex effIndex)
// Skyshatter Harness item set bonus
// Stormstrike
if (AuraEffect* aurEff = m_caster->IsScriptOverriden(m_spellInfo, 5634))
m_caster->CastSpell(m_caster, 38430, true, NULL, aurEff);
m_caster->CastSpell(m_caster, 38430, true, nullptr, aurEff);
// Lava lash damage increased by Flametongue weapon
if (m_caster->GetAuraEffect(SPELL_AURA_DUMMY, SPELLFAMILY_SHAMAN, 688, EFFECT_0))
AddPct(totalDamagePercentMod, 25.0f);
@@ -6289,7 +6289,7 @@ void Spell::EffectRechargeManaGem(SpellEffIndex /*effIndex*/)
ItemTemplate const* pProto = sObjectMgr->GetItemTemplate(item_id);
if (!pProto)
{
player->SendEquipError(EQUIP_ERR_ITEM_NOT_FOUND, NULL, nullptr);
player->SendEquipError(EQUIP_ERR_ITEM_NOT_FOUND, nullptr, nullptr);
return;
}