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

Disassembly:
push ebp
mov ebp, esp
add esp, 0xffffff4c
push ebx
push esi
push edi
mov esi, ecx
lea edi, [ebp - 0x40]
movsd dword es:[edi], dword [esi]
movsd dword es:[edi], dword [esi]
movsd dword es:[edi], dword [esi]
movsd dword es:[edi], dword [esi]
mov esi, edx
mov ebx, eax
mov edx, dword [ebp + 0x18]
mov eax, dword [ebp + 0x1c]
cmp dl, 0xff
jae 0x509c91
mov byte [ebp - 0x26], dl
jmp 0x509c98
movzx edx, byte [ebx + 8]
mov byte [ebp - 0x26], dl
cmp byte [ebp + 0x14], 0xff
jae 0x509ca7
movzx edx, byte [ebp + 0x14]
mov byte [ebp - 0x27], dl
jmp 0x509cae
movzx edx, byte [ebx + 0x10]
mov byte [ebp - 0x27], dl
cmp byte [ebp + 0x10], 0xff
jae 0x509cbd
movzx edx, byte [ebp + 0x10]
mov byte [ebp - 0x28], dl
jmp 0x509cc4
movzx edx, byte [ebx + 0x24]
mov byte [ebp - 0x28], dl
cmp byte [ebp + 0xc], 0xff
jae 0x509cd3
movzx edx, byte [ebp + 0xc]
mov byte [ebp - 0x29], dl
jmp 0x509cda
movzx edx, byte [ebx + 0x2c]
mov byte [ebp - 0x29], dl
cmp al, 0xff
jae 0x509ce3
mov byte [ebp - 0x25], al
jmp 0x509ced
movzx eax, byte [ebx + 0x8c]
mov byte [ebp - 0x25], al
fld dword [ebp - 0x34]
fcomp dword [0x50a440]
wait
fnstsw ax
sahf
je 0x50a179
fld dword [ebp - 0x38]
fcomp dword [0x50a440]
wait
fnstsw ax
sahf
je 0x50a179
test esi, esi
je 0x50a434
xor eax, eax
mov dword [ebp - 4], eax
cmp dword [ebx + 0x20], 0
jle 0x509de3
cmp dword [ebx + 0x34], 0x1fffffff
je 0x509de3
push 1
movzx ecx, byte [ebx + 0x78]
mov edx, dword [ebx + 0x30]
lea eax, [ebp - 0x40]
call fcn.00509418
mov dword [ebp - 8], eax
mov ecx, dword [ebp - 8]
mov dl, 1
mov eax, dword [0x504834]
call fcn.005072bc
mov edi, eax
mov edx, 4
mov eax, edi
call fcn.005073e8
push 0
xor ecx, ecx
xor edx, edx
xor eax, eax
call fcn.00507be0
mov dword [ebp - 0x6c], eax
mov edx, dword [ebx + 0x34]
mov al, 0xb4
call fcn.00507c08
mov dword [ebp - 0x68], eax
mov edx, dword [ebx + 0x34]
mov al, 0xb4
call fcn.00507c08
mov dword [ebp - 0x64], eax
xor eax, eax
mov dword [ebp - 0x78], eax
mov dword [ebp - 0x74], 0x3dcccccd
mov dword [ebp - 0x70], 0x3f800000
push 3
lea ecx, [ebp - 0x78]
lea edx, [ebp - 0x6c]
mov eax, edi
call fcn.00507404
mov ecx, dword [ebp - 8]
mov edx, edi
mov eax, esi
call fcn.00507b7c
mov eax, dword [ebp - 8]
call fcn.00404904
mov eax, edi
call fcn.00404904
fild dword [ebx + 0x20]
fsubr dword [ebp - 0x38]
fstp dword [ebp - 0x38]
wait
fild dword [ebx + 0x20]
fsubr dword [ebp - 0x34]
fstp dword [ebp - 0x34]
wait
mov eax, dword [ebx + 0xc]
cmp eax, 7
je 0x509f40
cmp eax, 9
je 0x509f40
cmp dword [ebx + 0x3c], 0x1fffffff
je 0x509f40
fld dword [ebp - 0x34]
fstp qword [ebp - 0x18]
wait
fld qword [ebp - 0x18]
fdiv dword [0x50a444]
fstp qword [ebp - 0x20]
wait
push dword [ebp - 0x40]
push dword [ebp - 0x3c]
push dword [ebp - 0x38]
fld dword [ebp - 0x34]
fsub qword [ebp - 0x20]
fadd dword [0x50a440]
add esp, 0xfffffffc
fstp dword [esp]
wait
lea eax, [ebp - 0x50]
call fcn.0050665c
cmp dword [ebx + 0xc], 1
jne 0x509e7e
cmp dword [ebx + 0x1c], 0x1fffffff
je 0x509ea0
mov eax, dword [ebx + 0x1c]
mov edi, dword [ebx + 0x44]
cmp dword [ebx + 0x44], 0x1fffffff
jne 0x509e5d
mov edi, eax
push edi
movzx edx, byte [ebp - 0x26]
push edx
movzx edx, byte [ebp - 0x27]
push edx
push 1
mov edx, dword [ebx + 0x30]
push edx
push 1
mov ecx, eax
lea edx, [ebp - 0x50]
mov eax, esi
call fcn.00509778
jmp 0x509ea0
push 0
movzx eax, byte [ebp - 0x26]
push eax
movzx eax, byte [ebp - 0x27]
push eax
movzx eax, byte [ebp - 0x28]
push eax
movzx eax, byte [ebp - 0x29]
push eax
lea ecx, [ebp - 0x50]
mov edx, esi
mov eax, ebx
call fcn.005094b4
push dword [ebp - 0x40]
fld dword [ebp - 0x3c]
fadd qword [ebp - 0x20]
fsub dword [0x50a440]
add esp, 0xfffffffc
fstp dword [esp]
wait
push dword [ebp - 0x38]
fld dword [ebp - 0x34]
fsub qword [ebp - 0x20]
fadd dword [0x50a440]
add esp, 0xfffffffc
fstp dword [esp]
wait
lea eax, [ebp - 0x60]
call fcn.0050665c
cmp dword [ebx + 0x28], 1
jne 0x509f1c
cmp dword [ebx + 0x3c], 0x1fffffff
je 0x509fa5
mov eax, dword [ebx + 0x3c]
mov edi, dword [ebx + 0x40]
cmp dword [ebx + 0x40], 0x1fffffff
jne 0x509ef8
mov edi, eax
push edi
movzx edx, byte [ebp - 0x28]
push edx
movzx edx, byte [ebp - 0x29]
push edx
push 0
mov edx, dword [ebx + 0x30]
push edx
push 2
mov ecx, eax
lea edx, [ebp - 0x60]
mov eax, esi
call fcn.00509778
jmp 0x509fa5
push 1
movzx eax, byte [ebp - 0x26]
push eax
movzx eax, byte [ebp - 0x27]
push eax
movzx eax, byte [ebp - 0x28]
push eax
movzx eax, byte [ebp - 0x29]
push eax
lea ecx, [ebp - 0x60]
mov edx, esi
mov eax, ebx
call fcn.005094b4
jmp 0x509fa5
cmp eax, 1
jne 0x509f83
cmp dword [ebx + 0x1c], 0x1fffffff
je 0x509fa5
mov eax, dword [ebx + 0x1c]
mov edi, dword [ebx + 0x44]
cmp dword [ebx + 0x44], 0x1fffffff
jne 0x509f5f
mov edi, eax
push edi
movzx edx, byte [ebp - 0x26]
push edx
movzx edx, byte [ebp - 0x27]
push edx
push 1
mov edx, dword [ebx + 0x30]
push edx
movzx edx, byte [ebx + 0x78]
push edx
mov ecx, eax
lea edx, [ebp - 0x40]
mov eax, esi
call fcn.00509778
jmp 0x509fa5
push 0
movzx eax, byte [ebp - 0x26]
push eax
movzx eax, byte [ebp - 0x27]
push eax
movzx eax, byte [ebp - 0x28]
push eax
movzx eax, byte [ebp - 0x29]
push eax
lea ecx, [ebp - 0x40]
mov edx, esi
mov eax, ebx
call fcn.005094b4
cmp dword [ebp - 4], 0
je 0x509fb3
mov eax, dword [ebp - 4]
call fcn.00404904
cmp byte [ebx + 0x9d], 0
jne 0x50a102
xor edi, edi
xor eax, eax
mov dword [ebp - 0x24], eax
mov eax, dword [ebx + 0x68]
mov edx, dword [eax]
call dword [edx + 0x1c]
test al, al
jne 0x509ff0
mov eax, dword [ebx + 0x68]
call fcn.0050566c
mov eax, dword [ebx + 0x68]
mov edx, dword [eax]
call dword [edx + 0x2c]
mov edi, eax
mov eax, dword [ebx + 0x68]
mov edx, dword [eax]
call dword [edx + 0x20]
mov dword [ebp - 0x24], eax
fld dword [ebp - 0x34]
call fcn.004034fc
push eax
lea eax, [ebp - 0x88]
push eax
fld dword [ebp - 0x38]
call fcn.004034fc
push eax
fld dword [ebp - 0x3c]
call fcn.004034fc
push eax
fld dword [ebp - 0x40]
call fcn.004034fc
pop edx
pop ecx
call fcn.0041ef58
cmp dword [ebx + 0xc], 9
jne 0x50a102
xor eax, eax
mov dword [ebp - 4], eax
xor eax, eax
mov dword [ebp - 0x30], eax
cmp byte [ebx + 0x9d], 0
jne 0x50a084
push esi
push edi
lea esi, [ebp - 0x40]
lea edi, [ebp - 0x98]
movsd dword es:[edi], dword [esi]
movsd dword es:[edi], dword [esi]
movsd dword es:[edi], dword [esi]
movsd dword es:[edi], dword [esi]
pop edi
pop esi
push 0
movzx ecx, byte [ebx + 0x78]
mov edx, dword [ebx + 0x30]
lea eax, [ebp - 0x98]
call fcn.00509418
mov dword [ebp - 4], eax
mov ecx, dword [ebp - 4]
mov dl, 1
mov eax, dword [0x5043f0]
call fcn.00506fdc
mov dword [ebp - 0x30], eax
xor ecx, ecx
mov edx, dword [ebp - 0x30]
mov eax, esi
call fcn.00507ba4
cmp byte [ebx + 0x64], 0xb
je 0x50a0b4
push edi
mov eax, dword [ebp - 0x24]
push eax
lea eax, [ebp - 0x88]
push eax
mov eax, dword [ebp - 0x88]
push eax
mov eax, dword [ebp - 0x84]
push eax
movzx ecx, byte [ebx + 0x64]
mov edx, dword [ebx + 0x68]
mov eax, esi
call fcn.0050999c
jmp 0x50a0d6
push edi
mov eax, dword [ebp - 0x24]
push eax
lea eax, [ebp - 0x88]
push eax
mov eax, dword [ebx + 0x60]
push eax
mov eax, dword [ebx + 0x5c]
push eax
movzx ecx, byte [ebx + 0x64]
mov edx, dword [ebx + 0x68]
mov eax, esi
call fcn.0050999c
cmp byte [ebx + 0x9d], 0
jne 0x50a102
mov eax, esi
call fcn.00507bc8
cmp dword [ebp - 0x30], 0
je 0x50a0f4
mov eax, dword [ebp - 0x30]
call fcn.00404904
cmp dword [ebp - 4], 0
je 0x50a102
mov eax, dword [ebp - 4]
call fcn.00404904
cmp dword [ebx + 0x38], 0
jle 0x50a1de
cmp dword [ebx + 4], 0x1fffffff
je 0x50a1de
push 0
movzx ecx, byte [ebx + 0x78]
mov edx, dword [ebx + 0x30]
lea eax, [ebp - 0x40]
call fcn.00509418
mov dword [ebp - 0x10], eax
fild dword [ebx + 0x38]
add esp, 0xfffffffc
fstp dword [esp]
wait
mov edx, dword [ebx + 4]
movzx eax, byte [ebp - 0x25]
call fcn.00507c08
mov ecx, eax
mov dl, 1
mov eax, dword [0x504728]
call fcn.005066f0
mov edi, eax
xor edx, edx
mov eax, edi
call fcn.00506774
mov ecx, dword [ebp - 0x10]
mov edx, edi
mov eax, esi
call fcn.00506e24
mov eax, edi
call fcn.00404904
mov eax, dword [ebp - 0x10]
call fcn.00404904
jmp 0x50a1de
cmp dword [ebx + 0x38], 0
jle 0x50a1de
cmp dword [ebx + 4], 0x1fffffff
je 0x50a1de
fild dword [ebx + 0x38]
add esp, 0xfffffffc
fstp dword [esp]
wait
mov edx, dword [ebx + 4]
movzx eax, byte [ebp - 0x25]
call fcn.00507c08
mov ecx, eax
mov dl, 1
mov eax, dword [0x504728]
call fcn.005066f0
mov edi, eax
push dword [ebp - 0x40]
push dword [ebp - 0x3c]
fld dword [ebp - 0x40]
fadd dword [ebp - 0x38]
add esp, 0xfffffffc
fstp dword [esp]
wait
fld dword [ebp - 0x3c]
fadd dword [ebp - 0x34]
add esp, 0xfffffffc
fstp dword [esp]
wait
mov edx, edi
mov eax, esi
call fcn.00507864
mov eax, edi
call fcn.00404904
mov edi, dword [ebx + 0x38]
mov dword [ebp - 0xac], edi
fild dword [ebp - 0xac]
fadd dword [ebp - 0x40]
add esp, 0xfffffffc
fstp dword [esp]
wait
fild dword [ebx + 0x38]
fadd dword [ebp - 0x3c]
add esp, 0xfffffffc
fstp dword [esp]
wait
mov eax, edi
add eax, eax
mov dword [ebp - 0xb0], eax
fild dword [ebp - 0xb0]
fsubr dword [ebp - 0x38]
add esp, 0xfffffffc
fstp dword [esp]
wait
mov eax, dword [ebx + 0x38]
add eax, eax
mov dword [ebp - 0xb4], eax
fild dword [ebp - 0xb4]
fsubr dword [ebp - 0x34]
add esp, 0xfffffffc
fstp dword [esp]
wait
lea eax, [ebp - 0xa8]
call fcn.0050665c
push esi
lea esi, [ebp - 0xa8]
lea edi, [ebx + 0x8d]
movsd dword es:[edi], dword [esi]
movsd dword es:[edi], dword [esi]
movsd dword es:[edi], dword [esi]
movsd dword es:[edi], dword [esi]
pop esi
cmp byte [ebx + 0x80], 0
je 0x50a2cd
push 0
mov edx, dword [ebx + 0x30]
sub edx, dword [ebx + 0x38]
movzx ecx, byte [ebx + 0x78]
lea eax, [ebx + 0x8d]
call fcn.00509418
mov dword [ebp - 0xc], eax
xor edx, edx
mov eax, esi
call fcn.00506e08
push 0x3f800000
mov edx, dword [ebx + 0x84]
movzx eax, byte [ebp - 0x26]
call fcn.00507c08
mov ecx, eax
mov dl, 1
mov eax, dword [0x504728]
call fcn.005066f0
mov edi, eax
mov edx, 2
mov eax, edi
call fcn.00506774
mov ecx, dword [ebp - 0xc]
mov edx, edi
mov eax, esi
call fcn.00506e24
mov eax, edi
call fcn.00404904
mov eax, dword [ebp - 0xc]
call fcn.00404904
cmp byte [ebx + 0x9d], 1
jne 0x50a391
xor edi, edi
xor eax, eax
mov dword [ebp - 0x24], eax
mov eax, dword [ebx + 0x68]
mov edx, dword [eax]
call dword [edx + 0x1c]
test al, al
jne 0x50a30a
mov eax, dword [ebx + 0x68]
call fcn.0050566c
mov eax, dword [ebx + 0x68]
mov edx, dword [eax]
call dword [edx + 0x2c]
mov edi, eax
mov eax, dword [ebx + 0x68]
mov edx, dword [eax]
call dword [edx + 0x20]
mov dword [ebp - 0x24], eax
fld dword [ebp - 0x34]
call fcn.004034fc
push eax
lea eax, [ebp - 0x88]
push eax
fld dword [ebp - 0x38]
call fcn.004034fc
push eax
fld dword [ebp - 0x3c]
call fcn.004034fc
push eax
fld dword [ebp - 0x40]
call fcn.004034fc
pop edx
pop ecx
call fcn.0041ef58
cmp dword [ebx + 0xc], 9
jne 0x50a391
movzx eax, byte [ebx + 0x64]
cmp al, 0xb
je 0x50a371
push edi
mov edx, dword [ebp - 0x24]
push edx
lea edx, [ebp - 0x88]
push edx
mov edx, dword [ebp - 0x88]
push edx
mov edx, dword [ebp - 0x84]
push edx
mov ecx, eax
mov edx, dword [ebx + 0x68]
mov eax, esi
call fcn.0050999c
jmp 0x50a391
push edi
mov edx, dword [ebp - 0x24]
push edx
lea edx, [ebp - 0x88]
push edx
mov edx, dword [ebx + 0x60]
push edx
mov edx, dword [ebx + 0x5c]
push edx
mov ecx, eax
mov edx, dword [ebx + 0x68]
mov eax, esi
call fcn.0050999c
xor edi, edi
xor eax, eax
mov dword [ebp - 0x24], eax
mov eax, dword [ebx + 0x14]
mov edx, dword [eax]
call dword [edx + 0x1c]
test al, al
jne 0x50a3d8
mov eax, dword [ebx + 0x14]
call fcn.0050566c
movzx eax, byte [ebx + 0x70]
sub al, 1
jb 0x50a3b8
je 0x50a3cf
jmp 0x50a3d8
mov eax, dword [ebx + 0x14]
mov edx, dword [eax]
call dword [edx + 0x2c]
mov edi, eax
mov eax, dword [ebx + 0x14]
mov edx, dword [eax]
call dword [edx + 0x20]
mov dword [ebp - 0x24], eax
jmp 0x50a3d8
mov edi, dword [ebx + 0x6c]
mov eax, dword [ebx + 0x74]
mov dword [ebp - 0x24], eax
movzx eax, byte [ebx + 9]
cmp al, 0xb
je 0x50a408
push edi
mov edx, dword [ebp - 0x24]
push edx
lea edx, [ebp - 0x88]
push edx
mov edx, dword [ebp - 0x88]
push edx
mov edx, dword [ebp - 0x84]
push edx
mov ecx, eax
mov edx, dword [ebx + 0x14]
mov eax, esi
call fcn.0050999c
jmp 0x50a428
push edi
mov edx, dword [ebp - 0x24]
push edx
lea edx, [ebp - 0x88]
push edx
mov edx, dword [ebx + 0x58]
push edx
mov edx, dword [ebx + 0x54]
push edx
mov ecx, eax
mov edx, dword [ebx + 0x14]
mov eax, esi
call fcn.0050999c
mov eax, dword [ebp + 8]
mov edi, eax
lea esi, [ebp - 0x40]
movsd dword es:[edi], dword [esi]
movsd dword es:[edi], dword [esi]
movsd dword es:[edi], dword [esi]
movsd dword es:[edi], dword [esi]
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 0x18