Function at 0x487ac4
Capabilities:
Get common file path

Disassembly:
push ebp
mov ebp, esp
add esp, 0xfffff004
push eax
add esp, 0xfffff154
push ebx
push esi
push edi
mov dword [ebp - 4], eax
mov edi, 0x4ae79c
mov eax, dword [ebp - 4]
cmp dword [eax + 0x30], 0
jne 0x487b2d
cmp dword [0x4c9890], 1
jne 0x487b05
mov ecx, 0x4bfd40
mov edx, 0x4bf940
mov eax, dword [ebp - 4]
call fcn.0040ff58
jmp 0x487b2d
push 0x30
mov eax, 0x65
call fcn.004129c8
push eax
mov eax, 0x14c
call fcn.004129c8
push eax
push dword [0x4c6eec]
call sub.USER32.DLL_MessageBoxA
jmp 0x487f06
push 0
lea edx, [edi + 4]
xor ecx, ecx
mov eax, 3
call fcn.004735f4
mov byte [ebp - 0x410], 0
lea edx, [ebp - 0x810]
push edx
push 0x400
call sub.KERNEL32.DLL_GetCurrentDirectoryA
mov byte [ebp - 0xc10], 0
xor esi, esi
xor eax, eax
mov dword [ebp - 8], eax
xor edx, edx
mov dword [ebp - 0xc], edx
jmp 0x487e3e
lea eax, [ebp - 0x1010]
call fcn.0040be48
push eax
mov eax, 0x20c
call fcn.004129c8
push eax
lea edx, [ebp - 0x1e10]
push edx
call fcn.0049bdcc
add esp, 0xc
lea eax, [ebp - 0x1e10]
call fcn.00475498
call fcn.00474794
lea edx, [ebp - 0x810]
push edx
call fcn.0049a80c
pop ecx
lea edx, [ebp - 0x1810]
lea eax, [ebp - 0x1010]
call fcn.0040ac6c
call fcn.0040a9b0
test al, al
jne 0x487e3e
inc dword [ebp - 8]
lea ecx, [ebp - 0xd]
lea edx, [ebp - 0x1010]
mov eax, 0x4c6f00
call fcn.0045c43c
test al, al
jne 0x487e68
test esi, esi
je 0x487bf9
lea eax, [edi + 4]
call fcn.004755b8
lea eax, [ebp - 0x1010]
call fcn.0040be48
call fcn.004755b8
mov eax, 0x264
call fcn.004129c8
call fcn.004755b8
call fcn.00449c20
xor ebx, ebx
push 1
push 0
lea ecx, [ebp - 0x1810]
lea edx, [ebp - 0x1010]
mov eax, 0x4c7c4c
call fcn.004567bc
dec eax
je 0x487cc0
mov bl, 1
lea eax, [ebp - 0x1e9c]
push eax
push 0
push 0
push 1
lea edx, [ebp - 0x1010]
mov eax, 0x4c7c4c
xor ecx, ecx
call fcn.00457e58
mov edx, dword [ebp - 0x1e9c]
sub edx, 1
jb 0x487c70
je 0x487c88
jmp 0x487ca0
lea eax, [edi + 0xa10]
push eax
lea edx, [ebp - 0x1eac]
push edx
call fcn.00498e7c
add esp, 8
jmp 0x487cd0
lea ecx, [edi + 0xa14]
push ecx
lea eax, [ebp - 0x1eac]
push eax
call fcn.00498e7c
add esp, 8
jmp 0x487cd0
xor edx, edx
mov dword [ebp - 0x1e9c], edx
lea ecx, [edi + 0xa18]
push ecx
lea eax, [ebp - 0x1eac]
push eax
call fcn.00498e7c
add esp, 8
jmp 0x487cd0
lea edx, [ebp - 0x1eac]
mov eax, 0x4c7c4c
call fcn.00457db0
lea edx, [ebp - 0x1eac]
push edx
lea ecx, [edi + 0xa1c]
push ecx
lea eax, [ebp - 0x1e10]
push eax
call fcn.0049bdcc
add esp, 0xc
lea eax, [ebp - 0x1e10]
call fcn.004755b8
cmp dword [ebp - 0x1e9c], 0
je 0x487d21
cmp dword [ebp - 0x1e9c], 1
je 0x487d21
mov eax, 0x266
call fcn.004129c8
call fcn.004755b8
inc dword [ebp - 0xc]
jmp 0x487e3e
lea eax, [edi + 4]
call fcn.004755b8
mov edx, 0x4bf940
lea eax, [ebp - 0x1010]
call fcn.0040acd8
mov edx, 0x4bfd40
lea eax, [ebp - 0x1810]
call fcn.0040ad28
mov edx, dword [ebp - 0x1e9c]
test bl, bl
mov dword [0x4be4f0], edx
jne 0x487d5d
test esi, esi
jne 0x487d9c
lea ecx, [ebp - 0x1010]
lea eax, [edi + 0xa24]
push ecx
push 0x48317b
push dword [0x4c6ef8]
push eax
push dword [0x4b41d0]
call sub.USER32.DLL_DialogBoxParamA
test eax, eax
je 0x487e68
lea edx, [ebp - 0xc10]
push edx
push 0x400
call sub.KERNEL32.DLL_GetCurrentDirectoryA
jmp 0x487da9
lea ecx, [ebp - 0xc10]
push ecx
call fcn.0049a80c
pop ecx
lea eax, [ebp - 0xc10]
push eax
push 0x4bba50
call fcn.00498e7c
add esp, 8
call fcn.00474794
mov eax, 0x4c7c4c
call fcn.00453864
lea edx, [edi + 0xa2e]
push edx
lea ecx, [ebp - 0x410]
push ecx
call fcn.00498e7c
add esp, 8
mov eax, 0x4bf940
call fcn.0040be48
push eax
lea edx, [ebp - 0x410]
push edx
call fcn.00498da0
add esp, 8
lea eax, [ebp - 0x410]
xor edx, edx
call fcn.0040a838
test al, al
jne 0x487e3d
lea ecx, [edi + 0xa35]
push ecx
lea eax, [ebp - 0x410]
push eax
call fcn.00498e7c
add esp, 8
mov eax, 0x4bf940
call fcn.0040be48
push eax
lea edx, [ebp - 0x410]
push edx
call fcn.00498da0
add esp, 8
inc esi
push 0x400
lea ecx, [ebp - 0x1810]
lea edx, [ebp - 0x1010]
mov eax, dword [ebp - 4]
call fcn.0040fff4
test al, al
je 0x487e68
cmp dword [0x4c989c], 0
je 0x487b6e
test esi, esi
jne 0x487e7d
cmp dword [ebp - 0xc], 0
jne 0x487e7d
push dword [0x4c6ef8]
call sub.USER32.DLL_DestroyWindow
cmp dword [ebp - 8], 0
jne 0x487ea6
push 0x30
mov eax, 0x65
call fcn.004129c8
push eax
mov eax, 0x14c
call fcn.004129c8
push eax
push dword [0x4c6eec]
call sub.USER32.DLL_MessageBoxA
cmp dword [0x4c6ef8], 0
je 0x487ed8
cmp dword [0x4c989c], 0
je 0x487ec4
mov eax, 0x271
call fcn.004129c8
jmp 0x487ece
mov eax, 0x270
call fcn.004129c8
call fcn.004755b8
call fcn.0047565c
cmp dword [0x4c988c], 0
jne 0x487f06
lea eax, [ebp - 0x410]
xor edx, edx
call fcn.0040a838
test al, al
je 0x487efa
lea edx, [ebp - 0x410]
jmp 0x487efc
xor edx, edx
mov eax, 0x4c6f00
call fcn.0045905c
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret