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

Disassembly:
push ebp
mov ebp, esp
and esp, 0xfffffff8
sub esp, 0x98
push ebx
push ebp
mov ebp, ecx
mov al, byte [ebp + 0x75]
test al, al
push esi
push edi
je 0x587721
mov al, byte [ebp + 0x7a]
test al, al
je 0x587721
mov ecx, dword [ebp + 0x28]
mov edi, dword [ebp + 0x88]
mov esi, ecx
test esi, esi
mov dword [esp + 0x38], edi
je 0x587721
test ecx, ecx
mov eax, dword [ebp + 0xe4]
mov edx, dword [ebp + 0xe8]
mov dword [esp + 0x88], eax
mov dword [esp + 0x78], edx
mov ebx, 0xffff80cd
je 0x58721e
cmp dword [ebp + 0xec], ebx
jne 0x58721e
call fcn.0041d1b0
jmp 0x587229
mov eax, dword [ebp + 0xec]
cdq
xor eax, edx
sub eax, edx
mov ecx, dword [ebp + 0x9c]
sub ecx, dword [ebp + 0xa0]
add ecx, eax
mov dword [esp + 0x58], ecx
mov ecx, dword [ebp + 0x28]
test ecx, ecx
je 0x587251
cmp dword [ebp + 0xf0], ebx
jne 0x587251
call fcn.0041d1e0
jmp 0x58725c
mov eax, dword [ebp + 0xf0]
cdq
xor eax, edx
sub eax, edx
mov ecx, dword [ebp + 0xa4]
mov ebx, dword [ebp + 0xa8]
mov edx, dword [esi + 0x130]
sub ecx, ebx
add ecx, eax
mov eax, dword [esi + 0x128]
mov dword [esp + 0x4c], ecx
mov ecx, dword [esi + 0x12c]
cmp eax, ecx
mov esi, dword [esi + 0x134]
mov dword [esp + 0x98], eax
mov dword [esp + 0x44], ecx
mov dword [esp + 0x50], edx
mov dword [esp + 0x70], esi
jge 0x587718
cmp edx, esi
jge 0x587718
mov eax, dword [edi]
xor ebx, ebx
push ebx
mov ecx, edi
call dword [eax + 0x50]
cmp word [ebp + 0x138], 0x80bd
mov eax, dword [edi + 0x9c]
mov ecx, dword [ebp + 0x13c]
mov edx, dword [ebp + 0x140]
sete byte [esp + 0x13]
test eax, eax
mov dword [esp + 0x48], ecx
mov dword [esp + 0x5c], edx
mov dword [esp + 0x94], eax
mov dword [esp + 0x28], ebx
mov dword [esp + 0x1c], ebx
jle 0x587721
cmp dword [edi + 0x9c], ebx
jbe 0x5876fc
mov eax, dword [edi + 0x94]
mov esi, dword [eax + ebx*4]
test esi, esi
je 0x5876fc
mov edx, dword [esi]
mov ecx, esi
call dword [edx + 4]
test eax, eax
je 0x58732e
cmp eax, 0x7de550
je 0x587429
mov eax, dword [eax + 4]
test eax, eax
jne 0x58731c
xor al, al
neg al
sbb eax, eax
and eax, esi
mov edi, eax
test edi, edi
mov dword [esp + 0x84], edi
je 0x5876f8
mov eax, dword [edi + 0x98]
fld dword [edi + 0x30]
mov ecx, dword [eax + 0x1c]
fadd dword [0x746498]
mov edx, dword [eax + 0x28]
xor esi, esi
mov si, word [eax + 8]
mov eax, dword [edi + 0x38]
sub esp, 8
fstp qword [esp]
mov dword [esp + 0x5c], ecx
mov dword [esp + 0x38], edx
mov dword [esp + 0x20], 0
mov dword [esp + 0xac], eax
mov dword [esp + 0x94], esi
call dword [sym.imp.MSVCRT.dll_floor]
call sub.MSVCRT.dll__ftol
fld dword [esp + 0xac]
mov ecx, dword [esp + 0x90]
fadd dword [0x746498]
add eax, ecx
mov dword [esp + 0x6c], eax
fstp qword [esp]
call dword [sym.imp.MSVCRT.dll_floor]
add esp, 8
call sub.MSVCRT.dll__ftol
mov ecx, dword [esp + 0x78]
mov edx, dword [esp + 0x1c]
mov ebx, eax
add ebx, ecx
mov ecx, dword [ebp + 0x64]
lea eax, [ecx + edx*8]
mov ecx, dword [eax]
mov edx, dword [eax + 4]
mov eax, dword [edi + 0x98]
mov dword [esp + 0x80], ecx
xor ecx, ecx
test esi, esi
mov cx, word [eax + 8]
mov dword [esp + 0x68], ebx
mov dword [esp + 0x6c], edx
mov dword [esp + 0x24], ecx
fild dword [esp + 0x24]
fst dword [esp + 0x34]
jle 0x587616
mov edi, dword [esp + 0x28]
mov eax, dword [esp + 0x30]
mov ecx, dword [esp + 0x54]
lea edx, [edi + edi*2]
shl edx, 2
mov dword [esp + 0x40], edx
mov dword [esp + 0x2c], eax
mov dword [esp + 0x20], ecx
mov dword [esp + 0x24], esi
jmp 0x587434
mov al, 1
jmp 0x587330
mov edi, dword [esp + 0x28]
mov eax, dword [ebp + 0x44]
mov ecx, dword [esp + 0x64]
mov esi, dword [ebp + 0x54]
add edx, eax
mov eax, dword [edx + 4]
add eax, ecx
mov ecx, dword [edx + 8]
lea esi, [esi + edi*8]
mov edi, dword [esi]
mov esi, dword [esi + 4]
add ecx, ebx
mov bl, byte [ebp + 0x74]
test bl, bl
mov dword [esp + 0x90], edi
mov dword [esp + 0x74], esi
mov dword [esp + 0x14], eax
mov dword [esp + 0x60], ecx
mov esi, eax
mov edi, ecx
je 0x58748c
movsx edx, byte [edx]
dec edx
je 0x587488
sub edx, 2
je 0x587484
dec edx
jne 0x58748c
add eax, dword [esp + 0x58]
jmp 0x58748c
add eax, dword [esp + 0x58]
sub ecx, dword [esp + 0x4c]
mov dl, byte [esp + 0x13]
test dl, dl
jne 0x587498
mov esi, eax
mov edi, ecx
mov edx, dword [esp + 0x5c]
mov ebx, dword [esp + 0x48]
add ecx, edx
mov edx, dword [esp + 0x98]
add eax, ebx
cmp eax, edx
jge 0x5874b1
mov eax, edx
mov ebx, dword [esp + 0x44]
cmp eax, ebx
jle 0x5874bb
mov eax, ebx
mov ebx, dword [esp + 0x50]
cmp ecx, ebx
jge 0x5874c5
mov ecx, ebx
mov ebx, dword [esp + 0x70]
cmp ecx, ebx
jle 0x5874cf
mov ecx, ebx
cmp esi, edx
jge 0x5874d5
mov esi, edx
mov edx, dword [esp + 0x44]
cmp esi, edx
jle 0x5874df
mov esi, edx
mov edx, dword [esp + 0x50]
cmp edi, edx
jge 0x5874e9
mov edi, edx
cmp edi, ebx
jle 0x5874ef
mov edi, ebx
cmp word [ebp + 0x138], 0x8064
jne 0x58750a
mov edi, dword [esp + 0x48]
mov edx, dword [esp + 0x5c]
mov esi, eax
sub esi, edi
mov edi, ecx
sub edi, edx
mov ebx, dword [esp + 0x64]
mov edx, eax
sub edx, ebx
mov ebx, dword [esp + 0x68]
mov dword [esp + 0x3c], edx
fild dword [esp + 0x3c]
mov edx, dword [esp + 0x20]
fstp dword [edx]
mov edx, ecx
sub edx, ebx
mov dword [esp + 0x3c], edx
fild dword [esp + 0x3c]
mov edx, dword [esp + 0x20]
fstp dword [edx + 8]
mov edx, dword [esp + 0x14]
cmp eax, edx
je 0x587555
fld dword [esp + 0x34]
mov dword [esp + 0x18], 1
fsub dword [0x746470]
fstp dword [esp + 0x34]
cmp ecx, dword [esp + 0x60]
je 0x587569
fsub dword [0x746470]
mov dword [esp + 0x18], 1
mov eax, dword [esp + 0x30]
test eax, eax
mov ecx, dword [esp + 0x2c]
je 0x5875d3
fld dword [ecx]
mov eax, dword [ecx + 4]
sub esi, edx
mov dword [esp + 0x14], esi
fild dword [esp + 0x14]
mov dword [esp + 0x7c], eax
sub edi, dword [esp + 0x60]
fmul dword [esp + 0x80]
mov dword [esp + 0x14], edi
fadd dword [esp + 0x90]
fstp dword [ecx]
fild dword [esp + 0x14]
fmul dword [esp + 0x6c]
fadd dword [esp + 0x74]
fst dword [esp + 0x14]
fstp dword [ecx + 4]
fcomp dword [ecx]
fnstsw ax
test ah, 0x40
je 0x5875cb
fld dword [esp + 0x7c]
fcomp dword [esp + 0x14]
fnstsw ax
test ah, 0x40
jne 0x5875d3
mov dword [esp + 0x18], 1
mov edi, dword [esp + 0x20]
mov edx, dword [esp + 0x28]
mov eax, dword [esp + 0x24]
add edi, 0xc
add ecx, 8
inc edx
mov dword [esp + 0x28], edx
mov edx, dword [esp + 0x40]
add edx, 0xc
dec eax
mov dword [esp + 0x20], edi
mov dword [esp + 0x2c], ecx
mov dword [esp + 0x40], edx
mov dword [esp + 0x24], eax
jne 0x587430
mov edi, dword [esp + 0x84]
mov esi, dword [esp + 0x8c]
fld dword [ebp + 0x144]
fcomp dword [0x746468]
fnstsw ax
test ah, 0x41
je 0x587640
fld dword [ebp + 0x148]
fcomp dword [0x746468]
fnstsw ax
test ah, 0x41
je 0x587640
xor al, al
jmp 0x587642
mov al, 1
mov ecx, dword [esp + 0x30]
test ecx, ecx
je 0x5876b3
test al, al
jne 0x5876b3
cmp word [ebp + 0x138], 0x8064
je 0x5876b3
cmp dword [ebp + 0x160], 0xffff80b5
jne 0x5876b3
fld dword [esp + 0x34]
fcomp dword [0x746468]
fnstsw ax
test ah, 0x40
je 0x58768a
xor eax, eax
test esi, esi
jle 0x58768a
mov edx, dword [ebp + 0x54]
mov edx, dword [edx + eax*8]
mov dword [ecx + eax*8], edx
inc eax
cmp eax, esi
jl 0x58767c
fcomp dword [0x746468]
fnstsw ax
test ah, 0x40
je 0x5876b5
xor eax, eax
test esi, esi
jle 0x5876b5
add ecx, 4
mov edx, dword [ebp + 0x54]
mov edx, dword [edx + eax*8 + 4]
mov dword [ecx], edx
inc eax
add ecx, 8
cmp eax, esi
jl 0x5876a0
jmp 0x5876b5
fstp st(0)
mov eax, dword [esp + 0x18]
test eax, eax
je 0x5876f4
mov eax, dword [edi + 0x98]
inc word [eax + 0x30]
cmp word [eax + 0x30], 0
jne 0x5876d4
mov word [eax + 0x30], 1
mov edi, dword [edi + 0x98]
mov eax, dword [esp + 0x54]
xor ecx, ecx
mov cx, word [edi + 8]
push 0xc
push eax
push ecx
lea ecx, [edi + 0xc]
call fcn.006ed170
mov byte [ebp + 0x79], 1
mov ebx, dword [esp + 0x1c]
mov edi, dword [esp + 0x38]
mov eax, dword [esp + 0x94]
inc ebx
cmp ebx, eax
mov dword [esp + 0x1c], ebx
jl 0x5872f4
pop edi
pop esi
pop ebp
pop ebx
mov esp, ebp
pop ebp
ret
mov edx, dword [edi]
push 1
mov ecx, edi
call dword [edx + 0x50]
pop edi
pop esi
pop ebp
pop ebx
mov esp, ebp
pop ebp
ret