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

Disassembly:
sub esp, 0x40
push ebx
push ebp
push esi
mov esi, ecx
xor ebx, ebx
push edi
mov eax, dword [esi + 0x78]
mov dword [esp + 0x14], esi
cmp eax, 2
mov dword [esp + 0x20], ebx
sete byte [esp + 0x13]
cmp eax, 2
mov word [esp + 0x24], bx
mov word [esp + 0x26], bx
mov word [esp + 0x28], 0x1f
mov word [esp + 0x2a], 0x29
mov word [esp + 0x2c], 0x33
mov word [esp + 0x2e], 0x3d
jne 0x406ab3
mov dword [esp + 0x18], 6
jmp 0x406ac3
mov edx, dword [esi + 0x1c]
xor eax, eax
cmp edx, 1
setne al
inc eax
mov dword [esp + 0x18], eax
mov dword [esp + 0x1c], ebx
lea ecx, [ebx*8]
sub ecx, ebx
lea ebp, [esi + ecx*2]
lea ecx, [ebp + 0x20]
call fcn.00407310
cmp ebx, dword [esp + 0x18]
jge 0x406cb8
test ebx, ebx
jne 0x406b22
mov al, byte [esp + 0x13]
test al, al
je 0x406b08
lea edx, [esp + 0x30]
push 0x20
push edx
push ebx
mov ecx, esi
call fcn.004069c0
test eax, eax
jne 0x406cd2
lea eax, [esp + 0x30]
push 0x18
push eax
push 0
mov ecx, esi
call fcn.004069c0
test eax, eax
jne 0x406cd2
jmp 0x406b43
cmp ebx, 1
je 0x406b43
mov dx, word [esp + ebx*2 + 0x24]
lea ecx, [esp + 0x30]
push 0xa
push ecx
push edx
mov ecx, esi
call fcn.004069c0
test eax, eax
jne 0x406cd2
lea edi, [ebx + ebx*4]
xor esi, esi
mov si, word [esp + ebx*2 + 0x24]
lea eax, [esp + 0x30]
shl edi, 3
push eax
push esi
mov ecx, dword [edi + 0x40bbec]
push ecx
call fcn.00406a40
lea edx, [esp + 0x3c]
mov byte [ebp + 0x23], al
mov eax, dword [edi + 0x40bbf0]
push edx
push esi
push eax
call fcn.00406a40
lea ecx, [esp + 0x48]
mov byte [ebp + 0x24], al
mov edx, dword [edi + 0x40bbf4]
push ecx
push esi
push edx
call fcn.00406a40
mov byte [ebp + 0x25], al
mov ecx, dword [edi + 0x40bbf8]
lea eax, [esp + 0x54]
push eax
push esi
push ecx
call fcn.00406a40
add esp, 0x30
lea edx, [esp + 0x30]
test ebx, ebx
mov byte [ebp + 0x26], al
push edx
jne 0x406bca
mov eax, dword [0x40bc00]
push 0
push eax
call fcn.00406a40
mov ecx, dword [esp + 0x20]
add esp, 0xc
mov word [ecx + 0x20], ax
jmp 0x406bfb
mov eax, dword [edi + 0x40bbfc]
push esi
push eax
call fcn.00406a40
mov edx, dword [edi + 0x40bc00]
lea ecx, [esp + 0x3c]
push ecx
mov ebx, eax
push esi
push edx
shl ebx, 8
call fcn.00406a40
add esp, 0x18
add ebx, eax
mov word [ebp + 0x20], bx
mov ebx, dword [esp + 0x1c]
mov ecx, dword [edi + 0x40bc04]
lea eax, [esp + 0x30]
push eax
push esi
push ecx
call fcn.00406a40
mov byte [ebp + 0x22], al
mov al, byte [esp + 0x1f]
add esp, 0xc
test al, al
je 0x406c72
mov eax, dword [edi + 0x40bc08]
lea edx, [esp + 0x30]
push edx
push esi
push eax
call fcn.00406a40
lea ecx, [esp + 0x3c]
mov word [ebp + 0x28], ax
mov edx, dword [edi + 0x40bc0c]
push ecx
push esi
push edx
call fcn.00406a40
lea ecx, [ebx + 3]
lea edx, [ecx*8]
sub edx, ecx
mov ecx, dword [esp + 0x2c]
mov word [ecx + edx*2], ax
mov eax, dword [edi + str.e_b_t_n_v_r_f]
lea edx, [esp + 0x48]
push edx
push esi
push eax
call fcn.00406a40
add esp, 0x24
mov word [ebp + 0x2c], ax
jmp 0x406c90
lea eax, [ebx + 3]
xor ecx, ecx
mov word [ebp + 0x28], cx
lea edx, [eax*8]
sub edx, eax
mov eax, dword [esp + 0x14]
mov word [eax + edx*2], cx
mov word [ebp + 0x2c], cx
mov al, byte [ebp + 0x23]
test al, al
ja 0x406cac
mov al, byte [ebp + 0x24]
test al, al
ja 0x406cac
mov al, byte [ebp + 0x25]
test al, al
ja 0x406cac
mov al, byte [ebp + 0x26]
test al, al
jbe 0x406cb4
mov dword [esp + 0x20], 1
mov esi, dword [esp + 0x14]
inc ebx
cmp ebx, 6
mov dword [esp + 0x1c], ebx
jl 0x406ac7
mov eax, dword [esp + 0x20]
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x40
ret
pop edi
pop esi
pop ebp
or eax, 0xffffffff
pop ebx
add esp, 0x40
ret