Core/GameObjects: Changed gameobject artkit type to uint

Port From (https://github.com/TrinityCore/TrinityCore/commit/bb3b2cf4cb4897a7dd087e2409a250c887c3fb9a)
This commit is contained in:
hondacrx
2022-06-02 20:58:32 -04:00
parent 7a3f188d2c
commit 8934cfb6dc
4 changed files with 8 additions and 8 deletions
@@ -753,7 +753,7 @@ namespace Game.Chat
obj.SetGoType((GameObjectTypes)objectState);
break;
case 2:
obj.SetGoArtKit((byte)objectState);
obj.SetGoArtKit(objectState);
break;
case 3:
obj.SetGoAnimProgress(objectState);
@@ -293,7 +293,7 @@ namespace Game.Entities
SetGoType(goInfo.type);
m_prevGoState = goState;
SetGoState(goState);
SetGoArtKit((byte)artKit);
SetGoArtKit(artKit);
SetUpdateFieldValue(m_values.ModifyValue(m_gameObjectData).ModifyValue(m_gameObjectData.SpawnTrackingStateAnimID), Global.DB2Mgr.GetEmptyAnimStateID());
@@ -1566,7 +1566,7 @@ namespace Game.Entities
if (artKitValue == 0)
Log.outError(LogFilter.Sql, $"GameObject {GetEntry()} hit by spell {spellId} needs `artkit{artKitIndex}` in `gameobject_template_addon`");
else
SetGoArtKit((byte)artKitValue);
SetGoArtKit(artKitValue);
break;
}
@@ -1624,7 +1624,7 @@ namespace Game.Entities
}
}
public void SetGoArtKit(byte kit)
public void SetGoArtKit(uint kit)
{
SetUpdateFieldValue(m_values.ModifyValue(m_gameObjectData).ModifyValue(m_gameObjectData.ArtKit), kit);
GameObjectData data = Global.ObjectMgr.GetGameObjectData(m_spawnId);
@@ -1632,7 +1632,7 @@ namespace Game.Entities
data.artKit = kit;
}
public void SetGoArtKit(byte artkit, GameObject go, uint lowguid)
public void SetGoArtKit(uint artkit, GameObject go, uint lowguid)
{
GameObjectData data = null;
if (go != null)
@@ -1438,7 +1438,7 @@ namespace Game.Entities
public Quaternion rotation;
public uint animprogress;
public GameObjectState goState;
public byte artKit;
public uint artKit;
public GameObjectData() : base(SpawnObjectType.GameObject) { }
}
@@ -260,11 +260,11 @@ namespace Game.PvP
Map map = Global.MapMgr.FindMap(530, 0);
var bounds = map.GetGameObjectBySpawnIdStore().LookupByKey(m_capturePointSpawnId);
foreach (var go in bounds)
go.SetGoArtKit((byte)artkit);
go.SetGoArtKit(artkit);
bounds = map.GetGameObjectBySpawnIdStore().LookupByKey(m_Objects[m_TowerType]);
foreach (var go in bounds)
go.SetGoArtKit((byte)artkit2);
go.SetGoArtKit(artkit2);
// send world state update
if (field != 0)