Function at 0x4053b6
Capabilities:
Get common file path
Query environment variable

Disassembly:
push ebx
push ecx
push ebp
push esi
push edi
mov esi, esp
sub esp, 0x74
mov eax, esp
mov edx, eax
add edx, 0x74
mov dword [eax], 0
add eax, 4
cmp eax, edx
jne 0x4053c7
mov edx, dword [esi + 0x18]
lea ecx, [esp]
call fcn.0040b7b1
push dword [0x4122f4]
mov eax, dword [0x4151c8]
call fcn.004161d0
lea ecx, [esp + 8]
pop edx
call fcn.0040b744
push dword [0x4122f4]
mov eax, dword [0x4151cc]
call fcn.004161d0
lea ecx, [esp + 0xc]
pop edx
call fcn.0040b744
mov edx, dword [esp + 4]
xor ecx, ecx
call fcn.0040b828
jne 0x4059c9
push dword [esp + 4]
mov edx, dword [0x4152dc]
pop ecx
call fcn.0040b828
jne 0x4059c7
push dword [esp + 8]
call fcn.0040dda0
push dword [esp]
call fcn.0040dda0
fcompp
fnstsw ax
test ah, 0x41
je 0x4059a8
push 0x3e7
call fcn.00404e72
push dword [0x4122f4]
mov ebx, dword [esp + 0x14]
add ebx, 0x63
mov eax, ebx
call fcn.0040aeab
push dword [0x4122f4]
mov ebx, dword [esp + 0x1c]
add ebx, 0x6f
mov eax, ebx
call fcn.0040aeab
pop eax
push dword [0x4122f4]
mov ebx, dword [esp + 0x20]
add ebx, 0x6d
mov eax, ebx
call fcn.0040aeab
pop eax
push dword [0x4122f4]
mov ebx, dword [esp + 0x18]
add ebx, 0x73
mov eax, ebx
call fcn.0040aeab
pop eax
push dword [0x4122f4]
mov ebx, dword [esp + 0x20]
add ebx, 0x70
mov eax, ebx
call fcn.0040aeab
pop eax
push dword [0x4122f4]
mov ebx, dword [esp + 0x24]
add ebx, 0x65
mov eax, ebx
call fcn.0040aeab
pop eax
push dword [0x4122f4]
mov ebx, dword [esp + 0x28]
add ebx, 0x63
mov eax, ebx
call fcn.0040aeab
pop eax
lea ecx, [esp + 0x10]
pop edx
call fcn.0040b744
push dword [0x4122f4]
mov eax, 0xff
call fcn.0040b23b
lea ecx, [esp + 0x28]
pop edx
call fcn.0040b744
push 0xff
push dword [esp + 0x28]
push dword [esp + 0x14]
call sub.KERNEL32.DLL_GetEnvironmentVariableA
push dword [0x4122f4]
mov eax, 0xff
call fcn.0040b23b
lea ecx, [esp + 0x2c]
pop edx
call fcn.0040b744
push dword [esp + 0x28]
push 0xff
call sub.KERNEL32.DLL_GetCurrentDirectoryA
push dword [0x4122f4]
push 1
mov eax, dword [esp + 0x30]
call fcn.0040b055
inc dword [0x4122f4]
mov edx, 0x412010
pop ecx
mov dword [0x4122f4], ecx
call fcn.0040b828
jne 0x4055a2
mov edx, dword [esp + 0x28]
push dword [0x4122f4]
call fcn.0040b7f0
mov edx, 0x412010
call fcn.0040b7f0
lea ecx, [esp + 0x2c]
pop edx
call fcn.0040b744
push dword [0x4122f4]
mov eax, 0xff
call fcn.0040b23b
lea ecx, [esp + 0x30]
pop edx
call fcn.0040b744
push 0xff
push dword [esp + 0x30]
push 0
call sub.KERNEL32.DLL_GetModuleFileNameA
push dword [0x4122f4]
push dword [esp + 0x30]
call fcn.0040e0b0
lea ecx, [esp + 0x34]
pop edx
call fcn.0040b744
push dword [0x4122f4]
mov ebx, dword [esp + 0x3c]
add ebx, 0xd6
mov eax, ebx
call fcn.0040aeab
push dword [0x4122f4]
mov ebx, dword [esp + 0x44]
add ebx, 0xe1
mov eax, ebx
call fcn.0040aeab
pop eax
push dword [0x4122f4]
mov ebx, dword [esp + 0x48]
add ebx, 0xd6
mov eax, ebx
call fcn.0040aeab
pop eax
push dword [0x4122f4]
mov ebx, dword [esp + 0x4c]
add ebx, 0xe0
mov eax, ebx
call fcn.0040aeab
pop eax
push dword [0x4122f4]
mov ebx, dword [esp + 0x50]
add ebx, 0xd8
mov eax, ebx
call fcn.0040aeab
pop eax
push dword [0x4122f4]
mov ebx, dword [esp + 0x54]
add ebx, 0xd7
mov eax, ebx
call fcn.0040aeab
pop eax
push dword [0x4122f4]
mov ebx, dword [esp + 0x58]
add ebx, 0xde
mov eax, ebx
call fcn.0040aeab
pop eax
push dword [0x4122f4]
mov ebx, dword [esp + 0x5c]
add ebx, 0xd8
mov eax, ebx
call fcn.0040aeab
pop eax
push dword [0x4122f4]
mov ebx, dword [esp + 0x60]
add ebx, 0xe0
mov eax, ebx
call fcn.0040aeab
pop eax
push dword [0x4122f4]
mov ebx, dword [esp + 0x58]
add ebx, 0xe1
mov eax, ebx
call fcn.0040aeab
pop eax
push dword [0x4122f4]
mov ebx, dword [esp + 0x50]
add ebx, 0x95
mov eax, ebx
call fcn.0040aeab
pop eax
push dword [0x4122f4]
mov ebx, dword [esp + 0x54]
add ebx, 0xa2
mov eax, ebx
call fcn.0040aeab
pop eax
push dword [0x4122f4]
mov ebx, dword [esp + 0x40]
add ebx, 0xd6
mov eax, ebx
call fcn.0040aeab
pop eax
push dword [0x4122f4]
mov ebx, dword [esp + 0x50]
add ebx, 0x93
mov eax, ebx
call fcn.0040aeab
pop eax
push dword [0x4122f4]
mov ebx, dword [esp + 0x64]
add ebx, 0xd7
mov eax, ebx
call fcn.0040aeab
pop eax
push dword [0x4122f4]
mov ebx, dword [esp + 0x48]
add ebx, 0xd8
mov eax, ebx
call fcn.0040aeab
pop eax
push dword [0x4122f4]
mov ebx, dword [esp + 0x60]
add ebx, 0xdf
mov eax, ebx
call fcn.0040aeab
pop eax
push dword [0x4122f4]
mov ebx, dword [esp + 0x64]
add ebx, 0x93
mov eax, ebx
call fcn.0040aeab
pop eax
push dword [0x4122f4]
mov ebx, dword [esp + 0x68]
add ebx, 0x95
mov eax, ebx
call fcn.0040aeab
pop eax
push dword [0x4122f4]
mov ebx, dword [esp + 0x5c]
add ebx, 0xe1
mov eax, ebx
call fcn.0040aeab
pop eax
push dword [0x4122f4]
mov ebx, dword [esp + 0x4c]
add ebx, 0xdd
mov eax, ebx
call fcn.0040aeab
pop eax
push dword [0x4122f4]
mov ebx, dword [esp + 0x58]
add ebx, 0xeb
mov eax, ebx
call fcn.0040aeab
pop eax
push dword [0x4122f4]
mov ebx, dword [esp + 0x48]
add ebx, 0xdb
mov eax, ebx
call fcn.0040aeab
pop eax
push dword [0x4122f4]
mov ebx, dword [esp + 0x54]
add ebx, 0xd4
mov eax, ebx
call fcn.0040aeab
pop eax
push dword [0x4122f4]
mov ebx, dword [esp + 0x48]
add ebx, 0xe2
mov eax, ebx
call fcn.0040aeab
pop eax
push dword [0x4122f4]
mov ebx, dword [esp + 0x44]
add ebx, 0xe0
mov eax, ebx
call fcn.0040aeab
pop eax
push dword [0x4122f4]
mov ebx, dword [esp + 0x64]
add ebx, 0xd4
mov eax, ebx
call fcn.0040aeab
pop eax
push dword [0x4122f4]
mov ebx, dword [esp + 0x44]
add ebx, 0xd9
mov eax, ebx
call fcn.0040aeab
pop eax
lea ecx, [esp + 0x38]
pop edx
call fcn.0040b744
push dword [0x4122f4]
push 9
push 0xb
mov eax, dword [esp + 0x40]
call fcn.0040affd
lea ecx, [esp + 0x68]
pop edx
call fcn.0040b744
mov edx, 0x41224b
lea ecx, [esp + 0x34]
call fcn.0040b790
mov dword [esp + 0x68], 1
mov eax, dword [esp + 0x64]
call fcn.0040afe7
cmp eax, dword [esp + 0x68]
jl 0x405936
push dword [0x4122f4]
push 1
push dword [esp + 0x70]
mov eax, dword [esp + 0x70]
call fcn.0040affd
lea ecx, [esp + 0x70]
pop edx
call fcn.0040b744
mov edx, dword [esp + 0x34]
push dword [0x4122f4]
call fcn.0040b7f0
push dword [0x4122f4]
mov eax, dword [esp + 0x74]
call fcn.0040aea0
mov ebx, eax
add ebx, 0xffffff8d
mov eax, ebx
call fcn.0040aeab
pop eax
lea ecx, [esp + 0x38]
pop edx
call fcn.0040b744
inc dword [esp + 0x68]
jmp 0x4058ca
mov edx, dword [esp + 0x34]
lea ecx, [esp + 0x64]
call fcn.0040b790
push dword [0x4122f4]
push 2
push 0x41224b
mov edx, dword [esp + 0x70]
push dword [0x4122f4]
call fcn.0040b7f0
mov edx, 0x412251
call fcn.0040b7f0
mov edx, dword [esp + 0x38]
call fcn.0040b7f0
mov edx, dword [esp + 0x40]
call fcn.0040b7f0
mov edx, 0x412251
call fcn.0040b7f0
inc dword [0x4122f4]
push dword [esp + 0x34]
call fcn.0040e130
pop dword [0x4122f4]
mov dword [esp + 0x70], eax
jmp 0x40ae60
push dword [0x4152dc]
mov eax, dword [0x4151c8]
call fcn.00416200
push dword [esp]
mov eax, dword [0x4151cc]
call fcn.00416200
jmp 0x4059c7
jmp 0x4059e6
push dword [0x4152dc]
mov eax, dword [0x4151c8]
call fcn.00416200
push dword [esp]
mov eax, dword [0x4151cc]
call fcn.00416200
xor eax, eax
mov edx, dword [esp + 0x64]
call fcn.0040b810
mov edx, dword [esp + 0xc]
call fcn.0040b810
mov edx, dword [esp + 0x24]
call fcn.0040b810
mov edx, dword [esp + 0x28]
call fcn.0040b810
mov edx, dword [esp + 4]
call fcn.0040b810
mov edx, dword [esp + 8]
call fcn.0040b810
mov edx, dword [esp + 0x30]
call fcn.0040b810
mov edx, dword [esp + 0x2c]
call fcn.0040b810
mov edx, dword [esp + 0x6c]
call fcn.0040b810
mov edx, dword [esp + 0x34]
call fcn.0040b810
mov edx, dword [esp]
call fcn.0040b810
add esp, 0x74
pop edi
pop esi
pop ebp
pop ecx
pop ebx
ret 4