Function at 0x5e2f90
Capabilities:
Get common file path
Set current directory

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x8bc
push esi
push edi
lea edi, [ebp - 0x8bc]
mov ecx, 0x22f
mov eax, 0xcccccccc
rep stosd dword es:[edi], eax
mov eax, dword [0x6bc858]
xor eax, ebp
mov dword [ebp - 4], eax
mov eax, dword [ebp + 8]
mov dword [ebp - 8], eax
mov ecx, dword [ebp - 8]
cmp dword [ecx + 0x16c], 0
je 0x5e2fce
jmp 0x5e32dc
mov edx, dword [ebp - 8]
mov eax, dword [edx + 0x170]
push eax
call fcn.005cd630
mov dword [ebp - 0xc], eax
cmp dword [ebp - 0xc], 0
jne 0x5e2ff8
push 0x65af8c
call fcn.005ab610
add esp, 4
jmp 0x5e32dc
xor ecx, ecx
mov word [ebp - 0x218], cx
push 0x206
push 0
lea edx, [ebp - 0x216]
push edx
call fcn.005ff630
add esp, 0xc
mov eax, dword [ebp - 0xc]
push eax
call fcn.00600eb0
add esp, 4
mov dword [ebp - 0x220], eax
cmp dword [ebp - 0x220], 0x104
jl 0x5e3047
push 0x65afa0
call fcn.005ab610
add esp, 4
jmp 0x5e32dc
mov ecx, dword [ebp - 0x220]
shl ecx, 1
push ecx
mov edx, dword [ebp - 0xc]
push edx
lea eax, [ebp - 0x218]
push eax
call fcn.00602090
add esp, 0xc
mov dword [ebp - 0x224], 0
jmp 0x5e307e
mov ecx, dword [ebp - 0x224]
add ecx, 1
mov dword [ebp - 0x224], ecx
mov edx, dword [ebp - 0x224]
cmp edx, dword [ebp - 0x220]
jge 0x5e30b1
mov eax, dword [ebp - 0x224]
movzx ecx, word [ebp + eax*2 - 0x218]
cmp ecx, 0x7c
jne 0x5e30af
xor edx, edx
mov eax, dword [ebp - 0x224]
mov word [ebp + eax*2 - 0x218], dx
jmp 0x5e306f
mov ecx, dword [ebp - 8]
mov dword [ecx + 0x16c], 1
xor edx, edx
mov word [ebp - 0x490], dx
push 0x206
push 0
lea eax, [ebp - 0x48e]
push eax
call fcn.005ff630
add esp, 0xc
mov ecx, dword [ebp - 8]
mov edx, dword [ecx + 0x174]
push edx
call fcn.005cd660
mov dword [ebp - 0x220], eax
cmp dword [ebp - 0x220], 0
jle 0x5e312d
cmp dword [ebp - 0x220], 0x104
jge 0x5e312d
mov eax, dword [ebp - 0x220]
push eax
mov ecx, dword [ebp - 8]
mov edx, dword [ecx + 0x174]
push edx
call fcn.005cd630
push eax
lea eax, [ebp - 0x490]
push eax
call fcn.0040ec80
add esp, 0xc
xor ecx, ecx
mov word [ebp - 0x6a0], cx
push 0x206
push 0
lea edx, [ebp - 0x69e]
push edx
call fcn.005ff630
add esp, 0xc
mov esi, esp
lea eax, [ebp - 0x6a0]
push eax
push 0x104
call dword [sym.imp.KERNEL32.dll_GetCurrentDirectoryW]
cmp esi, esp
call fcn.00605df0
push 0x58
push 0
lea ecx, [ebp - 0x280]
push ecx
call fcn.005ff630
add esp, 0xc
mov dword [ebp - 0x280], 0x58
lea edx, [ebp - 0x490]
mov dword [ebp - 0x264], edx
mov dword [ebp - 0x260], 0x208
lea eax, [ebp - 0x218]
mov dword [ebp - 0x274], eax
mov dword [ebp - 0x268], 1
mov dword [ebp - 0x25c], 0
mov dword [ebp - 0x258], 0
mov dword [ebp - 0x254], 0
mov ecx, dword [ebp + 8]
push ecx
call fcn.005814f0
mov dword [ebp - 0x27c], eax
mov dword [ebp - 0x24c], 0x81800
mov esi, esp
lea edx, [ebp - 0x280]
push edx
call dword [sym.imp.COMDLG32.dll_GetOpenFileNameW]
cmp esi, esp
call fcn.00605df0
test eax, eax
je 0x5e32a8
mov eax, dword [ebp - 8]
cmp dword [eax + 0x178], 0
je 0x5e3298
mov ecx, dword [ebp - 8]
mov edx, dword [ecx + 0x178]
push edx
call fcn.005cd630
mov dword [ebp - 0x6a8], eax
cmp dword [ebp - 0x6a8], 0
je 0x5e3298
xor eax, eax
mov word [ebp - 0x8b4], ax
push 0x206
push 0
lea ecx, [ebp - 0x8b2]
push ecx
call fcn.005ff630
add esp, 0xc
mov esi, esp
push 0x80
lea edx, [ebp - 0x490]
push edx
push 0x10
mov eax, dword [ebp - 0x6a8]
push eax
lea ecx, [ebp - 0x8b4]
push ecx
call dword [sym.imp.SHLWAPI.dll_PathRelativePathToW]
cmp esi, esp
call fcn.00605df0
cmp eax, 1
jne 0x5e3298
lea edx, [ebp - 0x8b4]
push edx
lea eax, [ebp - 0x490]
push eax
call fcn.005e3370
add esp, 8
lea ecx, [ebp - 0x490]
push ecx
mov edx, dword [ebp + 8]
push edx
call fcn.005b51d0
mov eax, dword [ebp - 8]
mov dword [eax + 0x16c], 0
mov esi, esp
lea ecx, [ebp - 0x6a0]
push ecx
call dword [sym.imp.KERNEL32.dll_SetCurrentDirectoryW]
cmp esi, esp
call fcn.00605df0
mov dword [ebp - 0x8bc], eax
push 0
mov edx, dword [ebp + 8]
push edx
call fcn.00582ca0
push edx
mov ecx, ebp
push eax
lea edx, [0x5e330c]
call fcn.00605e20
pop eax
pop edx
pop edi
pop esi
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.005f0da0
add esp, 0x8bc
cmp ebp, esp
call fcn.00605df0
mov esp, ebp
pop ebp
ret