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

Disassembly:
push edi
push esi
push ebp
push ebx
sub esp, 0x98
mov ebp, ecx
mov dword [esp + 0x3c], edx
mov ebx, eax
mov eax, dword [esp + 0xc4]
mov edx, dword [esp + 0xd0]
mov edi, dword [esp + 0xe0]
mov esi, dword [esp + 0xf0]
mov dword [esp + 0x4c], edx
mov edx, dword [esp + 0xdc]
mov ecx, dword [esp + 0x104]
mov dword [esp + 0x70], edx
mov edx, dword [esp + 0xe4]
mov eax, dword [eax]
mov dword [esp + 0x7c], edi
mov dword [esp + 0x8c], edx
mov edx, dword [esp + 0xe8]
mov dword [esp + 0x84], edx
mov edx, dword [esp + 0xec]
mov dword [esp + 0x6c], edx
mov edx, dword [esp + 0xf4]
mov dword [esp + 0x78], esi
mov dword [esp + 0x88], edx
mov edx, dword [esp + 0xf8]
mov dword [esp + 0x80], edx
mov edx, dword [esp + 0xfc]
mov dword [esp + 0x68], edx
mov edx, dword [esp + 0x100]
mov dword [esp + 0x74], edx
mov dword [esp + 0x90], ecx
mov ecx, dword [esp + 0x108]
mov dword [esp + 0x94], ecx
lea ecx, [ebp + ebp*2]
mov dword [esp + 0x50], ecx
lea ecx, [ebp + ecx]
mov dword [esp + 0x48], ecx
mov ecx, ebx
sub ecx, ebp
mov dword [esp + 0x54], ecx
add eax, ecx
mov ecx, dword [esp + 0xcc]
mov dword [esp + 0xc], ecx
mov ecx, dword [esp + 0xd4]
mov dword [esp + 0x10], ecx
mov ecx, dword [esp + 0xd8]
mov dword [esp + 0x14], ecx
mov ecx, dword [esp + 0xc8]
mov dword [esp + 0x18], edi
mov dword [esp + 0x1c], esi
mov dword [esp + 0x20], edx
mov edx, dword [esp + 0xbc]
call fcn.00866808
mov esi, dword [esp + 0xc4]
mov eax, dword [esi]
add eax, ebx
mov edi, dword [esp + 0xcc]
mov edx, dword [esp + 0xd4]
mov dword [esp + 0xc], edi
mov ecx, dword [esp + 0xc8]
mov dword [esp + 0x10], edx
mov edx, dword [esp + 0xd8]
mov dword [esp + 0x14], edx
mov edx, dword [esp + 0x8c]
mov dword [esp + 0x18], edx
mov edx, dword [esp + 0x88]
mov dword [esp + 0x1c], edx
mov edx, dword [esp + 0x90]
mov dword [esp + 0x20], edx
mov edx, dword [esp + 0xbc]
call fcn.00866808
lea edi, [ebp + ebx]
mov esi, dword [esp + 0xc4]
mov eax, dword [esi]
mov dword [esp + 0x58], edi
add eax, edi
mov edx, dword [esp + 0xcc]
mov dword [esp + 0xc], edx
mov edx, dword [esp + 0xd4]
mov dword [esp + 0x10], edx
mov edx, dword [esp + 0xd8]
mov ecx, dword [esp + 0xc8]
mov dword [esp + 0x14], edx
mov edx, dword [esp + 0x84]
mov dword [esp + 0x18], edx
mov edx, dword [esp + 0x80]
mov dword [esp + 0x1c], edx
mov edx, dword [esp + 0x94]
mov dword [esp + 0x20], edx
mov edx, dword [esp + 0xbc]
call fcn.00866808
test ebp, ebp
jle 0x8667e8
mov eax, dword [esp + 0xc4]
mov ecx, dword [eax]
dec ecx
mov edx, dword [esp + 0xc0]
test edx, edx
jle 0x86652a
mov dword [esp + 0x5c], ecx
xor eax, eax
xor esi, esi
mov dword [esp + 0x64], eax
mov edi, dword [esp + 0x3c]
mov dword [esp + 0x40], ebx
mov dword [esp + 0x60], ebp
mov ebp, dword [esp + 0x4c]
mov ebx, dword [esp + 0xc4]
mov ebx, dword [ebx + esi]
mov eax, dword [esp + 0x60]
test eax, eax
jle 0x866535
mov eax, dword [esp + 0x5c]
cmp ebx, eax
jle 0x866483
mov dword [esp + 0x4c], ebp
mov edx, dword [esp + 0x70]
mov dword [esp + 0x44], esi
mov eax, dword [esp + 0x7c]
mov esi, dword [esp + 0x6c]
mov dword [esp + 0x70], eax
mov eax, dword [esp + 0x8c]
mov dword [esp + 0x7c], eax
mov eax, dword [esp + 0x84]
mov ebp, dword [esp + 0x68]
mov dword [esp + 0x8c], eax
mov eax, dword [esp + 0x78]
mov dword [esp + 0x84], edx
mov ecx, dword [esp + 0x60]
mov dword [esp + 0x6c], eax
mov eax, dword [esp + 0x88]
mov dword [esp + 0x78], eax
mov eax, dword [esp + 0x80]
mov dword [esp + 0x88], eax
mov eax, dword [esp + 0x74]
mov dword [esp + 0x80], esi
mov dword [esp + 0x68], eax
mov eax, dword [esp + 0x90]
mov dword [esp + 0x74], eax
mov eax, dword [esp + 0x94]
mov dword [esp + 0x90], eax
mov eax, dword [esp + 0x40]
lea eax, [eax + ecx*2]
mov dword [esp + 0x94], ebp
add eax, ebx
mov ecx, dword [esp + 0xcc]
mov dword [esp + 0xc], ecx
mov ecx, dword [esp + 0xd4]
mov dword [esp + 0x10], ecx
mov ecx, dword [esp + 0xd8]
mov dword [esp + 0x14], ecx
mov ecx, dword [esp + 0xc8]
mov dword [esp + 0x18], edx
mov edx, dword [esp + 0xbc]
mov dword [esp + 0x1c], esi
mov esi, dword [esp + 0x44]
mov dword [esp + 0x20], ebp
mov ebp, dword [esp + 0x4c]
call fcn.00866808
mov edx, dword [esp + 0x60]
mov eax, dword [esp + 0x5c]
lea ecx, [eax + edx*2]
cmp ebx, ecx
jl 0x866386
mov dword [esp + 0x3c], ebx
mov ecx, dword [esp + 0x70]
mov dword [esp + 0x44], esi
mov eax, dword [esp + 0x7c]
mov edx, dword [esp + 0x6c]
mov dword [esp + 0x70], eax
mov eax, dword [esp + 0x8c]
mov dword [esp + 0x7c], eax
mov eax, dword [esp + 0x78]
mov esi, dword [esp + 0x68]
mov dword [esp + 0x8c], ecx
mov dword [esp + 0x6c], eax
mov eax, dword [esp + 0x88]
mov dword [esp + 0x78], eax
mov eax, dword [esp + 0x74]
mov dword [esp + 0x88], edx
mov dword [esp + 0x68], eax
mov eax, dword [esp + 0x90]
mov dword [esp + 0x74], eax
mov eax, dword [esp + 0x58]
lea eax, [ebx + eax]
mov dword [esp + 0x90], esi
mov ebx, dword [esp + 0xcc]
mov dword [esp + 0xc], ebx
mov ebx, dword [esp + 0xd4]
mov dword [esp + 0x10], ebx
mov ebx, dword [esp + 0xd8]
mov dword [esp + 0x14], ebx
mov ebx, dword [esp + 0x3c]
mov dword [esp + 0x18], ecx
mov ecx, dword [esp + 0xc8]
mov dword [esp + 0x1c], edx
mov edx, dword [esp + 0xbc]
mov dword [esp + 0x20], esi
mov esi, dword [esp + 0x44]
call fcn.00866808
mov eax, dword [esp + 0x50]
mov edx, dword [esp + 0x5c]
lea ecx, [eax + edx]
cmp ebx, ecx
jl 0x866420
mov dword [esp + 0x3c], ebx
mov ecx, dword [esp + 0x70]
mov dword [esp + 0x44], esi
mov eax, dword [esp + 0x7c]
mov edx, dword [esp + 0x6c]
mov dword [esp + 0x70], eax
mov eax, dword [esp + 0x78]
mov dword [esp + 0x7c], ecx
mov esi, dword [esp + 0x68]
mov dword [esp + 0x6c], eax
mov eax, dword [esp + 0x74]
mov dword [esp + 0x78], edx
mov dword [esp + 0x68], eax
mov eax, dword [esp + 0x40]
lea eax, [eax + ebx]
mov dword [esp + 0x74], esi
mov ebx, dword [esp + 0xcc]
mov dword [esp + 0xc], ebx
mov ebx, dword [esp + 0xd4]
mov dword [esp + 0x10], ebx
mov ebx, dword [esp + 0xd8]
mov dword [esp + 0x14], ebx
mov ebx, dword [esp + 0x3c]
mov dword [esp + 0x18], ecx
mov ecx, dword [esp + 0xc8]
mov dword [esp + 0x1c], edx
mov edx, dword [esp + 0xbc]
mov dword [esp + 0x20], esi
mov esi, dword [esp + 0x44]
call fcn.00866808
mov eax, dword [esp + 0x5c]
add eax, dword [esp + 0x48]
cmp ebx, eax
jl 0x86647f
mov eax, dword [esp + 0x54]
lea eax, [ebx + eax]
mov edx, dword [esp + 0xcc]
mov dword [esp + 0xc], edx
mov edx, dword [esp + 0xd4]
mov dword [esp + 0x10], edx
mov edx, dword [esp + 0xd8]
mov ecx, dword [esp + 0xc8]
mov dword [esp + 0x14], edx
mov edx, dword [esp + 0x70]
mov dword [esp + 0x18], edx
mov edx, dword [esp + 0x6c]
mov dword [esp + 0x1c], edx
mov edx, dword [esp + 0x68]
mov dword [esp + 0x20], edx
mov edx, dword [esp + 0xbc]
call fcn.00866808
mov dword [esp + 0x5c], ebx
mov ebx, dword [esp + 0x70]
mov eax, dword [esp + 0x7c]
mov edx, dword [esp + 0xbc]
mov dword [esp + 0xc], ebx
mov ecx, ebp
mov dword [esp + 0x10], eax
mov eax, dword [esp + 0x8c]
mov dword [esp + 0x14], eax
mov eax, dword [esp + 0x84]
mov dword [esp + 0x18], eax
mov eax, dword [esp + 0x6c]
mov dword [esp + 0x1c], eax
mov eax, dword [esp + 0x78]
mov dword [esp + 0x20], eax
mov eax, dword [esp + 0x88]
mov dword [esp + 0x24], eax
mov eax, dword [esp + 0x80]
mov dword [esp + 0x28], eax
mov eax, dword [esp + 0x68]
mov dword [esp + 0x2c], eax
mov eax, dword [esp + 0x74]
mov dword [esp + 0x30], eax
mov eax, dword [esp + 0x90]
mov dword [esp + 0x34], eax
mov eax, dword [esp + 0x94]
mov dword [esp + 0x38], eax
mov eax, edi
call fcn.00866af0
add edi, dword [esp + 0xb8]
add esi, 4
add ebp, 4
mov eax, dword [esp + 0x64]
inc eax
mov edx, dword [esp + 0xc0]
mov dword [esp + 0x64], eax
cmp eax, edx
jl 0x8661bf
add esp, 0x98
pop ebx
pop ebp
pop esi
pop edi
ret
mov eax, dword [esp + 0x5c]
cmp ebx, eax
jge 0x866483
mov dword [esp + 0x4c], ebp
mov edx, dword [esp + 0x70]
mov dword [esp + 0x44], esi
mov eax, dword [esp + 0x7c]
mov esi, dword [esp + 0x6c]
mov dword [esp + 0x70], eax
mov eax, dword [esp + 0x8c]
mov dword [esp + 0x7c], eax
mov eax, dword [esp + 0x84]
mov ebp, dword [esp + 0x68]
mov dword [esp + 0x8c], eax
mov eax, dword [esp + 0x78]
mov dword [esp + 0x84], edx
mov ecx, dword [esp + 0x60]
mov dword [esp + 0x6c], eax
mov eax, dword [esp + 0x88]
mov dword [esp + 0x78], eax
mov eax, dword [esp + 0x80]
mov dword [esp + 0x88], eax
mov eax, dword [esp + 0x74]
mov dword [esp + 0x80], esi
mov dword [esp + 0x68], eax
mov eax, dword [esp + 0x90]
mov dword [esp + 0x74], eax
mov eax, dword [esp + 0x94]
mov dword [esp + 0x90], eax
mov eax, dword [esp + 0x40]
lea eax, [eax + ecx*2]
mov dword [esp + 0x94], ebp
add eax, ebx
mov ecx, dword [esp + 0xcc]
mov dword [esp + 0xc], ecx
mov ecx, dword [esp + 0xd4]
mov dword [esp + 0x10], ecx
mov ecx, dword [esp + 0xd8]
mov dword [esp + 0x14], ecx
mov ecx, dword [esp + 0xc8]
mov dword [esp + 0x18], edx
mov edx, dword [esp + 0xbc]
mov dword [esp + 0x1c], esi
mov esi, dword [esp + 0x44]
mov dword [esp + 0x20], ebp
mov ebp, dword [esp + 0x4c]
call fcn.00866808
mov edx, dword [esp + 0x60]
mov eax, dword [esp + 0x5c]
lea ecx, [eax + edx*2]
cmp ebx, ecx
jg 0x8666e6
mov dword [esp + 0x3c], ebx
mov ecx, dword [esp + 0x70]
mov dword [esp + 0x44], esi
mov eax, dword [esp + 0x7c]
mov edx, dword [esp + 0x6c]
mov dword [esp + 0x70], eax
mov eax, dword [esp + 0x8c]
mov dword [esp + 0x7c], eax
mov eax, dword [esp + 0x78]
mov esi, dword [esp + 0x68]
mov dword [esp + 0x8c], ecx
mov dword [esp + 0x6c], eax
mov eax, dword [esp + 0x88]
mov dword [esp + 0x78], eax
mov eax, dword [esp + 0x74]
mov dword [esp + 0x88], edx
mov dword [esp + 0x68], eax
mov eax, dword [esp + 0x90]
mov dword [esp + 0x74], eax
mov eax, dword [esp + 0x58]
lea eax, [ebx + eax]
mov dword [esp + 0x90], esi
mov ebx, dword [esp + 0xcc]
mov dword [esp + 0xc], ebx
mov ebx, dword [esp + 0xd4]
mov dword [esp + 0x10], ebx
mov ebx, dword [esp + 0xd8]
mov dword [esp + 0x14], ebx
mov ebx, dword [esp + 0x3c]
mov dword [esp + 0x18], ecx
mov ecx, dword [esp + 0xc8]
mov dword [esp + 0x1c], edx
mov edx, dword [esp + 0xbc]
mov dword [esp + 0x20], esi
mov esi, dword [esp + 0x44]
call fcn.00866808
mov eax, dword [esp + 0x50]
mov edx, dword [esp + 0x5c]
lea ecx, [eax + edx]
cmp ebx, ecx
jg 0x866780
mov dword [esp + 0x3c], ebx
mov ecx, dword [esp + 0x70]
mov dword [esp + 0x44], esi
mov eax, dword [esp + 0x7c]
mov edx, dword [esp + 0x6c]
mov dword [esp + 0x70], eax
mov eax, dword [esp + 0x78]
mov dword [esp + 0x7c], ecx
mov esi, dword [esp + 0x68]
mov dword [esp + 0x6c], eax
mov eax, dword [esp + 0x74]
mov dword [esp + 0x78], edx
mov dword [esp + 0x68], eax
mov eax, dword [esp + 0x40]
lea eax, [eax + ebx]
mov dword [esp + 0x74], esi
mov ebx, dword [esp + 0xcc]
mov dword [esp + 0xc], ebx
mov ebx, dword [esp + 0xd4]
mov dword [esp + 0x10], ebx
mov ebx, dword [esp + 0xd8]
mov dword [esp + 0x14], ebx
mov ebx, dword [esp + 0x3c]
mov dword [esp + 0x18], ecx
mov ecx, dword [esp + 0xc8]
mov dword [esp + 0x1c], edx
mov edx, dword [esp + 0xbc]
mov dword [esp + 0x20], esi
mov esi, dword [esp + 0x44]
call fcn.00866808
mov eax, dword [esp + 0x5c]
add eax, dword [esp + 0x48]
cmp ebx, eax
jg 0x86647f
mov eax, dword [esp + 0x54]
lea eax, [ebx + eax]
mov edx, dword [esp + 0xcc]
mov dword [esp + 0xc], edx
mov edx, dword [esp + 0xd4]
mov dword [esp + 0x10], edx
mov edx, dword [esp + 0xd8]
mov ecx, dword [esp + 0xc8]
mov dword [esp + 0x14], edx
mov edx, dword [esp + 0x70]
mov dword [esp + 0x18], edx
mov edx, dword [esp + 0x6c]
mov dword [esp + 0x1c], edx
mov edx, dword [esp + 0x68]
mov dword [esp + 0x20], edx
mov edx, dword [esp + 0xbc]
call fcn.00866808
jmp 0x86647f
mov eax, dword [esp + 0xc4]
mov ecx, dword [eax]
inc ecx
mov edx, dword [esp + 0xc0]
test edx, edx
jg 0x8661a3
jmp 0x86652a