Core/Spells: rework part 5: GameObject casting

Port From (https://github.com/TrinityCore/TrinityCore/commit/962f6d7988b9003e550f6745be7cff812e9d8efa)
This commit is contained in:
hondacrx
2021-08-29 18:27:08 -04:00
parent e97ffa304d
commit 949d4806c5
39 changed files with 5236 additions and 4781 deletions
+7
View File
@@ -226,6 +226,12 @@ namespace Game.Entities
}
}
public override uint GetFaction()
{
Cypher.Assert(_caster != null);
return _caster.GetFaction();
}
void BindToCaster()
{
Cypher.Assert(_caster == null);
@@ -312,6 +318,7 @@ namespace Game.Entities
public Unit GetCaster() { return _caster; }
public uint GetSpellId() { return m_dynamicObjectData.SpellID; }
public ObjectGuid GetCasterGUID() { return m_dynamicObjectData.Caster; }
public override ObjectGuid GetOwnerGUID() { return GetCasterGUID(); }
public float GetRadius() { return m_dynamicObjectData.Radius; }
DynamicObjectData m_dynamicObjectData;