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

Disassembly:
push ebp
mov ebp, esp
and esp, 0xfffffff8
sub esp, 0xec
mov eax, dword [0x456178]
xor eax, esp
mov dword [esp + 0xe8], eax
mov eax, dword [ebp + 8]
xor edx, edx
push ebx
push esi
mov esi, ecx
mov dword [esp + 0x3c], eax
mov ecx, dword [ebp + 0x18]
push edi
mov dword [esp + 0x2c], esi
cmp dword [esi], edx
jne 0x408189
mov eax, 0x80004005
jmp 0x40864f
mov eax, dword [ebp + 0x14]
mov ebx, edx
mov dword [esi + 4], eax
mov byte [esp + 0x12], 1
mov dword [esp + 0x34], edx
mov dword [esp + 0x38], ebx
mov dword [esp + 0x3c], edx
push 0x18
pop edi
test ecx, ecx
je 0x40828c
lea eax, [esp + 0x34]
mov byte [esp + 0x12], dl
push eax
push 0x3b
pop edx
call fcn.0040f680
mov ebx, dword [esp + 0x3c]
mov eax, ebx
mov esi, dword [esp + 0x38]
sub eax, esi
cdq
idiv edi
pop ecx
test eax, eax
je 0x40820e
mov edi, esi
mov esi, eax
push 0x44979c
mov edx, 0x449818
mov ecx, edi
call fcn.0040c5a0
pop ecx
push 0x5c
push 0x2f
pop edx
mov ecx, edi
call fcn.0040c670
add esp, 4
mov edx, 0x44981c
call fcn.0040c730
add edi, 0x18
dec esi
jne 0x4081d6
mov esi, dword [esp + 0x34]
push 0x18
pop edi
cmp esi, ebx
je 0x40827e
add esi, 0x18
mov dword [esp + 0x1c], esi
cmp dword [esi - 8], 0
jne 0x408267
mov edi, esi
cmp esi, ebx
je 0x40823c
push 0xffffffffffffffe8
pop esi
push edi
lea ecx, [edi + esi]
call fcn.00401e84
add edi, 0x18
cmp edi, ebx
jne 0x408228
mov esi, dword [esp + 0x1c]
lea eax, [ebx - 0x18]
mov dword [esp + 0x18], eax
mov edi, eax
lea eax, [ebx - 0x18]
cmp eax, ebx
je 0x40825e
push 0
push 1
mov ecx, edi
call fcn.00401751
add edi, 0x18
cmp edi, ebx
jne 0x40824c
mov ebx, dword [esp + 0x18]
push 0x18
pop edi
jmp 0x40826d
add esi, edi
mov dword [esp + 0x1c], esi
lea eax, [esi - 0x18]
cmp eax, ebx
jne 0x408219
mov dword [esp + 0x38], ebx
cmp dword [esp + 0x34], ebx
jne 0x408288
mov esi, 0x80004005
jmp 0x408644
mov esi, dword [esp + 0x2c]
push dword [esp + 0x40]
lea ecx, [esp + 0x9c]
call fcn.00401e5c
cmp dword [esp + 0xa8], 0
je 0x4082b5
push 0x10
pop edx
lea ecx, [esp + 0x98]
call fcn.0040cc10
mov edi, dword [esi]
mov dword [esp + 0x54], edi
test edi, edi
je 0x4082c6
mov ecx, edi
call fcn.00410460
lea ecx, [esi + 8]
call fcn.0040892a
mov ecx, eax
mov dword [esp + 0x1c], ecx
test ecx, ecx
jne 0x4082e2
mov esi, 0x80004005
jmp 0x408629
xor eax, eax
lea edx, [esp + 0x30]
mov dword [esp + 0x20], eax
mov dword [esp + 0x24], eax
mov dword [esp + 0x28], eax
mov dword [esp + 0x30], eax
mov eax, dword [ecx]
push edx
call dword [eax + 0x18]
mov esi, eax
test esi, esi
jne 0x408609
mov eax, dword [esp + 0x30]
test eax, eax
je 0x408462
xor edx, edx
mov dword [esp + 0x14], edx
test eax, eax
je 0x408458
lea ecx, [esp + 0x70]
mov byte [esp + 0x13], 0
call fcn.004104a0
mov ecx, dword [esp + 0x1c]
lea esi, [esp + 0x70]
push esi
push 6
push edx
mov eax, dword [ecx]
call dword [eax + 0x1c]
mov esi, eax
test esi, esi
jne 0x408469
cmp dword [esp + 0x70], 4
jne 0x408367
mov eax, dword [esp + 0x90]
or eax, dword [esp + 0x94]
je 0x408367
mov byte [esp + 0x13], 1
lea ecx, [esp + 0x70]
call fcn.00410580
mov ecx, dword [esp + 0x1c]
lea edx, [esp + 0x70]
push edx
push 3
push dword [esp + 0x1c]
mov eax, dword [ecx]
call dword [eax + 0x1c]
mov esi, eax
test esi, esi
jne 0x408469
lea eax, [esp + 0x74]
push eax
lea ecx, [esp + 0x5c]
call fcn.00401e5c
cmp byte [esp + 0x12], 0
je 0x4083fc
mov ecx, dword [esp + 0x2c]
mov eax, dword [ecx + 0x2c]
mov ecx, eax
mov esi, eax
mov edx, dword [ecx + 4]
mov ecx, dword [esp + 0x14]
cmp byte [edx + 0xd], 0
jne 0x4083cb
cmp dword [edx + 0x10], ecx
jae 0x4083c5
mov edx, dword [edx + 8]
jmp 0x4083b5
mov esi, edx
mov edx, dword [edx]
jmp 0x4083b5
mov edx, eax
cmp esi, edx
je 0x4083e0
cmp ecx, dword [esi + 0x10]
jb 0x4083e0
mov dword [esp + 0x50], esi
lea ecx, [esp + 0x50]
jmp 0x4083e8
mov dword [esp + 0x44], edx
lea ecx, [esp + 0x44]
cmp dword [ecx], eax
jne 0x40842f
lea eax, [esp + 0x14]
push eax
lea ecx, [esp + 0x24]
call fcn.00408745
jmp 0x40842f
cmp byte [esp + 0x13], 0
jne 0x40842f
mov esi, dword [esp + 0x34]
cmp esi, ebx
je 0x40842f
mov edx, esi
lea ecx, [esp + 0x58]
call fcn.0040c500
test al, al
je 0x408428
lea eax, [esp + 0x14]
push eax
lea ecx, [esp + 0x24]
call fcn.00408745
add esi, 0x18
cmp esi, ebx
jne 0x40840b
push 0
push 1
lea ecx, [esp + 0x60]
call fcn.00401751
lea ecx, [esp + 0x70]
call fcn.00410510
mov edx, dword [esp + 0x14]
inc edx
mov dword [esp + 0x14], edx
cmp edx, dword [esp + 0x30]
jb 0x408322
mov eax, dword [esp + 0x20]
cmp eax, dword [esp + 0x24]
jne 0x408477
xor esi, esi
jmp 0x408609
lea ecx, [esp + 0x70]
call fcn.00410510
jmp 0x408609
push 0x150
call fcn.0043451f
pop ecx
test eax, eax
je 0x408495
mov ecx, eax
call fcn.00414bb3
mov ebx, eax
mov dword [esp + 0x14], eax
jmp 0x40849b
xor ebx, ebx
mov dword [esp + 0x14], ebx
test ebx, ebx
je 0x4084a4
lea eax, [ebx + 8]
jmp 0x4084a6
xor eax, eax
push eax
lea ecx, [esp + 0x1c]
call fcn.00408975
mov eax, dword [ebp + 0x10]
sub esp, 0x14
movzx eax, al
push eax
mov eax, dword [ebp + 0xc]
movzx eax, al
push eax
push ecx
push ecx
mov ecx, ebx
call fcn.004151d4
lea ecx, [esp + 0xb0]
call fcn.0040d210
mov ebx, dword [esp + 0x2c]
lea edx, [esp + 0xb0]
lea esi, [ebx + 0x14]
mov ecx, esi
call fcn.0040e720
and dword [esp + 0x68], 0
lea ecx, [esp + 0x58]
xor eax, eax
mov dword [esp + 0x6c], 7
push 0x44979c
mov word [esp + 0x5c], ax
call fcn.00401628
xor eax, eax
lea ecx, [esp + 0xc8]
mov dword [esp + 0x44], eax
mov dword [esp + 0x48], eax
mov dword [esp + 0x4c], eax
mov eax, dword [esp + 0x40]
push eax
push esi
sub esp, 0xc
push dword [esp + 0xe8]
push dword [esp + 0xe8]
push ecx
lea ecx, [esp + 0x78]
push ecx
lea ecx, [esp + 0x68]
push ecx
push eax
push ecx
push dword [ebx + 0x10]
mov ebx, dword [esp + 0x50]
mov ecx, dword [esp + 0x48]
push ebx
call fcn.00414fdc
lea ecx, [esp + 0x44]
call fcn.004017e0
push 0
push 1
lea ecx, [esp + 0x60]
call fcn.00401751
cmp byte [esp + 0x12], 0
je 0x408589
mov ecx, dword [esp + 0x2c]
mov eax, dword [esp + 0x24]
cmp dword [ecx + 0x30], 0
cmove eax, dword [esp + 0x20]
mov dword [esp + 0x24], eax
mov esi, dword [ebx]
lea ecx, [esp + 0x18]
call fcn.0040892a
push eax
push 0
lea eax, [esp + 0x28]
mov ecx, ebx
push eax
call dword [esi + 0x20]
mov esi, eax
test esi, esi
jne 0x4085f4
cmp byte [esp + 0x12], al
jne 0x4085f4
mov eax, dword [esp + 0x24]
xor ebx, ebx
mov ecx, dword [esp + 0x20]
sub eax, ecx
sar eax, 2
test eax, eax
je 0x4085f4
mov edi, dword [esp + 0x2c]
movzx eax, byte [0x45ae4f]
push eax
lea eax, [ecx + ebx*4]
push eax
push ecx
lea eax, [esp + 0x50]
push eax
lea ecx, [edi + 0x2c]
call fcn.00408999
mov eax, dword [esp + 0x24]
inc ebx
mov ecx, dword [esp + 0x20]
sub eax, ecx
sar eax, 2
cmp ebx, eax
jb 0x4085c4
mov edi, dword [esp + 0x54]
lea ecx, [esp + 0xb0]
call fcn.0040d2b0
lea ecx, [esp + 0x18]
call fcn.0040891e
cmp dword [esp + 0x20], 0
je 0x408629
push dword [esp + 0x20]
call fcn.004342bb
and dword [esp + 0x24], 0
and dword [esp + 0x28], 0
and dword [esp + 0x2c], 0
pop ecx
test edi, edi
je 0x408634
mov ecx, edi
call fcn.00410470
push 0
push 1
lea ecx, [esp + 0xa0]
call fcn.00401751
lea ecx, [esp + 0x34]
call fcn.004017e0
mov eax, esi
mov ecx, dword [esp + 0xf4]
pop edi
pop esi
pop ebx
xor ecx, esp
call fcn.004333fa
mov esp, ebp
pop ebp
ret 0x14