v1.0.8.10: Hotbar crash fix when dragging inventory items; Release builds strip PDBs
Co-authored-by: Cursor <cursoragent@cursor.com>
This commit is contained in:
@@ -22,8 +22,19 @@ namespace HSUI.Helpers
|
||||
|
||||
public static IDalamudTextureWrap? GetTextureFromIconId(uint iconId, uint stackCount = 0, bool hdIcon = true)
|
||||
{
|
||||
GameIconLookup lookup = new GameIconLookup(iconId + stackCount, false, hdIcon);
|
||||
return Plugin.TextureProvider.GetFromGameIcon(lookup).GetWrapOrDefault();
|
||||
if (iconId == 0)
|
||||
return null;
|
||||
|
||||
try
|
||||
{
|
||||
GameIconLookup lookup = new GameIconLookup(iconId + stackCount, false, hdIcon);
|
||||
return Plugin.TextureProvider.GetFromGameIcon(lookup).GetWrapOrDefault();
|
||||
}
|
||||
catch
|
||||
{
|
||||
// GetFromGameIcon can throw for invalid/unsupported icon IDs (e.g. certain inventory item icons during drag-drop)
|
||||
return null;
|
||||
}
|
||||
}
|
||||
|
||||
public static IDalamudTextureWrap? GetTextureFromPath(string path)
|
||||
|
||||
Reference in New Issue
Block a user