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

Disassembly:
push 0xffffffffffffffff
push 0x52fe38
mov eax, dword fs:[0]
push eax
mov dword fs:[0], esp
sub esp, 0x54
push ebx
push ebp
push esi
mov esi, dword [esp + 0x70]
push edi
mov edi, ecx
mov eax, dword [esi + 8]
mov ecx, dword [esi + 4]
push eax
push ecx
mov ecx, esi
mov dword [esp + 0x18], edi
call fcn.004ba220
mov eax, dword [edi + 0x20]
lea ecx, [esp + 0x34]
push eax
push ecx
mov ecx, dword [edi + 0xc]
call fcn.004e8220
mov eax, dword [esp + 0x3c]
mov dword [esp + 0x6c], 0
test eax, eax
je 0x501379
mov dl, byte [esp + 0x34]
push 0
lea ecx, [esp + 0x18]
mov byte [esp + 0x18], dl
call fcn.00405cc0
mov eax, dword [0x531160]
lea ecx, [esp + 0x34]
push eax
push 0
push ecx
lea ecx, [esp + 0x20]
call fcn.00407be0
mov ebp, dword [esp + 0x78]
mov byte [esp + 0x6c], 1
test ebp, ebp
je 0x50106b
push 1
lea edx, [esp + 0x78]
push 0
push edx
lea ecx, [esp + 0x20]
mov byte [esp + 0x80], 0x3a
call fcn.004ab270
mov edi, eax
mov eax, dword [0x531160]
cmp edi, eax
je 0x50106b
push edi
lea eax, [esp + 0x28]
push 0
push eax
lea ecx, [esp + 0x20]
call fcn.0049e4f0
mov eax, dword [esp + 0x2c]
mov bl, 2
test eax, eax
mov byte [esp + 0x6c], bl
je 0x50117f
mov eax, dword [esp + 0x28]
test eax, eax
jne 0x50100d
mov eax, 0x53115c
push 0xa
push 0
push eax
call fcn.00515dbe
add esp, 0xc
mov byte [ebp], al
mov ecx, dword [0x531160]
inc edi
push ecx
lea edx, [esp + 0x48]
push edi
push edx
lea ecx, [esp + 0x20]
call fcn.0049e4f0
mov ecx, dword [0x531160]
mov byte [esp + 0x6c], 3
push ecx
push 0
push eax
lea ecx, [esp + 0x20]
call fcn.00407be0
push 1
lea ecx, [esp + 0x48]
mov byte [esp + 0x70], bl
call fcn.00405cc0
push 1
lea ecx, [esp + 0x28]
mov byte [esp + 0x70], 1
call fcn.00405cc0
push 1
lea edx, [esp + 0x78]
push 0
push edx
lea ecx, [esp + 0x20]
mov byte [esp + 0x80], 0x2c
call fcn.004ab270
mov edi, eax
mov eax, dword [0x531160]
cmp edi, eax
mov ebx, 4
je 0x501266
push edi
lea eax, [esp + 0x28]
push 0
push eax
lea ecx, [esp + 0x20]
call fcn.0049e4f0
lea ebp, [edi + 1]
mov edi, 0x54fdcc
or ecx, 0xffffffff
xor eax, eax
repne scasb al, byte es:[edi]
not ecx
dec ecx
mov byte [esp + 0x6c], bl
push ecx
push eax
push 0x54fdcc
lea ecx, [esp + 0x30]
mov dword [esp + 0x84], 0
call fcn.004ab270
cmp eax, dword [0x531160]
jne 0x5011b7
mov edi, 0x5501b4
or ecx, 0xffffffff
xor eax, eax
repne scasb al, byte es:[edi]
not ecx
dec ecx
push ecx
push eax
push 0x5501b4
lea ecx, [esp + 0x30]
call fcn.004ab270
cmp eax, dword [0x531160]
jne 0x5011b7
mov eax, dword [esp + 0x28]
test eax, eax
jne 0x50111f
mov eax, 0x53115c
push 0xa
push 0
push eax
call fcn.00515dbe
add esp, 0xc
lea ecx, [esp + 0x78]
mov dword [esp + 0x78], eax
mov eax, dword [esi + 8]
push ecx
push 1
push eax
mov ecx, esi
call fcn.0040d620
mov edx, dword [0x531160]
lea eax, [esp + 0x44]
push edx
push ebp
push eax
lea ecx, [esp + 0x20]
call fcn.0049e4f0
mov ecx, dword [0x531160]
mov byte [esp + 0x6c], 6
push ecx
push 0
push eax
lea ecx, [esp + 0x20]
call fcn.00407be0
mov byte [esp + 0x6c], bl
push 1
lea ecx, [esp + 0x48]
jmp 0x50121c
push 1
lea ecx, [esp + 0x28]
mov byte [esp + 0x70], 1
call fcn.00405cc0
push 1
lea ecx, [esp + 0x18]
mov byte [esp + 0x70], 0
call fcn.00405cc0
push 1
lea ecx, [esp + 0x38]
mov dword [esp + 0x70], 0xffffffff
call fcn.00405cc0
jmp 0x50139d
mov eax, dword [esp + 0x28]
test eax, eax
jne 0x5011c4
mov eax, 0x53115c
push 0x10
push 0
push eax
call fcn.00515dbe
add esp, 0xc
mov dword [esp + 0x78], eax
mov eax, dword [esi + 8]
lea edx, [esp + 0x78]
push edx
push eax
mov ecx, esi
call fcn.005016c0
mov eax, dword [0x531160]
lea ecx, [esp + 0x54]
push eax
push ebp
push ecx
lea ecx, [esp + 0x20]
call fcn.0049e4f0
mov edx, dword [0x531160]
lea ecx, [esp + 0x14]
push edx
push 0
push eax
mov byte [esp + 0x78], 5
call fcn.00407be0
mov byte [esp + 0x6c], bl
push 1
lea ecx, [esp + 0x58]
call fcn.00405cc0
push 1
lea ecx, [esp + 0x28]
mov byte [esp + 0x70], 1
call fcn.00405cc0
push 1
lea eax, [esp + 0x78]
push 0
push eax
lea ecx, [esp + 0x20]
mov byte [esp + 0x80], 0x2c
call fcn.004ab270
mov edi, eax
mov eax, dword [0x531160]
cmp edi, eax
jne 0x501099
xor edi, edi
cmp ebp, edi
jne 0x5012ea
jmp 0x501268
xor edi, edi
mov ecx, dword [esp + 0x10]
mov eax, dword [ecx + 0x18]
cmp eax, 3
je 0x501291
cmp eax, ebx
je 0x501291
cmp eax, 5
je 0x501291
cmp eax, 6
je 0x501291
cmp eax, 7
je 0x501291
cmp eax, 8
je 0x501291
cmp eax, 9
jne 0x5012bb
mov eax, dword [esp + 0x18]
cmp eax, edi
jne 0x50129e
mov eax, 0x53115c
push 0x10
push edi
push eax
call fcn.00515dbe
add esp, 0xc
lea edx, [esp + 0x74]
mov dword [esp + 0x74], eax
mov eax, dword [esi + 8]
push edx
push 1
push eax
jmp 0x501312
cmp eax, 0xd
jne 0x5012ea
mov eax, dword [esp + 0x18]
cmp eax, edi
jne 0x5012cd
mov eax, 0x53115c
push 0x10
push edi
push eax
call fcn.00515dbe
mov edx, dword [esi + 8]
add esp, 0xc
lea ecx, [esp + 0x74]
mov dword [esp + 0x74], eax
push ecx
push 1
push edx
jmp 0x501312
mov eax, dword [esp + 0x18]
cmp eax, edi
jne 0x5012f7
mov eax, 0x53115c
push 0xa
push edi
push eax
call fcn.00515dbe
mov ecx, dword [esi + 8]
add esp, 0xc
mov dword [esp + 0x74], eax
lea eax, [esp + 0x74]
push eax
push 1
push ecx
mov ecx, esi
call fcn.0040d620
mov ecx, dword [esp + 0x18]
cmp ecx, edi
je 0x50133d
mov al, byte [ecx - 1]
test al, al
je 0x501333
cmp al, 0xff
je 0x501333
dec al
mov byte [ecx - 1], al
jmp 0x50133d
dec ecx
push ecx
call fcn.00514120
add esp, 4
mov ecx, dword [esp + 0x38]
mov dword [esp + 0x18], edi
cmp ecx, edi
mov dword [esp + 0x1c], edi
mov dword [esp + 0x20], edi
je 0x501372
mov al, byte [ecx - 1]
test al, al
je 0x501368
cmp al, 0xff
je 0x501368
dec al
mov byte [ecx - 1], al
mov eax, 1
jmp 0x50139f
dec ecx
push ecx
call fcn.00514120
add esp, 4
mov eax, 1
jmp 0x50139f
mov ecx, dword [esp + 0x38]
test ecx, ecx
je 0x50139d
mov al, byte [ecx - 1]
test al, al
je 0x501393
cmp al, 0xff
je 0x501393
dec al
mov byte [ecx - 1], al
jmp 0x50139d
dec ecx
push ecx
call fcn.00514120
add esp, 4
xor eax, eax
mov ecx, dword [esp + 0x64]
pop edi
pop esi
pop ebp
pop ebx
mov dword fs:[0], ecx
add esp, 0x60
ret 8