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

Disassembly:
push ebp
push edi
push esi
push ebx
add esp, 0xffffff80
mov ebp, dword [esp + 0x9c]
mov dword [esp + 0x40], 0
mov dword [esp + 0x44], 0
mov dword [esp + 0x48], 0
mov dword [esp + 0x4c], 0
mov dword [esp + 0x50], 0
mov dword [esp + 0x54], 0
mov dword [esp + 0x58], 0
mov dword [esp + 0x5c], 0
test ebp, ebp
je 0x59c593
mov eax, dword [esp + 0x98]
lea ecx, [eax + ebp*2]
movzx edx, word [eax]
inc word [esp + edx*2 + 0x40]
add eax, 2
cmp eax, ecx
jne 0x59c584
mov edx, dword [esp + 0xa4]
mov eax, dword [edx]
movzx ecx, word [esp + 0x5e]
test cx, cx
jne 0x59c692
cmp word [esp + 0x5c], 0
jne 0x59cc7d
cmp word [esp + 0x5a], 0
jne 0x59cc8a
cmp word [esp + 0x58], 0
jne 0x59cc97
cmp word [esp + 0x56], 0
jne 0x59cca4
cmp word [esp + 0x54], 0
jne 0x59ccb1
cmp word [esp + 0x52], 0
jne 0x59cd16
cmp word [esp + 0x50], 0
jne 0x59cd09
cmp word [esp + 0x4e], 0
jne 0x59cce2
cmp word [esp + 0x4c], 0
jne 0x59cd23
cmp word [esp + 0x4a], 0
jne 0x59ccfc
cmp word [esp + 0x48], 0
jne 0x59ccc8
cmp word [esp + 0x46], 0
jne 0x59ccd5
cmp word [esp + 0x44], 0
jne 0x59ccef
cmp word [esp + 0x42], 0
jne 0x59cb58
mov edi, dword [esp + 0xa0]
mov eax, dword [edi]
mov byte [eax], 0x40
mov byte [eax + 1], 1
mov word [eax + 2], 0
mov byte [eax + 4], 0x40
mov byte [eax + 5], 1
mov word [eax + 6], 0
add eax, 8
mov dword [edi], eax
mov eax, dword [esp + 0xa4]
mov dword [eax], 1
xor eax, eax
sub esp, 0xffffff80
pop ebx
pop esi
pop edi
pop ebp
ret
mov dword [esp + 0x10], 0xf
mov edi, dword [esp + 0x10]
cmp edi, eax
jbe 0x59c6a4
mov edi, eax
cmp word [esp + 0x42], 0
jne 0x59cb6b
mov eax, 1
mov edx, dword [esp + 0x10]
jmp 0x59c6c4
cmp word [esp + eax*2 + 0x40], 0
jne 0x59c6c9
inc eax
cmp eax, edx
jne 0x59c6bc
movzx ebx, word [esp + 0x42]
mov edx, 2
sub edx, ebx
shl edx, 1
movzx esi, word [esp + 0x44]
sub edx, esi
js 0x59cb7d
lea ebx, [edx + edx]
movzx edx, word [esp + 0x46]
sub ebx, edx
js 0x59cb7d
shl ebx, 1
movzx edx, word [esp + 0x48]
sub ebx, edx
js 0x59cb7d
shl ebx, 1
movzx edx, word [esp + 0x4a]
sub ebx, edx
js 0x59cb7d
shl ebx, 1
movzx edx, word [esp + 0x4c]
sub ebx, edx
js 0x59cb7d
shl ebx, 1
movzx edx, word [esp + 0x4e]
sub ebx, edx
js 0x59cb7d
shl ebx, 1
movzx edx, word [esp + 0x50]
sub ebx, edx
js 0x59cb7d
shl ebx, 1
movzx edx, word [esp + 0x52]
sub ebx, edx
js 0x59cb7d
shl ebx, 1
movzx edx, word [esp + 0x54]
sub ebx, edx
js 0x59cb7d
shl ebx, 1
movzx edx, word [esp + 0x56]
sub ebx, edx
js 0x59cb7d
shl ebx, 1
movzx edx, word [esp + 0x58]
sub ebx, edx
js 0x59cb7d
shl ebx, 1
movzx edx, word [esp + 0x5a]
sub ebx, edx
js 0x59cb7d
shl ebx, 1
movzx edx, word [esp + 0x5c]
sub ebx, edx
js 0x59cb7d
lea edx, [ebx + ebx]
sub edx, ecx
cmp edx, 0
jl 0x59cb7d
je 0x59c7c3
mov ecx, dword [esp + 0x94]
test ecx, ecx
je 0x59cb7d
cmp dword [esp + 0x10], 1
jne 0x59cb7d
mov word [esp + 0x62], 0
mov dx, word [esp + 0x42]
mov word [esp + 0x64], dx
add edx, dword [esp + 0x44]
mov word [esp + 0x66], dx
add dx, word [esp + 0x46]
mov word [esp + 0x68], dx
add edx, dword [esp + 0x48]
mov word [esp + 0x6a], dx
add dx, word [esp + 0x4a]
mov word [esp + 0x6c], dx
add edx, dword [esp + 0x4c]
mov word [esp + 0x6e], dx
add dx, word [esp + 0x4e]
mov word [esp + 0x70], dx
add edx, dword [esp + 0x50]
mov word [esp + 0x72], dx
add dx, word [esp + 0x52]
mov word [esp + 0x74], dx
add edx, dword [esp + 0x54]
mov word [esp + 0x76], dx
add dx, word [esp + 0x56]
mov word [esp + 0x78], dx
add edx, dword [esp + 0x58]
mov word [esp + 0x7a], dx
add dx, word [esp + 0x5a]
mov word [esp + 0x7c], dx
add edx, dword [esp + 0x5c]
mov word [esp + 0x7e], dx
xor edx, edx
test ebp, ebp
je 0x59c893
mov dword [esp + 4], eax
mov dword [esp + 8], edi
mov ebx, dword [esp + 0x98]
movzx eax, word [ebx + edx*2]
test ax, ax
je 0x59c886
mov cx, word [esp + eax*2 + 0x60]
movzx esi, cx
mov edi, dword [esp + 0xa8]
mov word [edi + esi*2], dx
inc ecx
mov word [esp + eax*2 + 0x60], cx
inc edx
cmp edx, ebp
jne 0x59c864
mov eax, dword [esp + 4]
mov edi, dword [esp + 8]
mov dword [esp + 0x28], eax
cmp eax, edi
jae 0x59c89f
mov dword [esp + 0x28], edi
mov edx, dword [esp + 0x94]
test edx, edx
jne 0x59cbca
mov edi, dword [esp + 0xa0]
mov edi, dword [edi]
mov dword [esp + 0x20], edi
mov dword [esp + 0x2c], 1
mov cl, byte [esp + 0x28]
shl dword [esp + 0x2c], cl
mov edi, dword [esp + 0x2c]
dec edi
mov dword [esp + 0x34], edi
mov edx, dword [esp + 0xa8]
mov dword [esp + 0x3c], edx
mov dword [esp + 0x38], edx
mov dword [esp + 0x24], 0x14
mov edx, dword [esp + 0xa8]
mov dword [esp + 0x18], edx
mov esi, dword [esp + 0x28]
mov dword [esp + 0x30], 0xffffffff
xor ebp, ebp
mov dword [esp + 0x14], 0
mov dword [esp + 0xc], eax
mov edi, ebp
mov ebp, esi
mov eax, edx
nop
mov bl, byte [esp + 0xc]
sub ebx, dword [esp + 0x14]
mov si, word [eax]
movzx eax, si
lea edx, [eax + 1]
cmp edx, dword [esp + 0x24]
jb 0x59cb20
cmp eax, dword [esp + 0x24]
jb 0x59cb28
sub eax, dword [esp + 0x24]
shl eax, 1
mov ecx, dword [esp + 0x3c]
mov dl, byte [ecx + eax]
mov ecx, dword [esp + 0x38]
mov si, word [ecx + eax]
mov ecx, dword [esp + 0xc]
sub ecx, dword [esp + 0x14]
mov eax, 1
shl eax, cl
mov dword [esp + 4], eax
mov eax, 1
mov ecx, ebp
shl eax, cl
mov dword [esp + 0x1c], eax
mov eax, dword [esp + 4]
neg eax
shl eax, 2
mov dword [esp + 8], eax
mov eax, edi
mov cl, byte [esp + 0x14]
shr eax, cl
add eax, dword [esp + 0x1c]
sub eax, dword [esp + 4]
mov ecx, dword [esp + 0x20]
lea eax, [ecx + eax*4]
mov ecx, dword [esp + 0x1c]
nop
mov byte [eax], dl
mov byte [eax + 1], bl
mov word [eax + 2], si
add eax, dword [esp + 8]
sub ecx, dword [esp + 4]
jne 0x59c99c
mov ecx, dword [esp + 0xc]
dec ecx
mov eax, 1
shl eax, cl
mov ecx, eax
test eax, edi
je 0x59c9ca
lea esi, [esi]
shr ecx, 1
test edi, ecx
jne 0x59c9c4
test ecx, ecx
je 0x59cb18
lea eax, [ecx - 1]
and eax, edi
lea edi, [eax + ecx]
mov edx, dword [esp + 0xc]
mov dx, word [esp + edx*2 + 0x40]
mov eax, edx
dec eax
mov edx, dword [esp + 0xc]
mov word [esp + edx*2 + 0x40], ax
test ax, ax
jne 0x59ca17
mov eax, dword [esp + 0x10]
cmp edx, eax
je 0x59cb8a
mov edx, dword [esp + 0x18]
movzx eax, word [edx + 2]
mov edx, dword [esp + 0x98]
movzx eax, word [edx + eax*2]
mov dword [esp + 0xc], eax
mov eax, dword [esp + 0xc]
cmp dword [esp + 0x28], eax
jae 0x59cb08
mov ebx, dword [esp + 0x34]
and ebx, edi
cmp ebx, dword [esp + 0x30]
je 0x59cb08
mov eax, dword [esp + 0x14]
test eax, eax
jne 0x59ca45
mov ecx, dword [esp + 0x28]
mov dword [esp + 0x14], ecx
mov edx, dword [esp + 0x20]
mov eax, dword [esp + 0x1c]
lea edx, [edx + eax*4]
mov dword [esp + 0x20], edx
mov ebp, dword [esp + 0xc]
sub ebp, dword [esp + 0x14]
mov edx, 1
mov ecx, ebp
shl edx, cl
mov eax, dword [esp + 0x10]
cmp dword [esp + 0xc], eax
jae 0x59caa2
mov ecx, dword [esp + 0xc]
movzx eax, word [esp + ecx*2 + 0x40]
sub edx, eax
test edx, edx
jle 0x59caa2
mov eax, dword [esp + 0x14]
lea ecx, [esp + eax*2 + 0x40]
mov esi, eax
jmp 0x59ca96
movzx eax, word [ecx + ebp*2]
sub edx, eax
test edx, edx
jle 0x59caa2
inc ebp
shl edx, 1
lea eax, [esi + ebp]
cmp dword [esp + 0x10], eax
ja 0x59ca8c
mov eax, 1
mov ecx, ebp
shl eax, cl
add dword [esp + 0x2c], eax
cmp dword [esp + 0x94], 1
je 0x59cb48
cmp dword [esp + 0x94], 2
je 0x59cb31
lea eax, [ebx*4]
mov ecx, dword [esp + 0xa0]
mov edx, dword [ecx]
mov ecx, ebp
mov byte [edx + eax], cl
mov ecx, dword [esp + 0xa0]
mov edx, dword [ecx]
mov cl, byte [esp + 0x28]
mov byte [edx + eax + 1], cl
mov edx, dword [esp + 0xa0]
mov ecx, dword [edx]
mov edx, dword [esp + 0x20]
sub edx, ecx
sar edx, 2
mov word [ecx + eax + 2], dx
mov dword [esp + 0x30], ebx
add dword [esp + 0x18], 2
mov eax, dword [esp + 0x18]
jmp 0x59c918
xor edi, edi
jmp 0x59c9da
xor edx, edx
jmp 0x59c952
xor esi, esi
mov dl, 0x60
jmp 0x59c952
cmp dword [esp + 0x2c], 0x250
jbe 0x59cac7
mov eax, 1
sub esp, 0xffffff80
pop ebx
pop esi
pop edi
pop ebp
ret
cmp dword [esp + 0x2c], 0x354
jbe 0x59cac7
jmp 0x59cb3b
mov edi, eax
test eax, eax
je 0x59cb63
mov edi, 1
mov dword [esp + 0x10], 1
movzx eax, word [esp + 0x42]
mov edx, 2
sub edx, eax
jns 0x59ccbe
mov eax, 0xffffffff
sub esp, 0xffffff80
pop ebx
pop esi
pop edi
pop ebp
ret
mov ebp, edi
test edi, edi
je 0x59cba3
mov edi, dword [esp + 0x20]
lea eax, [edi + ebp*4]
mov byte [eax], 0x40
mov byte [eax + 1], bl
mov word [eax + 2], 0
mov eax, dword [esp + 0x2c]
shl eax, 2
mov edx, dword [esp + 0xa0]
add dword [edx], eax
mov ecx, dword [esp + 0x28]
mov edi, dword [esp + 0xa4]
mov dword [edi], ecx
xor eax, eax
sub esp, 0xffffff80
pop ebx
pop esi
pop edi
pop ebp
ret
cmp dword [esp + 0x94], 1
je 0x59cc2f
mov edx, dword [esp + 0xa0]
mov edx, dword [edx]
mov dword [esp + 0x20], edx
mov dword [esp + 0x2c], 1
mov cl, byte [esp + 0x28]
shl dword [esp + 0x2c], cl
mov edi, dword [esp + 0x2c]
dec edi
mov dword [esp + 0x34], edi
cmp dword [esp + 0x94], 2
jne 0x59cc12
cmp dword [esp + 0x2c], 0x250
ja 0x59cb3b
mov dword [esp + 0x24], 0
mov dword [esp + 0x3c], 0x6364c0
mov dword [esp + 0x38], 0x636440
jmp 0x59c8eb
mov edi, dword [esp + 0xa0]
mov edi, dword [edi]
mov dword [esp + 0x20], edi
mov edi, dword [esp + 0x94]
mov cl, byte [esp + 0x28]
shl edi, cl
mov dword [esp + 0x2c], edi
dec edi
mov dword [esp + 0x34], edi
mov dword [esp + 0x24], 0x101
mov dword [esp + 0x3c], 0x636480
mov dword [esp + 0x38], 0x636400
cmp dword [esp + 0x2c], 0x354
jbe 0x59c8eb
jmp 0x59cb3b
mov dword [esp + 0x10], 0xe
jmp 0x59c69a
mov dword [esp + 0x10], 0xd
jmp 0x59c69a
mov dword [esp + 0x10], 0xc
jmp 0x59c69a
mov dword [esp + 0x10], 0xb
jmp 0x59c69a
mov dword [esp + 0x10], 0xa
jmp 0x59c69a
mov eax, 1
jmp 0x59c6d5
mov dword [esp + 0x10], 4
jmp 0x59c69a
mov dword [esp + 0x10], 3
jmp 0x59c69a
mov dword [esp + 0x10], 7
jmp 0x59c69a
mov dword [esp + 0x10], 2
jmp 0x59c69a
mov dword [esp + 0x10], 5
jmp 0x59c69a
mov dword [esp + 0x10], 8
jmp 0x59c69a
mov dword [esp + 0x10], 9
jmp 0x59c69a
mov dword [esp + 0x10], 6
jmp 0x59c69a