fix: addonargs name

This commit is contained in:
Kaz Wolfe 2025-08-05 12:34:38 -07:00
parent 39060d2501
commit dc28194ade
No known key found for this signature in database
GPG key ID: 258813F53A16EBB4
2 changed files with 7 additions and 6 deletions

View file

@ -38,7 +38,7 @@ public abstract unsafe class AddonArgs
/// </summary> /// </summary>
/// <param name="name">The name to check.</param> /// <param name="name">The name to check.</param>
/// <returns>Whether it is the case.</returns> /// <returns>Whether it is the case.</returns>
internal bool IsAddon(ReadOnlySpan<char> name) internal bool IsAddon(string name)
{ {
if (this.Addon.IsNull) if (this.Addon.IsNull)
return false; return false;
@ -46,12 +46,10 @@ public abstract unsafe class AddonArgs
if (name.Length is 0 or > 32) if (name.Length is 0 or > 32)
return false; return false;
var addonName = this.Addon.Name; if (string.IsNullOrEmpty(this.Addon.Name))
if (string.IsNullOrEmpty(addonName))
return false; return false;
return name == addonName; return name == this.Addon.Name;
} }
/// <summary> /// <summary>

View file

@ -1,3 +1,4 @@
using System.Diagnostics;
using System.Diagnostics.CodeAnalysis; using System.Diagnostics.CodeAnalysis;
using System.Linq; using System.Linq;
@ -117,9 +118,11 @@ public class AddonLifecycleWidget : IDataWindowWidget
{ {
ImGui.Columns(2); ImGui.Columns(2);
var functionAddress = receiveEventListener.FunctionAddress;
ImGui.Text("Hook Address"u8); ImGui.Text("Hook Address"u8);
ImGui.NextColumn(); ImGui.NextColumn();
ImGui.Text(receiveEventListener.FunctionAddress.ToString("X")); ImGui.Text($"0x{functionAddress:X} (ffxiv_dx11.exe+{functionAddress - Process.GetCurrentProcess().MainModule!.BaseAddress:X})");
ImGui.NextColumn(); ImGui.NextColumn();
ImGui.Text("Hook Status"u8); ImGui.Text("Hook Status"u8);