Function at 0x4592e8
Capabilities:
Check if file exists

Disassembly:
push 0x4f0
mov eax, 0x5bee49
call fcn.00598fca
mov eax, dword [ebp + 8]
xor ebx, ebx
mov esi, ecx
mov dword [ebp - 0x4c8], esi
cmp eax, ebx
je 0x459688
add eax, 0x1048
push eax
mov dword [ebp - 0x4c0], eax
call dword [sym.imp.SHLWAPI.dll_PathFileExistsW]
test eax, eax
je 0x459688
lea ecx, [esi + 0x68]
mov edi, 0x5e9948
mov edx, edi
mov dword [ebp - 4], ebx
mov dword [ebp - 0x4b8], ecx
call fcn.0054b949
cmp byte [eax + 8], bl
je 0x459688
mov ecx, dword [ebp - 0x4b8]
mov edx, edi
call fcn.0054b949
call fcn.0054bd25
test al, al
je 0x459688
mov ecx, dword [ebp - 0x4b8]
mov edx, edi
call fcn.0054b949
call fcn.0054b6cc
test eax, eax
je 0x459688
lea ecx, [esi + 0x18]
mov edx, str.main
mov dword [ebp - 0x4bc], ebx
mov dword [ebp - 0x4c4], ecx
call fcn.0054b949
mov edx, edi
mov ecx, eax
mov dword [ebp - 0x4b0], eax
call fcn.0054b949
call fcn.0054b6cc
test eax, eax
je 0x4593e1
mov ecx, dword [ebp - 0x4b0]
mov edx, edi
call fcn.0054b949
push ebx
mov ecx, eax
call fcn.0054b71c
mov edx, str.fidx
mov ecx, eax
call fcn.0054b949
mov ecx, eax
call fcn.0054b340
xor ecx, ecx
cmp eax, ebx
sete cl
mov dword [ebp - 0x4bc], ecx
xor eax, eax
push 0x7e
mov word [ebp - 0x9c], ax
lea eax, [ebp - 0x9a]
push ebx
push eax
call fcn.00596530
add esp, 0xc
xor eax, eax
mov esi, 0x206
push esi
mov word [ebp - 0x2a4], ax
lea eax, [ebp - 0x2a2]
push ebx
push eax
call fcn.00596530
mov ecx, dword [ebp - 0x4b8]
add esp, 0xc
mov edx, edi
call fcn.0054b949
push ebx
mov ecx, eax
call fcn.0054b71c
mov edx, 0x5e99e8
mov ecx, eax
call fcn.0054b949
push dword [eax]
lea eax, [ebp - 0x4b4]
push eax
call fcn.0047f54f
pop ecx
pop ecx
lea eax, [ebp - 0x2a4]
mov byte [ebp - 4], 1
mov ecx, dword [ebp - 0x4b4]
push 0x103
push eax
call fcn.0042c637
pop ecx
pop ecx
cmp eax, ebx
je 0x459491
lea eax, [ebp - 0x2a4]
push eax
call dword [sym.imp.SHLWAPI.dll_PathFindExtensionW]
push eax
push 0x5db9e0
lea eax, [ebp - 0x9c]
push 0x3f
push eax
call fcn.0058f42f
add esp, 0x10
xor eax, eax
cmp ax, word [ebp - 0x9c]
je 0x45967a
push esi
mov word [ebp - 0x4ac], ax
lea eax, [ebp - 0x4aa]
push ebx
push eax
call fcn.00596530
add esp, 0xc
lea eax, [ebp - 0x4ac]
push eax
push dword [ebp - 0x4bc]
lea ecx, [ebp - 0x9c]
push ebx
mov eax, str.adimgbg
call fcn.004578a8
push dword [ebp - 0x4c0]
lea ecx, [ebp - 0x4ac]
call fcn.00476205
pop ecx
test eax, eax
je 0x45967a
lea eax, [ebp - 0x4fc]
push eax
push 6
pop ebx
call fcn.0054af1d
mov esi, eax
mov ecx, dword [ebp - 0x4b0]
mov edx, edi
mov byte [ebp - 4], 2
call fcn.0054b949
push esi
mov esi, eax
call fcn.0054b224
lea ecx, [ebp - 0x4fc]
mov byte [ebp - 4], 1
call fcn.0054b1a0
mov ecx, dword [ebp - 0x4b8]
mov edx, edi
call fcn.0054b949
mov ecx, dword [ebp - 0x4b0]
mov edx, edi
mov esi, eax
call fcn.0054b949
xor ebx, ebx
push ebx
mov ecx, esi
mov edi, eax
call fcn.0054b71c
push eax
push edi
call fcn.0054bb5f
push dword [ebp - 0x4bc]
lea edi, [ebp - 0x4fc]
call fcn.0054af9b
mov esi, eax
mov ecx, dword [ebp - 0x4b0]
mov edi, 0x5e9948
mov edx, edi
mov byte [ebp - 4], 3
call fcn.0054b949
push ebx
mov ecx, eax
call fcn.0054b71c
mov edx, str.fidx
mov ecx, eax
call fcn.0054b949
push esi
mov esi, eax
call fcn.0054b224
lea ecx, [ebp - 0x4fc]
mov byte [ebp - 4], 1
call fcn.0054b1a0
lea eax, [ebp - 0x9c]
push eax
lea eax, [ebp - 0x4c0]
push eax
call fcn.0047f493
pop ecx
pop ecx
mov byte [ebp - 4], 4
push dword [eax]
lea eax, [ebp - 0x4fc]
push eax
call fcn.0054afd5
mov esi, eax
mov ecx, dword [ebp - 0x4b0]
mov edx, edi
mov byte [ebp - 4], 5
call fcn.0054b949
push ebx
mov ecx, eax
call fcn.0054b71c
mov edx, str.fext
mov ecx, eax
call fcn.0054b949
push esi
mov esi, eax
call fcn.0054b224
lea ecx, [ebp - 0x4fc]
mov byte [ebp - 4], 4
call fcn.0054b1a0
mov byte [ebp - 4], 1
mov eax, dword [ebp - 0x4c0]
add eax, 0xfffffff0
call fcn.00407b6b
mov ecx, dword [ebp - 0x4c4]
mov edx, str.main
call fcn.0054b949
mov edx, 0x5e9904
mov ecx, eax
call fcn.0054b949
mov esi, eax
mov ecx, eax
call fcn.0054b340
inc eax
push eax
lea edi, [ebp - 0x4fc]
call fcn.0054af9b
push eax
mov byte [ebp - 4], 6
call fcn.0054b224
mov ecx, edi
mov byte [ebp - 4], 1
call fcn.0054b1a0
mov eax, dword [ebp - 0x4c8]
dec dword [eax + 0x14]
mov dword [eax + 0x10], 1
mov eax, dword [ebp - 0x4b4]
add eax, 0xfffffff0
call fcn.00407b6b
call fcn.00599026
ret 4