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

Disassembly:
sub esp, 0xd4
mov eax, dword [0x10314008]
xor eax, esp
mov dword [esp + 0xcc], eax
push ebx
push ebp
mov ebp, ecx
mov dword [esp + 0x20], edx
push esi
xor ebx, ebx
mov dword [esp + 0x34], ebp
push edi
mov eax, dword [ebp]
mov edi, dword [esp + 0xe8]
mov esi, dword [ebp + 0xc]
mov dword [esp + 0x18], edi
mov eax, dword [eax]
mov dword [esp + 0x50], eax
mov dword [esp + 0x24], 0
mov dword [esp + 0x30], ebx
mov ecx, dword [eax]
xor eax, eax
mov dword [esp + 0x2c], ecx
mov dword [esp + 0x20], eax
mov dword [esp + 0x6c], esi
cmp byte [ecx + 0x51], al
je 0x1021f2a4
lea eax, [ebx + 7]
jmp 0x1021f9e3
mov eax, dword [esi + 0x24]
mov edx, 0x18
test al, 0x20
movzx ecx, word [esi + 0x18]
mov dword [esp + 0x4c], eax
mov eax, 0x1bf
cmove edx, eax
mov dword [esp + 0x3c], ecx
movzx eax, word [esi + 0x1a]
mov dword [esp + 0x5c], eax
movzx eax, word [esi + 0x1c]
mov dword [esp + 0x60], eax
movzx eax, word [esi + 0x2a]
mov dword [esp + 0x68], eax
movzx eax, word [esi + 0x28]
mov dword [esp + 0x64], eax
mov eax, dword [esi]
mov dword [esp + 0x54], eax
mov eax, dword [esi + 4]
mov dword [esp + 0x58], eax
movzx eax, word [esi + 0x16]
mov ebx, eax
mov dword [esp + 0x48], eax
mov eax, dword [edi + 0x38]
mov dword [esp + 0x74], ebx
movzx ebx, cx
mov ecx, edx
and ecx, 0xffffffc3
mov dword [esp + 0x1c], ebx
and al, 4
mov eax, dword [esp + 0x28]
cmove ecx, edx
mov edx, dword [ebp + 4]
push edi
push ecx
push ebx
push dword [eax + 0x2c]
lea ecx, [esp + 0x88]
call fcn.1021d3c0
mov ebp, eax
add esp, 0x10
xor eax, eax
mov word [esi + 0x12], ax
mov eax, dword [edi + 8]
movzx eax, word [eax]
mov ecx, eax
mov dword [esp + 0x70], ecx
cmp cx, 0xa
jg 0x1021f351
mov dword [esp + 0x44], 0
jmp 0x1021f368
cwde
cdq
push edx
push eax
call fcn.101a9770
add esp, 8
sub ax, 0x21
movzx eax, ax
mov dword [esp + 0x44], eax
mov eax, dword [esp + 0xec]
mov ecx, 0x100
mov dword [esp + 0x34], eax
test ebp, ebp
je 0x1021f8bf
movzx edx, word [ebp + 0xc]
mov eax, edx
mov dword [esp + 0x14], 0
mov dword [esp + 0x40], eax
cmp ax, cx
jne 0x1021f3c2
mov eax, dword [edi + 4]
movsx ecx, word [eax + ebx*2]
test ecx, ecx
js 0x1021f3b9
mov eax, dword [edi + 0xc]
lea ecx, [ecx + ecx*4]
mov eax, dword [eax + 4]
mov al, byte [eax + ecx*4 + 0xc]
test al, al
jne 0x1021f8a4
jmp 0x1021f3c2
cmp ecx, 0xffffffff
je 0x1021f8a4
mov ecx, dword [esi + 8]
mov eax, dword [esi + 0xc]
and ecx, dword [ebp + 0x20]
and eax, dword [ebp + 0x24]
or ecx, eax
jne 0x1021f8a4
mov eax, 0x100
test word [ebp + 0xa], ax
je 0x1021f3ea
cmp edx, 0x10
je 0x1021f8a4
mov eax, dword [esp + 0x28]
test byte [eax + 0x24], 8
je 0x1021f401
mov eax, dword [ebp]
test byte [eax + 4], 1
je 0x1021f8a4
cmp byte [edi + 0x36], 0
je 0x1021f41a
movzx eax, word [edi + 0x32]
dec eax
cmp ebx, eax
jne 0x1021f41a
mov ebx, dword [esp + 0x38]
or dword [ebx + 0x14], 2
jmp 0x1021f422
mov eax, dword [esp + 0x38]
or dword [eax + 0x14], 1
mov eax, dword [esp + 0x4c]
mov edx, esi
mov ebx, dword [esp + 0x2c]
mov ecx, ebx
mov dword [esi + 0x24], eax
mov eax, dword [esp + 0x3c]
mov word [esi + 0x18], ax
mov eax, dword [esp + 0x5c]
mov word [esi + 0x1a], ax
mov eax, dword [esp + 0x60]
mov word [esi + 0x1c], ax
mov eax, dword [esp + 0x64]
mov word [esi + 0x28], ax
movzx eax, ax
inc eax
push eax
call fcn.1021e8b0
add esp, 4
test eax, eax
jne 0x1021f8c3
movzx ecx, word [esi + 0x28]
mov eax, dword [esi + 0x30]
mov dword [eax + ecx*4], ebp
mov ax, word [esi + 0x28]
mov ecx, dword [esi + 8]
inc ax
mov word [esi + 0x28], ax
not ecx
mov edx, dword [ebp + 0x24]
mov edi, dword [ebp + 0x20]
or edx, dword [esp + 0x58]
or edi, dword [esp + 0x54]
movzx ebx, ax
and edi, ecx
mov eax, dword [esi + 0xc]
not eax
mov dword [esi], edi
and edx, eax
mov eax, dword [esp + 0x40]
mov dword [esi + 4], edx
test al, 1
je 0x1021f586
mov edx, dword [ebp]
test dword [edx + 4], 0x800
je 0x1021f51b
lea edi, [ebx - 1]
mov dword [esp + 0x14], 0x2e
xor ecx, ecx
test edi, edi
jle 0x1021f53c
mov ebx, dword [esi + 0x30]
mov esi, dword [esp + 0x14]
nop
mov eax, dword [ebx + ecx*4]
test eax, eax
je 0x1021f4e6
cmp dword [eax], edx
mov dword [esp + 0x14], 0
cmove esi, dword [esp + 0x14]
inc ecx
cmp ecx, edi
jl 0x1021f4d0
mov dword [esp + 0x14], esi
mov esi, dword [esp + 0x6c]
mov ebx, dword [esp + 0x14]
mov eax, dword [esp + 0x18]
test byte [eax + 0x38], 0x80
je 0x1021f572
mov eax, dword [eax + 8]
mov ecx, dword [esp + 0x1c]
movzx edi, word [eax + ecx*2]
movzx eax, bx
mov ecx, eax
cmp ax, 0xa
jg 0x1021f543
xor eax, eax
jmp 0x1021f558
mov eax, dword [edx + 0x14]
test eax, eax
je 0x1021f4f3
mov eax, dword [eax]
test eax, eax
je 0x1021f4f3
cdq
push edx
push eax
call fcn.101a9770
movsx ebx, ax
add esp, 8
mov dword [esp + 0x14], ebx
jmp 0x1021f4f7
mov ebx, 0x2e
jmp 0x1021f4f7
movsx eax, cx
cdq
push edx
push eax
call fcn.101a9770
add esp, 8
sub ax, 0x21
movzx eax, ax
movsx ecx, ax
movsx eax, di
add eax, 0xa
add ecx, eax
mov eax, dword [esp + 0x44]
cwde
add eax, ebx
cmp ecx, eax
jl 0x1021f89c
or dword [esi + 0x24], 4
mov ebx, dword [esi + 0x24]
mov edi, dword [esp + 0x18]
mov ecx, dword [esp + 0x20]
jmp 0x1021f6d3
mov edi, dword [esp + 0x18]
test al, 0x82
je 0x1021f603
mov eax, dword [edi + 4]
mov ecx, dword [esp + 0x1c]
movsx eax, word [eax + ecx*2]
mov ecx, dword [esi + 0x24]
or ecx, 1
mov dword [esi + 0x24], ecx
cmp eax, 0xffffffff
je 0x1021f5ef
mov ebx, ecx
test eax, eax
js 0x1021f5fa
cmp word [esp + 0x34], 0
jne 0x1021f5fa
movzx edx, word [edi + 0x32]
lea eax, [edx - 1]
cmp dword [esp + 0x1c], eax
jne 0x1021f5fa
test byte [edi + 0x38], 8
jne 0x1021f5ef
cmp edx, 1
jne 0x1021f5db
cmp byte [edi + 0x36], 0
je 0x1021f5db
cmp word [esp + 0x40], 2
je 0x1021f5ef
mov ebx, ecx
mov ecx, dword [esp + 0x20]
or ebx, 0x10000
mov dword [esi + 0x24], ebx
jmp 0x1021f6d3
mov ebx, ecx
or ebx, 0x1000
mov dword [esi + 0x24], ebx
mov ecx, dword [esp + 0x20]
jmp 0x1021f6d3
mov ebx, dword [esi + 0x24]
test eax, 0x100
je 0x1021f61c
mov ecx, dword [esp + 0x20]
or ebx, 8
mov dword [esi + 0x24], ebx
jmp 0x1021f6d3
mov ecx, dword [esp + 0x50]
test al, 0x24
mov eax, dword [esp + 0x28]
push ebp
push dword [esp + 0x20]
push edi
je 0x1021f69f
or ebx, 0x22
mov dword [esi + 0x24], ebx
mov edx, dword [eax + 0x2c]
call fcn.1021f0a0
mov word [esi + 0x1a], ax
xor ebx, ebx
mov eax, 0x100
mov dword [esp + 0x2c], ebp
add esp, 0xc
mov dword [esp + 0x30], ebx
test word [ebp + 0xa], ax
je 0x1021f696
movzx eax, word [esi + 0x28]
lea ebx, [ebp + 0x30]
mov ecx, dword [esp + 0x2c]
inc eax
push eax
mov edx, esi
mov dword [esp + 0x34], ebx
call fcn.1021e8b0
add esp, 4
test eax, eax
jne 0x1021f8bf
movzx ecx, word [esi + 0x28]
mov eax, dword [esi + 0x30]
mov dword [eax + ecx*4], ebx
mov eax, 1
inc word [esi + 0x28]
or dword [esi + 0x24], 0x10
mov word [esi + 0x1c], ax
mov ebx, dword [esi + 0x24]
mov ecx, dword [esp + 0x20]
jmp 0x1021f6d3
or ebx, 0x12
mov dword [esi + 0x24], ebx
mov edx, dword [eax + 0x2c]
call fcn.1021f0a0
mov ebx, dword [esi + 0x24]
add esp, 0xc
mov word [esi + 0x1c], ax
mov dword [esp + 0x30], ebp
test bl, 0x20
je 0x1021f6cd
movzx ecx, word [esi + 0x28]
mov eax, dword [esi + 0x30]
mov ecx, dword [eax + ecx*4 - 8]
jmp 0x1021f6cf
xor ecx, ecx
mov dword [esp + 0x20], ecx
test bl, 2
je 0x1021f76e
movzx eax, word [esi + 0x16]
movsx edi, ax
test ecx, ecx
je 0x1021f6f7
movzx ecx, word [ecx + 8]
test cx, cx
jg 0x1021f6f4
add eax, ecx
jmp 0x1021f6f7
sub eax, 0x14
mov ebx, dword [esp + 0x30]
movzx ecx, ax
test ebx, ebx
je 0x1021f715
movzx ecx, word [ebx + 8]
test cx, cx
jg 0x1021f70f
add eax, ecx
jmp 0x1021f712
add eax, 0xffffffec
movzx ecx, ax
mov ebp, dword [esp + 0x20]
movzx edx, cx
test ebp, ebp
je 0x1021f738
cmp word [ebp + 8], 0
jle 0x1021f738
test ebx, ebx
je 0x1021f738
cmp word [ebx + 8], 0
jle 0x1021f738
lea eax, [ecx - 0x14]
movzx edx, ax
xor eax, eax
test ebp, ebp
setne al
sub edi, eax
xor eax, eax
test ebx, ebx
mov ebx, dword [esi + 0x24]
setne al
sub edi, eax
cmp dx, 0xa
mov eax, 0xa
cmovl edx, eax
movzx eax, di
movsx ecx, dx
cmp ecx, edi
movzx edx, cx
cmovge edx, eax
movzx eax, dx
mov edi, eax
jmp 0x1021f7c7
inc word [esi + 0x18]
movzx ecx, word [ebp + 8]
movzx edx, word [esi + 0x18]
test cx, cx
jg 0x1021f79d
mov eax, dword [edi + 4]
mov ebp, dword [esp + 0x1c]
cmp word [eax + ebp*2], 0
jl 0x1021f79d
mov ebp, dword [esp + 0x14]
sub ecx, ebp
add word [esi + 0x16], cx
movzx edi, word [esi + 0x16]
jmp 0x1021f7cf
mov eax, dword [edi + 8]
mov cx, word [esi + 0x16]
sub cx, word [eax + edx*2 - 2]
add cx, word [eax + edx*2]
test dword [esp + 0x40], 0x100
movzx eax, cx
mov word [esi + 0x16], cx
movzx edi, cx
je 0x1021f7cb
add eax, 0xa
movzx edi, ax
mov word [esi + 0x16], ax
mov ebp, dword [esp + 0x14]
mov eax, dword [esp + 0x18]
movsx eax, word [eax + 0x30]
mov edx, eax
shl edx, 4
sub edx, eax
mov eax, dword [esp + 0x28]
mov eax, dword [eax + 0x10]
movsx ecx, word [eax + 0x30]
mov eax, edx
cdq
idiv ecx
mov ecx, dword [esp + 0x44]
lea edx, [eax + 1]
add edx, edi
call fcn.101a9700
movzx ecx, ax
mov word [esi + 0x14], ax
movzx eax, ax
test ebx, 0x140
jne 0x1021f819
lea edx, [edi + 0x10]
call fcn.101a9700
movzx eax, ax
push dword [esp + 0x70]
movzx ebx, bp
mov edx, esi
mov ebp, dword [esp + 0x3c]
add eax, ebx
add eax, dword [esp + 0x38]
mov word [esi + 0x14], ax
lea eax, [edi + ebx]
add eax, dword [esp + 0x38]
mov word [esi + 0x16], ax
mov ecx, dword [ebp + 4]
call fcn.1021ef50
add esp, 4
mov edx, esi
mov ecx, ebp
call fcn.1021ed40
test byte [esi + 0x24], 2
mov dword [esp + 0x24], eax
mov eax, dword [esp + 0x74]
movzx ecx, di
mov edi, dword [esp + 0x18]
movzx edx, ax
cmove edx, ecx
mov word [esi + 0x16], dx
test byte [esi + 0x24], 0x10
jne 0x1021f892
mov cx, word [esi + 0x18]
cmp cx, word [edi + 0x34]
jae 0x1021f892
mov eax, dword [esp + 0x34]
mov ecx, ebp
mov edx, dword [esp + 0x28]
add eax, ebx
push eax
push edi
call fcn.1021f240
add esp, 8
mov eax, dword [esp + 0x48]
mov word [esi + 0x16], ax
jmp 0x1021f8a0
mov edi, dword [esp + 0x18]
mov ebx, dword [esp + 0x1c]
lea ecx, [esp + 0x78]
call fcn.1021d090
cmp dword [esp + 0x24], 0
mov ebp, eax
mov ecx, 0x100
je 0x1021f378
mov ebx, dword [esp + 0x2c]
mov ecx, dword [esp + 0x5c]
mov eax, dword [esp + 0x54]
mov ebp, dword [esp + 0x68]
mov edx, dword [esp + 0x64]
mov word [esi + 0x1a], cx
mov ecx, dword [esp + 0x60]
mov dword [esi], eax
mov eax, dword [esp + 0x58]
mov word [esi + 0x1c], cx
mov ecx, dword [esp + 0x4c]
mov dword [esi + 4], eax
mov eax, dword [esp + 0x3c]
mov dword [esi + 0x24], ecx
mov ecx, dword [esp + 0x48]
mov word [esi + 0x18], ax
mov word [esi + 0x2a], bp
mov word [esi + 0x16], cx
mov word [esi + 0x28], dx
cmp ax, bp
jne 0x1021f9dd
mov ebp, dword [esp + 0x1c]
movzx ecx, word [edi + 0x32]
lea eax, [ebp + 1]
cmp eax, ecx
jae 0x1021f9dd
cmp word [esp + 0x3c], dx
jne 0x1021f9dd
test byte [edi + 0x38], 0x40
jne 0x1021f9dd
mov eax, 0x4000
test word [ebx + 0x4c], ax
jne 0x1021f9dd
mov eax, dword [edi + 8]
cmp word [eax + ebp*2 + 2], 0x2a
jl 0x1021f9dd
movzx eax, dx
mov ecx, ebx
inc eax
mov edx, esi
push eax
call fcn.1021e8b0
mov ebx, eax
add esp, 4
test ebx, ebx
jne 0x1021f9e1
movzx ecx, word [esi + 0x28]
mov eax, dword [esi + 0x30]
inc word [esi + 0x18]
inc word [esi + 0x2a]
mov edx, dword [esp + 0x34]
mov dword [eax + ecx*4], ebx
add edx, 5
inc word [esi + 0x28]
or dword [esi + 0x24], 0x8000
mov eax, dword [edi + 8]
mov ecx, dword [esp + 0x38]
mov di, word [eax + ebp*2]
sub di, word [eax + ebp*2 + 2]
movzx eax, di
sub word [esi + 0x16], ax
add eax, edx
mov edx, dword [esp + 0x28]
push eax
mov eax, dword [esp + 0x1c]
push eax
call fcn.1021f240
mov eax, dword [esp + 0x50]
add esp, 8
mov word [esi + 0x16], ax
mov eax, dword [esp + 0x3c]
mov word [esi + 0x18], ax
mov eax, dword [esp + 0x68]
mov word [esi + 0x2a], ax
mov eax, dword [esp + 0x4c]
mov dword [esi + 0x24], eax
jmp 0x1021f9e1
mov ebx, dword [esp + 0x24]
mov eax, ebx
mov ecx, dword [esp + 0xdc]
pop edi
pop esi
pop ebp
pop ebx
xor ecx, esp
call fcn.1025b3e6
add esp, 0xd4
ret