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

Disassembly:
sub esp, 0x80
push ebx
push ebp
mov ebp, dword [esp + 0x8c]
mov ecx, ebp
mov edx, dword [ecx]
mov dword [esp + 0x3c], edx
mov edx, dword [ecx + 4]
mov ecx, dword [ecx + 8]
mov dword [esp + 0x40], edx
mov edx, dword [eax]
mov dword [esp + 0x44], ecx
mov ecx, dword [eax + 4]
mov dword [esp + 0x48], edx
mov edx, dword [eax + 8]
mov eax, ebp
mov dword [esp + 0x4c], ecx
mov ecx, dword [eax]
mov dword [esp + 0x50], edx
mov edx, dword [eax + 4]
mov eax, dword [eax + 8]
push esi
xor ebx, ebx
push edi
mov dword [esp + 0x10], ebx
mov dword [esp + 0x38], ecx
mov dword [esp + 0x3c], edx
mov dword [esp + 0x40], eax
or edi, 0xffffffff
jmp 0x50a2c0
mov edi, dword [esp + 0x14]
fld dword [esp + 0x38]
fabs
fcomp qword [0x612338]
fnstsw ax
test ah, 5
jp 0x50a2fd
fld dword [esp + 0x3c]
fabs
fcomp qword [0x612338]
fnstsw ax
test ah, 5
jp 0x50a2fd
fld dword [esp + 0x40]
fabs
fcomp qword [0x612338]
fnstsw ax
test ah, 5
jnp 0x50a724
movsx esi, word [esp + 0x10]
mov ecx, dword [esp + 0xa8]
imul esi, esi, 0x2c
mov eax, dword [esp + 0x98]
add esi, ecx
push esi
lea ecx, [esp + 0x3c]
push ecx
lea edx, [esp + 0x58]
push edx
push eax
call fcn.00508660
add esp, 0x10
test al, al
je 0x50a70d
mov edx, dword [esp + 0x10]
fld dword [0x612224]
fsub dword [esi]
inc edx
fld dword [esp + 0x44]
mov dword [esp + 0x10], edx
lea ecx, [esi + 4]
fmul st(1)
mov edx, dword [ecx]
mov eax, dword [ecx + 4]
mov ecx, dword [ecx + 8]
fstp dword [esp + 0x44]
mov dword [esp + 0x5c], edx
fld dword [esp + 0x48]
inc edi
fmul st(1)
movsx edx, di
imul edx, edx, 0x2c
fstp dword [esp + 0x48]
fld dword [esp + 0x4c]
fmul st(1)
fstp dword [esp + 0x4c]
fstp st(0)
mov dword [esp + 0x60], eax
mov dword [esp + 0x64], ecx
mov ecx, dword [esp + 0xa8]
lea esi, [edx + ecx + 0x10]
mov eax, esi
mov edx, dword [eax]
mov dword [esp + 0x80], edx
mov edx, dword [eax + 4]
mov dword [esp + 0x84], edx
mov edx, dword [eax + 8]
mov dword [esp + 0x88], edx
mov eax, dword [eax + 0xc]
fld dword [esp + 0x88]
mov dword [esp + 0x8c], eax
fmul dword [esp + 0x4c]
mov dword [esp + 0x14], edi
fld dword [esp + 0x84]
mov ebp, 1
fmul dword [esp + 0x48]
mov word [esp + 0x24], di
faddp st(1)
fld dword [esp + 0x80]
fmul dword [esp + 0x44]
faddp st(1)
fchs
fld dword [esp + 0x80]
fmul st(1)
fadd dword [esp + 0x44]
fstp dword [esp + 0x38]
fld dword [esp + 0x84]
fmul st(1)
fadd dword [esp + 0x48]
fstp dword [esp + 0x3c]
fld dword [esp + 0x88]
fmul st(1)
fadd dword [esp + 0x4c]
fstp dword [esp + 0x40]
fstp st(0)
fld dword [esp + 0x64]
fmul dword [esp + 0x88]
fld dword [esp + 0x60]
fmul dword [esp + 0x84]
faddp st(1)
fld dword [esp + 0x5c]
fmul dword [esp + 0x80]
faddp st(1)
fsub dword [esp + 0x8c]
fchs
fld dword [esp + 0x80]
fmul st(1)
fadd dword [esp + 0x5c]
fstp dword [esp + 0x50]
fld dword [esp + 0x84]
fmul st(1)
fadd dword [esp + 0x60]
fstp dword [esp + 0x54]
test bx, bx
fld dword [esp + 0x88]
fmul st(1)
fadd dword [esp + 0x64]
fstp dword [esp + 0x58]
fstp st(0)
jle 0x50a6d4
movsx edx, word [esp + 0x1c]
fld dword [esp + 0x40]
imul edx, edx, 0x2c
fmul dword [edx + ecx + 0x18]
fld dword [esp + 0x3c]
fmul dword [edx + ecx + 0x14]
faddp st(1)
fld dword [esp + 0x38]
fmul dword [edx + ecx + 0x10]
lea edx, [edx + ecx + 0x10]
mov dword [esp + 0x18], edx
faddp st(1)
fcomp dword [0x612318]
fnstsw ax
test ah, 5
jp 0x50a606
lea ecx, [esp + 0x2c]
lea edi, [esp + 0x74]
call fcn.004d25e0
test al, al
je 0x50a5ff
fld dword [esp + 0x30]
mov ax, word [esp + 0x1c]
fmul dword [esp + 0x48]
lea ecx, [esp + 0x5c]
fld dword [esp + 0x4c]
push ecx
fmul dword [esp + 0x38]
mov word [esp + 0x2a], ax
lea edx, [esp + 0x54]
lea eax, [esp + 0x30]
faddp st(1)
mov ecx, edi
fld dword [esp + 0x30]
mov ebp, 2
fmul dword [esp + 0x48]
faddp st(1)
fld dword [esp + 0x34]
fmul dword [esp + 0x34]
fld dword [esp + 0x30]
fmul dword [esp + 0x30]
faddp st(1)
fld dword [esp + 0x38]
fmul dword [esp + 0x38]
faddp st(1)
fdivp st(1)
fld dword [esp + 0x30]
fmul st(1)
fstp dword [esp + 0x3c]
fld dword [esp + 0x34]
fmul st(1)
fstp dword [esp + 0x40]
fmul dword [esp + 0x38]
fstp dword [esp + 0x44]
call fcn.0050a190
add esp, 4
cmp bx, 1
jle 0x50a6d4
movsx edx, word [esp + 0x1e]
fld dword [esp + 0x40]
mov eax, dword [esp + 0xa8]
imul edx, edx, 0x2c
fmul dword [edx + eax + 0x18]
fld dword [esp + 0x3c]
fmul dword [edx + eax + 0x14]
faddp st(1)
fld dword [esp + 0x38]
fmul dword [edx + eax + 0x10]
lea edi, [edx + eax + 0x10]
faddp st(1)
fcomp dword [0x612318]
fnstsw ax
test ah, 5
jp 0x50a6d4
mov ebx, dword [esp + 0x18]
push esi
lea esi, [esp + 0x6c]
call fcn.004d2440
add esp, 4
test al, al
je 0x50a6d4
mov cx, word [esp + 0x1e]
mov edx, dword [esp + 0x68]
mov eax, dword [esp + 0x6c]
mov word [esp + 0x28], cx
mov ecx, dword [esp + 0x70]
mov ebp, 3
mov dword [esp + 0x38], 0
mov dword [esp + 0x3c], 0
mov dword [esp + 0x40], 0
mov dword [esp + 0x50], edx
mov dword [esp + 0x54], eax
mov dword [esp + 0x58], ecx
jmp 0x50a6d4
mov ecx, dword [esp + 0xa8]
cmp bx, 1
jle 0x50a6d4
mov bx, word [esp + 0x1e]
fld dword [esp + 0x40]
movsx edx, bx
imul edx, edx, 0x2c
fmul dword [edx + ecx + 0x18]
fld dword [esp + 0x3c]
fmul dword [edx + ecx + 0x14]
faddp st(1)
fld dword [esp + 0x38]
fmul dword [edx + ecx + 0x10]
lea edx, [edx + ecx + 0x10]
faddp st(1)
fcomp dword [0x612318]
fnstsw ax
test ah, 5
jp 0x50a6d4
lea ecx, [esp + 0x2c]
lea edi, [esp + 0x74]
call fcn.004d25e0
test al, al
je 0x50a6d4
fld dword [esp + 0x30]
lea eax, [esp + 0x5c]
fmul dword [esp + 0x48]
push eax
fld dword [esp + 0x50]
lea edx, [esp + 0x54]
fmul dword [esp + 0x38]
lea eax, [esp + 0x30]
mov ecx, edi
mov ebp, 2
faddp st(1)
mov word [esp + 0x2a], bx
fld dword [esp + 0x30]
fmul dword [esp + 0x48]
faddp st(1)
fld dword [esp + 0x34]
fmul dword [esp + 0x34]
fld dword [esp + 0x30]
fmul dword [esp + 0x30]
faddp st(1)
fld dword [esp + 0x38]
fmul dword [esp + 0x38]
faddp st(1)
fdivp st(1)
fld dword [esp + 0x30]
fmul st(1)
fstp dword [esp + 0x3c]
fld dword [esp + 0x34]
fmul st(1)
fstp dword [esp + 0x40]
fmul dword [esp + 0x38]
fstp dword [esp + 0x44]
call fcn.0050a190
add esp, 4
mov ax, word [esp + 0xa4]
movsx ecx, bp
shl ecx, 1
mov edx, ecx
shr ecx, 2
lea esi, [esp + 0x24]
lea edi, [esp + 0x1c]
rep movsd dword es:[edi], dword [esi]
mov ecx, edx
and ecx, 3
cmp word [esp + 0x10], ax
mov ebx, ebp
mov ebp, dword [esp + 0x94]
rep movsb byte es:[edi], byte [esi]
jl 0x50a2bc
jmp 0x50a724
add esi, 4
mov ecx, dword [esi]
mov edx, dword [esi + 4]
mov eax, dword [esi + 8]
mov dword [esp + 0x50], ecx
mov dword [esp + 0x54], edx
mov dword [esp + 0x58], eax
mov eax, dword [esp + 0x9c]
mov ecx, dword [esp + 0x50]
mov edx, dword [esp + 0x54]
mov dword [eax], ecx
mov ecx, dword [esp + 0x58]
mov dword [eax + 4], edx
mov dword [eax + 8], ecx
movsx edi, bx
jmp dword [edi*4 + 0x50aa4c]