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

Disassembly:
mov eax, 0x1021ada1
call fcn.10210210
sub esp, 0x60
push ebp
push esi
push edi
mov dword [esp + 0x2c], ecx
mov ebp, dword [esp + 0x84]
and dword [esp + 0x74], 0
mov eax, dword [ebp + 0xcc]
test eax, eax
je 0x1009760e
mov esi, dword [eax - 4]
mov dword [esp + 0xc], esi
jmp 0x10097613
and dword [esp + 0xc], 0
mov eax, dword [ebp]
lea ecx, [esp + 0x4c]
push ebx
push dword [esp + 0x84]
xor edi, edi
push ecx
mov ecx, ebp
mov dword [esp + 0x1c], edi
call dword [eax + 0x480]
mov eax, dword [esp + 0x5c]
sub eax, dword [esp + 0x54]
mov ebx, dword [esp + 0x58]
inc eax
sub ebx, dword [esp + 0x50]
mov dword [esp + 0x48], eax
inc ebx
mov eax, dword [esp + 0x8c]
mov dword [esp + 0x2c], ebx
mov eax, dword [eax + 0x4ac]
cmp eax, 0x80000000
je 0x10097689
cmp eax, 3
jl 0x10097689
mov eax, dword [ebp + 0xb0]
xor ecx, ecx
mov edx, 0x7fffffff
cmp eax, edx
cmove eax, ecx
cmp ebx, eax
jg 0x10097689
mov eax, dword [ebp + 0xb0]
cmp eax, edx
cmove eax, ecx
mov dword [esp + 0x2c], eax
mov eax, dword [ebp]
mov ecx, ebp
call dword [eax + 0x49c]
mov ecx, dword [ebp + 0xec]
mov dword [esp + 0x28], eax
test ecx, ecx
je 0x100976a8
push ecx
call fcn.100c9d51
and dword [esp + 0x20], edi
xor ebx, ebx
and dword [esp + 0x44], edi
xor esi, esi
and dword [esp + 0x40], edi
xor ecx, ecx
and dword [esp + 0x88], ebx
mov dword [esp + 0x18], ebx
mov dword [esp + 0x24], ebx
mov dword [esp + 0x1c], esi
mov dword [esp + 0x38], esi
mov dword [esp + 0x34], ecx
cmp dword [esp + 0x10], ecx
jle 0x100977e8
mov edx, dword [esp + 0x10]
jmp 0x100976e9
mov ecx, dword [esp + 0x34]
mov eax, dword [ebp + 0xcc]
mov ebx, dword [eax + ecx*4]
test ebx, ebx
je 0x10097c29
mov eax, dword [ebx + 0x2c]
test eax, eax
jne 0x10097708
mov eax, dword [0x102b7738]
jmp 0x10097721
cmp eax, dword [0x102b7738]
jne 0x10097721
push 0
push ecx
push dword [esp + 0x8c]
mov ecx, ebx
call fcn.10079533
and dword [esp + 0x3c], 0
lea ecx, [esp + 0x3c]
push eax
call fcn.1000fd99
push dword [esp + 0x84]
mov byte [esp + 0x7c], 1
mov ecx, ebx
mov eax, dword [ebx]
call dword [eax + 0x3e4]
mov esi, dword [esp + 0x3c]
test eax, eax
jne 0x100978ea
mov eax, dword [esi + 0x490]
cmp eax, 0x80000000
je 0x10097768
cmp eax, 3
je 0x100978ea
mov byte [esp + 0x78], 0
test esi, esi
je 0x10097778
mov eax, dword [esi]
mov ecx, esi
call dword [eax + 4]
mov ecx, dword [esp + 0x88]
mov edx, dword [esp + 0x10]
mov eax, dword [esp + 0x34]
inc eax
mov dword [esp + 0x34], eax
cmp eax, edx
jl 0x100976e5
test ecx, ecx
je 0x100977e0
mov eax, dword [ecx]
push dword [esp + 0x84]
call dword [eax + 0x3e4]
test eax, eax
je 0x100977e0
mov eax, dword [ebp]
lea ecx, [esp + 0x40]
push ecx
lea ecx, [esp + 0x48]
push ecx
lea ecx, [esp + 0x28]
push ecx
push 0
push dword [esp + 0x98]
mov ecx, ebp
push dword [esp + 0xa0]
push dword [esp + 0x9c]
call dword [eax + 0x138]
add edi, dword [esp + 0x20]
mov ebx, dword [esp + 0x18]
mov esi, dword [esp + 0x1c]
mov ecx, dword [ebp + 0xec]
test ecx, ecx
je 0x1009783e
cmp dword [ebp + 0x88], 0
jle 0x1009783e
push dword [esp + 0x84]
call fcn.100ca8a3
mov esi, dword [ebp + 0xec]
cmp eax, ebx
mov ecx, esi
cmovg ebx, eax
mov dword [esp + 0x24], ebx
call fcn.100ca53e
push dword [esp + 0x84]
inc eax
mov ecx, esi
cmp edi, eax
cmovl edi, eax
call fcn.100ca938
mov esi, dword [esp + 0x1c]
cmp esi, eax
cmovl esi, eax
mov dword [esp + 0x38], esi
cmp ebx, esi
mov dword [ebp + 0xb8], edi
lea eax, [esp + 0x24]
mov dword [ebp + 0xbc], edi
lea ecx, [esp + 0x38]
mov dword [ebp + 0xb0], ebx
cmovle eax, ecx
pop ebx
mov eax, dword [eax]
mov dword [ebp + 0xb4], eax
mov eax, dword [esp + 0x88]
mov eax, dword [eax + 0x4b0]
cmp eax, 0x80000000
je 0x1009787e
test eax, eax
jne 0x1009788c
cmp dword [ebp + 0x8c], edi
jge 0x1009788c
mov dword [ebp + 0x8c], edi
push dword [esp + 0x80]
mov eax, dword [ebp]
lea ecx, [esp + 0x60]
push ecx
mov ecx, ebp
call dword [eax + 0x480]
pop edi
pop esi
mov edx, dword [eax + 0xc]
sub edx, dword [eax + 4]
mov ecx, dword [eax + 8]
inc edx
sub ecx, dword [eax]
inc ecx
mov dword [ebp + 0xa4], edx
mov dword [ebp + 0xa0], ecx
or dword [ebp + 0xe8], 1
or dword [esp + 0x6c], 0xffffffff
mov ecx, dword [esp + 0x80]
pop ebp
test ecx, ecx
je 0x100978db
mov eax, dword [ecx]
call dword [eax + 4]
mov ecx, dword [esp + 0x60]
mov dword fs:[0], ecx
leave
ret 0xc
push dword [esp + 0x48]
mov eax, dword [ebx]
mov ecx, ebx
push dword [esp + 0x30]
push dword [esp + 0x8c]
call dword [eax + 0x11c]
test byte [ebx + 0xe0], 0x10
je 0x1009795e
mov eax, dword [ebx]
mov ecx, ebx
push dword [esp + 0x84]
call dword [eax + 0x27c]
mov eax, dword [esp + 0x30]
mov ecx, ebx
mov edi, dword [ebx]
push dword [eax + 8]
push dword [esp + 0x88]
call dword [edi + 0x12c]
push eax
push dword [esp + 0x88]
mov ecx, ebx
call dword [edi + 0x1c4]
mov byte [esp + 0x78], 0
test esi, esi
je 0x10097955
mov eax, dword [esi]
mov ecx, esi
call dword [eax + 4]
mov edi, dword [esp + 0x14]
jmp 0x10097778
test byte [ebp + 0xe0], 0x20
jne 0x100979f4
mov eax, dword [ebx]
mov ecx, ebx
call dword [eax + 0x1d4]
mov dword [esp + 0x4c], eax
test eax, eax
je 0x100979f4
mov eax, dword [ebx]
mov ecx, ebx
push dword [esp + 0x84]
call dword [eax + 0x27c]
mov eax, dword [esp + 0x30]
mov ecx, ebx
mov edi, dword [ebx]
push dword [eax + 8]
push dword [esp + 0x88]
call dword [edi + 0x12c]
push eax
push dword [esp + 0x88]
mov ecx, ebx
call dword [edi + 0x1c4]
mov eax, dword [esp + 0x88]
mov edi, dword [esp + 0x14]
mov ecx, edi
test eax, eax
je 0x100979cc
mov ecx, dword [eax + 0x48]
add ecx, edi
cmp dword [esp + 0x4c], 1
push ebx
push ecx
push dword [esp + 0x8c]
mov ecx, dword [esp + 0x34]
jne 0x100979ea
call fcn.10078365
jmp 0x10097768
call fcn.10078437
jmp 0x10097768
mov ecx, ebx
call fcn.1001741e
test al, al
je 0x10097a1e
mov eax, dword [ebx + 0x5c]
add eax, dword [ebx + 0x4c]
add eax, dword [ebx + 0x3c]
mov dword [ebx + 0x78], eax
mov eax, dword [ebx + 0x60]
add eax, dword [ebx + 0x50]
add eax, dword [ebx + 0x40]
add eax, edi
mov dword [ebx + 0x7c], eax
jmp 0x10097768
mov eax, dword [ebx]
mov ecx, ebx
push dword [esp + 0x84]
call dword [eax + 0x318]
push dword [esp + 0x84]
mov ecx, eax
mov eax, dword [esp + 0x1c]
cmp ecx, eax
mov dword [esp + 0x50], ecx
cmovg eax, ecx
mov ecx, ebx
mov dword [esp + 0x1c], eax
mov dword [esp + 0x28], eax
mov eax, dword [ebx]
call dword [eax + 0x324]
mov ecx, dword [esp + 0x1c]
cmp eax, ecx
cmovg ecx, eax
mov dword [esp + 0x1c], ecx
mov dword [esp + 0x38], ecx
mov ecx, dword [esp + 0x4c]
cmp ecx, dword [ebp + 0x88]
jle 0x10097a85
mov eax, dword [esp + 0x18]
cmp ecx, eax
cmovg eax, ecx
mov dword [esp + 0x18], eax
mov dword [esp + 0x24], eax
mov eax, dword [esi + 0x490]
cmp eax, 0x80000000
je 0x10097aa4
cmp eax, 3
jne 0x10097aa4
cmp dword [ebx + 0xc8], 0
je 0x10097768
mov eax, dword [ebp]
lea ecx, [esp + 0x40]
push ecx
lea ecx, [esp + 0x48]
push ecx
lea ecx, [esp + 0x28]
push ecx
push ebx
push dword [esp + 0x98]
mov ecx, ebp
push dword [esp + 0xa0]
push dword [esp + 0x9c]
call dword [eax + 0x138]
add edi, dword [esp + 0x20]
xor ecx, ecx
mov eax, dword [esi + 0x4dc]
cmp eax, 0x80000000
push ebp
cmove eax, ecx
mov ecx, dword [esp + 0x2c]
push eax
push edi
call fcn.100785fc
mov edi, eax
add edi, dword [ebx + 0x60]
add edi, dword [ebx + 0x50]
mov dword [ebx + 0x7c], edi
mov edx, dword [esp + 0x8c]
mov dword [esp + 0x14], edi
mov ecx, dword [edx + 0x4a0]
test ecx, ecx
jne 0x10097b36
cmp dword [esi + 0x44], 0xff
je 0x10097c18
cmp dword [esi + 0x44], 1
jne 0x10097c18
push 3
pop ecx
test ecx, ecx
je 0x10097c18
mov edi, dword [esp + 0x2c]
sub edi, dword [ebx + 0x88]
sub edi, dword [ebx + 0x64]
sub edi, dword [ebx + 0x54]
sub edi, dword [ebx + 0x44]
sub edi, dword [ebx + 0x3c]
mov eax, dword [ebx + 0x4c]
sub edi, eax
sub edi, dword [ebx + 0x5c]
jns 0x10097b6a
mov edx, dword [edx + 0x4ac]
cmp edx, 0x80000000
je 0x10097b68
test edx, edx
jne 0x10097b6a
xor edi, edi
cmp ecx, 1
jne 0x10097beb
add eax, dword [ebx + 0x3c]
add eax, dword [ebx + 0x5c]
mov dword [ebx + 0x78], eax
mov edi, dword [esp + 0x14]
mov eax, dword [ebx]
mov ecx, ebx
push dword [esp + 0x84]
call dword [eax + 0x27c]
mov ecx, dword [esp + 0x30]
mov eax, dword [ebx]
push dword [ecx + 8]
mov ecx, ebx
push dword [esp + 0x88]
call dword [eax + 0x12c]
mov dword [ebx + 0x8c], eax
mov ecx, ebx
mov eax, dword [ebx]
push 0
push dword [esp + 0x88]
call dword [eax + 0x12c]
mov eax, dword [ebx + 0x68]
mov ecx, ebx
add eax, dword [ebx + 0x58]
add eax, dword [ebx + 0x8c]
add edi, eax
mov dword [esp + 0x88], ecx
mov dword [esp + 0x14], edi
mov byte [esp + 0x78], 0
test esi, esi
je 0x1009777f
jmp 0x10097771
cmp ecx, 3
jne 0x10097bfd
add eax, dword [ebx + 0x3c]
add eax, dword [ebx + 0x5c]
add eax, edi
jmp 0x10097b75
cmp ecx, 2
jne 0x10097b78
mov eax, edi
cdq
sub eax, edx
sar eax, 1
add eax, dword [ebx + 0x3c]
add eax, dword [ebx + 0x4c]
jmp 0x10097b72
mov eax, dword [ebx + 0x5c]
add eax, dword [ebx + 0x4c]
add eax, dword [ebx + 0x3c]
mov dword [ebx + 0x78], eax
jmp 0x10097b7c
mov ecx, dword [esp + 0x88]
jmp 0x10097783