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

Disassembly:
push 0xffffffffffffffff
push 0x45d276
mov eax, dword fs:[0]
push eax
sub esp, 0x4f0
mov eax, dword [0x477564]
xor eax, esp
mov dword [esp + 0x4e8], eax
push ebx
push ebp
push esi
push edi
mov eax, dword [0x477564]
xor eax, esp
push eax
lea eax, [esp + 0x504]
mov dword fs:[0], eax
mov eax, dword [esp + 0x514]
push edx
xor ebx, ebx
push eax
mov dword [esp + 0x24], ecx
mov byte [esp + 0x1f], bl
call fcn.0042ebf0
mov ebp, eax
add esp, 8
cmp ebp, ebx
je 0x40edd8
push 0x22c
lea eax, [esp + 0xa4]
push ebx
push eax
call fcn.004423c0
xor eax, eax
add esp, 0xc
cmp dword [ebp], 1
mov dword [esp + 0x9c], eax
mov word [esp + 0xa0], bx
mov dword [esp + 0x2c8], ebx
je 0x40eafe
push ebp
mov dword [0x47ceac], 0x80000
call fcn.0042ed40
add esp, 4
mov al, bl
jmp 0x40edda
mov esi, dword [ebp + 4]
mov edi, dword [esi]
or ecx, 0xffffffff
cmp dword [edi + 4], ecx
jg 0x40eb12
mov ecx, 0x10000
jmp 0x40eb77
cmp dword [esi + 4], ecx
je 0x40eb1f
call fcn.0042e430
or ecx, 0xffffffff
mov dword [esi + 4], ecx
mov ecx, dword [esi]
mov eax, dword [ecx + 4]
mov dword [esp + 0x9c], eax
mov word [esp + 0xa0], bx
mov dword [esp + 0x2a8], ebx
mov dword [esp + 0x2ac], ebx
mov dword [esp + 0x2b0], ebx
mov dword [esp + 0x2b4], ebx
mov dword [esp + 0x2b8], ebx
mov dword [esp + 0x2bc], ebx
mov dword [esp + 0x2c0], ebx
mov dword [esp + 0x2c4], ebx
mov dword [esp + 0x2c8], ebx
xor ecx, ecx
cmp ecx, ebx
mov dword [0x47ceac], ecx
jne 0x40eda4
cmp eax, ebx
mov byte [esp + 0x17], 1
mov dword [esp + 0x20], eax
mov dword [esp + 0x18], ebx
jle 0x40eda4
lea ebx, [ebx]
push 0x22c
lea edx, [esp + 0x2d4]
push ebx
push edx
call fcn.004423c0
add esp, 0xc
cmp dword [ebp], 1
mov dword [esp + 0x2cc], ebx
mov word [esp + 0x2d0], bx
mov dword [esp + 0x4f8], ebx
jne 0x40ed96
mov edx, dword [esp + 0x18]
mov eax, dword [ebp + 4]
lea ecx, [esp + 0x2cc]
push ecx
push edx
push eax
call fcn.0042e560
cmp eax, ebx
mov dword [0x47ceac], eax
jne 0x40eda0
mov al, byte [esp + 0x4d8]
test al, 0x10
je 0x40ec8b
mov dword [esp + 0x78], 7
mov dword [esp + 0x74], ebx
mov word [esp + 0x64], bx
mov dword [esp + 0x98], 0xf
mov dword [esp + 0x94], ebx
mov byte [esp + 0x84], bl
mov dword [esp + 0x50c], ebx
mov eax, dword [esp + 0x4d8]
mov dword [esp + 0x7c], eax
lea eax, [esp + 0x2d0]
lea edx, [eax + 2]
mov edi, edi
mov cx, word [eax]
add eax, 2
cmp cx, bx
jne 0x40ec50
sub eax, edx
sar eax, 1
push eax
lea ecx, [esp + 0x2d4]
push ecx
lea esi, [esp + 0x68]
call fcn.0040c2d0
mov edi, esi
call fcn.0040e9e0
mov edx, esi
mov esi, dword [esp + 0x1c]
push edx
call fcn.0040f460
mov esi, edi
jmp 0x40ed62
test al, 0x20
je 0x40eda0
mov dword [esp + 0x3c], 7
mov dword [esp + 0x38], ebx
mov word [esp + 0x28], bx
mov dword [esp + 0x5c], 0xf
mov dword [esp + 0x58], ebx
mov byte [esp + 0x48], bl
mov dword [esp + 0x50c], 1
mov eax, dword [esp + 0x4d8]
mov dword [esp + 0x40], eax
lea eax, [esp + 0x2d0]
lea edx, [eax + 2]
mov cx, word [eax]
add eax, 2
cmp cx, bx
jne 0x40ecd4
sub eax, edx
sar eax, 1
push eax
lea ecx, [esp + 0x2d4]
push ecx
lea esi, [esp + 0x2c]
call fcn.0040c2d0
mov edi, esi
call fcn.0040e9e0
mov eax, dword [esp + 0x4f8]
cmp eax, ebx
jle 0x40ed50
mov ecx, dword [esp + 0x58]
cmp eax, ecx
ja 0x40ed1d
push 0xffffffffffffffff
push eax
lea ecx, [esp + 0x4c]
call fcn.00406440
jmp 0x40ed29
push ebx
sub eax, ecx
lea edi, [esp + 0x48]
call fcn.00405d70
cmp dword [esp + 0x5c], 0x10
mov eax, dword [esp + 0x48]
jae 0x40ed38
lea eax, [esp + 0x48]
mov edx, dword [esp + 0x18]
mov ecx, dword [esp + 0x58]
push eax
push edx
mov eax, ebp
call fcn.0042ed00
add esp, 8
cmp eax, ebx
jne 0x40edb3
mov esi, dword [esp + 0x1c]
lea eax, [esp + 0x24]
push eax
call fcn.0040f460
lea esi, [esp + 0x24]
mov dword [esp + 0x50c], 0xffffffff
call fcn.00407dd0
mov eax, dword [esp + 0x18]
add eax, 1
cmp eax, dword [esp + 0x20]
mov dword [esp + 0x18], eax
jl 0x40eba0
push ebp
call fcn.0042ed40
mov al, byte [esp + 0x1b]
add esp, 4
jmp 0x40edda
mov dword [0x47ceac], 0x80000
mov byte [esp + 0x17], bl
push ebp
call fcn.0042ed40
mov al, byte [esp + 0x1b]
add esp, 4
jmp 0x40edda
lea esi, [esp + 0x24]
mov byte [esp + 0x17], bl
mov dword [esp + 0x50c], 0xffffffff
call fcn.00407dd0
push ebp
call fcn.0042ed40
add esp, 4
mov al, bl
jmp 0x40edda
mov al, bl
mov ecx, dword [esp + 0x504]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebp
pop ebx
mov ecx, dword [esp + 0x4e8]
xor ecx, esp
call fcn.0043c709
add esp, 0x4fc
ret