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

Disassembly:
sub esp, 0xcc
mov eax, dword [0x101a2ce4]
xor eax, esp
mov dword [esp + 0xc8], eax
mov eax, dword [esp + 0xd4]
xor ecx, ecx
push ebx
push ebp
mov ebp, dword [esp + 0xe0]
xor ebx, ebx
push esi
push edi
mov edi, dword [esp + 0xe0]
mov dword [esp + 0x24], eax
mov dword [esp + 0x40], edi
mov dword [esp + 0x10], ebp
mov eax, dword [edi]
mov esi, dword [edi + 8]
mov dword [esp + 0x28], ebx
mov dword [esp + 0x18], ecx
mov eax, dword [eax]
mov dword [esp + 0x68], eax
mov edx, dword [eax]
xor eax, eax
mov dword [esp + 0x3c], edx
mov dword [esp + 0x30], eax
cmp byte [edx + 0x57], al
je 0x1015d189
lea eax, [ebx + 7]
jmp 0x1015d98d
mov eax, dword [esi + 0x2c]
mov edx, 0x18
test al, 0x20
movzx ecx, word [esi + 0x18]
mov dword [esp + 0x50], eax
mov eax, 0x1bf
cmove edx, eax
mov dword [esp + 0x44], 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 + 0x32]
mov dword [esp + 0x64], eax
movzx eax, word [esi + 0x30]
mov dword [esp + 0x48], 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 + 0x4c], eax
movzx eax, cx
mov ecx, edx
mov dword [esp + 0x1c], eax
and ecx, 0xffffffc3
mov eax, dword [ebp + 0x38]
test al, 4
mov eax, dword [esp + 0x24]
push ebp
cmove ecx, edx
mov dword [esp + 0x74], ebx
push ecx
push dword [esp + 0x24]
push dword [eax + 0x2c]
lea eax, [esp + 0x88]
push dword [edi + 4]
push eax
call fcn.10160af0
mov edi, eax
add esp, 0x18
xor eax, eax
mov dword [esp + 0x20], edi
mov word [esi + 0x12], ax
mov eax, dword [ebp + 8]
movzx eax, word [eax]
mov ecx, eax
mov dword [esp + 0x6c], ecx
cmp cx, 0xa
jg 0x1015d23e
mov dword [esp + 0x38], 0
jmp 0x1015d255
cwde
cdq
push edx
push eax
call fcn.10124920
add esp, 8
sub ax, 0x21
movzx eax, ax
mov dword [esp + 0x38], eax
mov eax, dword [esp + 0xec]
mov ecx, 0x100
mov ebx, dword [esp + 0x28]
mov dword [esp + 0x2c], eax
nop dword [eax]
test edi, edi
je 0x1015d869
movzx edx, word [edi + 0xc]
lea ebp, [edi + 0xa]
mov eax, edx
mov dword [esp + 0x14], 0
mov dword [esp + 0x34], eax
cmp ax, cx
je 0x1015d298
test byte [ebp], 0x80
je 0x1015d2eb
mov ebx, dword [esp + 0x10]
mov ecx, dword [esp + 0x1c]
mov eax, dword [ebx + 4]
movsx ecx, word [eax + ecx*2]
test ecx, ecx
js 0x1015d2e4
mov eax, dword [ebx + 0xc]
add ecx, ecx
mov eax, dword [eax + 4]
test dword [eax + ecx*8 + 4], 0xf
je 0x1015d2ef
mov ebp, ebx
lea eax, [esp + 0x78]
push eax
call fcn.10160c00
mov ebx, dword [esp + 0x2c]
add esp, 4
mov edi, eax
mov ecx, 0x100
mov dword [esp + 0x20], edi
test ebx, ebx
je 0x1015d270
jmp 0x1015d869
cmp ecx, 0xffffffff
je 0x1015d2bd
jmp 0x1015d2ef
mov ebx, dword [esp + 0x10]
mov ecx, dword [esi + 8]
mov eax, dword [esi + 0xc]
and ecx, dword [edi + 0x20]
and eax, dword [edi + 0x24]
or ecx, eax
jne 0x1015d858
mov eax, 0x100
test word [ebp], ax
je 0x1015d317
cmp edx, 0x10
je 0x1015d858
mov eax, dword [esp + 0x24]
mov cl, byte [eax + 0x24]
test cl, 0x58
je 0x1015d353
mov eax, dword [edi]
mov edx, dword [eax + 4]
test dl, 3
je 0x1015d858
mov ebx, dword [esp + 0x24]
mov eax, dword [eax + 0x24]
cmp eax, dword [ebx + 0x2c]
mov ebx, dword [esp + 0x10]
jne 0x1015d2bd
test cl, 0x18
je 0x1015d353
test dl, 2
jne 0x1015d2bd
cmp byte [ebx + 0x36], 0
je 0x1015d36e
movzx eax, word [ebx + 0x32]
dec eax
cmp dword [esp + 0x1c], eax
jne 0x1015d36e
mov eax, dword [esp + 0x40]
or byte [eax + 0x10], 2
jmp 0x1015d376
mov eax, dword [esp + 0x40]
or byte [eax + 0x10], 1
mov eax, dword [esp + 0x50]
mov ecx, dword [esp + 0x48]
mov dword [esi + 0x2c], eax
mov eax, dword [esp + 0x44]
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
movzx eax, cx
mov word [esi + 0x30], cx
cmp ax, word [esi + 0x34]
jb 0x1015d3bd
inc eax
push eax
push esi
push dword [esp + 0x44]
call fcn.1015f070
add esp, 0xc
test eax, eax
jne 0x1015d861
movzx ecx, word [esi + 0x30]
mov eax, dword [esi + 0x38]
mov dword [eax + ecx*4], edi
mov ax, word [esi + 0x30]
mov edi, dword [esp + 0x54]
inc ax
mov ecx, dword [esi + 8]
mov word [esi + 0x30], ax
not ecx
movzx ebx, ax
mov eax, dword [esp + 0x20]
or edi, dword [eax + 0x20]
mov edx, dword [eax + 0x24]
and edi, ecx
mov eax, dword [esi + 0xc]
or edx, dword [esp + 0x58]
not eax
and edx, eax
mov dword [esi], edi
mov eax, dword [esp + 0x34]
mov dword [esi + 4], edx
test al, 1
je 0x1015d507
mov edx, dword [esp + 0x20]
mov edx, dword [edx]
test dword [edx + 4], 0x1000
je 0x1015d485
lea edi, [ebx - 1]
mov ebp, 0x2e
xor ecx, ecx
mov dword [esp + 0x14], ebp
test edi, edi
jle 0x1015d4a6
mov ebx, dword [esi + 0x38]
nop dword [eax]
mov eax, dword [ebx + ecx*4]
test eax, eax
je 0x1015d446
cmp dword [eax], edx
mov dword [esp + 0x14], 0
cmove ebp, dword [esp + 0x14]
inc ecx
cmp ecx, edi
jl 0x1015d430
mov dword [esp + 0x14], ebp
mov ecx, dword [esp + 0x14]
mov ebp, dword [esp + 0x10]
test byte [ebp + 0x38], 0x80
je 0x1015d4f3
cmp word [esp + 0x38], 0xa
jl 0x1015d4f3
mov eax, dword [ebp + 8]
mov edx, dword [esp + 0x1c]
movzx edi, cx
movzx ebx, word [eax + edx*2]
cmp di, 0xa
jg 0x1015d4aa
xor eax, eax
jmp 0x1015d4bf
mov eax, dword [edx + 0x14]
test eax, eax
je 0x1015d44f
mov eax, dword [eax]
test eax, eax
je 0x1015d44f
cdq
push edx
push eax
call fcn.10124920
movsx ecx, ax
add esp, 8
mov dword [esp + 0x14], ecx
jmp 0x1015d453
mov ecx, ebp
jmp 0x1015d453
movsx eax, di
cdq
push edx
push eax
call fcn.10124920
add esp, 8
sub ax, 0x21
movzx eax, ax
sub eax, edi
sub eax, dword [esp + 0x38]
add eax, 0xa
add eax, ebx
test ax, ax
jns 0x1015d4f3
cmp word [esp + 0x2c], 2
jge 0x1015d2bf
mov eax, dword [esp + 0x3c]
test dword [eax + 0x50], 0x20000
jne 0x1015d2bf
or dword [esi + 0x2c], 0x100000
or dword [esi + 0x2c], 4
mov ebx, dword [esi + 0x2c]
mov edi, dword [esp + 0x20]
mov edx, dword [esp + 0x18]
jmp 0x1015d66c
test al, 0x82
je 0x1015d599
mov ebp, dword [esp + 0x10]
mov ecx, dword [esp + 0x1c]
mov eax, dword [ebp + 4]
movsx eax, word [eax + ecx*2]
mov ecx, dword [esi + 0x2c]
or ecx, 1
mov dword [esi + 0x2c], ecx
cmp eax, 0xffffffff
je 0x1015d56a
mov edx, ecx
mov ebx, ecx
test eax, eax
js 0x1015d577
cmp word [esp + 0x2c], 0
jne 0x1015d577
movzx eax, word [ebp + 0x32]
mov edi, eax
dec eax
cmp dword [esp + 0x1c], eax
jne 0x1015d577
test byte [ebp + 0x38], 8
jne 0x1015d56a
cmp edi, 1
jne 0x1015d562
cmp byte [ebp + 0x36], 0
je 0x1015d562
cmp word [esp + 0x34], 2
je 0x1015d56a
or ebx, 0x10000
jmp 0x1015d572
mov ebx, ecx
or ebx, 0x1000
mov edx, ebx
mov dword [esi + 0x2c], ebx
cmp byte [esp + 0x91], 1
jbe 0x1015d58c
mov ebx, edx
or ebx, 0x200000
mov dword [esi + 0x2c], ebx
mov edi, dword [esp + 0x20]
mov edx, dword [esp + 0x18]
jmp 0x1015d66c
mov edi, dword [esp + 0x20]
test eax, 0x100
je 0x1015d5b6
mov ebx, dword [esi + 0x2c]
mov edx, dword [esp + 0x18]
or ebx, 8
mov dword [esi + 0x2c], ebx
jmp 0x1015d668
mov eax, dword [esp + 0x10]
push edi
push dword [esp + 0x20]
push eax
mov eax, dword [esp + 0x30]
push dword [eax + 0x2c]
push dword [esp + 0x78]
call fcn.10160900
mov ebx, dword [esi + 0x2c]
add esp, 0x14
test byte [esp + 0x34], 0x24
je 0x1015d642
mov word [esi + 0x1a], ax
or ebx, 0x22
xor eax, eax
mov dword [esi + 0x2c], ebx
mov dword [esp + 0x30], eax
mov eax, 0x100
mov dword [esp + 0x18], edi
test word [ebp], ax
je 0x1015d63c
movzx eax, word [esi + 0x30]
lea ebx, [edi + 0x30]
inc eax
mov dword [esp + 0x30], ebx
push eax
push esi
push dword [esp + 0x44]
call fcn.1015f070
add esp, 0xc
test eax, eax
jne 0x1015d861
movzx ecx, word [esi + 0x30]
mov eax, dword [esi + 0x38]
mov dword [eax + ecx*4], ebx
mov eax, 1
inc word [esi + 0x30]
or dword [esi + 0x2c], 0x10
mov ebx, dword [esi + 0x2c]
mov word [esi + 0x1c], ax
mov edx, dword [esp + 0x18]
jmp 0x1015d668
or ebx, 0x12
mov word [esi + 0x1c], ax
mov dword [esi + 0x2c], ebx
mov dword [esp + 0x30], edi
test bl, 0x20
je 0x1015d662
movzx ecx, word [esi + 0x30]
mov eax, dword [esi + 0x38]
mov edx, dword [eax + ecx*4 - 8]
jmp 0x1015d664
xor edx, edx
mov dword [esp + 0x18], edx
mov ebp, dword [esp + 0x10]
test bl, 2
je 0x1015d711
movzx eax, word [esi + 0x16]
movsx edi, ax
test edx, edx
je 0x1015d696
movzx ecx, word [edx + 8]
test cx, cx
jg 0x1015d68d
add eax, ecx
jmp 0x1015d696
test byte [edx + 0xa], 0x80
jne 0x1015d696
sub eax, 0x14
mov ebp, dword [esp + 0x30]
movzx ecx, ax
test ebp, ebp
je 0x1015d6ba
movzx edx, word [ebp + 8]
test dx, dx
jg 0x1015d6ae
add eax, edx
jmp 0x1015d6b7
test byte [ebp + 0xa], 0x80
jne 0x1015d6ba
add eax, 0xffffffec
movzx ecx, ax
mov eax, dword [esp + 0x18]
movzx edx, cx
test eax, eax
je 0x1015d6dd
cmp word [eax + 8], 0
jle 0x1015d6dd
test ebp, ebp
je 0x1015d6dd
cmp word [ebp + 8], 0
jle 0x1015d6dd
lea eax, [ecx - 0x14]
movzx edx, ax
xor eax, eax
cmp dword [esp + 0x18], eax
setne al
sub edi, eax
xor eax, eax
test ebp, ebp
setne al
sub edi, eax
cmp dx, 0xa
mov eax, 0xa
cmovl edx, eax
movzx eax, dx
cmp eax, edi
mov edx, eax
movzx eax, di
cmovge edx, eax
movzx eax, dx
mov edi, eax
jmp 0x1015d76e
inc word [esi + 0x18]
movzx ecx, word [edi + 8]
movzx edx, word [esi + 0x18]
test cx, cx
jg 0x1015d743
mov eax, dword [ebp + 4]
mov edi, dword [esp + 0x1c]
cmp word [eax + edi*2], 0
jl 0x1015d743
mov ax, word [esi + 0x16]
sub ax, word [esp + 0x14]
add ax, cx
movzx eax, ax
mov edi, eax
jmp 0x1015d76e
mov eax, dword [ebp + 8]
mov cx, word [esi + 0x16]
sub cx, word [eax + edx*2 - 2]
add cx, word [eax + edx*2]
test dword [esp + 0x34], 0x100
movzx eax, cx
mov ecx, eax
mov word [esi + 0x16], ax
mov edi, eax
je 0x1015d772
lea eax, [ecx + 0xa]
movzx edi, ax
mov word [esi + 0x16], ax
mov eax, dword [esp + 0x10]
movzx ebp, di
movsx eax, word [eax + 0x30]
mov edx, eax
shl edx, 4
sub edx, eax
mov eax, dword [esp + 0x24]
mov eax, dword [eax + 0x10]
movsx ecx, word [eax + 0x28]
mov eax, edx
cdq
idiv ecx
inc eax
add eax, edi
push eax
push dword [esp + 0x3c]
call fcn.101249c0
add esp, 8
movzx ecx, ax
movzx eax, ax
test ebx, 0x140
jne 0x1015d7c2
lea eax, [edi + 0x10]
push eax
push ecx
call fcn.101249c0
add esp, 8
movzx eax, ax
mov ecx, dword [esp + 0x14]
push dword [esp + 0x6c]
movzx ebx, cx
add eax, ebx
add eax, dword [esp + 0x30]
mov word [esi + 0x14], ax
lea eax, [edi + ebx]
mov edi, dword [esp + 0x44]
add eax, dword [esp + 0x30]
mov word [esi + 0x16], ax
push esi
push dword [edi + 4]
call fcn.1015ee80
push esi
push edi
call fcn.1015ebd0
mov ecx, dword [esp + 0x84]
add esp, 0x14
mov dword [esp + 0x28], eax
mov eax, dword [esi + 0x2c]
test al, 2
movzx edx, cx
mov ecx, ebp
mov ebp, dword [esp + 0x10]
cmove edx, ecx
mov word [esi + 0x16], dx
test al, 0x10
jne 0x1015d84b
movzx eax, word [esi + 0x18]
cmp ax, word [ebp + 0x34]
jae 0x1015d84b
cmp ax, word [ebp + 0x32]
jb 0x1015d836
mov eax, dword [ebp + 0x38]
and al, 3
cmp al, 2
je 0x1015d84b
mov eax, dword [esp + 0x2c]
add eax, ebx
push eax
push ebp
push dword [esp + 0x2c]
push edi
call fcn.1015d120
add esp, 0x10
mov eax, dword [esp + 0x4c]
mov word [esi + 0x16], ax
jmp 0x1015d2bf
mov ebp, dword [esp + 0x10]
jmp 0x1015d2bf
mov ebx, dword [esp + 0x28]
mov ebp, dword [esp + 0x10]
mov ecx, dword [esp + 0x5c]
mov eax, dword [esp + 0x54]
mov edx, dword [esp + 0x64]
mov word [esi + 0x1a], cx
mov ecx, dword [esp + 0x60]
mov word [esi + 0x1c], cx
mov ecx, dword [esp + 0x50]
mov dword [esi], eax
mov eax, dword [esp + 0x58]
mov dword [esi + 0x2c], ecx
mov ecx, dword [esp + 0x4c]
mov dword [esi + 4], eax
mov eax, dword [esp + 0x44]
mov word [esi + 0x16], cx
mov ecx, dword [esp + 0x48]
mov word [esi + 0x18], ax
mov word [esi + 0x32], dx
mov word [esi + 0x30], cx
cmp ax, dx
jne 0x1015d98b
mov edi, dword [esp + 0x1c]
movzx ecx, word [ebp + 0x32]
lea eax, [edi + 1]
cmp eax, ecx
jae 0x1015d98b
mov eax, dword [esp + 0x48]
movzx edx, ax
cmp word [esp + 0x44], dx
jne 0x1015d98b
mov eax, dword [ebp + 0x38]
test al, 0x40
jne 0x1015d98b
test al, al
jns 0x1015d98b
mov ecx, dword [esp + 0x3c]
test dword [ecx + 0x50], 0x4000
jne 0x1015d98b
mov eax, dword [ebp + 8]
cmp word [eax + edi*2 + 2], 0x2a
jl 0x1015d98b
inc edx
push edx
push esi
push ecx
call fcn.1015f070
mov ebx, eax
add esp, 0xc
test ebx, ebx
jne 0x1015d98b
movzx ecx, word [esi + 0x30]
mov eax, dword [esi + 0x38]
inc word [esi + 0x18]
inc word [esi + 0x32]
mov dword [eax + ecx*4], ebx
inc word [esi + 0x30]
or dword [esi + 0x2c], 0x8000
mov eax, dword [ebp + 8]
mov cx, word [eax + edi*2]
sub cx, word [eax + edi*2 + 2]
mov edi, dword [esp + 0x40]
movzx eax, cx
mov ecx, dword [esp + 0x2c]
sub word [esi + 0x16], ax
add ecx, 5
add eax, ecx
push eax
push ebp
push dword [esp + 0x2c]
push edi
call fcn.1015d120
mov eax, dword [esp + 0x5c]
add esp, 0x10
mov word [esi + 0x16], ax
mov eax, dword [esp + 0x44]
mov word [esi + 0x18], ax
mov eax, dword [esp + 0x64]
mov word [esi + 0x32], ax
mov eax, dword [esp + 0x50]
mov dword [esi + 0x2c], eax
mov eax, ebx
mov ecx, dword [esp + 0xd8]
pop edi
pop esi
pop ebp
pop ebx
xor ecx, esp
call fcn.10169f7a
add esp, 0xcc
ret