Core/Entities: Added GetStringId helper methods

Port From (https://github.com/TrinityCore/TrinityCore/commit/5cea37153eb6675bf0a25320a1c11cd0ec4969b6)
This commit is contained in:
Hondacrx
2024-08-05 14:57:21 -04:00
parent 337ba82a92
commit b8d0b4bf2e
3 changed files with 9 additions and 0 deletions
@@ -1024,6 +1024,13 @@ namespace Framework.Constants
BelongsToLayer = 0x100000,
}
public enum StringIdType
{
Template = 0,
Spawn = 1,
Script = 2
}
// values based at Holidays.dbc
public enum HolidayIds
{
@@ -2935,6 +2935,7 @@ namespace Game.Entities
}
public string[] GetStringIds() { return m_stringIds; }
public string GetStringId(StringIdType type) { return m_stringIds[(int)type]; }
public VendorItemData GetVendorItems()
{
@@ -2685,6 +2685,7 @@ namespace Game.Entities
}
public string[] GetStringIds() { return m_stringIds; }
public string GetStringId(StringIdType type) { return m_stringIds[(int)type]; }
public override string GetName(Locale locale = Locale.enUS)
{