feat(CI/Codestyle): add check core logs (#6012)

This commit is contained in:
Kargatum
2021-05-31 16:03:00 +07:00
committed by GitHub
parent 9b6c3c7d2c
commit e3c1e739c6
8 changed files with 36 additions and 21 deletions

View File

@@ -1036,7 +1036,7 @@ SpellCastResult Unit::CastSpell(SpellCastTargets const& targets, SpellInfo const
{
if (!spellInfo)
{
LOG_ERROR("server", "CastSpell: unknown spell by caster: %s %u)", (GetTypeId() == TYPEID_PLAYER ? "player (GUID:" : "creature (Entry:"), (GetTypeId() == TYPEID_PLAYER ? GetGUID().GetCounter() : GetEntry()));
LOG_ERROR("entities.unit", "CastSpell: unknown spell by caster %s", GetGUID().ToString().c_str());
return SPELL_FAILED_SPELL_UNAVAILABLE;
}
@@ -1070,7 +1070,7 @@ SpellCastResult Unit::CastSpell(Unit* victim, uint32 spellId, TriggerCastFlags t
SpellInfo const* spellInfo = sSpellMgr->GetSpellInfo(spellId);
if (!spellInfo)
{
LOG_ERROR("server", "CastSpell: unknown spell id %u by caster: %s %u)", spellId, (GetTypeId() == TYPEID_PLAYER ? "player (GUID:" : "creature (Entry:"), (GetTypeId() == TYPEID_PLAYER ? GetGUID().GetCounter() : GetEntry()));
LOG_ERROR("entities.unit", "CastSpell: unknown spell %u by caster %s", spellId, GetGUID().ToString().c_str());
return SPELL_FAILED_SPELL_UNAVAILABLE;
}
@@ -1120,9 +1120,10 @@ SpellCastResult Unit::CastCustomSpell(uint32 spellId, CustomSpellValues const& v
SpellInfo const* spellInfo = sSpellMgr->GetSpellInfo(spellId);
if (!spellInfo)
{
LOG_ERROR("server", "CastSpell: unknown spell id %u by caster: %s %u)", spellId, (GetTypeId() == TYPEID_PLAYER ? "player (GUID:" : "creature (Entry:"), (GetTypeId() == TYPEID_PLAYER ? GetGUID().GetCounter() : GetEntry()));
LOG_ERROR("entities.unit", "CastSpell: unknown spell %u by caster %s", spellId, GetGUID().ToString().c_str());
return SPELL_FAILED_SPELL_UNAVAILABLE;
}
SpellCastTargets targets;
targets.SetUnitTarget(victim);
@@ -1134,9 +1135,10 @@ SpellCastResult Unit::CastSpell(float x, float y, float z, uint32 spellId, bool
SpellInfo const* spellInfo = sSpellMgr->GetSpellInfo(spellId);
if (!spellInfo)
{
LOG_ERROR("server", "CastSpell: unknown spell id %u by caster: %s %u)", spellId, (GetTypeId() == TYPEID_PLAYER ? "player (GUID:" : "creature (Entry:"), (GetTypeId() == TYPEID_PLAYER ? GetGUID().GetCounter() : GetEntry()));
LOG_ERROR("entities.unit", "CastSpell: unknown spell %u by caster %s", spellId, GetGUID().ToString().c_str());
return SPELL_FAILED_SPELL_UNAVAILABLE;
}
SpellCastTargets targets;
targets.SetDst(x, y, z, GetOrientation());
@@ -1148,9 +1150,10 @@ SpellCastResult Unit::CastSpell(GameObject* go, uint32 spellId, bool triggered,
SpellInfo const* spellInfo = sSpellMgr->GetSpellInfo(spellId);
if (!spellInfo)
{
LOG_ERROR("server", "CastSpell: unknown spell id %u by caster: %s %u)", spellId, (GetTypeId() == TYPEID_PLAYER ? "player (GUID:" : "creature (Entry:"), (GetTypeId() == TYPEID_PLAYER ? GetGUID().GetCounter() : GetEntry()));
LOG_ERROR("entities.unit", "CastSpell: unknown spell %u by caster %s", spellId, GetGUID().ToString().c_str());
return SPELL_FAILED_SPELL_UNAVAILABLE;
}
SpellCastTargets targets;
targets.SetGOTarget(go);