Skip to content

Commit

Permalink
Added some logging for hooking...
Browse files Browse the repository at this point in the history
  • Loading branch information
awgil committed Jun 6, 2024
1 parent 666d652 commit 24979d6
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions BossMod/Util/Hook.cs
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,7 @@ public bool Enabled
public HookAddress(Address address, T detour, bool autoEnable = true) : this(address.Value, detour, autoEnable) { }
public HookAddress(nint address, T detour, bool autoEnable = true)
{
Service.Log($"Hooking {typeof(T)} @ 0x{address:X}");
_hook = Service.Hook.HookFromAddress(address, detour);
if (autoEnable)
_hook.Enable();
Expand Down

0 comments on commit 24979d6

Please sign in to comment.