mirror of
https://github.com/goatcorp/Dalamud.git
synced 2025-12-12 18:27:23 +01:00
feat: add NameId to actor struct and Npc in object model
This commit is contained in:
parent
49f450958b
commit
eb16ffde49
3 changed files with 8 additions and 2 deletions
|
|
@ -14,5 +14,10 @@ namespace Dalamud.Game.ClientState.Actors.Types.NonPlayer {
|
|||
/// The data ID of the NPC linking to their respective game data.
|
||||
/// </summary>
|
||||
public int DataId => this.actorStruct.DataId;
|
||||
|
||||
/// <summary>
|
||||
/// The name ID of the NPC linking to their respective game data.
|
||||
/// </summary>
|
||||
public int NameId => this.actorStruct.NameId;
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -24,7 +24,8 @@ namespace Dalamud.Game.ClientState.Structs
|
|||
|
||||
// This field can't be correctly aligned, so we have to cut it manually.
|
||||
[FieldOffset(0x17d0)] [MarshalAs(UnmanagedType.ByValArray, SizeConst = 7)] public byte[] CompanyTag;
|
||||
|
||||
|
||||
[FieldOffset(0x1868)] public int NameId;
|
||||
[FieldOffset(0x1884)] public byte CurrentWorld;
|
||||
[FieldOffset(0x1886)] public byte HomeWorld;
|
||||
[FieldOffset(6328)] public int CurrentHp;
|
||||
|
|
|
|||
|
|
@ -90,7 +90,7 @@ namespace Dalamud.Interface
|
|||
$" -> {i} - {actor.Name} - {actor.Position.X} {actor.Position.Y} {actor.Position.Z}\n";
|
||||
|
||||
if (actor is Npc npc)
|
||||
stateString += $" DataId: {npc.DataId}\n";
|
||||
stateString += $" DataId: {npc.DataId} NameId:{npc.NameId}\n";
|
||||
|
||||
if (actor is Chara chara)
|
||||
stateString +=
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue