Function at 0x516940
Capabilities:
Resolve function by parsing pe exports

Disassembly:
sub esp, 0x40
push esi
mov esi, ecx
cmp dword [esi + 0x1d8], 2
je 0x516e35
mov eax, dword [esi + 0x78]
push ebx
mov dword [esi + 0x84], eax
mov ecx, dword [esi + 0x7c]
mov dword [esi + 0x88], ecx
mov edx, dword [esi + 0x80]
mov dword [esi + 0x8c], edx
mov eax, dword [esi + 4]
mov dword [esi + 0x78], eax
mov ecx, dword [esi + 8]
mov dword [esi + 0x7c], ecx
mov edx, dword [esi + 0xc]
mov dword [esi + 0x80], edx
mov eax, dword [esi + 0x5c]
mov dword [esi + 0x90], eax
mov ecx, dword [esi + 0x60]
mov dword [esi + 0x94], ecx
mov edx, dword [esi + 0x64]
mov dword [esi + 0x98], edx
mov eax, dword [esi + 0x68]
mov dword [esi + 0x9c], eax
mov ecx, dword [esi + 0x6c]
push ebp
mov dword [esi + 0xa0], ecx
mov edx, dword [esi + 0x70]
lea ebx, [esi + 0x28]
push edi
push ebx
lea ecx, [esi + 0xa8]
mov dword [esi + 0xa4], edx
call fcn.004eb390
lea ebp, [esi + 0x38]
lea edi, [esi + 0xb8]
cmp edi, ebp
je 0x5169fb
push ebp
mov ecx, edi
call fcn.004149e0
lea eax, [ebp + 0xc]
lea ecx, [edi + 0xc]
push eax
call fcn.004149e0
lea ecx, [ebp + 0x18]
push ecx
lea ecx, [edi + 0x18]
call fcn.004149e0
mov eax, dword [esi + 0x198]
lea edi, [esi + 0x10]
test eax, eax
je 0x516b74
mov eax, dword [esi + 0x19c]
test eax, eax
je 0x516a81
push edi
lea edx, [esp + 0x2c]
push ebp
push edx
call fcn.0051f4d0
mov ecx, dword [eax]
push ebp
mov dword [esp + 0x20], ecx
mov edx, dword [eax + 4]
mov dword [esp + 0x24], edx
lea ecx, [esp + 0x38]
fld dword [eax + 8]
fld dword [esp + 0x20]
fmul dword [esi + 0x18c]
lea eax, [esp + 0x20]
push eax
push ecx
fstp dword [esp + 0x28]
fld dword [esp + 0x2c]
fmul dword [esi + 0x190]
fstp dword [esp + 0x2c]
fmul dword [esi + 0x194]
fstp dword [esp + 0x30]
call fcn.0051f470
mov edx, dword [eax]
add esp, 0x18
mov dword [esp + 0x10], edx
mov ecx, dword [eax + 4]
mov dword [esp + 0x14], ecx
mov edx, dword [eax + 8]
mov dword [esp + 0x18], edx
jmp 0x516ab1
fld dword [edi]
fld dword [edi + 4]
fxch st(1)
fmul dword [esi + 0x18c]
mov eax, dword [edi + 8]
mov dword [esp + 0x18], eax
fstp dword [esp + 0x10]
fmul dword [esi + 0x190]
fstp dword [esp + 0x14]
fld dword [esp + 0x18]
fmul dword [esi + 0x194]
fstp dword [esp + 0x18]
mov eax, dword [esi + 0x19c]
test eax, eax
je 0x516b13
lea ecx, [esi + 0x1c]
lea edx, [esp + 0x28]
push ecx
push ebp
push edx
call fcn.0051f4d0
mov ecx, dword [eax]
push ebp
mov dword [esp + 0x2c], ecx
mov edx, dword [eax + 4]
mov dword [esp + 0x30], edx
lea ecx, [esp + 0x38]
fld dword [eax + 8]
fld dword [esp + 0x2c]
fmul dword [esi + 0x180]
lea eax, [esp + 0x2c]
push eax
push ecx
fstp dword [esp + 0x34]
fld dword [esp + 0x38]
fmul dword [esi + 0x184]
fstp dword [esp + 0x38]
fmul dword [esi + 0x188]
fstp dword [esp + 0x3c]
call fcn.0051f470
add esp, 0x18
xor edx, edx
mov ecx, edi
fld dword [ecx]
fsub dword [esp + edx*4 + 0x10]
fcomp dword [0x552458]
fnstsw ax
test ah, 5
jp 0x516b32
fld dword [0x552538]
jmp 0x516b38
fld dword [0x552454]
fld dword [ecx]
fcomp dword [0x552458]
fnstsw ax
test ah, 5
jp 0x516b4f
fld dword [0x552538]
jmp 0x516b55
fld dword [0x552454]
fxch st(1)
fcompp
fnstsw ax
test ah, 0x44
jnp 0x516b66
mov dword [ecx], 0
inc edx
add ecx, 4
cmp edx, 3
jl 0x516b17
jmp 0x516c06
fld dword [esi + 0x18c]
push ecx
lea edx, [esp + 0x20]
fstp dword [esp]
push edi
push edx
call fcn.004039d0
fld dword [esi + 0xdc]
fsub dword [esp + 0x28]
add esp, 8
lea eax, [esi + 0x1c]
lea ecx, [esp + 0x20]
fstp dword [esi + 0xdc]
fld dword [esi + 0xe0]
fsub dword [esp + 0x24]
fstp dword [esi + 0xe0]
fld dword [esi + 0xe4]
fsub dword [esp + 0x28]
fstp dword [esi + 0xe4]
fld dword [esi + 0x180]
fstp dword [esp]
push eax
push ecx
call fcn.004039d0
fld dword [esi + 0xe8]
fsub dword [esp + 0x28]
add esp, 0xc
fstp dword [esi + 0xe8]
fld dword [esi + 0xec]
fsub dword [esp + 0x20]
fstp dword [esi + 0xec]
fld dword [esi + 0xf0]
fsub dword [esp + 0x24]
fstp dword [esi + 0xf0]
cmp dword [esi + 0x1d8], 1
jne 0x516c5d
fld dword [esi + 0x1dc]
fdiv dword [esi + 0x1e0]
fsubr dword [0x552454]
fld st(0)
fmul dword [edi]
fstp dword [edi]
fld st(0)
fmul dword [edi + 4]
fstp dword [edi + 4]
fmul dword [edi + 8]
fstp dword [edi + 8]
fld dword [esi + 0x1dc]
fdiv dword [esi + 0x1e0]
fsubr dword [0x552454]
fld st(0)
fmul dword [esi + 0x1c]
fstp dword [esi + 0x1c]
fld st(0)
fmul dword [esi + 0x20]
fstp dword [esi + 0x20]
fmul dword [esi + 0x24]
fstp dword [esi + 0x24]
fld dword [esp + 0x54]
fmul dword [esi + 0x5c]
fld dword [esp + 0x54]
fmul dword [esi + 0x60]
fld dword [esp + 0x54]
fmul dword [esi + 0x64]
push ecx
lea eax, [esi + 0x68]
lea edx, [esp + 0x20]
fstp dword [esp + 0x28]
fxch st(1)
fadd dword [esi + 4]
fstp dword [esi + 4]
fadd dword [esi + 8]
fstp dword [esi + 8]
fld dword [esp + 0x28]
fadd dword [esi + 0xc]
fstp dword [esi + 0xc]
fld dword [esp + 0x58]
fmul dword [esi + 0xdc]
fld dword [esp + 0x58]
fmul dword [esi + 0xe0]
fld dword [esp + 0x58]
fmul dword [esi + 0xe4]
fstp dword [esp + 0x28]
fxch st(1)
fadd dword [edi]
fstp dword [edi]
fadd dword [edi + 4]
fstp dword [edi + 4]
fld dword [esp + 0x28]
fadd dword [edi + 8]
fstp dword [edi + 8]
fld dword [esp + 0x58]
fmul dword [esi + 0xe8]
fld dword [esp + 0x58]
fmul dword [esi + 0xec]
fld dword [esp + 0x58]
fmul dword [esi + 0xf0]
fstp dword [esp + 0x28]
fxch st(1)
fadd dword [esi + 0x1c]
fstp dword [esi + 0x1c]
fadd dword [esi + 0x20]
fstp dword [esi + 0x20]
fld dword [esp + 0x28]
fadd dword [esi + 0x24]
fstp dword [esi + 0x24]
fld dword [esp + 0x58]
fmul dword [0x55244c]
fstp dword [esp]
push eax
push edx
call fcn.004039d0
fld dword [ebx + 0xc]
add esp, 8
lea eax, [esp + 0x20]
fstp dword [esp]
lea ecx, [esp + 0x14]
push eax
push ecx
call fcn.004039d0
lea edx, [esp + 0x28]
push ebx
push edx
call fcn.00403a00
add esp, 0x10
fchs
fstp dword [esp]
lea eax, [esp + 0x20]
push ebx
lea ecx, [esp + 0x30]
push eax
push ecx
call fcn.004052a0
push eax
lea edx, [esp + 0x24]
lea eax, [esp + 0x48]
push edx
push eax
call fcn.00405210
add esp, 0x18
lea ecx, [esp + 0x44]
push eax
call fcn.00465a30
lea ecx, [esp + 0x40]
push ecx
mov ecx, ebx
call fcn.004e8160
fld dword [esp + 0x4c]
fadd dword [ebx + 0xc]
push ebx
push ebx
fstp dword [ebx + 0xc]
call fcn.004f2910
fstp dword [esp + 4]
add esp, 4
call fcn.0051f140
fdivr dword [0x552454]
add esp, 4
mov ecx, ebx
fstp dword [esp + 0x54]
mov edx, dword [esp + 0x54]
push edx
call fcn.00444d60
fld dword [esp + 0x54]
fmul dword [ebx + 0xc]
push ebx
mov ecx, ebp
fstp dword [ebx + 0xc]
call fcn.00520a60
mov ecx, esi
call fcn.00516380
mov ecx, esi
call fcn.005167c0
fld dword [esi + 0x1a8]
fadd dword [esi + 4]
xor eax, eax
pop edi
pop ebp
pop ebx
fstp dword [esi + 4]
fld dword [esi + 0x1ac]
fadd dword [esi + 8]
fstp dword [esi + 8]
fld dword [esi + 0x1b0]
fadd dword [esi + 0xc]
fstp dword [esi + 0xc]
mov dword [esi + 0xe4], eax
mov dword [esi + 0xe0], eax
mov dword [esi + 0xdc], eax
mov dword [esi + 0xf0], eax
mov dword [esi + 0xec], eax
mov dword [esi + 0xe8], eax
mov dword [esi + 0x1b0], eax
mov dword [esi + 0x1ac], eax
mov dword [esi + 0x1a8], eax
pop esi
add esp, 0x40
ret 4