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

Disassembly:
sub esp, 0x50
cmp byte [esp + 0x6c], 0
mov edx, dword [esp + 0x58]
push ebp
mov ebp, 1
mov dword [esp + 0x10], 3
push esi
mov esi, dword [edx + 0x14d10]
push edi
lea edi, [ebp + 5]
jne 0x10157786
mov ecx, dword [esp + 0x60]
cmp byte [ecx + 0x3eb9c], 0
jne 0x10157786
push ebx
cmp dword [ecx + 0x3ede8], ebp
je 0x1015730a
mov eax, dword [ecx + 0x3ac20]
xor edx, edx
imul eax, dword [ecx + 0x3ac24]
cmp eax, 0x1fa400
setl dl
lea edx, [edx*2 + 3]
mov dword [esp + 0x7c], edx
mov edi, edx
mov edx, dword [esp + 0x68]
cmp esi, 3
jl 0x101572ea
cmp dword [edx + 0x243a4], 0x1f4
jbe 0x101572ea
mov eax, dword [ecx + 0x3ac24]
imul eax, dword [ecx + 0x3ac20]
cmp eax, 0x38400
jl 0x101572ea
xor ebx, ebx
mov ebp, 2
cmp esi, 3
setg bl
add ebx, 4
mov dword [esp + 0x1c], ebx
mov eax, dword [edx + 0x10b0]
mov edx, dword [ecx + 0x3accc]
mov eax, dword [eax]
mov dword [esp + 0x38], eax
cmp edx, 0xffffffff
je 0x1015731d
mov eax, dword [ecx + edx*4 + 0x3ad7c]
jmp 0x1015731f
cmp dword [ecx + 0x5cbd8], 0
je 0x101572b1
mov dword [esp + 0x1c], 7
jmp 0x101572ea
xor eax, eax
mov dword [esp + 0x7c], eax
mov eax, dword [ecx + 0x3acd8]
cmp eax, 0xffffffff
je 0x10157337
mov eax, dword [ecx + eax*4 + 0x3ad7c]
jmp 0x10157339
xor eax, eax
mov ebx, dword [ecx + 0x3ace4]
mov dword [esp + 0x10], eax
cmp ebx, 0xffffffff
je 0x10157351
mov ebx, dword [ecx + ebx*4 + 0x3ad7c]
jmp 0x10157353
xor ebx, ebx
cmp edx, 0xffffffff
je 0x10157369
shl edx, 4
lea eax, [ecx + 0x3acfc]
add eax, edx
mov dword [esp + 0x14], eax
jmp 0x10157371
mov dword [esp + 0x14], 0
mov eax, dword [esp + 0x6c]
mov ecx, ebp
add eax, eax
mov dword [esp + 0x2c], 0
mov dword [esp + 0x34], eax
xor edx, edx
mov eax, dword [esp + 0x70]
mov esi, 1
shr eax, cl
mov dword [esp + 0x40], eax
mov eax, dword [esp + 0x74]
div edi
xor edx, edx
mov dword [esp + 0x30], 0
mov dword [esp + 0x44], eax
mov eax, dword [esp + 0x78]
div edi
mov edi, dword [esp + 0x68]
mov dword [esp + 0x48], eax
mov dword [esp + 0x20], 0x538
mov dword [esp + 0x24], 0x24
lea ebp, [edi + 0x618]
mov dword [esp + 0x28], 0x1c
mov ecx, dword [ebp + 0x14]
lea eax, [esi + esi*8]
add ecx, dword [esp + 0x34]
lea edx, [edi + eax*8]
mov eax, dword [ebp + 0x18]
mov dword [esp + 0x18], edx
lea eax, [eax + ecx*2]
mov edi, dword [eax*4 + 0x106341d0]
mov dword [esp + 0x3c], edi
cmp edi, 0xff
je 0x10157711
cmp byte [esp + 0x80], 0
je 0x10157539
mov eax, dword [esp + 0x38]
cmp byte [eax + 0x14], 1
jne 0x10157453
push dword [ebp + 0x40]
mov eax, dword [esp + 0x68]
push dword [ebp + 0x30]
shl edi, 6
push dword [edx + 0x28]
mov eax, dword [eax]
push dword [edx + 0x18]
mov eax, dword [edi + eax + 0xc5cc]
call eax
mov ecx, eax
add esp, 0x10
mov eax, esi
imul eax, eax, 4
add eax, 0xfffffffc
add eax, dword [esp + 0x84]
jmp 0x10157569
mov edx, dword [esp + 0x7c]
cmp esi, 1
jne 0x10157467
lea ecx, [edx + 0x4f4]
lea eax, [esi + 0x2b]
jmp 0x10157472
lea ecx, [edx + 0x4f8]
mov eax, 0x30
test edx, edx
mov edx, dword [esp + 0x20]
cmove ecx, eax
mov eax, dword [esp + 0x68]
push dword [edx + eax + 0xf8]
mov edx, dword [esp + 0x6c]
imul eax, esi, 0x538
push dword [eax + edx + 0xf4]
mov eax, edx
mov edx, dword [esp + 0x84]
push dword [esp + 0x1c]
test edx, edx
push dword [eax + 0xe4]
push dword [eax + 0xe0]
lea eax, [edx + 0x4ec]
cmove eax, dword [esp + 0x38]
push dword [eax]
lea eax, [edx + 0x4e4]
cmove eax, dword [esp + 0x40]
push dword [eax]
lea eax, [edx + 0x4dc]
mov edx, 0x14
cmove eax, edx
push dword [eax]
mov eax, dword [esp + 0x88]
push dword [ecx]
mov eax, dword [eax + 0x10b0]
mov eax, dword [eax]
push dword [eax]
lea eax, [esp + 0x74]
push eax
call fcn.10159a30
push dword [esp + 0x88]
mov ecx, dword [esp + 0x48]
mov eax, dword [esp + 0x94]
push dword [esp + 0x7c]
shl edi, 6
push dword [ecx + 0x28]
mov eax, dword [eax]
push dword [ecx + 0x18]
mov eax, dword [edi + eax + 0xc5cc]
call eax
mov ecx, eax
add esp, 0x3c
mov eax, esi
imul eax, eax, 4
add eax, 0xfffffffc
add eax, dword [esp + 0x84]
jmp 0x10157569
push dword [ebp + 0x2c]
mov eax, dword [esp + 0x68]
push dword [ebp + 0x1c]
shl edi, 6
push dword [edx + 0x28]
mov eax, dword [eax]
push dword [edx + 0x18]
mov eax, dword [edi + eax + 0xc5cc]
call eax
mov ecx, eax
add esp, 0x10
mov eax, dword [esp + 0x84]
add eax, 0xfffffffc
lea eax, [eax + esi*4]
cmp dword [esp + 0x74], 0xffffffff
mov dword [eax], ecx
je 0x1015763f
mov edx, dword [esp + 0x10]
cmp esi, 1
jne 0x1015758a
lea ecx, [edx + 0x4f4]
lea eax, [esi + 0x2b]
jmp 0x10157595
lea ecx, [edx + 0x4f8]
mov eax, 0x30
test edx, edx
mov edx, dword [esp + 0x68]
cmove ecx, eax
imul eax, esi, 0x538
push dword [eax + edx + 0xf8]
push dword [eax + edx + 0xf4]
mov eax, edx
mov edx, dword [esp + 0x18]
push dword [esp + 0x1c]
test edx, edx
push dword [eax + 0xe4]
push dword [eax + 0xe0]
lea eax, [edx + 0x4ec]
cmove eax, dword [esp + 0x38]
push dword [eax]
lea eax, [edx + 0x4e4]
cmove eax, dword [esp + 0x40]
push dword [eax]
lea eax, [edx + 0x4dc]
mov edx, 0x14
cmove eax, edx
push dword [eax]
mov eax, dword [esp + 0x88]
push dword [ecx]
mov eax, dword [eax + 0x10b0]
mov eax, dword [eax]
push dword [eax]
lea eax, [esp + 0x74]
push eax
call fcn.10159a30
push dword [esp + 0x88]
mov ecx, dword [esp + 0x48]
mov eax, dword [esp + 0x94]
push dword [esp + 0x7c]
push dword [ecx + 0x28]
mov eax, dword [eax]
push dword [ecx + 0x18]
mov eax, dword [edi + eax + 0xc5cc]
call eax
add esp, 0x3c
mov dword [esp + 0x2c], eax
cmp dword [esp + 0x78], 0xffffffff
je 0x10157711
cmp esi, 1
jne 0x1015765a
lea ecx, [ebx + 0x4f4]
lea eax, [esi + 0x2b]
jmp 0x10157665
lea ecx, [ebx + 0x4f8]
mov eax, 0x30
mov edi, dword [esp + 0x68]
test ebx, ebx
mov edx, 0x24
cmove ecx, eax
imul eax, esi, 0x538
test ebx, ebx
push dword [eax + edi + 0xf8]
push dword [eax + edi + 0xf4]
lea eax, [ebx + 0x4ec]
push dword [esp + 0x1c]
cmove eax, edx
mov edx, 0x1c
push dword [edi + 0xe4]
push dword [edi + 0xe0]
push dword [eax]
lea eax, [ebx + 0x4e4]
cmove eax, edx
mov edx, 0x14
push dword [eax]
lea eax, [ebx + 0x4dc]
cmove eax, edx
push dword [eax]
mov eax, dword [edi + 0x10b0]
push dword [ecx]
mov eax, dword [eax]
push dword [eax]
lea eax, [esp + 0x74]
push eax
call fcn.10159a30
push dword [esp + 0x88]
mov ecx, dword [esp + 0x48]
mov eax, dword [esp + 0x94]
push dword [esp + 0x7c]
mov edx, dword [esp + 0x70]
push dword [ecx + 0x28]
mov eax, dword [eax]
push dword [ecx + 0x18]
shl edx, 6
mov eax, dword [edx + eax + 0xc5cc]
call eax
add esp, 0x3c
mov dword [esp + 0x30], eax
jmp 0x10157715
mov edi, dword [esp + 0x68]
mov eax, dword [esp + 0x84]
mov edx, dword [eax + esi*4 - 4]
cmp edx, dword [esp + 0x40]
jbe 0x10157730
mov byte [esi + edi + 0x2438b], 1
jmp 0x10157749
mov eax, dword [esp + 0x70]
mov ecx, dword [esp + 0x1c]
shr eax, cl
cmp edx, eax
sbb al, al
and al, 0xfe
add al, 2
mov byte [esi + edi + 0x2438b], al
mov eax, dword [esp + 0x44]
cmp dword [esp + 0x2c], eax
seta al
mov byte [esi + edi + 0x2438d], al
mov eax, dword [esp + 0x48]
cmp dword [esp + 0x30], eax
seta al
add dword [esp + 0x20], 0x538
mov byte [esi + edi + 0x2438f], al
add ebp, 0x538
inc esi
cmp esi, 3
jl 0x101573d6
pop ebx
pop edi
pop esi
pop ebp
add esp, 0x50
ret