-
Notifications
You must be signed in to change notification settings - Fork 1
/
EmotesText.cs
31 lines (24 loc) · 964 Bytes
/
EmotesText.cs
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
using TrinityCore.Dbc.Net.Lib.Attributes;
namespace TrinityCore.Dbc.Net.Lib.Definitions
{
[DbcFile("EmotesText.dbc")]
public class EmotesText : DbcFile
{
[DbcColumn(0, Enums.DbcColumnDataType.Int32)]
public int Id { get; set; }
[DbcColumn(1, Enums.DbcColumnDataType.StringRef)]
public string? Name { get; set; }
[DbcColumn(2, Enums.DbcColumnDataType.Int32)]
public int EmoteId { get; set; }
[DbcColumn(3, Enums.DbcColumnDataType.ArrayOfUint32, 16)]
public int[]? EmoteText { get; set; }
public Emotes? GetEmoteIdEmotes()
{
return DbcDirectory.Open<Emotes>()?.Where(c => c.Id == this.EmoteId).FirstOrDefault();
}
public EmotesTextData[]? GetEmoteTextEmotesTextDatas()
{
return DbcDirectory.Open<EmotesTextData>()?.Where(c => this.EmoteText != null && this.EmoteText.Contains(c.Id)).ToArray();
}
}
}