*Allow zero entry for script target (players).

--HG--
branch : trunk
This commit is contained in:
megamage
2008-12-08 18:22:10 -06:00
parent 8e4928a21a
commit 91ab0288c7
2 changed files with 5 additions and 4 deletions
+1 -1
View File
@@ -618,7 +618,7 @@ namespace Trinity
}break;
case SPELL_TARGETS_ENTRY:
{
if(itr->getSource()->GetTypeId()!=TYPEID_UNIT || itr->getSource()->GetEntry()!= i_entry)
if(itr->getSource()->GetEntry()!= i_entry)
continue;
}break;
default: continue;
+4 -3
View File
@@ -1685,12 +1685,13 @@ void SpellMgr::LoadSpellScriptTarget()
}
default:
{
if( targetEntry==0 )
//players
/*if( targetEntry==0 )
{
sLog.outErrorDb("Table `spell_script_target`: target entry == 0 for not GO target type (%u).",type);
continue;
}
if(!sCreatureStorage.LookupEntry<CreatureInfo>(targetEntry))
}*/
if(targetEntry && !sCreatureStorage.LookupEntry<CreatureInfo>(targetEntry))
{
sLog.outErrorDb("Table `spell_script_target`: creature template entry %u does not exist.",targetEntry);
continue;