Core/Entities: Update StringId assignment to use StringIdType
Port From (https://github.com/TrinityCore/TrinityCore/commit/9959a1373a1851e484ddef9268d98b116c5d8241)
This commit is contained in:
@@ -411,7 +411,7 @@ namespace Game.Entities
|
|||||||
//We must update last scriptId or it looks like we reloaded a script, breaking some things such as gossip temporarily
|
//We must update last scriptId or it looks like we reloaded a script, breaking some things such as gossip temporarily
|
||||||
LastUsedScriptID = GetScriptId();
|
LastUsedScriptID = GetScriptId();
|
||||||
|
|
||||||
m_stringIds[0] = cInfo.StringId;
|
m_stringIds[(int)StringIdType.Template] = cInfo.StringId;
|
||||||
|
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
@@ -2925,12 +2925,12 @@ namespace Game.Entities
|
|||||||
if (!id.IsEmpty())
|
if (!id.IsEmpty())
|
||||||
{
|
{
|
||||||
m_scriptStringId = id;
|
m_scriptStringId = id;
|
||||||
m_stringIds[2] = m_scriptStringId;
|
m_stringIds[(int)StringIdType.Script] = m_scriptStringId;
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
m_scriptStringId = null;
|
m_scriptStringId = null;
|
||||||
m_stringIds[2] = null;
|
m_stringIds[(int)StringIdType.Script] = null;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -3531,7 +3531,7 @@ namespace Game.Entities
|
|||||||
// checked at creature_template loading
|
// checked at creature_template loading
|
||||||
DefaultMovementType = (MovementGeneratorType)data.movementType;
|
DefaultMovementType = (MovementGeneratorType)data.movementType;
|
||||||
|
|
||||||
m_stringIds[1] = data.StringId;
|
m_stringIds[(int)StringIdType.Spawn] = data.StringId;
|
||||||
|
|
||||||
if (addToMap && !GetMap().AddToMap(this))
|
if (addToMap && !GetMap().AddToMap(this))
|
||||||
return false;
|
return false;
|
||||||
|
|||||||
@@ -380,7 +380,7 @@ namespace Game.Entities
|
|||||||
|
|
||||||
LastUsedScriptID = GetGoInfo().ScriptId;
|
LastUsedScriptID = GetGoInfo().ScriptId;
|
||||||
|
|
||||||
m_stringIds[0] = goInfo.StringId;
|
m_stringIds[(int)StringIdType.Template] = goInfo.StringId;
|
||||||
|
|
||||||
AIM_Initialize();
|
AIM_Initialize();
|
||||||
|
|
||||||
@@ -1163,7 +1163,7 @@ namespace Game.Entities
|
|||||||
|
|
||||||
m_goData = data;
|
m_goData = data;
|
||||||
|
|
||||||
m_stringIds[1] = data.StringId;
|
m_stringIds[(int)StringIdType.Spawn] = data.StringId;
|
||||||
|
|
||||||
if (addToMap && !GetMap().AddToMap(this))
|
if (addToMap && !GetMap().AddToMap(this))
|
||||||
return false;
|
return false;
|
||||||
@@ -2675,12 +2675,12 @@ namespace Game.Entities
|
|||||||
if (!id.IsEmpty())
|
if (!id.IsEmpty())
|
||||||
{
|
{
|
||||||
m_scriptStringId = id;
|
m_scriptStringId = id;
|
||||||
m_stringIds[2] = m_scriptStringId;
|
m_stringIds[(int)StringIdType.Script] = m_scriptStringId;
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
m_scriptStringId = null;
|
m_scriptStringId = null;
|
||||||
m_stringIds[2] = null;
|
m_stringIds[(int)StringIdType.Script] = null;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user