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

Disassembly:
mov eax, dword fs:[0]
push 0xffffffffffffffff
push 0x580d48
push eax
mov eax, dword [esp + 0x1c]
mov dword fs:[0], esp
sub esp, 0x58
push esi
mov esi, ecx
push eax
call fcn.004ff730
mov eax, dword [esp + 0x6c]
test eax, eax
je 0x4fe9e0
push ebx
push ebp
push edi
mov edi, dword [esp + 0x88]
xor eax, eax
test edi, edi
setne al
add eax, 2
xor edi, edi
test eax, eax
mov dword [esp + 0x18], eax
mov dword [esp + 0x14], edi
jle 0x4fe9bd
test edi, edi
jne 0x4fe7c5
mov ecx, dword [esp + 0x78]
mov dword [esp + 0x10], ecx
jmp 0x4fe7e2
cmp edi, 1
jne 0x4fe7d7
mov edx, dword [esp + 0x80]
mov dword [esp + 0x10], edx
jmp 0x4fe7e2
mov eax, dword [esp + 0x88]
mov dword [esp + 0x10], eax
mov eax, dword [esp + 0x84]
test eax, eax
je 0x4fe80c
test edi, edi
jne 0x4fe7f9
lea ebp, [esi + 0x2f8]
jmp 0x4fe829
cmp edi, 1
lea ebp, [esi + 0x3c4]
je 0x4fe829
lea ebp, [esi + 0x490]
jmp 0x4fe829
test edi, edi
jne 0x4fe818
lea ebp, [esi + 0x94]
jmp 0x4fe829
cmp edi, 1
lea ebp, [esi + 0x160]
je 0x4fe829
lea ebp, [esi + 0x22c]
mov eax, dword [esp + 0x10]
test eax, eax
je 0x4fe9bd
lea ecx, [esp + 0x3c]
push ecx
push eax
call dword [0x5885f4]
mov eax, dword [esp + 0x4c]
lea edx, [esp + 0x50]
push edx
push 0x18
push eax
call dword [0x587078]
mov ecx, dword [esp + 0x54]
mov edx, dword [esp + 0x58]
test edi, edi
mov dword [esi + 0x8c], ecx
mov dword [esi + 0x90], edx
jne 0x4fe956
lea ecx, [esp + 0x1c]
call fcn.004631b4
push edi
mov dword [esp + 0x74], edi
call dword [0x587094]
push eax
lea ecx, [esp + 0x20]
call fcn.004631ae
mov eax, dword [esp + 0x4c]
push 0x2000
push edi
push edi
push edi
push eax
call dword [0x588748]
mov ebx, eax
test ebx, ebx
je 0x4fe945
mov ecx, dword [esp + 0x20]
push ebx
push ecx
call dword [0x5870b4]
mov edi, eax
mov eax, dword [esi + 0x8c]
mov dword [esp + 0x34], eax
mov eax, 0x5d2000
xor edx, edx
mov ecx, dword [esi + 0x90]
neg eax
mov dword [esp + 0x2c], edx
mov dword [esp + 0x30], edx
mov edx, dword [0x5d2004]
mov dword [esp + 0x38], ecx
sbb eax, eax
and eax, edx
lea edx, [esp + 0x2c]
push eax
mov eax, dword [esp + 0x24]
push edx
push eax
call dword [0x588794]
mov edx, dword [esp + 0x20]
mov ecx, dword [esi + 0x90]
lea eax, [esp + 0x1c]
push 3
neg eax
sbb eax, eax
push 0
and eax, edx
mov edx, dword [esi + 0x8c]
push 0
push ecx
mov ecx, dword [esp + 0x20]
push edx
push ecx
push 0
push 0
push eax
call dword [0x58867c]
test edi, edi
je 0x4fe93a
mov edx, dword [esp + 0x20]
push edi
push edx
call dword [0x5870b4]
push ebx
call dword [0x5870ac]
mov edi, dword [esp + 0x14]
lea ecx, [esp + 0x1c]
mov dword [esp + 0x70], 0xffffffff
call fcn.004631a2
mov eax, dword [esp + 0x4c]
mov ebx, dword [0x5870ac]
push eax
call ebx
mov ecx, dword [esp + 0x48]
push ecx
call ebx
mov eax, dword [esp + 0x54]
mov ebx, dword [esp + 0x8c]
mov ecx, dword [esp + 0x58]
mov dword [ebp + 4], eax
test ebx, ebx
mov dword [ebp + 8], ecx
jne 0x4fe99f
mov eax, dword [0x5d1f94]
mov ecx, dword [ebp + 0xa0]
cmp eax, ecx
je 0x4fe99f
mov ecx, ebp
mov dword [ebp + 0xa0], eax
call fcn.004ed2f0
mov edx, dword [esp + 0x10]
push ebx
push edx
mov ecx, ebp
call fcn.004eb980
mov eax, dword [esp + 0x18]
inc edi
cmp edi, eax
mov dword [esp + 0x14], edi
jl 0x4fe7b7
mov eax, dword [esp + 0x7c]
pop edi
pop ebp
pop ebx
test eax, eax
je 0x4fe9e0
mov eax, dword [esp + 0x6c]
mov esi, dword [0x588680]
push eax
call esi
mov eax, dword [esp + 0x74]
test eax, eax
je 0x4fe9e0
push eax
call esi
mov ecx, dword [esp + 0x5c]
pop esi
mov dword fs:[0], ecx
add esp, 0x64
ret 0x18