mirror of
https://github.com/mangosfour/server.git
synced 2025-12-14 16:37:01 +00:00
[7914] Fixed variable name typos in creature event AI code.
Signed-off-by: VladimirMangos <vladimir@getmangos.com>
This commit is contained in:
parent
548f47b2b3
commit
c7c480f6ba
4 changed files with 17 additions and 17 deletions
|
|
@ -412,12 +412,12 @@ void CreatureEventAI::ProcessAction(CreatureEventAI_Action const& action, uint32
|
|||
}
|
||||
case ACTION_T_MORPH_TO_ENTRY_OR_MODEL:
|
||||
{
|
||||
if (action.morph.creatireId || action.morph.modelId)
|
||||
if (action.morph.creatureId || action.morph.modelId)
|
||||
{
|
||||
//set model based on entry from creature_template
|
||||
if (action.morph.creatireId)
|
||||
if (action.morph.creatureId)
|
||||
{
|
||||
if (CreatureInfo const* ci = GetCreatureTemplateStore(action.morph.creatireId))
|
||||
if (CreatureInfo const* ci = GetCreatureTemplateStore(action.morph.creatureId))
|
||||
{
|
||||
//use default display
|
||||
if (ci->DisplayID_A)
|
||||
|
|
@ -521,12 +521,12 @@ void CreatureEventAI::ProcessAction(CreatureEventAI_Action const& action, uint32
|
|||
Creature* pCreature = NULL;
|
||||
|
||||
if (action.summon.duration)
|
||||
pCreature = m_creature->SummonCreature(action.summon.creatured, 0.0f, 0.0f, 0.0f, 0.0f, TEMPSUMMON_TIMED_OR_DEAD_DESPAWN, action.summon.duration);
|
||||
pCreature = m_creature->SummonCreature(action.summon.creatureId, 0.0f, 0.0f, 0.0f, 0.0f, TEMPSUMMON_TIMED_OR_DEAD_DESPAWN, action.summon.duration);
|
||||
else
|
||||
pCreature = m_creature->SummonCreature(action.summon.creatured, 0.0f, 0.0f, 0.0f, 0.0f, TEMPSUMMON_TIMED_DESPAWN_OUT_OF_COMBAT, 0);
|
||||
pCreature = m_creature->SummonCreature(action.summon.creatureId, 0.0f, 0.0f, 0.0f, 0.0f, TEMPSUMMON_TIMED_DESPAWN_OUT_OF_COMBAT, 0);
|
||||
|
||||
if (!pCreature)
|
||||
sLog.outErrorDb( "CreatureEventAI: failed to spawn creature %u. Spawn event %d is on creature %d", action.summon.creatured, EventId, m_creature->GetEntry());
|
||||
sLog.outErrorDb( "CreatureEventAI: failed to spawn creature %u. Spawn event %d is on creature %d", action.summon.creatureId, EventId, m_creature->GetEntry());
|
||||
else if (action.summon.target != TARGET_T_SELF && target)
|
||||
pCreature->AI()->AttackStart(target);
|
||||
break;
|
||||
|
|
|
|||
|
|
@ -193,7 +193,7 @@ struct CreatureEventAI_Action
|
|||
// ACTION_T_MORPH_TO_ENTRY_OR_MODEL = 3
|
||||
struct
|
||||
{
|
||||
uint32 creatireId; // set one from fields (or 0 for both to demorph)
|
||||
uint32 creatureId; // set one from fields (or 0 for both to demorph)
|
||||
uint32 modelId;
|
||||
} morph;
|
||||
// ACTION_T_SOUND = 4
|
||||
|
|
@ -230,7 +230,7 @@ struct CreatureEventAI_Action
|
|||
// ACTION_T_SUMMON = 12
|
||||
struct
|
||||
{
|
||||
uint32 creatured;
|
||||
uint32 creatureId;
|
||||
uint32 target;
|
||||
uint32 duration;
|
||||
} summon;
|
||||
|
|
|
|||
|
|
@ -438,19 +438,19 @@ void CreatureEventAIMgr::LoadCreatureEventAI_Scripts()
|
|||
}
|
||||
break;
|
||||
case ACTION_T_MORPH_TO_ENTRY_OR_MODEL:
|
||||
if (action.morph.creatireId !=0 || action.morph.modelId !=0)
|
||||
if (action.morph.creatureId !=0 || action.morph.modelId !=0)
|
||||
{
|
||||
if (action.morph.creatireId && !sCreatureStorage.LookupEntry<CreatureInfo>(action.morph.creatireId))
|
||||
if (action.morph.creatureId && !sCreatureStorage.LookupEntry<CreatureInfo>(action.morph.creatureId))
|
||||
{
|
||||
sLog.outErrorDb("CreatureEventAI: Event %u Action %u uses non-existant Creature entry %u.", i, j+1, action.morph.creatireId);
|
||||
action.morph.creatireId = 0;
|
||||
sLog.outErrorDb("CreatureEventAI: Event %u Action %u uses non-existant Creature entry %u.", i, j+1, action.morph.creatureId);
|
||||
action.morph.creatureId = 0;
|
||||
}
|
||||
|
||||
if (action.morph.modelId)
|
||||
{
|
||||
if (action.morph.creatireId)
|
||||
if (action.morph.creatureId)
|
||||
{
|
||||
sLog.outErrorDb("CreatureEventAI: Event %u Action %u have unused ModelId %u with also set creature id %u.", i, j+1, action.morph.modelId,action.morph.creatireId);
|
||||
sLog.outErrorDb("CreatureEventAI: Event %u Action %u have unused ModelId %u with also set creature id %u.", i, j+1, action.morph.modelId,action.morph.creatureId);
|
||||
action.morph.modelId = 0;
|
||||
}
|
||||
else if (!sCreatureDisplayInfoStore.LookupEntry(action.morph.modelId))
|
||||
|
|
@ -512,8 +512,8 @@ void CreatureEventAIMgr::LoadCreatureEventAI_Scripts()
|
|||
break;
|
||||
}
|
||||
case ACTION_T_SUMMON:
|
||||
if (!sCreatureStorage.LookupEntry<CreatureInfo>(action.summon.creatured))
|
||||
sLog.outErrorDb("CreatureEventAI: Event %u Action %u uses non-existent creature entry %u.", i, j+1, action.summon.creatured);
|
||||
if (!sCreatureStorage.LookupEntry<CreatureInfo>(action.summon.creatureId))
|
||||
sLog.outErrorDb("CreatureEventAI: Event %u Action %u uses non-existent creature entry %u.", i, j+1, action.summon.creatureId);
|
||||
|
||||
if (action.summon.target >= TARGET_T_END)
|
||||
sLog.outErrorDb("CreatureEventAI: Event %u Action %u uses incorrect Target type", i, j+1);
|
||||
|
|
|
|||
|
|
@ -1,4 +1,4 @@
|
|||
#ifndef __REVISION_NR_H__
|
||||
#define __REVISION_NR_H__
|
||||
#define REVISION_NR "7913"
|
||||
#define REVISION_NR "7914"
|
||||
#endif // __REVISION_NR_H__
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue