From 0dc0a534cf1b652be3d43762ce8d3807bb5a8a49 Mon Sep 17 00:00:00 2001 From: Ottermandias Date: Thu, 20 Jul 2023 00:57:11 +0200 Subject: [PATCH] Use CS in sig. --- Glamourer/Interop/UpdateSlotService.cs | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/Glamourer/Interop/UpdateSlotService.cs b/Glamourer/Interop/UpdateSlotService.cs index d2357ba..95cbfaa 100644 --- a/Glamourer/Interop/UpdateSlotService.cs +++ b/Glamourer/Interop/UpdateSlotService.cs @@ -20,6 +20,8 @@ public unsafe class UpdateSlotService : IDisposable EquipmentLoadingEvent = equipmentLoadingEvent; SignatureHelper.Initialise(this); _flagSlotForUpdateHook.Enable(); + _loadEquipmentHook = + Hook.FromAddress((nint) DrawDataContainer.MemberFunctionPointers.LoadEquipment, LoadEquipmentDetour); _loadEquipmentHook.Enable(); } @@ -53,8 +55,6 @@ public unsafe class UpdateSlotService : IDisposable private delegate void LoadEquipmentDelegateIntern(DrawDataContainer* drawDataContainer, uint slotIdx, CharacterArmor data, bool force); - // TODO: use client structs. - [Signature("E8 ?? ?? ?? ?? 41 B5 ?? FF C6", DetourName = nameof(LoadEquipmentDetour))] private readonly Hook _loadEquipmentHook = null!; private ulong FlagSlotForUpdateDetour(nint drawObject, uint slotIdx, CharacterArmor* data)