mirror of
https://github.com/xivdev/Penumbra.git
synced 2025-12-15 21:24:18 +01:00
Why does this not work, stupid Conditional.
This commit is contained in:
parent
9c4f7b7562
commit
10c0117402
1 changed files with 9 additions and 5 deletions
|
|
@ -30,7 +30,7 @@ public unsafe class GameEventManager : IDisposable
|
||||||
_resourceHandleDestructorHook.Enable();
|
_resourceHandleDestructorHook.Enable();
|
||||||
_characterBaseCreateHook.Enable();
|
_characterBaseCreateHook.Enable();
|
||||||
_characterBaseDestructorHook.Enable();
|
_characterBaseDestructorHook.Enable();
|
||||||
_weaponReloadHook.Enable();
|
_weaponReloadHook.Enable();
|
||||||
EnableDebugHook();
|
EnableDebugHook();
|
||||||
Penumbra.Log.Verbose($"{Prefix} Created.");
|
Penumbra.Log.Verbose($"{Prefix} Created.");
|
||||||
}
|
}
|
||||||
|
|
@ -268,18 +268,22 @@ public unsafe class GameEventManager : IDisposable
|
||||||
|
|
||||||
private delegate void TestDelegate(nint a1, int a2);
|
private delegate void TestDelegate(nint a1, int a2);
|
||||||
private void TestDetour(nint a1, int a2)
|
private void TestDetour(nint a1, int a2)
|
||||||
{
|
{
|
||||||
Penumbra.Log.Information($"Test: {a1:X} {a2}");
|
Penumbra.Log.Information($"Test: {a1:X} {a2}");
|
||||||
_testHook!.Original(a1, a2);
|
_testHook!.Original(a1, a2);
|
||||||
}
|
}
|
||||||
#endif
|
|
||||||
[Conditional("DEBUG")]
|
|
||||||
private void EnableDebugHook()
|
private void EnableDebugHook()
|
||||||
=> _testHook?.Enable();
|
=> _testHook?.Enable();
|
||||||
|
|
||||||
[Conditional("DEBUG")]
|
|
||||||
private void DisposeDebugHook()
|
private void DisposeDebugHook()
|
||||||
=> _testHook?.Dispose();
|
=> _testHook?.Dispose();
|
||||||
|
#else
|
||||||
|
private void EnableDebugHook()
|
||||||
|
{ }
|
||||||
|
|
||||||
|
private void DisposeDebugHook()
|
||||||
|
{ }
|
||||||
|
#endif
|
||||||
|
|
||||||
#endregion
|
#endregion
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue