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

Disassembly:
push ebp
mov ebp, esp
and esp, 0xfffffff0
sub esp, 0x88
mov eax, edx
mov dword [esp + 0x5c], 0
push esi
xorps xmm0, xmm0
mov dword [esp + 0x64], 0
push edi
mov esi, dword [eax + 0x10]
movaps xmmword [esp + 0x70], xmm0
movq qword [esp + 0x80], xmm0
mov dword [esp + 0x60], eax
mov edi, dword [esi]
mov dword [esp + 0x48], eax
mov dword [esp + 0x44], ecx
mov dword [esp + 0x38], 0xffffffff
mov dword [esp + 0x34], 0
cmp edi, 5
je 0x50c034
mov ecx, dword [esi + 0xc]
lea eax, [esp + 0x60]
push eax
push 0x50be10
lea edx, [esp + 0x3c]
call fcn.0050bdb0
add esp, 8
test eax, eax
jne 0x50c615
cmp edi, 2
je 0x50c026
mov ecx, dword [esi + 0x10]
lea eax, [esp + 0x60]
push eax
push 0x50be10
lea edx, [esp + 0x3c]
call fcn.0050bdb0
add esp, 8
test eax, eax
jne 0x50c615
mov edi, dword [esp + 0x64]
jmp 0x50c039
mov edi, 1
lea esi, [edi + edi*4]
mov dword [esp + 0x20], edi
shl esi, 3
mov dword [esp + 0x4c], esi
call fcn.004e4f50
test eax, eax
jne 0x50c610
push eax
push esi
call fcn.0043b050
mov esi, eax
add esp, 8
test esi, esi
je 0x50c610
push dword [esp + 0x4c]
push 0
push esi
call fcn.00570cd0
mov ecx, dword [esp + 0x54]
add esp, 0xc
mov eax, dword [ebp + 8]
mov dword [esp + 0x70], ecx
mov dword [esp + 0x74], eax
mov ecx, dword [ecx + 0x10]
mov eax, dword [esp + 0x44]
mov dword [esp + 0x80], esi
mov dword [esp + 0x78], eax
mov dword [esp + 0x7c], edi
mov dword [esp + 0x84], 0xffffffff
mov eax, dword [ecx]
mov dword [esp + 0x48], ecx
mov dword [esp + 0x34], 0
mov dword [esp + 0x4c], eax
cmp eax, 5
je 0x50c118
mov ecx, dword [ecx + 0xc]
lea eax, [esp + 0x70]
push eax
push 0x50bef0
lea edx, [esp + 0x3c]
call fcn.0050bdb0
mov ecx, eax
add esp, 8
mov dword [esp + 0x1c], ecx
test ecx, ecx
jne 0x50c592
cmp dword [esp + 0x4c], 2
je 0x50c1b2
mov ecx, dword [esp + 0x48]
lea eax, [esp + 0x70]
push eax
push 0x50bef0
lea edx, [esp + 0x3c]
mov ecx, dword [ecx + 0x10]
call fcn.0050bdb0
mov ecx, eax
add esp, 8
mov dword [esp + 0x1c], ecx
jmp 0x50c1aa
mov eax, dword [ecx + 0x14]
mov edx, ecx
mov eax, dword [eax + 0x40]
mov dword [esi], eax
lea eax, [esp + 0x34]
mov ecx, dword [esp + 0x70]
push eax
push dword [esp + 0x78]
call fcn.004f4960
mov ecx, eax
add esp, 8
mov eax, dword [esp + 0x34]
mov dword [esp + 0x1c], ecx
test eax, eax
je 0x50c1aa
mov dword [esi + 4], eax
mov cl, byte [eax]
test cl, cl
jns 0x50c165
lea edx, [esp + 0x4c]
mov ecx, eax
call fcn.004ea670
mov edx, dword [esp + 0x4c]
mov ecx, eax
mov eax, dword [esp + 0x34]
jmp 0x50c16d
movzx edx, cl
mov ecx, 1
add eax, ecx
lea ecx, [edx - 2]
mov dword [esp + 0x4c], eax
mov eax, ecx
cdq
mov dword [esp + 0x48], eax
test ecx, ecx
jns 0x50c18c
mov ecx, 0x10b
mov dword [esp + 0x1c], ecx
jmp 0x50c1aa
mov eax, dword [esp + 0x4c]
mov ecx, dword [esp + 0x1c]
mov dword [esi + 0x10], eax
mov dword [esi + 0x20], eax
mov eax, dword [esp + 0x48]
mov dword [esi + 8], eax
mov dword [esi + 0xc], edx
mov dword [esi + 0x18], eax
mov dword [esi + 0x1c], edx
test ecx, ecx
jne 0x50c592
xor esi, esi
test edi, edi
jle 0x50c208
mov eax, dword [esp + 0x80]
mov edi, dword [ebp + 0x14]
add eax, 0x10
mov ecx, dword [esp + 0x20]
mov dword [esp + 0x34], eax
nop dword [eax]
cmp dword [eax], 0
je 0x50c1fc
xor eax, eax
xor ecx, ecx
mov edx, esi
and edx, 0x3f
bts eax, edx
cmp edx, 0x20
cmovae ecx, eax
xor eax, ecx
cmp edx, 0x40
cmovae ecx, eax
or dword [edi], eax
or dword [edi + 4], ecx
mov eax, dword [esp + 0x34]
mov ecx, dword [esp + 0x20]
inc esi
add eax, 0x28
mov dword [esp + 0x34], eax
cmp esi, ecx
jl 0x50c1d0
mov ecx, dword [ebp + 0x18]
mov eax, dword [ebp + 8]
mov dword [ecx], eax
mov ecx, dword [esp + 0x7c]
cmp dword [esp + 0x84], 0
jge 0x50c271
xor edi, edi
mov dword [esp + 0x84], 0
test ecx, ecx
jle 0x50c334
xor esi, esi
nop word [eax + eax]
mov eax, dword [esp + 0x80]
push dword [esp + 0x78]
lea edx, [eax + 8]
lea ecx, [eax + 0x10]
add edx, esi
add ecx, esi
call fcn.0050be50
mov ecx, dword [esp + 0x80]
inc edi
add esp, 4
add esi, 0x28
cmp edi, ecx
jl 0x50c240
jmp 0x50c334
mov edx, 0x7fffffff
mov dword [esp + 0x20], edx
test ecx, ecx
jle 0x50c589
mov esi, dword [esp + 0x80]
add esi, 8
nop dword [eax]
cmp dword [esi + 8], 0
je 0x50c2b2
mov edi, dword [esi]
mov eax, edx
cdq
cmp dword [esi + 4], edx
jg 0x50c2ae
jl 0x50c2a6
cmp edi, eax
jae 0x50c2ae
mov edx, edi
mov dword [esp + 0x20], edx
jmp 0x50c2b2
mov edx, dword [esp + 0x20]
add esi, 0x28
sub ecx, 1
jne 0x50c290
cmp edx, 0x7fffffff
je 0x50c589
mov eax, edx
xor edi, edi
sub eax, dword [esp + 0x78]
inc eax
mov dword [esp + 0x48], eax
mov dword [esp + 0x84], eax
lea eax, [edx + 1]
xor edx, edx
mov dword [esp + 0x4c], eax
mov dword [esp + 0x34], edx
nop word [eax + eax]
mov esi, dword [esp + 0x80]
push dword [esp + 0x4c]
add esi, edx
lea edx, [esi + 8]
lea ecx, [esi + 0x10]
call fcn.0050be50
add esp, 4
lea edx, [esi + 0x18]
lea ecx, [esi + 0x20]
push dword [esp + 0x48]
call fcn.0050be50
mov edx, dword [esp + 0x38]
inc edi
mov ecx, dword [esp + 0x80]
add edx, 0x28
add esp, 4
mov dword [esp + 0x34], edx
cmp edi, ecx
jl 0x50c2f0
mov eax, dword [esp + 0x84]
xorps xmm0, xmm0
mov dword [esp + 0x20], eax
xor esi, esi
movlpd qword [esp + 0x60], xmm0
mov eax, dword [esp + 0x60]
mov edi, dword [esp + 0x64]
movlpd qword [esp + 0x58], xmm0
mov edx, dword [esp + 0x58]
mov dword [esp + 0x18], eax
mov eax, dword [esp + 0x5c]
mov dword [esp + 0x14], esi
mov dword [esp + 0x28], esi
mov dword [esp + 0x10], edi
test ecx, ecx
jle 0x50c552
mov dword [esp + 0x34], edx
mov edx, esi
mov dword [esp + 0x2c], esi
mov dword [esp + 0x30], eax
nop word [eax + eax]
add edx, dword [esp + 0x80]
mov dword [esp + 0x54], edx
mov eax, dword [edx + 0x20]
mov dword [esp + 0x40], eax
test eax, eax
je 0x50c52a
mov eax, dword [esp + 0x78]
mov edi, dword [edx + 0x1c]
add eax, dword [esp + 0x20]
mov esi, dword [edx + 0x18]
cdq
mov dword [esp + 0x24], esi
mov dword [esp + 0x44], edi
cmp edi, edx
jg 0x50c52a
jl 0x50c3d3
cmp esi, eax
jae 0x50c52a
mov eax, dword [esp + 0x28]
and eax, 0x8000003f
jns 0x50c3e3
dec eax
or eax, 0xffffffc0
inc eax
mov ecx, dword [esp + 0x20]
mov dword [esp + 0x50], eax
mov eax, ecx
cdq
mov dword [esp + 0x48], eax
mov dword [esp + 0x4c], edx
jmp 0x50c404
mov eax, dword [esp + 0x48]
cmp edi, edx
jl 0x50c526
jg 0x50c416
cmp esi, eax
jb 0x50c526
mov eax, dword [esp + 0x50]
xor esi, esi
bts esi, eax
xor edi, edi
cmp eax, 0x20
cmovae edi, esi
xor esi, edi
cmp eax, 0x40
mov eax, dword [esp + 0x24]
cmovae edi, esi
sub eax, ecx
xor ecx, ecx
xor edx, edx
bts edx, eax
cmp eax, 0x20
cmovae ecx, edx
xor edx, ecx
cmp eax, 0x40
mov eax, dword [esp + 0x10]
cmovae ecx, edx
mov dword [esp + 0x60], edx
or eax, dword [ebp + 0x10]
mov dword [esp + 0x58], ecx
and eax, edi
mov ecx, dword [esp + 0x18]
or ecx, dword [ebp + 0xc]
and ecx, esi
or ecx, eax
mov eax, 1
jne 0x50c472
mov eax, 0x3e8
add dword [esp + 0x14], eax
mov eax, dword [esp + 0x54]
or dword [esp + 0x18], esi
xor esi, esi
or dword [esp + 0x10], edi
mov edi, dword [eax]
test edi, edi
jle 0x50c4ae
nop word [eax + eax]
mov eax, edx
mov ecx, esi
mov edx, dword [esp + 0x58]
call fcn.00596d00
or dword [esp + 0x30], edx
inc esi
or dword [esp + 0x34], eax
mov edx, dword [esp + 0x60]
cmp esi, edi
jl 0x50c490
mov edi, dword [esp + 0x40]
mov al, byte [edi]
test al, 0xfe
je 0x50c526
test al, al
jns 0x50c4cf
lea edx, [esp + 0x3c]
mov ecx, edi
call fcn.004ea670
mov ecx, eax
mov eax, dword [esp + 0x3c]
jmp 0x50c4db
movzx eax, al
mov ecx, 1
mov dword [esp + 0x3c], eax
mov esi, dword [esp + 0x24]
add eax, 0xfffffffe
cdq
add edi, ecx
mov ecx, dword [esp + 0x20]
add esi, eax
mov eax, dword [esp + 0x14]
mov dword [esp + 0x40], edi
mov edi, dword [esp + 0x44]
adc edi, edx
mov dword [esp + 0x14], eax
mov eax, dword [esp + 0x78]
add eax, ecx
mov dword [esp + 0x24], esi
cdq
cmp edi, edx
mov dword [esp + 0x44], edi
mov edx, dword [esp + 0x4c]
jl 0x50c400
jg 0x50c526
cmp esi, eax
mov eax, dword [esp + 0x48]
jb 0x50c404
mov ecx, dword [esp + 0x7c]
mov eax, dword [esp + 0x28]
mov edx, dword [esp + 0x2c]
inc eax
add edx, 0x28
mov dword [esp + 0x28], eax
mov dword [esp + 0x2c], edx
cmp eax, ecx
jl 0x50c390
mov eax, dword [esp + 0x30]
mov edx, dword [esp + 0x34]
mov esi, dword [esp + 0x14]
cmp esi, dword [esp + 0x38]
jle 0x50c214
mov edi, dword [ebp + 0x18]
mov esi, dword [esp + 0x20]
mov dword [edi + 4], esi
mov esi, edi
mov edi, dword [esp + 0x10]
mov dword [esi + 0x14], eax
mov eax, dword [esp + 0x18]
mov dword [esi + 0x10], edx
mov dword [esi + 8], eax
mov dword [esi + 0xc], edi
mov esi, dword [esp + 0x14]
mov dword [esp + 0x38], esi
jmp 0x50c214
mov eax, dword [ebp + 0x1c]
mov ecx, dword [esp + 0x38]
mov dword [eax], ecx
mov esi, dword [esp + 0x80]
test esi, esi
je 0x50c606
cmp dword [0x5dac30], 0
je 0x50c5f6
mov eax, dword [0x5dfe08]
test eax, eax
je 0x50c5b9
push eax
call dword [0x5dac80]
add esp, 4
push esi
call dword [0x5dac5c]
sub dword [0x5dfca8], eax
add esp, 4
dec dword [0x5dfccc]
push esi
call dword [0x5dac54]
mov eax, dword [0x5dfe08]
add esp, 4
test eax, eax
je 0x50c606
push eax
call dword [0x5dac88]
mov eax, dword [esp + 0x20]
add esp, 4
pop edi
pop esi
mov esp, ebp
pop ebp
ret
push dword [esp + 0x80]
call dword [0x5dac54]
add esp, 4
mov eax, dword [esp + 0x1c]
pop edi
pop esi
mov esp, ebp
pop ebp
ret
mov eax, 7
pop edi
pop esi
mov esp, ebp
pop ebp
ret