From 4fc72677df03839e9073c97d5599d13e86f4f032 Mon Sep 17 00:00:00 2001 From: 4z0t Date: Wed, 20 Nov 2024 23:50:43 +0300 Subject: [PATCH] remove stack frame of math funcs --- hooks/math.hook | 31 +++++++++++++++++++++++++++++++ 1 file changed, 31 insertions(+) create mode 100644 hooks/math.hook diff --git a/hooks/math.hook b/hooks/math.hook new file mode 100644 index 0000000..5c662e3 --- /dev/null +++ b/hooks/math.hook @@ -0,0 +1,31 @@ +0x00452FC0: // sqrt + fld dword ptr [esp+4] + fsqrt + ret +0x0040EAF0: // sqrt + fld dword ptr [esp+4] + fsqrt + ret +0x0050D150: // inverse sqrt + fld dword ptr [esp+4] + fsqrt + fld1 + fdivrp st(1), st + ret +0x005734E0: // sin + fld dword ptr [esp+4] + fsin + ret +0x005734D0: // cos + fld dword ptr [esp+4] + fcos + ret +0x0040DAB0: // abs + fld dword ptr [esp+4] + fabs + ret +0x004E9DF0: // atan2 + fld dword ptr [esp+4] + fld dword ptr [esp+8] + fpatan + ret \ No newline at end of file