mirror of
https://github.com/goatcorp/Dalamud.git
synced 2025-12-14 12:44:16 +01:00
add version of CreateItemLink that takes a lumina Item to avoid a duplicate lookup
This commit is contained in:
parent
535312dd22
commit
94bba30c21
2 changed files with 2 additions and 3 deletions
|
|
@ -562,7 +562,7 @@ namespace Dalamud {
|
||||||
{
|
{
|
||||||
this.Framework.Gui.Chat.PrintChat(new XivChatEntry
|
this.Framework.Gui.Chat.PrintChat(new XivChatEntry
|
||||||
{
|
{
|
||||||
MessageBytes = SeStringUtils.CreateItemLink((uint)item.RowId, false).Encode()
|
MessageBytes = SeStringUtils.CreateItemLink(item, false).Encode()
|
||||||
});
|
});
|
||||||
};
|
};
|
||||||
this.isImguiDrawItemSearchWindow = true;
|
this.isImguiDrawItemSearchWindow = true;
|
||||||
|
|
|
||||||
|
|
@ -3,7 +3,6 @@ using Lumina.Excel.GeneratedSheets;
|
||||||
using System;
|
using System;
|
||||||
using System.Collections.Generic;
|
using System.Collections.Generic;
|
||||||
using System.Linq;
|
using System.Linq;
|
||||||
using System.Text;
|
|
||||||
|
|
||||||
using DalamudItem = Dalamud.Data.TransientSheet.Item;
|
using DalamudItem = Dalamud.Data.TransientSheet.Item;
|
||||||
|
|
||||||
|
|
@ -36,7 +35,7 @@ namespace Dalamud.Game.Chat.SeStringHandling
|
||||||
return new SeString(payloads);
|
return new SeString(payloads);
|
||||||
}
|
}
|
||||||
|
|
||||||
public static SeString CreateItemLink(Item item, bool isHQ, string displayNameOverride = null)
|
public static SeString CreateItemLink(DalamudItem item, bool isHQ, string displayNameOverride = null)
|
||||||
{
|
{
|
||||||
return CreateItemLink((uint)item.RowId, isHQ, displayNameOverride ?? item.Name);
|
return CreateItemLink((uint)item.RowId, isHQ, displayNameOverride ?? item.Name);
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue