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

Disassembly:
mov eax, dword [0x81a558]
sub esp, 0x10c
push ebx
mov ebx, ecx
push esi
test eax, eax
jne 0x40132b
push edi
push 0x100
push eax
mov dword [esp + 0x14], eax
mov dword [esp + 0x18], eax
mov word [esp + 0x1c], ax
lea eax, [esp + 0x20]
push eax
call fcn.004015f0
add esp, 0xc
xor edi, edi
xor eax, eax
lea esp, [esp]
mov byte [esp + eax + 0x18], al
inc eax
cmp eax, 0x100
jb 0x4010a0
xor esi, esi
mov edi, edi
mov dl, byte [esp + esi + 0x18]
mov eax, esi
and eax, 3
movzx ecx, dl
movzx eax, byte [eax + 0x41e0e4]
add eax, edi
add ecx, eax
movzx edi, cl
mov al, byte [esp + edi + 0x18]
mov byte [esp + esi + 0x18], al
inc esi
mov byte [esp + edi + 0x18], dl
cmp esi, 0x100
jb 0x4010b0
mov cl, byte [esp + 0x19]
movzx esi, cl
movzx eax, byte [esp + esi + 0x18]
mov byte [esp + 0x19], al
mov byte [esp + esi + 0x18], cl
movzx eax, byte [esp + 0x19]
add eax, esi
mov cl, byte [esp + 0x1a]
movzx eax, al
movzx edx, cl
movzx eax, byte [esp + eax + 0x18]
xor al, 0xce
mov byte [esp + 0xc], al
lea eax, [edx + esi]
movzx esi, al
movzx eax, byte [esp + esi + 0x18]
mov byte [esp + 0x1a], al
mov byte [esp + esi + 0x18], cl
movzx eax, byte [esp + 0x1a]
add eax, edx
mov cl, byte [esp + 0x1b]
movzx eax, al
movzx edx, cl
movzx eax, byte [esp + eax + 0x18]
xor al, 0x26
mov byte [esp + 0xd], al
lea eax, [edx + esi]
movzx esi, al
movzx eax, byte [esp + esi + 0x18]
mov byte [esp + 0x1b], al
mov byte [esp + esi + 0x18], cl
movzx eax, byte [esp + 0x1b]
mov cl, byte [esp + 0x1c]
add eax, edx
movzx eax, al
movzx edx, cl
movzx eax, byte [esp + eax + 0x18]
xor al, 0x8d
mov byte [esp + 0xe], al
lea eax, [edx + esi]
movzx esi, al
movzx eax, byte [esp + esi + 0x18]
mov byte [esp + 0x1c], al
mov byte [esp + esi + 0x18], cl
movzx eax, byte [esp + 0x1c]
mov cl, byte [esp + 0x1d]
add eax, edx
movzx eax, al
movzx edx, cl
movzx eax, byte [esp + eax + 0x18]
xor al, 0x3a
mov byte [esp + 0xf], al
lea eax, [edx + esi]
movzx esi, al
movzx eax, byte [esp + esi + 0x18]
mov byte [esp + 0x1d], al
mov byte [esp + esi + 0x18], cl
movzx eax, byte [esp + 0x1d]
mov cl, byte [esp + 0x1e]
add eax, edx
movzx eax, al
movzx edx, cl
movzx eax, byte [esp + eax + 0x18]
xor al, 0x8c
mov byte [esp + 0x10], al
lea eax, [edx + esi]
movzx esi, al
movzx eax, byte [esp + esi + 0x18]
mov byte [esp + 0x1e], al
mov byte [esp + esi + 0x18], cl
movzx eax, byte [esp + 0x1e]
mov cl, byte [esp + 0x1f]
add eax, edx
movzx eax, al
movzx edx, cl
movzx eax, byte [esp + eax + 0x18]
xor al, 0x6f
mov byte [esp + 0x11], al
lea eax, [edx + esi]
movzx esi, al
movzx eax, byte [esp + esi + 0x18]
mov byte [esp + 0x1f], al
mov byte [esp + esi + 0x18], cl
movzx eax, byte [esp + 0x1f]
add eax, edx
mov cl, byte [esp + 0x20]
movzx eax, al
movzx eax, byte [esp + eax + 0x18]
xor al, 0x5b
mov byte [esp + 0x12], al
movzx eax, cl
add eax, esi
movzx edx, al
movzx eax, byte [esp + edx + 0x18]
mov byte [esp + 0x20], al
mov byte [esp + edx + 0x18], cl
movzx eax, byte [esp + 0x20]
movzx ecx, cl
add ecx, eax
movzx eax, cl
mov cl, byte [esp + 0x21]
movzx eax, byte [esp + eax + 0x18]
xor al, 3
mov byte [esp + 0x13], al
movzx eax, cl
add eax, edx
movzx esi, al
movzx eax, byte [esp + esi + 0x18]
mov byte [esp + 0x21], al
mov byte [esp + esi + 0x18], cl
movzx eax, byte [esp + 0x21]
mov dl, byte [esp + 0x22]
movzx ecx, cl
add ecx, eax
movzx eax, cl
lea ecx, [esp + 0x18]
movzx eax, byte [esp + eax + 0x18]
xor al, 0x9e
mov byte [esp + 0x14], al
movzx eax, dl
add eax, esi
movzx eax, al
add ecx, eax
movzx eax, byte [ecx]
mov byte [esp + 0x22], al
mov byte [ecx], dl
movzx eax, byte [esp + 0x22]
movzx ecx, dl
add ecx, eax
movzx eax, cl
movzx eax, byte [esp + eax + 0x18]
xor al, 0xfb
mov byte [esp + 0x15], al
call fcn.00403240
mov esi, eax
call fcn.004035e0
pop edi
test esi, esi
je 0x4012f6
mov eax, dword [esi + 0x3c]
test eax, eax
je 0x4012f6
mov ecx, dword [eax + esi + 0x7c]
test ecx, ecx
je 0x4012f6
mov eax, dword [eax + esi + 0x78]
test eax, eax
je 0x4012f6
lea edx, [esp + 8]
push edx
push ecx
lea edx, [eax + esi]
mov ecx, esi
call fcn.00401670
add esp, 8
test eax, eax
jne 0x401317
mov eax, dword [0x819400]
test eax, eax
jne 0x40130f
pop esi
mov dword [0x81a558], eax
pop ebx
add esp, 0x10c
ret 4
lea ecx, [esp + 8]
push ecx
push esi
call eax
mov dword [0x81a558], eax
test eax, eax
jne 0x40132b
pop esi
pop ebx
add esp, 0x10c
ret 4
push 0x18
push 8
push ebx
call eax
pop esi
pop ebx
add esp, 0x10c
ret 4