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

Disassembly:
push 0xffffffffffffffff
push 0x5866fc
mov eax, dword fs:[0]
push eax
sub esp, 0xc8
push ebx
push ebp
push esi
push edi
mov eax, dword [0x67d978]
xor eax, esp
push eax
lea eax, [esp + 0xdc]
mov dword fs:[0], eax
mov ebx, dword [esp + 0xec]
call fcn.004fc4d0
mov esi, eax
mov eax, dword [esi + 4]
xor edi, edi
cmp eax, edi
jne 0x4faf9a
mov dword [esp + 0x18], edi
jmp 0x4fafa5
mov ecx, dword [esi + 8]
sub ecx, eax
sar ecx, 1
mov dword [esp + 0x18], ecx
cmp eax, edi
je 0x4fafb2
mov ecx, dword [esi + 8]
sub ecx, eax
sar ecx, 1
jne 0x4fafb7
call fcn.00536646
mov edx, dword [esi + 4]
push 1
lea eax, [esp + 0x40]
push eax
mov dword [esp + 0x24], edx
call fcn.004e4c70
mov dword [esp + 0xe4], edi
lea edi, [ebx + 0x14]
mov eax, ebx
lea esi, [esp + 0xa0]
call fcn.004d7ac0
mov ecx, eax
lea ebp, [ebx + 0x28]
mov eax, ebp
lea esi, [esp + 0x8c]
mov byte [esp + 0xe4], 1
call fcn.004d7b00
mov edi, eax
lea eax, [esp + 0x3c]
lea esi, [esp + 0xb4]
mov byte [esp + 0xe4], 2
call fcn.004d7aa0
mov esi, eax
push 0x8000
lea ecx, [esp + 0x7c]
push ecx
mov byte [esp + 0xec], 3
call fcn.004e4c70
mov edi, eax
mov edx, edi
mov eax, esi
call fcn.004d7a50
test al, al
jne 0x4fb041
mov esi, edi
cmp dword [esi + 0x10], 0
mov eax, dword [esi + 0xc]
mov eax, dword [eax]
je 0x4fb04e
neg eax
lea ecx, [esp + 0x78]
mov esi, eax
call fcn.0046ae2f
lea ecx, [esp + 0xb4]
mov byte [esp + 0xe4], 2
call fcn.0046ae2f
lea ecx, [esp + 0x8c]
mov byte [esp + 0xe4], 1
call fcn.0046ae2f
lea ecx, [esp + 0xa0]
mov byte [esp + 0xe4], 0
call fcn.0046ae2f
lea ecx, [esp + 0x3c]
mov dword [esp + 0xe4], 0xffffffff
call fcn.0046ae2f
lea edi, [ebx + 0x44]
push edi
call fcn.004fc0e0
mov eax, esi
call fcn.0040dd43
mov eax, dword [ebx + 0x3c]
test eax, eax
jne 0x4fb104
xor esi, esi
cmp dword [esp + 0x18], esi
jbe 0x4fb20f
lea esp, [esp]
mov edx, dword [esp + 0x1c]
movzx eax, word [edx + esi*2]
push eax
mov eax, ebp
call fcn.004e7cd0
mov ecx, dword [esp + 0x1c]
movzx edx, word [ecx + esi*2]
push ebp
push ebx
push edx
push edi
mov ecx, eax
call fcn.004facd0
add esi, 1
add esp, 0x10
cmp esi, dword [esp + 0x18]
jb 0x4fb0d0
jmp 0x4fb20f
push eax
lea eax, [esp + 0x54]
push eax
call fcn.004e4c70
lea eax, [esp + 0x50]
mov edi, ebx
lea esi, [esp + 0xc8]
mov dword [esp + 0xe4], 4
call fcn.004d7ac0
push 1
lea ecx, [esp + 0x68]
push ecx
push eax
mov byte [esp + 0xf0], 5
call fcn.004d77d0
mov ecx, esi
mov byte [esp + 0xe4], 7
call fcn.0046ae2f
lea ecx, [esp + 0x50]
mov byte [esp + 0xe4], 8
call fcn.0046ae2f
push 1
lea edx, [esp + 0x2c]
push edx
push ebp
call fcn.004d77d0
cmp dword [esp + 0x18], 0
mov byte [esp + 0xe4], 9
mov dword [esp + 0x20], 0
jbe 0x4fb1ea
mov eax, dword [esp + 0x1c]
mov ecx, dword [esp + 0x20]
movzx esi, word [eax + ecx*2]
movzx edi, si
push edi
mov eax, ebp
call fcn.004e7cd0
push ebp
movzx ecx, ax
push ebx
lea eax, [ebx + 0x44]
push esi
push eax
mov dword [esp + 0x34], ecx
call fcn.004facd0
movzx eax, word [esp + 0x34]
add eax, eax
add esp, 0x10
cmp eax, edi
jl 0x4fb1bf
sub eax, edi
movzx ecx, ax
lea edx, [esp + 0x28]
push edx
lea eax, [esp + 0x68]
push eax
lea eax, [ebx + 0x44]
push esi
push eax
call fcn.004facd0
mov eax, dword [esp + 0x30]
add eax, 1
add esp, 0x10
cmp eax, dword [esp + 0x18]
mov dword [esp + 0x20], eax
jb 0x4fb185
lea ecx, [esp + 0x28]
mov byte [esp + 0xe4], 8
call fcn.0046ae2f
lea ecx, [esp + 0x64]
mov dword [esp + 0xe4], 0xffffffff
call fcn.0046ae2f
mov ecx, dword [esp + 0xdc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebp
pop ebx
add esp, 0xd4
ret 4